I have rebuilt cocoon from its CVS "latest source distribution".  I'm not
sure exactly which version that is distributed but I believe it might be
2.0.4 due to the timestamp.  After troubleshooting some pipeline and
map:match pattern issues, I realized that the generated sitemap_xmap.java
file that is created by cocoon (tomcat work folder) will properly set the
pattern for my matches for the first sequential map:match tag.  All
subsequent matches will have the pattern of ""


[code]
          // Prepare the pattern for "hello.html"
          this.matcher_N1006B_expr = this.preparePattern("wildcard",
"hello.html");
          
          // Prepare the pattern for "helloCustom.html"
          this.matcher_N1007C_expr = this.preparePattern("wildcard", "");
          
          // Prepare the pattern for "hellocustomgen.html"
          this.matcher_N1008D_expr = this.preparePattern("wildcard", "");
[/code]

Notice the preparePattern is coming in blank.  Here is my xmap file
snippet...

[code]
 <map:pipelines>
 
        <map:pipeline>   
                <map:match pattern="hello.html" type="wildcard">
                        <map:generate src="test/hello.xml" />
                    <map:transform src="test/hello.xsl" />
                    <map:serialize type="html" />
                </map:match>
        </map:pipeline>
 
        <map:pipeline>   
                <map:match pattern="helloCustom.html" type="wildcard">
                        <map:generate type="myGenerator" />
                        <map:transform src="test/hello.xsl" />
                    <map:serialize type="html" />
                </map:match>
        </map:pipeline>
        
 
        <map:pipeline>   
                <map:match pattern="hellocustomgen.html" type="wildcard">
                        <map:generate type="myGenerator" />
                        <map:transform src="test/hello.xsl" />
                    <map:serialize type="html" />
                </map:match>
        </map:pipeline>

</map:pipelines>
[/code]



I've tried placing the map:match tags all inside one pipeline as well with
the same results.  If I switch them around, they will have their correct
values for the first match only.  Each one works properly by itself.

I noticed something similar with session issues causing blank values from
the CVS builds in earlier posts.  Does anyone have insight into this?


>On Mon, 8 Apr 2002, James Harris wrote:
>
>> After having numerous problems trying to get sessions to work, looking
back
>> through the mailing list I discovered the messages below...  Am I to
believe
>> from this that sessions in cocoon 2.0.1 are problematic if not broken?
This
>> has perplexed me all day so I would appreciate a quick response from
>> someone.  Is it fixed in 2.0.2?
>
>Sessions work in c2.0.1, were broken in 2.0.2 and are fixed in current
>CVS.
>
>HTH,
>
>Andrew.




--
Derek Guardiola
Elsevier
Sr. Software Engineer

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to