<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">

  <title><![CDATA[the fancy part of the web]]></title>
  <link href="http://blog.tolleiv.de/atom.xml" rel="self"/>
  <link href="http://blog.tolleiv.de/"/>
  <updated>2014-05-04T11:33:35+02:00</updated>
  <id>http://blog.tolleiv.de/</id>
  <author>
    <name><![CDATA[Tolleiv Nietsch]]></name>
    
  </author>
  <generator uri="http://octopress.org/">Octopress</generator>

  
  <entry>
    <title type="html"><![CDATA[Octopress migration]]></title>
    <link href="http://blog.tolleiv.de/2014/05/octopress-migration/"/>
    <updated>2014-05-04T09:57:25+02:00</updated>
    <id>http://blog.tolleiv.de/2014/05/octopress-migration</id>
    <content type="html"><![CDATA[<p>I&rsquo;ve finally managed to step away from Wordpress and migrated my blog to <a href="http://octopress.org/">Octopress</a>. There were many reasons for me, the main reasons was that I didn&rsquo;t want to host it by myself anymore.</p>

<p>The migration itself was guided by some blog posts which helped me a lot to get insights into Octopress:</p>

<ul>
<li><a href="http://zhen.org/blog/migrating-40000-posts-from-wordpress-to-octopress/">Migrating 40,000 Posts From Wordpress to Octopress</a></li>
<li><a href="http://learnaholic.me/2012/10/15/octopress-seo-and-disabling-the-blog-route/">Octopress SEO and Disabling the Blog Route</a></li>
<li><a href="http://robdodson.me/blog/2012/04/30/custom-domain-with-octopress-and-github-pages/">Custom Domain With Octopress and Github Pages</a></li>
<li><a href="http://luosky.com/2012/07/24/create-custom-rss-feed-for-octopress/">Create Custom Rss Feed for Octopress</a></li>
</ul>


<p>Besides that I managed to keep all the old URLs and migrated the comments to Diqus which went pretty smooth with very little configuration.</p>
]]></content>
  </entry>
  
  <entry>
    <title type="html"><![CDATA[TemplaVoila - followup]]></title>
    <link href="http://blog.tolleiv.de/2013/06/templavoila-followup/"/>
    <updated>2013-06-14T11:45:54+02:00</updated>
    <id>http://blog.tolleiv.de/2013/06/templavoila-followup</id>
    <content type="html"><![CDATA[<p>It seems that publishing the <a href="http://blog.tolleiv.de/2013/06/templavoila-future/">news regarding TemplaVoila</a> came to the right time and it found its way through the community. But along with it, some irritation came up which needs some additional words.</p>

<h3>Will there be a TYPO3 CMS 6.2 compatible version of TemplaVoila?</h3>

<p><strong>As it seems: yes &ndash; </strong>some members of the community offered their help. I&rsquo;ll reach out to them in the next days and try to connect them as good as I can. I will of course support them as good as possible. I can&rsquo;t really tell whether there will be a TER release for that or whether we&rsquo;ll keep it in the Git repository only. That&rsquo;s up for discussion &ndash; I made my point about that already and find it still valid. In case you&rsquo;re interested to help (coding, documentation, anything) &ndash; just sent me a note.</p>

<h3>Was it a black day for the community?</h3>

<p><strong>I doubt that &ndash; </strong>a <a href="http://twitter.com/spacedani/status/343756724198576130">single tweet</a> mentioning people clapping on the news made a <a href="http://lists.typo3.org/pipermail/typo3-german/2013-June/093272.html">large wave</a> through the newsgroups, nothing else. Most likely this was just a misunderstanding and most importantly it didn&rsquo;t reflect the generally very positive feedback I got through all other canals.</p>

<h3>What about #T3CS13?</h3>

<p>That&rsquo;s first of all a great community event and everyone should reach out for #T3CS14 tickets next year. Nevertheless as it seems <a href="http://lists.typo3.org/pipermail/typo3-english/2013-June/086209.html">some people (still) clapped their hands</a> when they heard the TemplaVoila news,<a href="http://twitter.com/StGebert/status/343675163814006784"> which seemed very inappropriate</a>. Due to that Jochen Weiland (one of the organizers) sent a personal apology to me and an &ldquo;<a href="http://twitter.com/t3cs/status/344432618688892928">official tweet</a>&rdquo; for what happened at the #T3CS13. From my perspective this wasn&rsquo;t even needed, but it&rsquo;s nice that he did it anyways. The fact that <a href="http://lists.typo3.org/pipermail/typo3-english/2013-June/086209.html">Peter Pröll</a> <a href="http://twitter.com/robert_we/status/343751092254949376">(proof)</a> made a very clear statement during the event about some peoples misbehavior was already the right move. So let&rsquo;s just close this chapter.</p>

<h3>What are the alternatives, now?</h3>

<p>We&rsquo;ll see, but I hope that 6.2 or 6.3 will come along with a very strong suggestion in that regard and maybe a &ldquo;Core candidate&rdquo; extension/solution. Just to avoid that a double or triple-solution situation starts to grow once again.</p>

<p>Finally thanks for all the warm words and wishes. This made me very happy. Also please keep in mind that I just maintained TemplaVoila during the last 3-4 years and that I took over from Dmitry, Robert and Kasper.</p>
]]></content>
  </entry>
  
  <entry>
    <title type="html"><![CDATA[TemplaVoila future]]></title>
    <link href="http://blog.tolleiv.de/2013/06/templavoila-future/"/>
    <updated>2013-06-08T09:20:34+02:00</updated>
    <id>http://blog.tolleiv.de/2013/06/templavoila-future</id>
    <content type="html"><![CDATA[<p>If you followed some of my comments in the TYPO3 newsgroups recently, you&rsquo;ve heard that I&rsquo;m not very satisfied with the TYPO3 project in general and that&rsquo;s also reflected in my activity for TemplaVoila. After a certain time of inactivity I even had to ask myself whether it&rsquo;s wort to keep it in the TYPO3 universe or not. Due to the fact that this isn&rsquo;t an easy decision, I created a pro and con list which I&rsquo;d like to share, before I make conclusions.</p>

<h3>Why TemplaVoila maintenance should continue:</h3>

<ul>
<li><p>it made TYPO3 attractive for many less technical people (people who don&rsquo;t even understand conditions or loops)</p></li>
<li><p>it contains and combines concepts (language, workspaces, content structuring) which aren&rsquo;t represented anyhow in other solutions</p></li>
<li><p>it is still used within the community and various indicators proof that it is still very popular</p></li>
</ul>


<h3>Why TemplaVoila should not be maintained anymore:</h3>

<ul>
<li><p>it is not supported by the <a href="http://lists.typo3.org/pipermail/typo3-team-core/2013-April/053866.html">active contributors</a> at all</p></li>
<li><p>it is constantly under some kind of PR-attack from the other solutions (which is very demotivating)</p></li>
<li><p>it lacks a developer &ldquo;community&rdquo; or at least a team</p></li>
<li><p>it has a horribly outdated documentation which has to be overworked</p></li>
<li><p>code refactoring is not really possible, the code is horrible to maintain</p></li>
<li><p>it&rsquo;s concepts can&rsquo;t be ported anyhow to FLOW/extbase (extbase itself is broken when it comes to workspaces or languages &ndash; no way to port over alternative concepts for these)</p></li>
<li><p>UI wise, Prototype and ExtJS have been used for it and need to be replaced with whatever the TYPO3 Core could offer</p></li>
<li><p>some of it&rsquo;s concepts need to be reworked (language) to be much more useable</p></li>
<li><p>the TYPO3 Core changes in a way that extension maintenance is no fun at all</p></li>
</ul>


<h3>Conclusions:</h3>

<p>I could add further points to both lists, but in general you&rsquo;ll get my point. All these have been on my mind for quite some time and I discussed them with various members of the TYPO3 community and I came to the conclusion that TemplaVoila should at least disappear from the TER to avoid that any new users start using it.</p>

<p>Along with that, I also came to the conclusion that handing over TemplaVoila back to Dmitry, Robert or Kasper wouldn&rsquo;t make sense either &ndash; the remaining workload is enormous and a single developer alone would never be able to deliver anything with reasonable quality (incl. documentation).</p>

<p>This basically means that TemplaVoila won&rsquo;t be actively distributed and supported by me and that there won&rsquo;t be any new public releases. In order to keep up the ability to fix bugs, I&rsquo;d offer to keep <a href="http://forge.typo3.org/projects/extension-templavoila">Forge+Git+Gerrit</a> open and I&rsquo;m still willing to review and merge patches (through Gerrit). Even though I didn&rsquo;t see too much activity from others for TemplaVoila within Gerrit, I assume that this should be enough to support running projects.</p>

<p>To avoid that the discussion which might be needed for that announcement ends up in my blog, I&rsquo;ll close the comments here and I&rsquo;d love to invite you to comment within the related newsgroup entry in <a href="http://lists.typo3.org/cgi-bin/mailman/listinfo/typo3-project-templavoila">typo3.project.templavoila</a>.</p>
]]></content>
  </entry>
  
  <entry>
    <title type="html"><![CDATA[Using genetic algorithms to optimize Apache Solr boost factors.]]></title>
    <link href="http://blog.tolleiv.de/2013/06/genetic-algorithms-boosting-solr/"/>
    <updated>2013-06-06T20:47:56+02:00</updated>
    <id>http://blog.tolleiv.de/2013/06/genetic-algorithms-boosting-solr</id>
    <content type="html"><![CDATA[<p><a href="/uploads/2013/06/Bildschirmfoto-2013-05-29-um-18.08.18.png"><img src="/uploads/2013/06/Bildschirmfoto-2013-05-29-um-18.08.18-150x150.png" alt="Configuration interface." /></a> Configuration interface.One thing I took along from last year&rsquo;s ApacheCon was the idea to combine Apache Solr along with some mathematical search algorithms to figure out boost factor values. I did some work on that back then and on the way to this year&rsquo;s BerlinBuzzwords. Now I finally have a proof-of-concept working which I&rsquo;d like to share. If you want to have a look right away &ndash; the code can be found on <a href="http://github.com/tolleiv/boostgenetics">Github</a>.</p>

<h2>The problem to solve:</h2>

<p>When running search indexes with Solr, one thing you might stumble opon is that you&rsquo;ve various fields in your documents and you&rsquo;ve to adjust their weights to get reasonable results. Finding those &ldquo;boosting&rdquo; values can be quite complex when you have many fields and many scenarios. Usually getting the values right is a task for very experienced integrators.</p>

<blockquote><p>/solr/select?defType=dismax&amp;q=my+query
&amp;qf=title^<strong>42</strong>+description^<strong>23</strong>+footnotes^<strong>5</strong>+dalmatiners^<strong>101</strong>+foo^<strong>9001</strong>+comments</p></blockquote>

<p>Looking at it from a more technical perspective &ndash; when your Solr query looks like the one above, the question you&rsquo;ve to answer is how the values for the highlighted numbers should look like to get <em>reasonable</em> results.</p>

<h2>Measuring &ldquo;reasonable&rdquo;:</h2>

<p>In order to solve the problem, the first thing we&rsquo;ve to do, is to answer what we expect the outcome to look like. In other words, we&rsquo;ve to measure how reasonable a specific solution is. For a search engine this can be done with some sample queries and some expectations along with that. The expectation could come in a form that we explicitly tell which documents we expect in the result lists of specific queries (and at predefined positions). Once we&rsquo;ve these expectations, we can simple test agains the expectations and check whether or not specific boost factor values actually satisfy them.</p>

<blockquote><p>A small example on that: In case we&rsquo;ve a sample query with the expectation that document 123 appears in the first position and document 248 appears second. We could run this with two specific boost factor combinations (a) and (b). Along with (a) we might find that, document 123 actually ranks on position 8 and document 248 is found on position 4 and with (b) we&rsquo;d find them on pos. 2 and pos. 14 &ndash; which one would we consider to be better?
Comparing the &ldquo;error&rdquo; and &ldquo;squared error&rdquo; produced by (a) and (b) gives us a possible hint:
(a): 8-1 + 4-2 = 7+2 = 9
(8-1)² + (4-2)² = 49+4 = 53
(b): 2-1 + 14-2 = 1+12 = 13
(2-1)² + (14-2)² = 1+144 = 145
While it&rsquo;s not clear to compare both with just the normal error value comparision, the squared error shows clearly that (a) seems to outperform (b) in those cases and we should choose (a) for further considerations.</p></blockquote>

<p>Being able to determine the &ldquo;error&rdquo; introduced by a specific solution then enables us to compare various solutions and helps us to play around with all sorts of optimizations.</p>

<h2>The idea:</h2>

<p>With a defined &ldquo;cost function&rdquo; like the one I introduced before, you&rsquo;d be able to tackle the problem with some well known algorithmic solutions. Considering the boost factors to be represented as numerical vectors, we could use gradient methodologies to find good solutions. But having 20-40 fields per document would require to &ldquo;search&rdquo; a large numerical space and with gradient methods, this would result in a large amount of queries.</p>

<p>Another approach to run these optimizations, is to utilize genetic algorithms which kind of help to find good solutions within predictable amounts of time. You might know genetic algorithms for some lectures where people solved <a href="http://www.math.hmc.edu/seniorthesis/archives/2001/kbryant/kbryant-2001-thesis.pdf">traveling salesman problems</a> and actually the only change you&rsquo;d have to make is to exchange the traveling salesman cost function with the cost function you saw before and you&rsquo;d be close to a solution already.</p>

<p><strong>With some more details:</strong> Genetic algorithms take an amount of randomly generated possible solutions (called the <em>population</em>) and try to find good solutions by applying the typical methods you know from your biology class (mutations, crossovers, natural selection). <em>Natural selection</em> is done in a way that from each generation only the top 50% &ldquo;survive and the rest of the population is filled up with now solutions generated through <em>mutations</em> (random parameter changes of existing solutions) and <em>crossovers</em> (interchanging parts of two existing solutions to create a third one). All solutions are always measured and compared on their response to the defined cost function and this way we&rsquo;re always able to determine the &#8220;best known solution&rdquo; even after very short time.</p>

<blockquote><p>If that sounds too high-level. For the shown query from above, the vector [42,23,5,101,9001,1] is the vector I used. In addition let&rsquo;s considering we have another vector [1,1,1,1,1,1] with equal weights for all fields. Assuming those are our fittest vectors at a given time, we could derive new possible solutions by mutating them (e.g. [42,23,5,101,9001,1] ~> [42,23,5,101,505,1] ) or creating a cross-over between both ( [42,23,5,101,9001,1] &amp; [1,1,1,1,1,1] ~> [42,23,5,1,1,1]). Even adding new random vectors to our population might add some value. Once we found enough new vectors to have a population of a decent size, we&rsquo;d compare the fitness and keep only the top 50% and continue our process until we reach convergence or a fixed iteration limit.</p></blockquote>

<p>A drawback of the genetic algorithm is that it might not deliver the optimal result, because it never found it. But that&rsquo;s just how nature works too. So it&rsquo;s more that you&rsquo;ve to sacrifice &ldquo;training runtime&rdquo; over accuracy or vice versa.</p>

<h2>Implementation:</h2>

<p><a href="/uploads/2013/06/Bildschirmfoto-2013-05-29-um-18.10.43.png"><img src="/uploads/2013/06/Bildschirmfoto-2013-05-29-um-18.10.43-150x150.png" alt="10 generation optimization" /></a> 10 generation optimizationThere&rsquo;s really not too much to say other than that the code can be found in <a href="http://github.com/tolleiv/boostgenetics">Github</a>. I used NodeJS with ExpressJs, SocketIO and an Twitter Bootstrap interface to have a relatively good looking and somewhat performing proof-of-concept. I used that setup, because NodeJS seems to me as the most easiest way to talk to Solr and it &ldquo;promises&rdquo; to be performant even with larger examples. SocketIO helped a lot to ease the pain when it comes to Server &lt;> Client communication. The only drawback of that setup is the that everything had to be turned into something which is able to deal with asynchronous processing. This makes the algorithmic parts look a bit odd and bloated &ndash; but for me the benefits outweigh the odds.</p>

<h2>Final thoughts:</h2>

<p>The proof-of-concept, which you&rsquo;ll find on the Github repository, demonstrates that such type of optimization can work and that&rsquo;s more or less all I wanted to do with it.</p>

<p>You can use the NodeJS tool with any of your Solr indexes and just go ahead and try it yourself. There are many parts which aren&rsquo;t too accurate yet, especially the measuring could maybe done better with precision and recall measurements &ndash; but I assume that any type of cost function would work for now, that&rsquo;s why P/R wasn&rsquo;t implemented along with the tool. Also I&rsquo;m not a NodeJS expert and the code might not follow best practice atm. &ndash; I&rsquo;d be very happy to change that if anyone is interested to help?</p>

<hr />

<p>When I did a small presentation during the <a href="http://berlinbuzzwords.de/wiki/barcamp">Berlin Buzzwords bar camp</a> I also got some other questions which don&rsquo;t necessarily relate to just this implementation but to all sorts of automated optimizations.</p>

<p><em>The first question was, how to get the list of example queries and the &ldquo;expected&rdquo; documents for them.</em> For now I assume that most applications at least know their top 50 or top 100 search and they should be able to predefine &ldquo;relevant&rdquo; documents for those searches. That&rsquo;s at least what I assume everyone should have. Another way to generate the test data is to do some log file analyses and check the search and pick/weight the documents people clicked from within the results. This should also help to get some results.</p>

<p><em>Another questions related to that was wether long tail would fall behind with that approach.</em> As this is only a proof-of-concept, I wasn&rsquo;t really able to answer this. But I assume that long-tail searches would still benefit a lot more from the relevance certain documents gain due to high TF-IDF scores and those should then outweigh the &ldquo;scoring bias&rdquo; in a way. Another approach (known from machine learning) could be to leave out the top 1% of the documents (and searches) and just optimize for the rest of the top X% and afterwards check wether the top 1% still performs good &ndash; this way long tail could be &ldquo;protected a bit more.</p>

<p><em>And the last question was whether I tested other (gradient based) algorithms already.</em> The answer was and is, no. So far this only ran on my MacBook and I really didn&rsquo;t want to benchmark my CPU. The code itself is somewhat prepared to take other optimization methods but I didn&rsquo;t add in others. If you&rsquo;re interested to do so &ndash; I&rsquo;d be happy to accept your pull-requests.</p>
]]></content>
  </entry>
  
  <entry>
    <title type="html"><![CDATA[Re: How to move on? #TYPO3]]></title>
    <link href="http://blog.tolleiv.de/2012/12/re-how-to-move-on-typo3/"/>
    <updated>2012-12-22T10:11:02+01:00</updated>
    <id>http://blog.tolleiv.de/2012/12/re-how-to-move-on-typo3</id>
    <content type="html"><![CDATA[<p>As I wanted to answer <a href="https://twitter.com/robertlemke">Robert&rsquo;s</a> post but didn&rsquo;t like the privacy of our Core-internal list, here&rsquo;s some kind of response to it. Alongside I&rsquo;ll try to explain the current situation and problems a bit***.</p>

<h3>What happend?</h3>

<p>In his post Robert kind of gave up his attempts to establish a TYPO3 product board [1]. The reasons for this are very wide-spread and mainly the various flame-wars in the last year and the very personal attacts brought him to the conclusion to:</p>

<blockquote><ul>
<li>no longer invest my time into setting up or participating in an overall product team</li>
<li>refrain from trying to establish leadership for the TYPO3 project</li>
<li>concentrate on Flow and Neos and invite teams to participate in frequent meetings about it</li>
<li>unsubscribe from the core internal mailing list</li>
</ul>
</blockquote>

<p>Even thought this shortens his entire mail a bit &ndash; that&rsquo;s the bottom line it comes down to****.</p>

<p>Looking at the recording of the &ldquo;Not-the-product-board&rdquo; [7] meeting from last Tuesday [2] it seems that these steps aren&rsquo;t necessary, as everybody seemed to be happy with the setup. So what&rsquo;s the criticism actually about? Lucky enough I don&rsquo;t have to describe it myself, but can cite an (again internal) response to an earlier mail from one of my fellow Core Team members:</p>

<blockquote><p>Suddenly, when you (Robert) left the steering committee of the T3A because of the
new bodies and bylaws, you realized that there is no more power for you
to decide about things. That&rsquo;s why you brought up the concept of a
product team. It&rsquo;s an attempt to replace the former steering committee,
which has backed up the decisions of the core team in a nice but
undemocratic way.</p></blockquote>

<p>In addition to these two standpoints we&rsquo;ve a mixture of opinions and directions in our community and all of them cause quite some irritation [3,4,5]. With all these repeating fights and discussions Robert and (I guess) most of us ask ourselves how the community could avoid the fighting?</p>

<p>So what&rsquo;s my opinion:</p>

<h3>What we should avoid</h3>

<ul>
<li><p><strong>Closed door meetings and private discussions</strong> &ndash; most of the &ldquo;emotional outbursts&rdquo; we saw where caused when the seemingly final results where presented to the community out of the blue. The fact that Core-internal is still a vivid place is a problem and we all should be abandon it.</p></li>
<li><p><strong>Working without vision</strong> &ndash; the long holding support (since 2006) for Neos and the nice drive gridelements got from it&rsquo;s fans [9] are two good examples that a vision can move mountains. But we should renew the vision statement and provide roadmaps on how we want to achieve it &ndash; mainly to motivate contributors and to enable collaboration between the teams.</p></li>
<li><p><strong>Leaders or leader groups</strong> &ndash; other OpenSource products have their <a href="http://en.wikipedia.org/wiki/Benevolent_dictatorship">benevolent dictator</a> &ndash; this wouldn&rsquo;t work for our community. Their focus will never reach the entire community and in the end their decisions will always cause confusion. Imho Kasper made a great job to bring TYPO3 to life &ndash; but he/we saw that the &ldquo;dictatorship&rdquo; didn&rsquo;t scale in the end [12] and imho Robert&rsquo;s response and the controversy around the product board kind of shows that too.**</p></li>
<li><p><strong>Personal attacks</strong> &ndash; nobody joined the TYPO3 community to fight, so there&rsquo;s no reason to fight back. Within all controversy and disappointment everyone tries to improve TYPO3 in his way [10]</p></li>
</ul>


<h3>What we need</h3>

<ul>
<li><p><strong>Diverse groups from all parts of the community</strong> &ndash; there&rsquo;s no other way to capture all ideas and to gather various people from the entire community. As a nice side effect they make the &ldquo;surface&rdquo; of our community much larger and might help to involve new users. Btw. our community manager<a href="https://twitter.com/benvantende"> Ben van&rsquo;t Ende </a>will be happy to help kickstarting and coordinating groups.</p></li>
<li><p><strong>Open meeting protocols and discussions</strong> &ndash; to make sure there&rsquo;s a chance for everyone to catch-up later and to avoid bad surprises as we saw during the rebranding [3] or during the version schema change [6] In both cases small groups of people made major (not necessarily bad) decisions on their own behind closed doors &ndash; the following controversies showed that good intentions can turn out very negative.</p></li>
<li><p><strong>Clear communication structures in the groups</strong> &ndash; to make sure things are &ldquo;presented&rdquo; appropriately. As see in [6] or in more recent situations [8] things would improve if groups had clear communication-channels. In [6] and [8]. seemingly official messages turned out to be personal attempts instead without actual &ldquo;approval&rdquo; / &ldquo;consensus&rdquo; from the related groups.</p></li>
<li><p><strong>Rough product roadmaps</strong> &ndash; They should exist to make sure people share a common vision but they should not be too straight to make sure nobody feels too bound to it. They should also exist to enable some kind of measurement. We should be able to ask the Neos or CMS team whether they &ldquo;live&rdquo; along their vision or whether it would be better to adjust it.</p></li>
<li><p><strong>Constructive honesty</strong> &ndash; people should discuss openly, in a respectful way [11]. Technical doubts and constructive criticism should be allowed, but it should be fair.</p></li>
</ul>


<h3>What does that mean for our products?</h3>

<p>Honestly: I don&rsquo;t know. Looking at the current situations with the lists from above: we have tons of groups working in many directions, we have a group that agreed on a common product-vision  (two times) [13], but the group communicates behind closed doors. I&rsquo;m not aware of any Neos or Flow roadmaps, but TYPO3 CMS has at least a (short) roadmap [14]. The Core team doesn&rsquo;t have clear communication structures yet and as shown this raises ton&rsquo;s of confusion. In addition our discussions tend to get very personal. It seems that sth. like a &ldquo;product board&rdquo; could help but&hellip;</p>

<h3>Product board and leadership</h3>

<p>On one hand I don&rsquo;t like the way how the &ldquo;product board&rdquo; was positioned in the beginning &ndash; it should not lead anything or decide anything. On the other hand it&rsquo;s great to have a group of people taking care to formulate a vision. The access to this group should be open to everyone, not just group leaders. Inner-circles, Top-10 groups, leader groups, Core-internal discussions should be avoided and open group-&ldquo;setups&rdquo; should be emphasized.</p>

<p>Hope this made sense?</p>

<h4>Read on:*</h4>

<p>[1] &ndash; <a href="https://docs.google.com/document/pub?id=18d92GAehVbU_eSZRCTjJga5pGxopkd7qYB0KNukc-Ys">Google Doc: Product Board (or “Product Team”)</a>
[2] &ndash; <a href="http://www.youtube.com/watch?v=NzeOjXD_3mA&amp;feature=youtu.be">TYPO3 Product Hangout (On Air)x</a>
[3] &ndash; <a href="http://typo3blogger.de/die-marke-typo3-erfindet-sich-neu/">Die Marke TYPO3 erfindet sich neu</a>
[4] &ndash; <a href="http://lists.typo3.org/pipermail/typo3-english/2012-October/082582.html">Rebranding: Get the green back</a>
[5] &ndash; <a href="http://typo3blogger.de/wieviel-kommunikation-und-roadmaps-braucht-ein-open-source-projekt/">Wieviel Kommunikation und Roadmaps braucht ein Open Source Projekt?</a>
[6] &ndash; <a href="http://buzz.typo3.org/people/xavier-perseguers/article/typo3-60-at-the-corner-how-is-it-possible/">TYPO3 6.0 at the corner? How is it possible?</a>
[7] &ndash; <a href="http://twitter.com/kdambekalns/status/281337939999457280">@kdambekalns: Now a first #TYPO3 &ldquo;product …&rdquo; meeting, not official, no decisions, nothing.</a>
[8] &ndash; <a href="http://twitter.com/WrYBiT/status/280618569077760002">@WrYBiT: @benvantende .. I expected, a mail by you and a news on T3O about it&hellip; </a>
[9] &ndash; <a href="http://www.startnext.de/typo3-grid-elements-2-0">Startnext: Verbessertes TYPO3-Backend mit neuen Features</a>
[10] &ndash; <a href="https://twitter.com/tom_noise/status/280624859501957120">@tom_noice: . @thomas_hempel The discussions are there because so many people care.</a>
[11] &ndash; <a href="http://typo3.org/community/code-of-conduct/">Community Code of Conduct</a>
[12] &ndash; <a href="http://typo3.org/videos/play/king-for-a-day-but-not-for-a-lifetime/">King for a day, but not for a lifetime</a>
[13] &ndash; <a href="http://typo3.org/news/article/the-phoenix-team-reports-on-the-developer-days-2012/">The Phoenix team reports on the Developer Days 2012</a>
[14] &ndash; <a href="http://lists.typo3.org/pipermail/typo3-team-core/2012-December/052936.html">Proposal for the upcoming Roadmap and LTS</a></p>

<hr />

<ul>
<li>take your time to read the endless lines of comments.
<strong> Imho <a href="https://twitter.com/ohader">Oliver Hader</a> choose a good attempt to (not)&ldquo;lead&rdquo; the Core Team &ndash; more in the sense of &ldquo;managing&rdquo; and &ldquo;enabling&rdquo; without ruling
</strong><em> Some tweets and messages from the Core members might have been quite confusing without the context
</em>*** I&rsquo;d prefer not to play TYPO3-leaks here, so it&rsquo;s up to Robert and the others to publish their mails by themselfs</li>
</ul>

]]></content>
  </entry>
  
  <entry>
    <title type="html"><![CDATA[TYPO3 login state and Varnish cache]]></title>
    <link href="http://blog.tolleiv.de/2012/12/typo3-login-state-and-varnish-cache/"/>
    <updated>2012-12-10T16:56:46+01:00</updated>
    <id>http://blog.tolleiv.de/2012/12/typo3-login-state-and-varnish-cache</id>
    <content type="html"><![CDATA[<p>Caching is hard in complex page setups with user specific content, especially when public pages change their content once a user is logged in. TYPO3 is smart enough to deal with the login state properly and cache appropriately. Once Varnish is involved, it&rsquo;s quite tricky to cache as much as possible without loosing the dynamic content. But it&rsquo;s not impossible and here&rsquo;s my summary how we resolved it for <a href="http://typo3.org">typo3.org</a>.</p>

<h4>Setup</h4>

<p>The basic Varnish setup is more or less always the same and best described by<a href="http://www.fabrizio-branca.de/nginx-varnish-apache-magento-typo3.html"> Farbrizio Branca</a>. On top of that we need   some TypoScript parameter tweaking to get the cache-control-headers in TYPO3 straight &ndash; <a href="http://www.typo3-media.com/blog/website-caching-login.html">Daniel Pötzinger&rsquo;s article</a> covers them best. Another very handy thing which can be found in Fabrizio&rsquo;s blog is the<a href="http://www.fabrizio-branca.de/make-your-magento-store-fly-using-varnish.html"> simplified flow chart</a> for the various <a href="https://www.varnish-cache.org/trac/wiki/VCLExampleDefault">Varnish subroutines</a>.Based on that all pages should be cached properly and your site should run smoothly. But in case you have a page with personalized content, you&rsquo;ll have to reconsider some parts.</p>

<h4>Problem</h4>

<p>The<a href="http://typo3.org/events/add-new-event/new/"> event submission page on typo3.org</a> is a good example. In case the user is not logged in (a.k.a <em>public page</em>), we just want to show a message which guides him to the login. If there&rsquo;s a login active (a.k.a <em>user page</em>), we&rsquo;ll show the submission form instead. In both cases we could cache the content nicely, but how would we ensure that Varnish delivers the correct content?</p>

<h4>Solution</h4>

<p>Ajax could be a solution, but for large sites it&rsquo;s usually smarter to avoid as much JavaScript as possible. EdgeSideIncludes (ESI) are another option, but I agree with <a href="http://www.typo3-media.com/blog/website-caching-login.html">Daniel</a>, they&rsquo;re not really useful in this case and I&rsquo;d rather go with Ajax than with ESI.</p>

<p>What we want in this scenario, is to cache the <em>public page </em>in Varnish and pass to the <em>user page</em> generated by TYPO3 if we find that the user is logged in. But this should of course only happen on pages where this is really necessary &ndash; normal pages should just ignore the login state of the user. Therefore we need sth. to distinguish <em>normal</em> from <em>login specific</em> pages in Varnish. Lucky enough TYPO3 already provides a field in the pages properties which allows this distinction. Using the <strong>Login Behaviour (pages.fe_login_mode)</strong> field, you can enable and disable the user-login for specific branches and pages*. As we want to whitelist <em>login specific</em> pages, our root page should have the default setting &ldquo;Disable Login&rdquo; &ndash; this will be inherited to all sub-pages. All the <em>login specific</em> pages should have the setting &ldquo;Re-Enable login&rdquo;.</p>

<p>Once this is done, we need a way to carry that out to Varnish. We improved <a href="http://forge.typo3.org/projects/extension-cacheinfo">EXT:cacheinfo</a> for that purpose, with that it now carries a &ldquo;<strong>loginAllowedInBranch</strong>&rdquo; or &ldquo;<strong>noLoginAllowedInBranch</strong>&rdquo; value in the &ldquo;<strong>X-T3CacheInfo&rdquo;</strong> header. Using all that, the Varnish VCL can be extended to make use of it like this:</p>

<pre><code>sub vcl_hit {
  if (obj.http.X-T3CacheInfo ~ "loginAllowedInBranch") {
    set obj.http.Cache-Control = "private";
    if (req.http.Cookie ~ "(e_typo_user|PHPSESSID|_pk_.*)") {
      # Do not cache requests which come from a logged in user
      return (pass);
    }
  }
}
</code></pre>

<p>This is straight forward. For every page which allows logins, we make sure that the client does not keep them in his cache. In case we&rsquo;re actually on such a page and find the related login-cookies, we pass the request along to TYPO3, otherwise we deliver the <em>public page</em> right away from the cache. The fact that we pass the request along to TYPO3 in some cases doesn&rsquo;t mean that we&rsquo;ll deliver the <em>user page</em>, it just indicates that we&rsquo;ve to rely on TYPO3 to make the right choice based on the actual login state.</p>

<h4>Conclusion</h4>

<p>For me the beauty here lies in the simplicity. Once you managed to wrap your head around the <a href="http://www.fabrizio-branca.de/make-your-magento-store-fly-using-varnish.html">flow chart</a> and once you managed to deliver appropriate meta-data to Varnish, many more complex scenarios can be resolved equally.</p>

<p>As most of the typo3.org stuff, this solution came from a great team. In this case <a href="https://twitter.com/stucki">Michael Stucki</a> and <a href="https://twitter.com/danpoetz">Daniel Pötzinger</a> helped to craft the final solution &ndash; thanks guys :)</p>

<hr />

<ul>
<li>the naming of the field&rsquo;s labels is really irritating &ndash; especially &ldquo;0 &ndash; Enable login&rdquo; should be &ldquo;Inherit setting&rdquo; as it really does not force any setting.</li>
</ul>

]]></content>
  </entry>
  
  <entry>
    <title type="html"><![CDATA[Finding TypoScript errors.]]></title>
    <link href="http://blog.tolleiv.de/2012/02/finding-typoscript-errors/"/>
    <updated>2012-02-16T17:02:31+01:00</updated>
    <id>http://blog.tolleiv.de/2012/02/finding-typoscript-errors</id>
    <content type="html"><![CDATA[<p>When you work on TypoScript templates in TYPO3, errors might show up in the TypoScript Object Browser. Within the error messages you&rsquo;ll see a more or less detailed error description with the related line number. Within most setups these line numbers won&rsquo;t relate to any of your sys_template records or TypoScript files directly. But they still provide value if you know how they help to find the right spot. As it&rsquo;s not too obvious how to find the right spot I&rsquo;ve created a little screenshot series to guide you to the broken spots in your templates.</p>

<p>So that&rsquo;s what you might see in your TypoScript Object Browser:</p>

<p><a href="/uploads/2012/02/typoscript-error.png"><img src="/uploads/2012/02/typoscript-error.png" alt="The error message from your TypoScript Object Browser might look like this." /></a></p>

<p> Switching from there to the Template Analyzer:</p>

<p><a href="/uploads/2012/02/typoscript-analyzer.png"><img src="/uploads/2012/02/typoscript-analyzer.png" alt="Switching to the TypoScript analyzer" /></a></p>

<p>At the bottom of the Template Analyzer, you&rsquo;ll find a &ldquo;Complete TS&rdquo; section and a link ~which looks like normal text.</p>

<p><a href="/uploads/2012/02/typoscript-analyzer-complete.png"><img src="/uploads/2012/02/typoscript-analyzer-complete.png" alt="And you'll find a link to the fully concatenated TypoScript of your current page." /></a></p>

<p>Clicking on that link will give you the entire concatenated TypoScript and here you&rsquo;ll also find that the line numbers finally match to the error message.</p>

<p><a href="/uploads/2012/02/typoscript-analyzer-error.png"><img src="/uploads/2012/02/typoscript-analyzer-error.png" alt="And you'll find that the line numbers are now what you saw in the error message before (might need some scrolling)." /></a></p>

<p>A well hidden gem which works most likely in all TYPO3 4.x versions ;)</p>

<hr />

<p>Edit: In the meantime, Ingo&rsquo;s patch made it through the review process. So users of TYPO3 4.7 and above will find a nice and handy &ldquo;Show details&rdquo; link next to the error message. Makes it much much faster to find the broken spot. Thanks Ingo :) / (<a href="http://twitter.com/irnnr">@irnnr</a>)</p>
]]></content>
  </entry>
  
  <entry>
    <title type="html"><![CDATA[Visualizing TYPO3 Core activity]]></title>
    <link href="http://blog.tolleiv.de/2012/01/visualizing-typo3-core-activity/"/>
    <updated>2012-01-20T09:00:12+01:00</updated>
    <id>http://blog.tolleiv.de/2012/01/visualizing-typo3-core-activity</id>
    <content type="html"><![CDATA[<blockquote><p>DISCLAIMER: Don&rsquo;t take the following too serious &ndash; when reading this post please keep in mind that the TYPO3 community itself consists of much more than just the Core team activity &ndash; many things take place outside of code repositories and can&rsquo;t be measured anyhow. <strong>Every</strong> contribution is important and <strong>every</strong> single action has value.</p></blockquote>

<p>Using Gerrit sometimes feels quite lonesome &ndash; you don&rsquo;t really see who&rsquo;s active and you don&rsquo;t really get a feeling on how much is done in the TYPO3 Core at a certain point. To visualize on how active the contributors are and to show the most active members I applied a little scoring and summed up the results for the time since 2006.</p>

<p><a href="http://blog.tolleiv.de/impact-chart"><img src="/uploads/2012/01/TYPO3-Core-impact.png" alt="Snippet of the impact chart." /></a></p>

<p>The scoring is quite easy &ndash; every author of a patch gets 10 points, testers get 3 and reviewers 1 point*. Looking at the stats it seems that even the statistics pulled from the old Subversion days seem to meet up with today&rsquo;s numbers &ndash; of course we&rsquo;ve to keep in mind that everything which was pulled from Subversion doesn&rsquo;t really point to the author but to the actual committer (except if there was a &ldquo;Thanks to XXXXX&rdquo; reference in the commit).</p>

<p>To visualize the numbers I choose a <a href="https://github.com/blog/219-impact-graph-speedups">Github</a> like <a href="http://blog.tolleiv.de/impact-chart">impact chart</a>**. Each contributor has it&rsquo;s own color and line in it and whenever he got active the width of the line scales up. To maintain the overview the scale of the width isn&rsquo;t linear and every contributor who&rsquo;s not within the &ldquo;Top 20&rdquo; had to be scaled down to &ldquo;1&rdquo;. The line stops if the contributor didn&rsquo;t get active anymore. The scores are grouped and compared by month.</p>

<p><a href="http://blog.tolleiv.de/impact-chart/stat.html"><img src="/uploads/2012/01/Core-Stats-January20121.png" alt="Snapshot of the &quot;Top 20&quot; stats taken Jan. 14th 2012" /></a></p>

<p>In addition to the chart I also created a <a href="http://blog.tolleiv.de/impact-chart/stat.html">table based overview for the &ldquo;Top 20&rdquo;</a> contributors with their score***.</p>

<p>Few things I got from the numbers. There have been 290 contributors already &ndash; simply amazing. Comparing the (huge) scores of the release managers with their fellow contributors shows once more that they can be really proud about the job they did or do. It&rsquo;s also quite cool to see that many people keep sticking around. And finally it was quite surprising to see that our community manager <a href="https://twitter.com/benvantende">Ben van&rsquo;t Ende</a> can also be found in the stats. Besides that it&rsquo;s up to everyone else to find their conclusions from these numbers. I hope it&rsquo;s motivating everyone to see that the community is active as always.</p>

<p><em>The script I created to generate the charts isn&rsquo;t too nice at the moment, <del>but I promise to publish it once I cleaned it up a bit. If you can&rsquo;t wait to get your hands on it, feel free to send me a mail or tweet.</del> &ndash; but I published it anyways: <a href="https://github.com/tolleiv/Repo-Activity-Monitor">github.com/tolleiv/Repo-Activity-Monitor</a></em></p>

<p>Links in short: <a href="http://blog.tolleiv.de/impact-chart">Impact chart</a>, <a href="http://blog.tolleiv.de/impact-chart/stat.html">Monthly &ldquo;Top 20&rdquo; tables</a>.</p>

<hr />

<ul>
<li>The scoring includes the commits to the Core master and all related submodule commits. Unfortunately the submodule commits don&rsquo;t hold the reviewer and tester information. Also some of the latest changes made in the submodules may not show up at the moment because the submodule pointers haven&rsquo;t been updated yet.
<strong> Inspired by the incredible RaphaëlJS vector graphics library which is distributed with an MIT license and can be found on <a href="http://raphaeljs.com/">raphaeljs.com</a>
</strong>* Again &ndash; don&rsquo;t take it too serious &ndash; the scoring doesn&rsquo;t take into account that some patches can be written in 15 minutes where others take days. It also only uses the final testers and reviewers mentioned in the commit message, other contributions are not counted atm</li>
</ul>

]]></content>
  </entry>
  
  <entry>
    <title type="html"><![CDATA[TemplaVoila 1.6.x]]></title>
    <link href="http://blog.tolleiv.de/2012/01/templavoila-1-6-x/"/>
    <updated>2012-01-16T08:10:33+01:00</updated>
    <id>http://blog.tolleiv.de/2012/01/templavoila-1-6-x</id>
    <content type="html"><![CDATA[<p>Quite some things changed in the past months and I never found the time to clear up my mind and write up a summary.</p>

<p>First of all <a href="http://typo3.org/extensions/repository/view/templavoila/current/">TemplaVoila 1.6</a> was released parallel to <a href="http://typo3.org/download/release-notes/typo3-46/">TYPO3 4.6</a>. It shipped with 22 bug and compatibility fixes. In general the 1.6.x branch is supposed to be compatible with TYPO3 4.4+ which also made it possible to clean up the extension quite a bit. In addition to that TemplaVoila 1.6.1 will show up in the TER in the next few hours. It fixes 10 additional issues.</p>

<p>Besides that, the main repository for TemplaVoila was moved to <a href="git.typo3.org/TYPO3v4/Extensions/templavoila">git.typo3.org</a> and the old Subversion repository and my Github repository have been removed. The new repository location also enables and enforces a new way to contribute code changes for the project. Comparable to the TYPO3v4 Core every change request can be sent to Gerrit, where I can review the changes before they get merged into the repository. That workflow turns out to be very efficient for me. A detailed summary on how to contribute code to any repository hosted on <a href="http://git.typo3.org">git.typo3.org</a> can be found on <a href="http://wiki.typo3.org/Contribution_Walkthrough_Tutorials">wiki.typo3.org</a>. To sum up some of the steps &ndash; here&rsquo;s how you submit a patch*:</p>

<pre><code>git clone git://git.typo3.org/TYPO3v4/Extensions/templavoila.git
cd templavoila
scp -p -P 29418 &lt;username&gt;@review.typo3.org:hooks/commit-msg .git/hooks/
git checkout -b workingBranch
# ... work on the files ...
git add &lt;changedFile&gt;
git commit
git push origin HEAD:refs/for/master/&lt;topic&gt;
</code></pre>

<p>A further general change to the team happend more or less silently. During 2011 nobody from the old team or any new developer showed interest in the project and only few contributors helped with bugfixes or reviews. Due to that I also changed my attitude regarding future releases.
I&rsquo;m currently planning to release one version parallel with every main TYPO3 4.x release, to make sure that TemplaVoila works in new versions and to make sure people can enjoy TYPO3 with TemplaVoila in the future as well. I&rsquo;ll also try to keep it compatible with all &ldquo;stable&rdquo; releases and aim to keep the issue count within the bugtracker as low as possible.
But I&rsquo;m not planning to integrate new major features such as the field content sliding (use <a href="http://typo3.org/extensions/repository/view/kb_tv_cont_slide/current/">EXT:kb_tv_cont_slide</a> please) or a context sensitive content wizard (a.k.a &ldquo;content firewall&rdquo;). Also major refactorings won&rsquo;t happen because they&rsquo;d consume far too much of my time &ndash; therefore also the desperately needed update of the mapping module or a new new page module will not be implemented in the near future.</p>

<p>Nevertheless I&rsquo;m open for any type of contribution and I&rsquo;d be happy to review and test any patch showing up in Mantis or Gerrit &ndash; I&rsquo;m just not able to spent a major part of my freetime for it.</p>

<hr />

<ul>
<li>You have to sign the <a href="http://typo3.org/about/licenses">Contributor License Agreement</a> to be able to push any change &ndash; it can be found on <a href="http://typo3.org/about/licenses">typo3.org</a></li>
</ul>

]]></content>
  </entry>
  
  <entry>
    <title type="html"><![CDATA[Further reading 2011]]></title>
    <link href="http://blog.tolleiv.de/2011/12/further-reading-2011/"/>
    <updated>2011-12-30T11:00:01+01:00</updated>
    <id>http://blog.tolleiv.de/2011/12/further-reading-2011</id>
    <content type="html"><![CDATA[<p>Holiday time is usually a great opportunity to take time for things which didn&rsquo;t really fit into the passed by year and to pick up things which help me to see beyond my nose. Along with some paper work and some house work there&rsquo;s quite a list of programming related things I read and tried during the last days. And to give you some inspiration here&rsquo;s my list:</p>

<ul>
<li><p><a href="http://pragprog.com/book/tpp/the-pragmatic-programmer">The Pragmatic Programmer: From Journeyman to Master</a> &ndash; a must read for every programmer and once in a while worth to take a look at. It also opens up tons of other topics which you should be pragmatic at.</p></li>
<li><p><a href="http://www.cs.utexas.edu/~shmat/courses/cs345/whyfp.pdf">Why Functional Programming Matters</a> &ndash; introducing the concepts of lazy evaluation and high-order functions for a couple of mathematical examples. With <a href="http://streamjs.org/">Steam.js</a> as implementation of lazy evaluation in JavaScript.</p></li>
<li><p><a href="http://research.google.com/archive/mapreduce.html">MapReduce: Simplified Data Processing on Large Clusters</a> &ndash; every now and then I&rsquo;m trying to get my hands dirty with <a href="http://couchdb.apache.org/">CouchDB</a> and re-reading this paper and the related works is always a good start.</p></li>
<li><p>Some texts worth looking at when it comes to user stories <a href="http://benmabey.com/2008/05/19/imperative-vs-declarative-scenarios-in-user-stories.html">Imperative vs Declarative Scenarios in User Stories</a>, <a href="http://www.codesqueeze.com/the-easy-way-to-writing-good-user-stories/">The Easy Way to Writing Good User Stories</a>, <a href="http://trailridgeconsulting.com/files/user-story-primer.pdf">A User Story Primer</a>, <a href="http://blog.nayima.be/2009/12/30/how-do-you-estimate-the-business-value-of-user-stories/">How do you estimate the Business Value of User Stories? You don’t.</a>, <a href="http://blog.josephwilk.net/agile/story-smells-the-valueless-story.html">Story Smells: The Valueless Story</a></p></li>
<li><p><a href="http://aslakhellesoy.com/post/11055981222/the-training-wheels-came-off">The training wheels came off</a> &ndash; shows how valuable BDD scenarios should look like and why the cucumber-rails (ruby gem) stopped shipping predefined step definitions to enforce better scenarios among newcomers.</p></li>
<li><p><a href="http://www.codesqueeze.com/what-your-dog-can-teach-you-about-building-teams/">What Your Dog Can Teach You About Building Teams</a> - a blog post which has a good point, it misses some background information though. In depth insights might come from <a href="http://www.management30.com/book/">Management 3.0: Leading Agile Developers, Developing Agile Leaders</a> and <a href="http://mikecohnsignatureseries.com/books/coaching-agile-teams">Coaching Agile Teams: A Companion for ScrumMasters, Agile Coaches, and Project Managers</a> which I won&rsquo;t have time to look into :(</p></li>
<li><p><a href="http://www.rubyinside.com/screencast-coding-conways-game-of-life-in-ruby-the-tdd-way-with-rspec-5564.html">Coding Conway’s Game of Life in Ruby the TDD Way with RSpec #1</a> &ndash; a great screencast showing TDD in action with Ruby and RSpec. This 50min screencast shows how things evolve during TDD coding sessions and how models can grow within test suits.</p></li>
</ul>


<p>What&rsquo;s on your list?</p>
]]></content>
  </entry>
  
  <entry>
    <title type="html"><![CDATA[Tagging page caches]]></title>
    <link href="http://blog.tolleiv.de/2011/12/tagging-page-caches/"/>
    <updated>2011-12-22T18:23:16+01:00</updated>
    <id>http://blog.tolleiv.de/2011/12/tagging-page-caches</id>
    <content type="html"><![CDATA[<p>In our small TYPO3 world it&rsquo;s quite common to have list and single views for extensions on specific pages. That&rsquo;s quite nice because once a record is changed it allowes users to flush the caches for these pages automatically, using:</p>

<pre><code>TCEMAIN.clearCacheCmd=all|&lt;pid&gt;
</code></pre>

<p>But of course it isn&rsquo;t very smart to clear all caches once you have filled them up for hundred or even thousand records. To work around these limits it&rsquo;s quite handy to use an API which lives in <a href="http://git.typo3.org/TYPO3v4/Core.git?a=commit;h=03af46">TYPO3 since 2008</a>. It allows to add tags to the page cache and removes the caches by tag.</p>

<p>Adding tags to the current page can be done with this block:</p>

<pre><code>$GLOBALS['TSFE']-&gt;addCacheTags(array('tx_example_model:' . $id));
</code></pre>

<p>Removing the caches for that specific page could look like this:</p>

<pre><code>$GLOBALS['typo3CacheManager']-&gt;getCache('cache_pages')-&gt;flushByTag('tx_example_model:' . $id);
</code></pre>

<p>Correctly integrating this with your extension is quite easy. To set the tags, add the first block into your controller and make sure you provide the proper uid for the rendered domain objects. To remove the caches once a record is saved in the backend just register a t3lib_tcemain hook and flush the tagged caches.</p>

<p>Credits: <a href="http://twitter.com/fbrnc">Fabrizio Branca @fbrnc</a> &ndash; thx for pointing me to it ;)</p>

<hr />

<p>The <a href="http://blog.tolleiv.de/2010/03/handling-data-in-typo3-with-tcemain/">Tcemain-Hook</a> could be integrated with these two snippets:
<em>EXT:example/Classes/Hooks/Tcemain.php</em></p>

<pre><code>class Tx_Example_Hooks_Tcemain {
    public function processDatamap_afterDatabaseOperations($status, $table, $id, $fieldArray, &amp;$reference) {
        if ($table == 'tx_example_model') {
            $GLOBALS['typo3CacheManager']-&gt;getCache('cache_pages')-&gt;flushByTag('tx_example_model:' . $id);
        }
    }
}
</code></pre>

<p><em>EXT:example/ext_localconf.php</em></p>

<pre><code>$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['t3lib/class.t3lib_tcemain.php']['processDatamapClass']['example'] = 'EXT:example/Classes/Hooks/Tcemain.php:Tx_Example_Hooks_Tcemain';
</code></pre>
]]></content>
  </entry>
  
  <entry>
    <title type="html"><![CDATA[Signal / Slots in Extbase]]></title>
    <link href="http://blog.tolleiv.de/2011/11/signal-slots-in-extbase/"/>
    <updated>2011-11-30T18:17:02+01:00</updated>
    <id>http://blog.tolleiv.de/2011/11/signal-slots-in-extbase</id>
    <content type="html"><![CDATA[<p>A nice thing to have at hand is definately <a href="http://en.wikipedia.org/wiki/Signals_and_slots">Signal and Slots</a>. I heard <a href="http://f.oer.tel">Felix</a> talking about them quite often and I finally found a nice usecase and came to play with them a little bit this afternoon. And just to avoid that others have to look around too much to find how they can get them to work here&rsquo;s how it&rsquo;s working for me.</p>

<p>First of all you should understand the concept. This nice little &ldquo;definition&rdquo; (from <a href="http://flow3.typo3.org/documentation/guide/partiii/signalsandslots.html">flow3.typo3.org</a>) sums it up pretty well:</p>

<blockquote><p>A signal, which contains event information as it makes sense in the case at hand, can be emitted (sent) by any part of the code and is received by one or more slots, which can be any function<del> in FLOW3</del> in extbase.</p></blockquote>

<p>To get this running in extbase, you&rsquo;ve to get hold of the <em>Tx_Extbase_SignalSlot_Dispatcher</em>, which is the central instance to manage all of it. Within Extbase that&rsquo;s done easily with this snippet within your classes:</p>

<pre><code>   ...
    /**
     * @var Tx_Extbase_SignalSlot_Dispatcher
     */
    protected $signalSlotDispatcher;

    /**
     * @param Tx_Extbase_SignalSlot_Dispatcher $signalSlotDispatcher
     */
    public function injectSignalSlotDispatcher(Tx_Extbase_SignalSlot_Dispatcher $signalSlotDispatcher) {
        $this-&gt;signalSlotDispatcher = $signalSlotDispatcher;
    }
   ...
</code></pre>

<p>Next thing is to make use of it. The Slot (listener) part could look like one of following blocks. In all cases you define the Signal by it&rsquo;s class (not necessarily a PHP Class) and it&rsquo;s name. Next to that the Slot can either be defined by a Closure, an object with a method name or a PHP-Class and a method name.</p>

<pre><code>   ...
// Using a closure
$this-&gt;signalSlotDispatcher-&gt;connect(
      'Crunching', 'emitDataReady', function($data) { crunch($data) }, NULL, FALSE
);
   ...
// Using a method of the current object
$this-&gt;signalSlotDispatcher-&gt;connect(
     'Crunching', 'emitDataReady', $this, 'crunch', FALSE
);
   ...
// Using a method of the specified class
$this-&gt;signalSlotDispatcher-&gt;connect(
     'Crunching', 'emitDataReady', 'Cruncher', 'crunch', FALSE
);
   ...
</code></pre>

<p>To trigger the Signal which invokes the Slots registered above, you&rsquo;ve to run the following code.</p>

<pre><code>$this-&gt;signalSlotDispatcher-&gt;dispatch('Crunching', 'emitDataReady', array($data));
</code></pre>

<p>One thing I found was that by default the <em>Tx_Extbase_SignalSlot_Dispatcher</em> it not a Singleton in older extbase versions. Bastian fixed that already in the <a href="https://review.typo3.org/#change,6785">master</a> and <a href="https://review.typo3.org/#change,6786">1-4</a> branches and lucky enough this change was part within the TYPO3 4.6.1 release. But I think it&rsquo;s still important to mention that this wasn&rsquo;t the default from the beginning on.</p>

<p>Even if <a href="http://flow3.typo3.org/documentation/guide/partiii/signalsandslots.html">AOP is a nicer way to implement this feature</a>, the extbase backport still works pretty straigh forward.</p>

<p>Edit: One thing I&rsquo;ve to add &ndash; Felix is not &ldquo;just&rdquo; talking about Signal/Slots &ndash; he&rsquo;s the one to thank for the <a href="https://review.typo3.org/1563">backport</a>. And now that his <a href="http://blog.foertel.com/2011/10/using-signalslots-in-extbase/">blog</a> is running again &ndash; this post seems like a summary ;)</p>
]]></content>
  </entry>
  
  <entry>
    <title type="html"><![CDATA[Release reviews (templavoila, imagemap_wizard, workspaces)]]></title>
    <link href="http://blog.tolleiv.de/2011/02/release-reviews-templavoila-imagemap_wizard-workspaces/"/>
    <updated>2011-02-24T22:17:14+01:00</updated>
    <id>http://blog.tolleiv.de/2011/02/release-reviews-templavoila-imagemap_wizard-workspaces</id>
    <content type="html"><![CDATA[<p>I just push the TER upload button two times and in addition to that TYPO3 4.5.2 will be released tomorrow containing some nice workspaces updates. So here&rsquo;s a short summary what happened in the extension releases.</p>

<p><strong>TemplaVoila 1.5.4</strong>
The current release focussed on 4.5 compatibility. It uses the new sys_language flag &ldquo;format&rdquo; to support sprites, it hooks into the new backend-form <em>(TCA)</em> &ldquo;layout&rdquo; and add&rsquo;s it&rsquo;s fields to the right tabs within the backend forms and adjusts everything to work fine with the new CSRF mechanism.</p>

<p>Besides that bug fixes for the section index, performance improvements and a couple more are included.</p>

<p><em>One thing in conjunction with 4.5 you should be aware of is that copied elements are hidden by default. In older versions hidden elements won&rsquo;t show up in the page module by default and therefore it might seem that nothing was copied, but that&rsquo;s not right. With 1.5.4 the default setting was changed so hidden elements will show up in the page module. Unfortunately the old setting (to skip hidden elements) might still be present in your session settings &ndash; so please either clear your session settings or use the &ldquo;Advanced function&rdquo; tab in the page module to change to setting and avoid confusion.</em></p>

<p><strong>Imagemap_wizard 0.6.0</strong>
The last versions proved to be very stable and with some additional sponsoring I was able to improve the DAM and TYPO3 workspaces support. Besides that a couple of issues which showed up in 4.4 and 4.5 were fixed. One of the next features will hopefully be a useful point of interest implementation &ndash; keep your fingers crossed that someone&rsquo;s clients want&rsquo;s to sponsor some time for that ;)</p>

<p><strong>Workspaces 4.5.1 / 4.5.2</strong>
Even if it&rsquo;s shipped with the Core and included in the <a href="http://news.typo3.org/news/article/typo3-451-released/">official release notes</a>, here&rsquo;s my summary of the improvements. The workspace module itself brought us lot&rsquo;s of good feedback and also the new workspace preview raised some attention. Even though 4.5.0 was quite stable we weren&rsquo;t able to get it working perfectly. The fixes made for 4.5.1 made sure that especially the preview window works much more stable, it introduced state persistence (so switching preview modes or module settings are memorized properly) and it brought some performance improvements.
Btw. if you didn&rsquo;t check out the new workspaces features and improvements the<a href="http://forge.typo3.org/projects/typo3v4-workspaces/repository/entry/workspaces/trunk/Documentation/manual.pdf"> new workspaces documentation from Susanne Moog</a> is a good point to start.</p>
]]></content>
  </entry>
  
  <entry>
    <title type="html"><![CDATA[TYPO3 4.5 beta1]]></title>
    <link href="http://blog.tolleiv.de/2010/11/typo3-4-5-beta1/"/>
    <updated>2010-11-18T22:48:31+01:00</updated>
    <id>http://blog.tolleiv.de/2010/11/typo3-4-5-beta1</id>
    <content type="html"><![CDATA[<p>As announced on <a href="http://news.typo3.org/news/article/typo3-45beta1-released/">news.typo3.org</a> yesterday the TYPO3 Core team published TYPO3 4.5 beta. With this beta the features for the next version are fixed and the remaining time until the release will be used for polishing and bug fixing.
A complete list of the included features and changes can be found on <a href="http://forge.typo3.org/projects/typo3v45-projects/wiki/TYPO3_450beta1">forge.typo3.org</a>.</p>

<p>As member of the <a href="http://blog.tolleiv.de/2010/06/typo3-workspaces/">TYPO3 workspace team</a> I&rsquo;d like to encourage everyone to send as much feedback as possible for all the workspace related changes and since <a href="http://blog.tolleiv.de/2010/10/templavoila-1-5-released/">maintaining TemplaVoila</a> is also still on my list, it would be great if you let me know if you find any TemplaVoila related issues with the new TYPO3 version.</p>

<p>If you&rsquo;d like to stay up-to-date with the latest changes in the TYPO3 Core, without reading all the newsgroup messages, you might be interested to use the <a href="http://feeds.feedburner.com/TYPO3-CoreTrunkChangelog">TYPO3 trunk Changelog RSS feed</a>. Besides the feed there&rsquo;s a great service from the Core team, they started to publish the protocol of their weekly meeting as <a href="http://lists.typo3.org/pipermail/typo3-project-v4/2010-November/000996.html">&ldquo;Minutes from the meeting of the release 4.5 team&rdquo;</a> to the typo3.project.v4 newsgroup. I hope this will be kept up in the future.</p>
]]></content>
  </entry>
  
  <entry>
    <title type="html"><![CDATA[TemplaVoila 1.5 released]]></title>
    <link href="http://blog.tolleiv.de/2010/10/templavoila-1-5-released/"/>
    <updated>2010-10-03T22:31:33+02:00</updated>
    <id>http://blog.tolleiv.de/2010/10/templavoila-1-5-released</id>
    <content type="html"><![CDATA[<p>The new version comes with many bugfixes,new features and a closer TYPO3 integration. Overall 95 issues have been resolved in the last 4 months to finalize this versions, some of the highlights are:</p>

<h4>HTML5 support</h4>

<p>The full list of HTML5 tags is now supported in TemplaVoila. The restrictions to specific tags was removed and the TYPO3 integrator is now able to use the full bandwidth of modern HTML. With this change also the tag-icons themself were replaced and the coloring schema was changed. The inspiration for the current color schema came from <a href="http://joshduck.com/periodic-table.html">Josh Duck&rsquo;s &ldquo;Periodic Table of the Elements&rdquo;</a>. In additon same mapping bugs have been resolved too &ndash; for details see <a href="http://bugs.typo3.org/view.php?id=13974">#13974</a> and <a href="http://bugs.typo3.org/view.php?id=14881">#14881</a>.</p>

<p><a href="/uploads/2010/09/tv15-page-module.png"><img src="/uploads/2010/09/tv15-page-module-300x190.png" alt="TemplaVoila 1.5 page module" /></a></p>

<h4>TYPO3 4.4 Look&amp;Feel and docHeader integration</h4>

<p>TYPO3 4.4 introduced a new skin and changed the look&amp;feel in the backend radically. Once installed in 4.4 TemplaVoila 1.5 adjusts it&rsquo;s look and provides the same usability improvements as the official page module. The page-module was optimized to use as much &ldquo;official&rdquo; CSS as possible to support designes with their own backend-skins. In addition to the CSS&amp;Markup changes, TemplaVoila also uses the <a href="http://blog.tolleiv.de/2010/07/typo3-4-4-sprites-in-your-extension/">TYPO3 4.4 SpriteIcon API</a> to provide and retrieve backend icons and uses the FlashMessage API to style all backend notifications.</p>

<p>Another important step was the integration of the so called docHeader. This is the area at the very top of each backend module page which provides useful tools and action-icons. With this version TemplaVoila finally provides docHeaders within every backend-part.</p>

<h4>Improved TYPO3 integration</h4>

<p>Besides the visual changes the general TYPO3 integration has been improved with various modifications.</p>

<p>With the current version there&rsquo;s no need to give &ldquo;Edit page&rdquo; rights to you editors if they want to add or remove content elements. Just the &ldquo;Edit content&rdquo; right and access to the &ldquo;Page>Content&rdquo; field is enough for them. For details see: <a href="http://bugs.typo3.org/view.php?id=3903">#3903</a></p>

<p>The &ldquo;advached header link inclusion&rdquo; is one of the integration steps in the frontend. All resources which are related to an FCE are passed through an TYPO3 API (pageRenderer). This avoids duplicate inclusion of one resource (e.g. CSS files) and enables further post-processing (e.g. compression or merging). It can be enabled using the &ldquo;advancedHeaderInclusion&rdquo; within your TypoScript setup which could then look like this:</p>

<pre><code>page = PAGE
page.typeNum = 0
page.10 = USER
page.10.userFunc = tx_templavoila_pi1-&gt;main_page
page.10.advancedHeaderInclusion= 1
</code></pre>

<hr />

<p>The full list of changes within this version can be found on <a href="http://bugs.typo3.org/search.php?project_id=2&amp;sticky_issues=on&amp;target_version=1.5.0&amp;sortby=last_updated&amp;dir=DESC&amp;hide_status_id=90">bugs.typo3.org</a>.
Many many thanks to all contributors and reviewers &ndash; it&rsquo;s great that more people try to help out and it keeps me motivated to continue improving this great TYPO3 extension.</p>
]]></content>
  </entry>
  
  <entry>
    <title type="html"><![CDATA[TemplaVoila on github.com]]></title>
    <link href="http://blog.tolleiv.de/2010/09/templavoila-on-github-com/"/>
    <updated>2010-09-03T17:52:14+02:00</updated>
    <id>http://blog.tolleiv.de/2010/09/templavoila-on-github-com</id>
    <content type="html"><![CDATA[<blockquote><p>Update: Finally TemplaVoila moved to git.typo3.org  &ndash; please read the <a href="http://blog.tolleiv.de/2012/01/templavoila-1-6-x/">update here</a></p></blockquote>

<p>As it seems, souce code version control for TYPO3 will be done with Git in the future. The Phoenix team already uses git.typo3.org, there&rsquo;s also already the possibility to get the latest updates for the v4 Core via <a href="http://github.com/typo3/typo3v4core">github.com</a> and it won&rsquo;t take long until git.typo3.org is been used for version 4 as well.</p>

<p>Due to the fact that my TemplaVoila development <a href="http://blog.tolleiv.de/2010/06/git-svn-for-typo3-extension-development/">workflow is also already git based</a>, I thought it might be interesting for some contributors to develop with a git repository upstream. Therefore I started to maintain a <a href="http://github.com/tolleiv/TemplaVoila">TemplaVoila repository on github.com</a> [1]. The <a href="https://svn.typo3.org/TYPO3v4/Extensions/templavoila/">Subversion repository on forge.typo3.org</a> [2] is of course still the master, but both repositories are kept in sync automatically.</p>

<p>So once you think about sending an RFC to the typo3.team.templavoila list, feel free to attach a git based patch-file.</p>

<p>[1] <a href="http://github.com/tolleiv/TemplaVoila">http://github.com/tolleiv/TemplaVoila</a>
[2] <a href="https://svn.typo3.org/TYPO3v4/Extensions/templavoila/">https://svn.typo3.org/TYPO3v4/Extensions/templavoila/</a></p>
]]></content>
  </entry>
  
  <entry>
    <title type="html"><![CDATA[Peter Sunde talking about flattr]]></title>
    <link href="http://blog.tolleiv.de/2010/08/peter-sunde-talking-about-flattr/"/>
    <updated>2010-08-02T17:11:59+02:00</updated>
    <id>http://blog.tolleiv.de/2010/08/peter-sunde-talking-about-flattr</id>
    <content type="html"><![CDATA[<p>Markus Beckedahl&rsquo;s interview with Peter Sunde brought up some interesting insights into the system of <a href="https://flattr.com/">flattr.com</a> and the idea behind it. So if you&rsquo;re interested in <a href="https://flattr.com/">flattr.com</a> you should  listen the <a href="http://www.netzpolitik.org/2010/npp095-peter-sunde-uber-flattr/">podcast on netzpolitik.org</a>.</p>

<p>My favorite quote:<em>&ldquo;In the end stupid stuff founds good stuff&rdquo;</em> P. Sunde</p>

<p>Another (shorter) interview taken during the Hacknight in Malmö can be found on <a href="http://www.nrli.tv/post/877506283/peter-sunde-discusses-flattr-an-interview-with">nrli.tv</a></p>
]]></content>
  </entry>
  
  <entry>
    <title type="html"><![CDATA[TYPO3 4.4 sprites in your extension...]]></title>
    <link href="http://blog.tolleiv.de/2010/07/typo3-4-4-sprites-in-your-extension/"/>
    <updated>2010-07-25T10:00:29+02:00</updated>
    <id>http://blog.tolleiv.de/2010/07/typo3-4-4-sprites-in-your-extension</id>
    <content type="html"><![CDATA[<p>TYPO3 4.4 ships with a long list of improvements. One of them is the sprite API which was developed during T3UXW09. It extends the iconWorks API and enables to retrieve any backend-icon from a central sprite.</p>

<p>As extension maintainer there are several ways to use these new parts of the API you can either just use it to display core icons, you can include your own icons and retrieve it with the new API or you can include your own sprite and retrieve the separate icons.</p>

<h4>Use sprite icons</h4>

<p>Using sprite icons is pretty easy, to get a checkmark icon you could use this:</p>

<pre><code>t3lib_iconWorks::getSpriteIcon('status-dialog-ok');
</code></pre>

<p>The list of all available icons can be retrieved using the &lsquo;<strong><a href="http://typo3.org/extensions/repository/view/spriteiconoverview/current/">spriteiconoverview</a></strong>&rsquo; extension which I just recently pushed into the TER ;)</p>

<h4>Add your own icons</h4>

<p>The API also provides the possibility to include your extension&rsquo;s icons using either single icons or your own icon sprite.
Using single icons can be done with the following code in your ext_tables.php or ext_localconf.php:</p>

<pre><code>$icons = array(
     'myicon' =&gt; t3lib_extMgm::extRelPath('myextension') . 'myicon.gif'
);
t3lib_SpriteManager::addSingleIcons($icons, 'myextension');
</code></pre>

<p>Using this icon is easy again:</p>

<pre><code>t3lib_iconWorks::getSpriteIcon('extensions-myextension-myicon');
</code></pre>

<p>If your extension comes with a larger amount of icons you might want to use your own sprite. This includes your sprite as a image file and a CSS file. The css file should look like this:</p>

<pre><code>.t3-icon-extensions-myextension {
     background-image:url(../../typo3conf/ext/myextension/myextension_sprite.gif);
}
.t3-icon-extensions-myextension-icon1 { background-position: 0px 0px; }
.t3-icon-extensions-myextension-icon2 { background-position: 0px -16px; }
</code></pre>

<p>The path to your sprite needs to be relative to the typo3temp/sprites/ folder, from where the (temporary) merged CSS file will be included.
This sprite can be included using:</p>

<pre><code>$icons = array(
     'extensions-myextension-icon1',
     'extensions-myextension-icon2'
);
t3lib_SpriteManager::addIconSprite(
     $icons,
     t3lib_extMgm::siteRelPath('myextension') . 'myextension_sprite.css'
);              
</code></pre>

<p>As you see it&rsquo;s quite easy to include the new API, the API provides some further options for overlays and further modifications which I didn&rsquo;t mention here. And as a final motivation this is a comparison between old and new API to get a &ldquo;back&rdquo; button:</p>

<pre><code>// old API
$icon = '&lt;img' . t3lib_iconWorks::skinImg($this-&gt;doc-&gt;backPath,'gfx/goback.gif','width="14" height="14"') . 'alt="" /&gt;';

// new API
$icon = t3lib_iconWorks::getSpriteIcon('actions-view-go-back');
</code></pre>

<hr />

<p>The sprite API is quite new and my knowledge about how to use it is also relatively fresh &ndash; so please let me know if you&rsquo;ve any remarks or questions.</p>

<h2>Btw. special kudos for his involvement during the implementation of this nice feature and many many thanks for helping me to understand it, to <a href="http://www.rs-websystems.de/">Steffen Ritter</a>  :)</h2>

