<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	>

<channel>
	<title>Axant Tech Blog</title>
	<atom:link href="http://blog.axant.it/feed" rel="self" type="application/rss+xml" />
	<link>http://blog.axant.it</link>
	<description>AXANT Experience Report</description>
	<pubDate>Wed, 28 Jul 2010 22:41:07 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.6</generator>
	<language>en</language>
	<xhtml:meta xmlns:xhtml="http://www.w3.org/1999/xhtml" name="robots" content="noindex" />
		<item>
		<title>Patched TG2 bootstrap script for python 2.6</title>
		<link>http://blog.axant.it/archives/294</link>
		<comments>http://blog.axant.it/archives/294#comments</comments>
		<pubDate>Wed, 28 Jul 2010 22:41:07 +0000</pubDate>
		<dc:creator>amol</dc:creator>
		
		<category><![CDATA[Uncategorized]]></category>

		<category><![CDATA[turbogears]]></category>

		<guid isPermaLink="false">http://blog.axant.it/?p=294</guid>
		<description><![CDATA[As actually I end up installing Tg2 on various systems having python2.6 quite often I have patched the bootstrap script to work on it.
If you had problems installing TG2 on python2.6 failing on Extremes or Zope dependencies you can try to use this script, it should work for you:
https://bitbucket.org/_amol_/tg-bootstrap-py2.6/src/tip/tg2-bootstrap.py
]]></description>
			<content:encoded><![CDATA[<p>As actually I end up installing Tg2 on various systems having python2.6 quite often I have patched the bootstrap script to work on it.</p>
<p>If you had problems installing TG2 on python2.6 failing on Extremes or Zope dependencies you can try to use this script, it should work for you:</p>
<p><a href="https://bitbucket.org/_amol_/tg-bootstrap-py2.6/src/tip/tg2-bootstrap.py">https://bitbucket.org/_amol_/tg-bootstrap-py2.6/src/tip/tg2-bootstrap.py</a></p>
]]></content:encoded>
			<wfw:commentRss>http://blog.axant.it/archives/294/feed</wfw:commentRss>
		</item>
		<item>
		<title>libacr published on PyPI</title>
		<link>http://blog.axant.it/archives/291</link>
		<comments>http://blog.axant.it/archives/291#comments</comments>
		<pubDate>Wed, 28 Jul 2010 08:51:00 +0000</pubDate>
		<dc:creator>puria</dc:creator>
		
		<category><![CDATA[Computer Science]]></category>

		<category><![CDATA[Opensource]]></category>

		<category><![CDATA[Software Development]]></category>

		<category><![CDATA[Web]]></category>

		<category><![CDATA[acr]]></category>

		<category><![CDATA[libacr]]></category>

		<category><![CDATA[pypi]]></category>

		<category><![CDATA[python]]></category>

		<guid isPermaLink="false">http://blog.axant.it/?p=291</guid>
		<description><![CDATA[As we are moving to make libacr a very cool and functional python CMF, we published libacr on PyPI!
Now you just need to:

pip install libacr

and you are done, as easy as saying!
More details on http://pypi.python.org/pypi/libacr/
]]></description>
			<content:encoded><![CDATA[<p>As we are moving to make <a href="http://www.axantlabs.com/libacr">libacr</a> a very cool and functional python <a href="http://en.wikipedia.org/wiki/List_of_content_management_frameworks">CMF</a>, we published libacr on <a href="http://pypi.python.org/pypi">PyPI</a>!</p>
<p>Now you just need to:</p>

<div class="wp_syntax"><div class="code"><pre class="python" style="font-family:monospace;">pip install libacr</pre></div></div>

<p>and you are done, as easy as saying!</p>
<p>More details on <a href="http://pypi.python.org/pypi/libacr/">http://pypi.python.org/pypi/libacr/</a></p>
]]></content:encoded>
			<wfw:commentRss>http://blog.axant.it/archives/291/feed</wfw:commentRss>
		</item>
		<item>
		<title>ACR plugins and themes</title>
		<link>http://blog.axant.it/archives/289</link>
		<comments>http://blog.axant.it/archives/289#comments</comments>
		<pubDate>Tue, 27 Jul 2010 16:29:12 +0000</pubDate>
		<dc:creator>amol</dc:creator>
		
		<category><![CDATA[Opensource]]></category>

		<category><![CDATA[acr]]></category>

		<guid isPermaLink="false">http://blog.axant.it/?p=289</guid>
		<description><![CDATA[Recently we decided to move our Turbogears 2 CMS, ACRCMS, from an example of how to use libacr to something more complete. Consequently to this decision we implemented the plugins architecture inside libacr, which permits to add plugins to libacr at run-time.
Until now there were no real plugins, the only available plugins were the three [...]]]></description>
			<content:encoded><![CDATA[<p>Recently we decided to move our Turbogears 2 CMS, ACRCMS, from an example of how to use <a href="http://www.axantlabs.com/libacr">libacr</a> to something more complete. Consequently to this decision we implemented the plugins architecture inside libacr, which permits to add plugins to libacr at run-time.</p>
<p>Until now there were no real plugins, the only available plugins were the three acr slice templates which have been moved from an internal function to a plugin.</p>
<p>Today the first real plugin for ACR has been pushed in a separate branch, the plugin is the Theme engine, which permits to add theme support to ACR. The plugin is available inside the ACRCMS acr_plugins directory and is now loaded by default by ACRCMS, it will be officially part of ACRCMS in the next release.</p>
<p>We decided to distribute it with ACRCMS instead of libacr as we felt that theme management is a function deserved to a <a href="http://en.wikipedia.org/wiki/Content_management_system">CMS</a>, not to a <a href="http://en.wikipedia.org/wiki/List_of_content_management_frameworks">CMF</a>.</p>
<p>For now you can test it from the <em>themable</em> branch of <a href="http://www.axantlabs.com/libacr">ACR</a></p>
]]></content:encoded>
			<wfw:commentRss>http://blog.axant.it/archives/289/feed</wfw:commentRss>
		</item>
		<item>
		<title>GCC using C++</title>
		<link>http://blog.axant.it/archives/286</link>
		<comments>http://blog.axant.it/archives/286#comments</comments>
		<pubDate>Mon, 31 May 2010 16:55:43 +0000</pubDate>
		<dc:creator>lu_zero</dc:creator>
		
		<category><![CDATA[Opensource]]></category>

		<category><![CDATA[Software Development]]></category>

		<category><![CDATA[C++]]></category>

		<category><![CDATA[gcc]]></category>

		<guid isPermaLink="false">http://blog.axant.it/?p=286</guid>
		<description><![CDATA[I got this news http://gcc.gnu.org/ml/gcc/2010-05/msg00705.html and it puzzled me a bit: you have the system C compiler depending on C++, making in fact it no more self hosting.
That alone makes me thing whoever decided and whoever requested that is next to suicidal. GCC is known for having _quite_ a shaky C++ standard library AND ABI, [...]]]></description>
			<content:encoded><![CDATA[<p>I got this news http://gcc.gnu.org/ml/gcc/2010-05/msg00705.html and it puzzled me a bit: you have the system C compiler depending on C++, making in fact it no more self hosting.</p>
<p>That alone makes me thing whoever decided and whoever requested that is next to suicidal. GCC is known for having _quite_ a shaky C++ standard library AND ABI, as in having at least an incompatibility every major version and sometimes even with minor ones.</p>
<p>I do dislike C++ usage mostly on this basis, let alone the fact is a language overly large, with not enough people dabbling it properly, let alone being proficient.</p>
<p>There are already compilers using C++, one that many people find interesting is llvm. It doesn&#8217;t aim to be a system compiler and it&#8217;s not exactly self hosting.</p>
<p>Many already stated that would switch to llvm clang front-end once it reaches full maturity (now freebsd proved that this level has been pretty well archived), I didn&#8217;t consider to fully switch to it just because it concerned me the fact it depends on C++ and how easy is to have subtle yet major breakages in that language implementations.</p>
<p>llvm people look to me way more capable of managing C++ than GCC ones and I saluted with please the fact they already have a libc++ implementation.</p>
<p>Back about being suicidal, if I have to pick between people that did well on C++ and people that botched many time on the same field, who would I pick?</p>
<p>The current discussions in the GCC mailing list are about C++ coding style, which features to pick and which to forbid, rearchitecture the whole beast to use a &#8220;proper&#8221; hierarchy and such, basically some/(many?) want to redo everything with the new toy. That makes me think again that llvm will be a better target for the next months/year.</p>
<p>I hope there are enough GCC developers and/or concerned party that will fork gcc now and keep a C branch. Probably having a radical cleanup and refactor is a completely orthogonal issue and should be done no matter they&#8217;ll pick C++ or C as their implementation language, GCC has lots of cruft, starting from their bad usage of the autotools.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.axant.it/archives/286/feed</wfw:commentRss>
		</item>
		<item>
		<title>Mercurial &#8220;git grep&#8221; equivalent extension</title>
		<link>http://blog.axant.it/archives/283</link>
		<comments>http://blog.axant.it/archives/283#comments</comments>
		<pubDate>Thu, 06 May 2010 12:12:27 +0000</pubDate>
		<dc:creator>amol</dc:creator>
		
		<category><![CDATA[Computer Science]]></category>

		<category><![CDATA[git]]></category>

		<category><![CDATA[mercurial]]></category>

		<guid isPermaLink="false">http://blog.axant.it/?p=283</guid>
		<description><![CDATA[As we are used to git when working on mercurial we miss a lot the &#8220;git grep&#8221; command as &#8220;hg grep&#8221; doesn&#8217;t really do the same thing. So we managed to quickly create a mercurial extension to add the hgrep command to hg which behaves a bit like git grep.

import itertools, os, os.path
&#160;
def hgrep&#40;ui, repo, [...]]]></description>
			<content:encoded><![CDATA[<p>As we are used to <a href="http://git-scm.com/">git</a> when working on <a href="http://mercurial.selenic.com/">mercurial</a> we miss a lot the &#8220;<em>git grep</em>&#8221; command as &#8220;<em>hg grep</em>&#8221; doesn&#8217;t really do the same thing. So we managed to quickly create a mercurial extension to add the <strong>hgrep</strong> command to hg which behaves a bit like git grep.</p>

<div class="wp_syntax"><div class="code"><pre class="python" style="font-family:monospace;"><span style="color: #ff7700;font-weight:bold;">import</span> <span style="color: #dc143c;">itertools</span>, <span style="color: #dc143c;">os</span>, <span style="color: #dc143c;">os</span>.<span style="color: black;">path</span>
&nbsp;
<span style="color: #ff7700;font-weight:bold;">def</span> hgrep<span style="color: black;">&#40;</span>ui, repo, what, <span style="color: #66cc66;">**</span>opts<span style="color: black;">&#41;</span>:
    files = <span style="color: black;">&#91;</span><span style="color: black;">&#93;</span>
    status = repo.<span style="color: black;">status</span><span style="color: black;">&#40;</span>clean=<span style="color: #008000;">True</span><span style="color: black;">&#41;</span>
&nbsp;
    <span style="color: #ff7700;font-weight:bold;">for</span> f <span style="color: #ff7700;font-weight:bold;">in</span> <span style="color: #dc143c;">itertools</span>.<span style="color: black;">chain</span><span style="color: black;">&#40;</span>status<span style="color: black;">&#91;</span><span style="color: #ff4500;">0</span><span style="color: black;">&#93;</span>, status<span style="color: black;">&#91;</span><span style="color: #ff4500;">1</span><span style="color: black;">&#93;</span>, status<span style="color: black;">&#91;</span><span style="color: #ff4500;">4</span><span style="color: black;">&#93;</span>, status<span style="color: black;">&#91;</span><span style="color: #ff4500;">6</span><span style="color: black;">&#93;</span><span style="color: black;">&#41;</span>:
        files.<span style="color: black;">append</span><span style="color: black;">&#40;</span><span style="color: #dc143c;">os</span>.<span style="color: black;">path</span>.<span style="color: black;">join</span><span style="color: black;">&#40;</span>repo.<span style="color: black;">root</span>, f<span style="color: black;">&#41;</span><span style="color: black;">&#41;</span>
&nbsp;
    <span style="color: #dc143c;">os</span>.<span style="color: black;">system</span><span style="color: black;">&#40;</span><span style="color: #483d8b;">&quot;grep %s %s&quot;</span> <span style="color: #66cc66;">%</span> <span style="color: black;">&#40;</span>what, <span style="color: #483d8b;">' '</span>.<span style="color: black;">join</span><span style="color: black;">&#40;</span>files<span style="color: black;">&#41;</span><span style="color: black;">&#41;</span><span style="color: black;">&#41;</span>
&nbsp;
cmdtable = <span style="color: black;">&#123;</span><span style="color: #483d8b;">&quot;hgrep&quot;</span>: <span style="color: black;">&#40;</span>hgrep, <span style="color: black;">&#91;</span><span style="color: black;">&#93;</span>, <span style="color: #483d8b;">&quot;[what]&quot;</span><span style="color: black;">&#41;</span><span style="color: black;">&#125;</span></pre></div></div>

<p>To have the &#8220;<strong>hg hgrep</strong>&#8221; command and make it work just save it as <strong>hgrep.py</strong> in your python modules path and add it to <strong>~/.hgrc</strong> inside the extensions section like:</p>
<pre>
[extensions]
hgrep =
</pre>
<p>Then you will be able to run &#8220;<em>hg grep what</em>&#8221; inside a mercurial repository and it will find each file at its current state that contains what you were looking for giving you the complete absolute path to the file.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.axant.it/archives/283/feed</wfw:commentRss>
		</item>
		<item>
		<title>Ogg vs World (as picked up from Slashdot)</title>
		<link>http://blog.axant.it/archives/278</link>
		<comments>http://blog.axant.it/archives/278#comments</comments>
		<pubDate>Wed, 28 Apr 2010 09:46:03 +0000</pubDate>
		<dc:creator>lu_zero</dc:creator>
		
		<category><![CDATA[Multimedia]]></category>

		<category><![CDATA[Opensource]]></category>

		<category><![CDATA[mkv]]></category>

		<category><![CDATA[nut]]></category>

		<category><![CDATA[ogg]]></category>

		<category><![CDATA[rants]]></category>

		<guid isPermaLink="false">http://blog.axant.it/?p=278</guid>
		<description><![CDATA[Ogg had been discussed a lot lately. Having messed a bit with it and having felt the pain about dabbling with it and with vorbis and theora probably I could chip in.
I said &#8220;a pain&#8221;, quite subjective and I think the term summarizes my overall experience with it. If that&#8217;s because it is &#8220;different&#8221;, &#8220;undocumented&#8221; [...]]]></description>
			<content:encoded><![CDATA[<p>Ogg had been <a title="Objections" href="http://hardwarebug.org/2010/03/03/ogg-objections/">discussed</a> <a title="Ogg Defense" href="http://people.xiph.org/~xiphmont/lj-pseudocut/o-response-1.html">a lot</a> lately. Having messed a bit with it and having felt the pain about dabbling with it and with <a title="Vorbis RTP" href="http://tools.ietf.org/html/rfc5215">vorbis</a> and theora probably I could chip in.</p>
<p>I said &#8220;a pain&#8221;, quite subjective and I think the term summarizes my overall experience with it. If that&#8217;s because it is &#8220;different&#8221;, &#8220;undocumented&#8221; or just &#8220;bad&#8221; is left to you readers to decide. Even messing with NUT hadn&#8217;t been this painful and NUT is anything but mature. Now let&#8217;s go back digressing about Ogg. Mans stated what he dislikes and why, Monty defended his format stated that his next container format will address some of shortcomings he agrees are present in Ogg. Both defense and criticism are quite technical, I&#8217;ll try to say why I think Ogg, as is, should not considered a savior using more down to earth arguments.</p>
<h1>Tin cans, class jars, plastic bottles&#8230; Containers!</h1>
<p>Lets think about something solid and real. If you consider a container format and a real life storage you might see some similarities:</p>
<ul>
<li>Usually you&#8217;d like the container to be robust so it won&#8217;t break if it falls</li>
<li>You&#8217;d like to be able to know which is its content w/out having to open it</li>
<li>You&#8217;d prefer if weight as less as possible if you are going to bring it around</li>
<li>You&#8217;d like to be able to open and close it with minor hassle.</li>
<li>If it has compartments you&#8217;d like that those won&#8217;t break and that picking and telling apart what it contains as easier as possible.</li>
</ul>
<p>There could be other points but I think those are enough. Now let&#8217;s see why there are people that dislike Ogg using those 5 points: robustness, transparency, overhead, accessibility and seekability</p>
<h2>Robustness</h2>
<p>I think Ogg is doing fine about robustness, the other containers are fine as well in my opinion.</p>
<h2>Transparency</h2>
<p>In this case the heading is a bit strange so let me explain what I mean. If you think about a tin can or a glass jar usually you can figure out better what&#8217;s in a transparent container than in an opaque one, obviously you can have labels with useful information. Usually you feel better if you can figure out some details about the content of a can even if you don&#8217;t know how to cook it.</p>
<p>In Ogg in order to get lots of data that the other containers provide as is you need to know some intimate details about the codec muxed in. &#8220;What&#8217;s the point of knowing them if I&#8217;m not able to decode it?&#8221; is an objection I saw raised on Slashdot comments. Well, what if you do not want to DECODE it but just give information or serve it in different way, you know <a href="http://en.wikipedia.org/wiki/Real-time_Transport_Protocol">actual streaming</a> ー not solutions based on HTTP ー? (e.g <a title="Feng Streaming Server" href="http://lscube.org/feng">Feng</a> and <a title="Darwin Streaming Server" href="http://dss.macosforge.org/">DSS</a> to name a couple).</p>
<h2>Overhead</h2>
<p>People likes plastic bottles over glass ones since the latter are heavier. When you move and store them that&#8217;s an actual concern.</p>
<p>Monty states that Ogg with a recent implementation of the muxer (libogg 1.2) the overhead in Ogg is about 0.6-0.7%, Mans states that it ranges between 0.4% and 1% usually nearer to the 1% than the 0.4%. So in my opinion they agree. How does that value fares with other containers? Mans states that the ISO mp4 container can easily archive about a tenth of the Ogg overhead. Monty went rambling about lots of different container stating some depressing numbers and discussing about random access on remote storage over HTTP and other protocols that <strong>are not meant</strong> for that.</p>
<p>I think that&#8217;s a large degree for improvement, or at least some benchmarking are required to see how that is true or false.</p>
<h2>Accessibility</h2>
<p>As in &#8220;which tool I need to use them?&#8221;. Ogg has some implementations, some even in hardware, Mans states that in some situations (e.g. embedded/minimalistic platform) isn&#8217;t the best choice. Monty states that similar problems would be there also for the other containers.</p>
<p>As I stated before in order to be able to process an Ogg you need to be able to decode or at least have a knowledge of the codec that nears the ability to fully decode. That means that you cannot do some kind of processing that in other containers doesn&#8217;t require such quantity of code and, to a degree, such CPU resources. Being able to do a streamcopy or to pick just a range among a content shouldn&#8217;t require decoding ability, those features are quite nice when you do actual streaming.</p>
<h2>Seekability</h2>
<p>Mans thinks the Ogg ability to move to a random offset within the media has a great degree of issues some related to the mentioned before requirement to know a lot about the codec inside the container other due the strategy in use to actually find the requested offset within the file. Monty goes again rambling about access remote files using HTTP and on how the other containers aren&#8217;t that better. The Slashdot article is already full of people stating that they DO feel seeking in Ogg SLOW, no matter the player and kills Monty arguments alone.</p>
<h1>In the end</h1>
<p>Obviously nothing is perfect and everything is perfectible. I do <strong>not like</strong> Ogg, I&#8217;m not afraid to state it.</p>
<p>Quite often you get labeled as &#8220;evil&#8221; if you state that or, god forbid, say that Theora isn&#8217;t good enough and maybe if you are that concerned about patents mpeg1 is the way to go since the patents are expired.</p>
<p>I&#8217;m quite happy with mkv and mov, probably I&#8217;ll use NUT more if/once it will get more spin and community. I&#8217;ll watch with curiosity how transOgg will evolve.</p>
<p>PS: I liked a lot this <a href="http://news.slashdot.org/story/10/04/27/1953234/Ogg-Format-Accusations-Refuted">comment</a>, Monty do your homework better =P</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.axant.it/archives/278/feed</wfw:commentRss>
		</item>
		<item>
		<title>VideoLAN Web Plugin: xpi vs crx</title>
		<link>http://blog.axant.it/archives/259</link>
		<comments>http://blog.axant.it/archives/259#comments</comments>
		<pubDate>Mon, 26 Apr 2010 23:14:16 +0000</pubDate>
		<dc:creator>lu_zero</dc:creator>
		
		<category><![CDATA[Hardware]]></category>

		<category><![CDATA[Opensource]]></category>

		<category><![CDATA[Software Development]]></category>

		<category><![CDATA[Uncategorized]]></category>

		<category><![CDATA[Web]]></category>

		<category><![CDATA[chrome]]></category>

		<category><![CDATA[crx]]></category>

		<category><![CDATA[firefox]]></category>

		<category><![CDATA[VLC]]></category>

		<category><![CDATA[xpi]]></category>

		<guid isPermaLink="false">http://blog.axant.it/?p=259</guid>
		<description><![CDATA[One of the main issue while preparing streaming solution is answering the obnoxious question:

Question: Is possible to use the service through a browser?
Answer: No, rtsp isn&#8217;t* http, a browser isn&#8217;t a tool for accessing any network content.
* Actually would be neat having rtsp support within the video tag but that&#8217;s yet another large can of [...]]]></description>
			<content:encoded><![CDATA[<p>One of the main issue while preparing streaming solution is answering the obnoxious question:</p>
<ul>
<li>Question: Is possible to use the service through a browser?</li>
<li>Answer: No, rtsp isn&#8217;t* http, a browser isn&#8217;t a tool for accessing any network content.</li>
<p><small>* Actually would be neat having rtsp support within the video tag but that&#8217;s yet another large can of worms</small></ul>
<p>Once you say that you have half of your audience leaving. Non technical people is too much used to consider the browser the one and only key to internet. The remaining ones will ask something along those lines:</p>
<ul>
<li>Question: My target user is <s style="color:#336688">a complete idiot</s><s style="color:#886633">technically impaired</s>naive and unaccustomed and could not be confronted with the hassle of a complex installation procedure, is there something that fits the bill?</li>
<li>Answer: VideoLAN Web Plugin</li>
</ul>
<p>Usually that makes some people happy since it&#8217;s something they actually know or at least they have heard about. Some might start complaining since they experienced an old version and well it crashed a lot. What would you be beware of is the following one:</p>
<ul>
<li>Question: Actually I need to install the VideoLAN Web Plugin and it requires attention, isn&#8217;t there a quicker route?</li>
<li>Answer: Yes xpi an crx for Firefox an Chrome</li>
</ul>
<p>Ok, that answer is more or less from the future and it&#8217;s the main subject of this post: Seamless bundling something as big and complex as vlc and make our non tecnical and naive target user happy.</p>
<p>I picked the VideoLAN web plugin since it is actually quite good already, has a nice javascript interface to let you do _lots_ of nice stuff and there are people actually working on it. Additional points since it is available on windows and MacOSX. Some time ago I investigated how to use the extension facility of firefox to have the fabled &#8220;one click&#8221; install. The current way is quite straightforward and has already landed in the <a title="VLC xpi bundle patch" href="http://git.videolan.org/?p=vlc.git;a=commit;h=33cb9ae7d1a34614445a6dc66f76fc8e6c99470e">vlc git tree</a> for the curious and lazy:</p>

<div class="wp_syntax"><div class="code"><pre class="xml" style="font-family:monospace;"><span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;RDF</span> <span style="color: #000066;">xmlns</span>=<span style="color: #ff0000;">&quot;http://www.w3.org/1999/02/22-rdf-syntax-ns#&quot;</span> <span style="color: #000066;">xmlns:em</span>=<span style="color: #ff0000;">&quot;http://www.mozilla.org/2004/em-rdf#&quot;</span><span style="color: #000000; font-weight: bold;">&gt;</span></span>
  <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;Description</span> <span style="color: #000066;">about</span>=<span style="color: #ff0000;">&quot;urn:mozilla:install-manifest&quot;</span><span style="color: #000000; font-weight: bold;">&gt;</span></span>
    <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;em:id<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>vlc-plugin@videolan.org<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/em:id<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>
    <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;em:name<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>VideoLAN<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/em:name<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>
    <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;em:version<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>1.2.0-git<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/em:version<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>
    <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;em:targetApplication<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>
      <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;Description<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>
        <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;em:id<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>{ec8030f7-c20a-464f-9b0e-13a3a9e97384}<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/em:id<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>
        <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;em:minVersion<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>1.5<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/em:minVersion<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>
        <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;em:maxVersion<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>3.6.*<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/em:maxVersion<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>
      <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/Description<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>
    <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/em:targetApplication<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>
  <span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/Description<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>
<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/RDF<span style="color: #000000; font-weight: bold;">&gt;</span></span></span></pre></div></div>

<p>Putting that as <a title="Install Manifests" href="https://developer.mozilla.org/en/Install_Manifests">install.rdf </a>in a zip containing a directory called plugins with libvlc, it&#8217;s modules and obviously the npapi plugin does the trick quite well.</p>
<p>Chrome now has <a title="Chrome Extensions Overview" href="http://code.google.com/chrome/extensions/overview.html">something similar</a> and it seems also <a title="npapi bundling" href="http://code.google.com/chrome/extensions/npapi.html">easier</a> so that&#8217;s what I put in the <a title="Manifest File" href="http://code.google.com/chrome/extensions/manifest.html">manifest.json</a>:</p>

<div class="wp_syntax"><div class="code"><pre class="javascript" style="font-family:monospace;"><span style="color: #009900;">&#123;</span>
<span style="color: #3366CC;">&quot;name&quot;</span><span style="color: #339933;">:</span> <span style="color: #3366CC;">&quot;VideoLAN&quot;</span><span style="color: #339933;">,</span>
<span style="color: #3366CC;">&quot;version&quot;</span><span style="color: #339933;">:</span> <span style="color: #3366CC;">&quot;1.2.0.99&quot;</span><span style="color: #339933;">,</span>
<span style="color: #3366CC;">&quot;description&quot;</span><span style="color: #339933;">:</span> <span style="color: #3366CC;">&quot;VideoLan Web Plugin Bundle&quot;</span><span style="color: #339933;">,</span>
<span style="color: #3366CC;">&quot;plugins&quot;</span><span style="color: #339933;">:</span> <span style="color: #009900;">&#91;</span><span style="color: #009900;">&#123;</span><span style="color: #3366CC;">&quot;path&quot;</span><span style="color: #339933;">:</span><span style="color: #3366CC;">&quot;plugins/npvlc.dll&quot;</span><span style="color: #339933;">,</span> <span style="color: #3366CC;">&quot;public&quot;</span><span style="color: #339933;">:</span><span style="color: #003366; font-weight: bold;">true</span> <span style="color: #009900;">&#125;</span><span style="color: #009900;">&#93;</span>
<span style="color: #009900;">&#125;</span></pre></div></div>

<p>Looks simpler and neater, isn&#8217;t it? Now we get to the problematic part about <a title="Packaging" href="http://code.google.com/chrome/extensions/packaging.html">chrome extension packaging</a>:</p>
<p>It is mostly a zip <strong>BUT</strong> you have to prepend to it a small header with more or less just the signature.</p>
<p>You can do that either by using chrome built-in facility or by a <a title="crxmake" href="http://github.com/Constellation/crxmake">small ruby script</a>. Reimplementing the same logic in Makefile using openssl is an option, for now I&#8217;ll stick with crxmake.</p>
<p>Then first test build for win32 are available as <a title="XPI Bundle for Firefox" href="http://lscube.org/files/tests/win32/vlc-plugin.xpi">xpi</a> and <a title="CRX Bundle for Chrome" href="http://lscube.org/files/tests/win32/vlc-plugin.crx">crx</a> hosted on <a href="http://lscube.org">lscube.org</a> as usual.</p>
<p>Sadly the crx file layout and the not so tolerant firefox xpi unpacker make impossible having a single zip containing both the manifest.xpi and the install.rdf served as xpi and crx.</p>
<p><strong> by the way, wordpress really sucks </strong></p>
]]></content:encoded>
			<wfw:commentRss>http://blog.axant.it/archives/259/feed</wfw:commentRss>
		</item>
		<item>
		<title>The zoom factor in webkit and gecko</title>
		<link>http://blog.axant.it/archives/257</link>
		<comments>http://blog.axant.it/archives/257#comments</comments>
		<pubDate>Thu, 08 Apr 2010 16:23:36 +0000</pubDate>
		<dc:creator>lu_zero</dc:creator>
		
		<category><![CDATA[Web]]></category>

		<guid isPermaLink="false">http://blog.axant.it/?p=257</guid>
		<description><![CDATA[Apparently all the major browsers tried to provide a zoom facility to improve the overall accessibility for the web users. Sadly that often breaks horribly your layout, if you are developing pixel precise interaction you might get a flood of strange bug reports you might not reproduce.
We got bitten by it while developing Glossom, severely&#8230;
Our [...]]]></description>
			<content:encoded><![CDATA[<p>Apparently all the major browsers tried to provide a zoom facility to improve the overall accessibility for the web users. Sadly that often breaks horribly your layout, if you are developing pixel precise interaction you might get a flood of strange bug reports you might not reproduce.</p>
<p>We got bitten by it while developing Glossom, severely&#8230;</p>
<p>Our way to figure out it&#8217;s value is quite simple once you discover it: Firefox scales proportionally the borders and makes the block dimensions constant, Webkit seems to do the opposite. It&#8217;s enough to check if a element with known dimensions and border width has it&#8217;s value reported as different and your can find our which is the factor.</p>
<p>This obviously is quite browser dependent and nobody grants that in different version it might get changed, anyway so far it seems to serve us well.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.axant.it/archives/257/feed</wfw:commentRss>
		</item>
		<item>
		<title>ACR got support for user permissions</title>
		<link>http://blog.axant.it/archives/253</link>
		<comments>http://blog.axant.it/archives/253#comments</comments>
		<pubDate>Wed, 07 Apr 2010 21:15:28 +0000</pubDate>
		<dc:creator>amol</dc:creator>
		
		<category><![CDATA[Opensource]]></category>

		<category><![CDATA[acr]]></category>

		<category><![CDATA[turbogears]]></category>

		<guid isPermaLink="false">http://blog.axant.it/?p=253</guid>
		<description><![CDATA[ACR opensource Turbogears2 CMS got support for user permissions to allow users to edit only some pages and create children only in some sections. This should permit to separate work between multiple people in ACR based sites.
ACR also got support for blog/news slice template. This permits to create blogs in ACR with just two clicks [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://labs.axant.it/acr">ACR</a> opensource <a href="http://www.turbogears.org">Turbogears2</a> CMS got support for user permissions to allow users to edit only some pages and create children only in some sections. This should permit to separate work between multiple people in ACR based sites.</p>
<p>ACR also got support for blog/news slice template. This permits to create blogs in ACR with just two clicks instead of having to declare the ACR slicegroup youself.</p>
<p>As usual you can download ACR from <em>http://repo.axant.it/hg/acr</em> by using <a href="http://mercurial.selenic.com/">mercurial</a></p>
]]></content:encoded>
			<wfw:commentRss>http://blog.axant.it/archives/253/feed</wfw:commentRss>
		</item>
		<item>
		<title>Redis and MongoDB insertion performance analysis</title>
		<link>http://blog.axant.it/archives/236</link>
		<comments>http://blog.axant.it/archives/236#comments</comments>
		<pubDate>Mon, 15 Mar 2010 23:09:34 +0000</pubDate>
		<dc:creator>amol</dc:creator>
		
		<category><![CDATA[Computer Science]]></category>

		<category><![CDATA[mongodb]]></category>

		<category><![CDATA[redis]]></category>

		<guid isPermaLink="false">http://blog.axant.it/?p=236</guid>
		<description><![CDATA[Recently we had to study a software where reads can be slow, but writes need to be as fast as possible.  Starting from this requirement we thought about which one between redis and mongodb would better fit the problem. Redis should be the obvious choice as its simpler data structure should make it light-speed [...]]]></description>
			<content:encoded><![CDATA[<p style="center;">Recently we had to study a software where reads can be slow, but writes need to be as fast as possible.  Starting from this requirement we thought about which one between redis and mongodb would better fit the problem. Redis should be the obvious choice as its simpler data structure should make it light-speed fast, and actually that is true, but we found a we interesting things that we would like to share.<br />
<img class="aligncenter" src="http://spreadsheets.google.com/oimg?key=0AuIJBJ437w0BdHRlX1RvdGpBMHZQNThYZTk5OTdqLXc&amp;oid=1&amp;v=1268694076807" alt="" width="600" height="441" /><br />
This first graph is about MongoDB Insertion vs Redis RPUSH.<br />
Up to 2000 entries the two are quite equivalent, then redis starts to get faster, usually twice as fast as mongodb. I expected this, and I have to say that antirez did a good job in thinking the redis paradigm, in some situations it is the perfect match solution.<br />
Anyway I would expect mongodb to be even slower relating to the features that a mongodb collection has over a simple list.<br />
<img class="aligncenter" src="http://spreadsheets.google.com/oimg?key=0AuIJBJ437w0BdHRlX1RvdGpBMHZQNThYZTk5OTdqLXc&amp;oid=2&amp;v=1268693294269" alt="" width="600" height="441" /></p>
<p>This second graph is about Redis RPUSH vs Mongo $PUSH vs Mongo insert, and I find this graph to be <strong>really</strong> interesting.<br />
Up to 5000 entries mongodb $push is faster even when compared to Redis RPUSH, then it becames incredibly slow, probably the mongodb array type has linear insertion time and so it becomes slower and slower. mongodb might gain a bit of performances by exposing a constant time insertion list type, but even with the linear time array type (which can guarantee constant time look-up) it has its applications for small sets of data.</p>
<p>I would like to say that this benchmarks have no real value, as usual, and have been performed just for curiosity</p>
<p>You can find here the three benchmarks snippets</p>

<div class="wp_syntax"><div class="code"><pre class="python" style="font-family:monospace;"><span style="color: #ff7700;font-weight:bold;">import</span> redis, <span style="color: #dc143c;">time</span>
MAX_NUMS = <span style="color: #ff4500;">1000</span>
&nbsp;
r = redis.<span style="color: black;">Redis</span><span style="color: black;">&#40;</span>host=<span style="color: #483d8b;">'localhost'</span>, port=<span style="color: #ff4500;">6379</span>, db=<span style="color: #ff4500;">0</span><span style="color: black;">&#41;</span>
<span style="color: #ff7700;font-weight:bold;">del</span> r<span style="color: black;">&#91;</span><span style="color: #483d8b;">'list'</span><span style="color: black;">&#93;</span>
&nbsp;
nums = <span style="color: #008000;">range</span><span style="color: black;">&#40;</span><span style="color: #ff4500;">0</span>, MAX_NUMS<span style="color: black;">&#41;</span>
clock_start = <span style="color: #dc143c;">time</span>.<span style="color: black;">clock</span><span style="color: black;">&#40;</span><span style="color: black;">&#41;</span>
time_start = <span style="color: #dc143c;">time</span>.<span style="color: #dc143c;">time</span><span style="color: black;">&#40;</span><span style="color: black;">&#41;</span>
<span style="color: #ff7700;font-weight:bold;">for</span> i <span style="color: #ff7700;font-weight:bold;">in</span> nums:
    r.<span style="color: black;">rpush</span><span style="color: black;">&#40;</span><span style="color: #483d8b;">'list'</span>, i<span style="color: black;">&#41;</span>
time_end = <span style="color: #dc143c;">time</span>.<span style="color: #dc143c;">time</span><span style="color: black;">&#40;</span><span style="color: black;">&#41;</span>
clock_end = <span style="color: #dc143c;">time</span>.<span style="color: black;">clock</span><span style="color: black;">&#40;</span><span style="color: black;">&#41;</span>
&nbsp;
<span style="color: #ff7700;font-weight:bold;">print</span> <span style="color: #483d8b;">'TOTAL CLOCK'</span>, clock_end-clock_start
<span style="color: #ff7700;font-weight:bold;">print</span> <span style="color: #483d8b;">'TOTAL TIME'</span>, time_end-time_start</pre></div></div>


<div class="wp_syntax"><div class="code"><pre class="python" style="font-family:monospace;"><span style="color: #ff7700;font-weight:bold;">import</span> pymongo, <span style="color: #dc143c;">time</span>
MAX_NUMS = <span style="color: #ff4500;">1000</span>
&nbsp;
con = pymongo.<span style="color: black;">Connection</span><span style="color: black;">&#40;</span><span style="color: black;">&#41;</span>
db = con.<span style="color: black;">test_db</span>
db.<span style="color: black;">testcol</span>.<span style="color: black;">remove</span><span style="color: black;">&#40;</span><span style="color: black;">&#123;</span><span style="color: black;">&#125;</span><span style="color: black;">&#41;</span>
db.<span style="color: black;">testlist</span>.<span style="color: black;">remove</span><span style="color: black;">&#40;</span><span style="color: black;">&#123;</span><span style="color: black;">&#125;</span><span style="color: black;">&#41;</span>
&nbsp;
nums = <span style="color: #008000;">range</span><span style="color: black;">&#40;</span><span style="color: #ff4500;">0</span>, MAX_NUMS<span style="color: black;">&#41;</span>
clock_start = <span style="color: #dc143c;">time</span>.<span style="color: black;">clock</span><span style="color: black;">&#40;</span><span style="color: black;">&#41;</span>
time_start = <span style="color: #dc143c;">time</span>.<span style="color: #dc143c;">time</span><span style="color: black;">&#40;</span><span style="color: black;">&#41;</span>
<span style="color: #ff7700;font-weight:bold;">for</span> i <span style="color: #ff7700;font-weight:bold;">in</span> nums:
    db.<span style="color: black;">testlist</span>.<span style="color: black;">insert</span><span style="color: black;">&#40;</span><span style="color: black;">&#123;</span><span style="color: #483d8b;">'v'</span>:i<span style="color: black;">&#125;</span><span style="color: black;">&#41;</span>
time_end = <span style="color: #dc143c;">time</span>.<span style="color: #dc143c;">time</span><span style="color: black;">&#40;</span><span style="color: black;">&#41;</span>
clock_end = <span style="color: #dc143c;">time</span>.<span style="color: black;">clock</span><span style="color: black;">&#40;</span><span style="color: black;">&#41;</span>
&nbsp;
<span style="color: #ff7700;font-weight:bold;">print</span> <span style="color: #483d8b;">'TOTAL CLOCK'</span>, clock_end-clock_start
<span style="color: #ff7700;font-weight:bold;">print</span> <span style="color: #483d8b;">'TOTAL TIME'</span>, time_end-time_start</pre></div></div>


<div class="wp_syntax"><div class="code"><pre class="python" style="font-family:monospace;"><span style="color: #ff7700;font-weight:bold;">import</span> pymongo, <span style="color: #dc143c;">time</span>
MAX_NUMS = <span style="color: #ff4500;">1000</span>
&nbsp;
con = pymongo.<span style="color: black;">Connection</span><span style="color: black;">&#40;</span><span style="color: black;">&#41;</span>
db = con.<span style="color: black;">test_db</span>
db.<span style="color: black;">testcol</span>.<span style="color: black;">remove</span><span style="color: black;">&#40;</span><span style="color: black;">&#123;</span><span style="color: black;">&#125;</span><span style="color: black;">&#41;</span>
db.<span style="color: black;">testlist</span>.<span style="color: black;">remove</span><span style="color: black;">&#40;</span><span style="color: black;">&#123;</span><span style="color: black;">&#125;</span><span style="color: black;">&#41;</span>
oid = db.<span style="color: black;">testcol</span>.<span style="color: black;">insert</span><span style="color: black;">&#40;</span><span style="color: black;">&#123;</span><span style="color: #483d8b;">'name'</span>:<span style="color: #483d8b;">'list'</span><span style="color: black;">&#125;</span><span style="color: black;">&#41;</span>
&nbsp;
nums = <span style="color: #008000;">range</span><span style="color: black;">&#40;</span><span style="color: #ff4500;">0</span>, MAX_NUMS<span style="color: black;">&#41;</span>
clock_start = <span style="color: #dc143c;">time</span>.<span style="color: black;">clock</span><span style="color: black;">&#40;</span><span style="color: black;">&#41;</span>
time_start = <span style="color: #dc143c;">time</span>.<span style="color: #dc143c;">time</span><span style="color: black;">&#40;</span><span style="color: black;">&#41;</span>
<span style="color: #ff7700;font-weight:bold;">for</span> i <span style="color: #ff7700;font-weight:bold;">in</span> nums:
    db.<span style="color: black;">testcol</span>.<span style="color: black;">update</span><span style="color: black;">&#40;</span><span style="color: black;">&#123;</span><span style="color: #483d8b;">'_id'</span>:oid<span style="color: black;">&#125;</span>, <span style="color: black;">&#123;</span><span style="color: #483d8b;">'$push'</span>:<span style="color: black;">&#123;</span><span style="color: #483d8b;">'values'</span>:i<span style="color: black;">&#125;</span><span style="color: black;">&#125;</span><span style="color: black;">&#41;</span>
time_end = <span style="color: #dc143c;">time</span>.<span style="color: #dc143c;">time</span><span style="color: black;">&#40;</span><span style="color: black;">&#41;</span>
clock_end = <span style="color: #dc143c;">time</span>.<span style="color: black;">clock</span><span style="color: black;">&#40;</span><span style="color: black;">&#41;</span>
&nbsp;
<span style="color: #ff7700;font-weight:bold;">print</span> <span style="color: #483d8b;">'TOTAL CLOCK'</span>, clock_end-clock_start
<span style="color: #ff7700;font-weight:bold;">print</span> <span style="color: #483d8b;">'TOTAL TIME'</span>, time_end-time_start</pre></div></div>

]]></content:encoded>
			<wfw:commentRss>http://blog.axant.it/archives/236/feed</wfw:commentRss>
		</item>
	</channel>
</rss>