<p>Further reading:</p>

<ul>
<li><p>If you&rsquo;ve never heard of sprites you might want to read this article an <a href="http://www.alistapart.com/articles/sprites">alistapart.com</a></p></li>
<li><p><a href="http://typo3.org/download/release-notes/typo3-44/">TYPO3 4.4 release notes</a></p></li>
<li><p><a href="http://news.typo3.org/news/article/t3dd10-its-all-about-sprites/">news.typo3.org &ndash; T3DD10: It&rsquo;s all about sprites</a></p></li>
<li><p><a href="http://typo3.org/extensions/repository/view/spriteiconoverview/current/">spriteiconoverview</a> extension</p></li>
</ul>


<hr />
]]></content>
  </entry>
  
  <entry>
    <title type="html"><![CDATA[T3DD10 Git workshop]]></title>
    <link href="http://blog.tolleiv.de/2010/07/t3dd10-git-workshop/"/>
    <updated>2010-07-09T00:11:29+02:00</updated>
    <id>http://blog.tolleiv.de/2010/07/t3dd10-git-workshop</id>
    <content type="html"><![CDATA[<p>I just found that <a href="http://www.xing.com/profile/Peter_Niederlag">Peter</a> shares the slides of the Git workshop from the T3DD10 on <a href="http://www.slideshare.net/jugglefish/t3dd10-git">slideshare</a>. Since this 4 hour workshop was &ndash; for many reasons &ndash; one of my favorites during the T3DD10, I felt that it&rsquo;s worth to mention it. And due to the fact that TYPO3 is moving very fast towards Git it&rsquo;s worth to look at them ;) &mdash;&ndash; <a href="http://www.slideshare.net/jugglefish/t3dd10-git">Open workshop slides</a></p>

<p>Btw. at the beginning I didn&rsquo;t belief that a Git workshop could fill 4 hours &ndash; now I don&rsquo;t think that shorter workshops make any sense :P</p>
]]></content>
  </entry>
  
  <entry>
    <title type="html"><![CDATA[Using git svn for TYPO3 extension development]]></title>
    <link href="http://blog.tolleiv.de/2010/06/git-svn-for-typo3-extension-development/"/>
    <updated>2010-06-30T08:00:30+02:00</updated>
    <id>http://blog.tolleiv.de/2010/06/git-svn-for-typo3-extension-development</id>
    <content type="html"><![CDATA[<p>When I first saw a presentation about Git 2 years ago I liked it, but I was convinced that Subversion covers all I need. Things have changed and especially the bad performance of Subversion for larger repositories and the need to commit things without messing up the official trunk motivated me to look up how to get started with Git. If you need more reasons why you should look into Git, you&rsquo;ll find them in [7] &ndash; anyways it&rsquo;s worth to have a look how I managed to work with it ;)</p>

<p>There are basically 2½ different tasks during the &ldquo;daily&rdquo; development.</p>

<ol>
<li><p> <em>Create a local working copy a.k.a clone the repository</em></p></li>
<li><p> Fix a bug or implement a feature and create a patch file with the changes</p></li>
<li><p> Receive a patch and review it &ndash; eventually commit the changes</p></li>
</ol>


<h4>0. Repository initialization</h4>

<p>Getting started and creating the repository from an existing Subversion repository looks like this:</p>

<pre><code>mkdir templavoila
cd templavoila
git svn init -t tags -b branches -T trunk https://svn.typo3.org/TYPO3v4/Extensions/templavoila
git-svn fetch
</code></pre>

<p>This will pull the entire SVN history into your local Git repository &ndash; use &ldquo;git-svn fetch -r &rdquo; to reduce the amount of imported revisions.</p>

<p>To keep your repository up-to-date you need these commands:</p>

<pre><code>git stash
git-svn fetch
git rebase trunk
git stash apply
</code></pre>

<p>If you followed the SVN trunk/tags/branches convention you should see that it also finds tags and branches during the import. But using &ldquo;git branch&rdquo; afterwards you&rsquo;ll see that there&rsquo;s only one local branch called &ldquo;master&rdquo;. That&rsquo;s where Git shows it&rsquo;s strength the first time, because it distinguishes between local and remote branches. Work can only be done within local branches, whereas the existing SVN branches are only recognized as &ldquo;remote&rdquo; branches so far. To list all remote branches you can use &ldquo;git branch -r&rdquo;. If you followed the trunk/tags/branches convention, you should see your SVN tags and branches within this list &ndash; otherwise you might want to read [8]. To make a remote (SVN) branch available in your local repository use:</p>

<pre><code>git checkout --track -b tv_1-4 templavoila_1-4
</code></pre>

<h4>1. Working with the repository</h4>

<p>Starting to work on a new feature or a bug always starts with a new branch in git:</p>

<pre><code>git branch issue00012345
git checkout issue00012345
</code></pre>

<p>You&rsquo;re now working in the &ldquo;issue00012345&rdquo; branch and all commits will just be committed to that branch. Once you made changes  you can either just commit all modifications with:</p>

<pre><code>git commit -a
</code></pre>

<p>or add particular files and commit only these files with:</p>

<pre><code>git add fileA
git add fileB
git commit
</code></pre>

<p>or with a nice pre commit preview which lets you decide which lines you want to commit:</p>

<pre><code>git add --patch
git commit
</code></pre>

<p><strong>Preparing the patch for the mailingslist:</strong>
In a pure Git workflow &ldquo;git format-patch&rdquo; is used to communicate patches, but due to the fact that there&rsquo;s a Subversion repository involved either the old style diff / patch or a workaround needs to be used to communicate changes.
Creating a patch which works for the mailinglist can basically be done using:</p>

<pre><code>git diff --no-prefix master &gt; myPatchFile.patch
</code></pre>

<p>An alternative workaround to create proper SVN diff files (including svn revision etc..) can be found in [10] it&rsquo;s used very straight forward:</p>

<pre><code>git svn-diff &gt; mySvnPatchFile.patch
</code></pre>

<h4>2. Review and commit patches</h4>

<p><strong>Reviewing the patch someone sent to the list:</strong>
As &ldquo;usual&rdquo;</p>

<pre><code>patch -p0 &lt; myPatchFile.patch
</code></pre>

<p>can be used to apply patch files.</p>

<p>Once the files passed the review the changes can be committed using &ldquo;<strong>git add</strong>&rdquo; and &ldquo;<strong>git commit</strong>&rdquo; as shown before.</p>

<p><strong>Committing to Subversion:</strong>
Once you committed everything to your local repository you&rsquo;re able to perform this command to &ldquo;forward&rdquo; your commits to the Subversion repository.</p>

<pre><code>git svn dcommit
</code></pre>

<p>Practically every single commit within git will also be reflected as a single Subversion commit. For several reason this might not always suit your situation.As a workaround you could merge all commits during the merge of your feature branches into the master branch using:</p>

<pre><code>git merge --commit --squash issue00012345
git svn dcommit
</code></pre>

<p>Of course I don&rsquo;t recommend to do this for your regular work since have small granular commits is always better.</p>

<h4>Sources and further reading</h4>

<p>[1] <a href="http://spyced.blogspot.com/2009/06/patch-oriented-development-made-sane.html">Patch-oriented development made sane with git-svn</a>
[2] <a href="http://utsl.gen.nz/talks/git-svn/intro.html#using">An introduction to git-svn for Subversion/SVK users and deserters</a>
[3] <a href="http://git-scm.org/course/svn.html">Git &ndash; SVN Crash Course</a>
[4] <a href="http://trac.parrot.org/parrot/wiki/git-svn-tutorial">Getting the GIT checkout</a>
[5] <a href="http://nathanj.github.com/gitguide/tour.html">An Illustrated Guide to Git on Windows</a>
[6] <a href="http://stackoverflow.com/questions/1129688/git-svn-workflow-feature-branches-and-merge">git svn workflow &ndash;
feature branches and merge</a>
[7] <a href="http://whygitisbetterthanx.com/#any-workflow">whygitisbetterthanx.com</a>
[8] <a href="http://www.dmo.ca/blog/20070608113513/">Multiple branches using git-svn</a>
[9] <a href="http://www.viget.com/extend/effectively-using-git-with-subversion/">Effectively using Git with subversion</a>
[10] <a href="http://mojodna.net/2009/02/24/my-work-git-workflow.html">Git Workflow with Upstream SVN</a></p>

<h4>Notes</h4>

<ul>
<li><p>Don&rsquo;t try to dcommit to <a href="https://svn.typo3.org/TYPO3v4/Extensions/templavoila">https://svn.typo3.org/TYPO3v4/Extensions/templavoila</a> unless you know what you&rsquo;re doing &ndash; I just used it to show you that it&rsquo;s even working with large history projects.</p></li>
<li><p>For projects hosted on forge.typo3.org there might be a native git support soon &ndash; stay tuned</p></li>
<li><p>Let me know if you had problems with any of the snippets</p></li>
<li><p>Further information about the review process for the TYPO3 Core and several other TYPO3 related projects can be found on <a href="http://typo3.org/teams/core/resources/maintenance-policy/">typo3.org</a></p></li>
</ul>

]]></content>
  </entry>
  
</feed>
