SourceWritingTransformer error

2002-05-28 Thread Olivier Rossel

Can anyone try this HOWTO and tell me if he/she gets the abnormal 
behaviour described here:

http://www.mail-archive.com/cocoon-dev%40xml.apache.org/msg16998.html

I would like to know if this bug is known and has been corrected.

PS: it is something that is in the scratchpad (I think). If you do not 
know what it is, you don't care.


-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html

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




Re: TreeProcessor performance

2002-05-27 Thread Olivier Rossel

COuld you please give us your bench with a brand new version of the 
sitemap.xmap (for example, edit it, change a line, save the file, 
measure the perf with a given processor, and reprocess all that for each
processor).

On a slow 128MB machine, sitemap compilation takes ages to complete.
TreeProcessor is much faster.

I did not try with Saxon.


Graaf, Edgar de (fin) wrote:

 Hi,
 
 Recently I installed the TreeProcessor instead of compiling. Everyone says
 it is faster then compiling the sitemap, so I didn't test it. Then I
 installed Saxon and tot test Saxon I did a Jmeter test. My application
 collapsed from 6 seconds average response time to 20 seconds!? So I put
 xalan back, 27 seconds!? Then I put the compiled version back and I got 6
 seconds my question to you is: 
 
 Does anybody know why this could be? Does the TreeProcessor cost more
 memory? (I only have 196 MB) Are there some bugs in certain versions of the
 TreeProcessor? Or is the TreeProcessor just not scaleable?
 
 Thanks,
 
 Edgar
 
 -
 Please check that your question has not already been answered in the
 FAQ before posting. http://xml.apache.org/cocoon/faqs.html
 
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 



-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html

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




Re: Aggregation sample

2002-04-19 Thread Olivier Rossel



Anyway, check the logs for better information about the stylesheet directed
termination error, most probably there is a typo in your sitemap.

BTW, it seems that the error reporting of Cocoon could be improved.

Why doesn't the error page mention the text of the exception? It is
available in the error.log  but people do not always know that this file 
exists,
and it is sometimes difficult to reach.
Idem for typo in the stylesheets: the error message is meaningless, and 
the real
info is in the log.

XSP compilation errors are reported nicely now.
Is it so hard to report other errors the same way?





-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html

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




Re: File Upload using action or any other approach

2002-04-16 Thread Olivier Rossel



 Hello?

 Has anyone accomplished to upload files from html forms 
 to the server to a specific directory ..

 Yes, I did, with an action. What is the problem? 

Can you please explain how you did that?
Or may be provide us the code, if it is not copyrighted?


-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html

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




Re: dynamically composing cinclude tag

2002-04-15 Thread Olivier Rossel



[EMAIL PROTECTED] wrote:

Hello!

In my xsp-page the following statemet works correctly:

 cinclude:include src=cocoon:/SimpleTable.htm element=xxx/
 
However I'm required to assign the value of src dynamically. 

Initially I tried this statement which did not work:

cinclude:include
src=xsp:expr(String)((java.util.Map)request.getAttribute(restructComps)).get(uiSimple)
 element=xxx/


Later I tried the following:
 
 cinclude:include
  xsl:attribute
name=srcxsp:expr(String)((java.util.Map)request.getAttribute(restructComps)).get(uiSimple)/xsp:expr/xsl:attribute
  xsl:attribute name=elementxxx/xsl:attribute
 /cinclude:include
 
.. which did not work.

Try xsp:attribute instead of xsl:attribute




-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html

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




Extracting an XML subtree with a transformer

2002-04-10 Thread Olivier Rossel

I wish to extract the tag /task/title from my XML generated.
I think that using a XSL for that is a bit heavy, so I would like to use
an existing transformer.

I tried FragmentExtractorTransformer, but I think the name
of the tag that is used for extraction must be declared not in
the map:pipeline (instanciation part), but in the map:components 
(declaration part). Am I wrong?
It seems also that the tag must have a namespace or the transformer does 
not trigger.
Am I wrong?

So I have tried the FilterTransformer.
It seems that 3 parameters must be filled:
element-name (here i said title)
but also the block number (what is it???)
and the number of rows(???)

It seems strange that those very specific transformers exist, and there 
is no default
transformer that can accept simply the name of a tag and extract the 
sub-tree that corresponds.

Any information is welcome.


-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html

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




Error when XML file for a map:part is absent.

2002-03-27 Thread Olivier Rossel

I make a map:aggregate with two XML files.

If both files are ok, the output is ok.

If one file is missing, half the output is an exception (a FileNotFound 
exception).

Most of the time, displaying an exception is bad.
So I would like the erroneous map:part simply be ignored, and the 
correct map:part be processed
as usual.



-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html

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




Re: Another problem with Cocoon 2.0.2

2002-03-26 Thread Olivier Rossel

I use C2.0.2 with JDK1.3.1_02 from Sun.

I try to generate the xjavadocs.
I use the command ./build.sh xjavadocs.
It complains that:
Cannot find com.sun.xml.XmlDoclet

I wonder if this class is available by default with JDK1.3?
And if this is the correct command to have the javadocs
generated correctly for inclusion in the documentation/ directory.

I think a HOWTO about javadocs integration into the C2 samples would be 
nice.



-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html

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




Power using the sitemap.

2002-03-26 Thread Olivier Rossel

Here is my problem:
i have several similar directories structures containing XML datas, for 
each customers I have (customer1/, customer2/, customer3/)
I need to apply the same pipeline on one directory tree, depending on a 
request parameter:
when I have URL?customer=IBM, i need my pipeline to get infos from 
somewhere inside the customer1/ directory
when I have URL?customer=Microsoft, i need my pipeline to get infos 
from somewhere inside the customer2/ directory.

I wonder how I can get that.

I tought about an action that sets a variable {customerRoot} depending 
on the request parameter customer.
And my pipeline builds all its URLs using this variable.

Or a pipeline that matches any pattern, tests the requestparameter with 
a selector and makes a map:read to
an internal pipeline, and with a src containing the good customerRoot 
string

Or a session-parameter set by I do now know who :-)

I presume that pointing to a different directory structure depending on 
a parameter is classic.
I just would like to know which option you would use.




-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html

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




Re: Automatic FAQ

2002-03-22 Thread Olivier Rossel

Very good remarks.
Especially, the idea of a weblog that points to interesting URLs (web, 
mailing-list archives or whatever)
could be really nice.

Keeping reading the list is a heavy task, so a weblog could be nice when 
you have not a lot of time for it.

I am french citizen and daily reads linuxfr.org, (coded in PHP, with XML 
as the
internal exchange format :-), it could be nice to have such a thing for 
Cocoon people.

It would be a must-read for any hard-core fan of Cocoon :-)
And the entry point of the Cocoon community.




-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html

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




External graphic, FOP and URIResolver

2002-03-21 Thread Olivier Rossel

Tell me if I am wrong:
FOP only accepts standard URLs for external-graphic src  attribute.
file://
http://
are ok.

No relative path, and no cocoon pseudo-protocol.

Can anyone confirm?

Is it possible that FOP uses the URIResolver of Cocoon instead, in order to
understand pseudo-protocol (especially cocoon:// and resource://) ?

Is there a trick in order to use relative paths in FOP? (I read the 
archives and everyone
seems to use full URLs :-(


-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html

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




Cinclude accepts only XML as input.

2002-03-21 Thread Olivier Rossel

I want to Cinclude a text retrieved from a clob in a database.
My idea was to have a internal pipeline that serialize as text the given 
clob (generate=serverpages, serialize=text).
The internal pipeline works well.

Now i want to cinclude it (using the cocoon:// pseudo-protocol).
The problem is that whatever I do, the cincluded stuff is always a XML 
fragment that is the output of the pipeline BEFORE the
text serialization.

Is it a bug? a misconfiguration on my side?
Does cinclude always get the data before serialization?
Or may be cocoon: ?


-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html

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




Re: Serving PDF's

2002-03-20 Thread Olivier Rossel



Phil Blake wrote:

 Hi all,

 I want to serve PDF's - nothing special, no generation or 
 transformation - simply returning an existing pdf from a request.

 So... I added the following to my sitemap:

map:match pattern=**pdf/**.pdf
 map:read src=resources/pdf/{2}.pdf mime-type=application/pdf/
/map:match

 I have a pile of PDF's in the /resources/pdf directory, however, none 
 of them are successfully served.

 Only a small amount of the original  PDF is transfered - ie. it's a 
 200K doc but less than 50K ends up at the browser and as far as 
 acrobat is concerned - it's damaged.

 What silly thing have I missed?

 Thanks in advance,

 Phil 

Not sure that it helps. But I have heard about a nasty bug in IE+Acrobat 
plug-in.
If you use them, you should try a different browser to check the serving 
of the PDF.

(I think the bug is about streaming PDF, that are handled incorrectly by IE)


-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html

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




Re: Running Cocoon on non-compliant servlet engines

2002-03-20 Thread Olivier Rossel



shameless-plug
For the same project, I also wrote the BlobSource (see 
http://www.mail-archive.com/cocoon-dev@xml.apache.org/msg12945

.html) for 
which I had no feedback up to now. Nobody interested in this ?
/shameless-plug

How can it be used? Are there any use-cases or samples?

I wonder if hsqldb can handle blobs? If so, then we can easily add an 
example that shows how
Cocoon can map:read a blob inside a database, in order to (for 
example) retrieve a GIF.

In addition to the blob source, I wonder if a clob source can be 
programmed in order to retrieve
text for a database using a pseudo-URL like 
clob://database/table/field[conditions of selection].

An nice example could be that a SVG is retrieved from a CLOB then 
transformed into a JPEG
and displayed inside a PDF :-)

BTW, great job Sylvain :-P


-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html

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




Streaming PDF.

2002-03-15 Thread Olivier Rossel

I wonder if FOP serializer can stream PDF documents instead of buffering 
the whole document before sending it.
I was told that it is because of a nasty bug in IE/Acrobat plug-in. But 
the FOP Serializer has already the capability.

Is it true?
Can this behaviour be enabled?




-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html

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




Q? about the pseudo protocol resource:

2002-03-13 Thread Olivier Rossel

I have several XSL files in a jar.
I call the main one via the pseudo protocol resource:/path/to/main.xsl

The problem is that main.xsl has several xsl:include.
How can I handle them?

Can i have relative URIs in my foobar.xsl?
Will Cocoon automagically understands that the protocol should be 
resource: / ?





-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html

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




C2-dev and iPlanet

2002-03-12 Thread Olivier Rossel

I tried to launch C2-dev (current CVS) with a old version of iPlanet and 
JDK1.2.2
I have no web.xml so I use all the default values (it works with 
Tomcat4+JDK1.3).
The servlet does not starts correctly.
Here is the error I get:
[12/Mar/2002:16:02:53] info (11168): Internal Info: loading servlet Cocoon2
[12/Mar/2002:16:02:54] info (11168): Cocoon2: init
[12/Mar/2002:16:03:04] info (11168): WARN(2002-03-12) 16:03.04:844   
[cocoon  ] (Unknown-URI) Unknown-thread/CocoonServlet: Servlet 
initialization argument 'configurations' not specified, attempting to 
use '/cocoon.xconf'

[12/Mar/2002:16:03:04] info (11168): INFO(2002-03-12) 16:03.04:876   
[cocoon  ] (Unknown-URI) Unknown-thread/CocoonServlet: Reloading from: 
file:/prj1-appli/appli/uc00_dev/V2_J2EE/httpd-01/html/cocoon.xconf

[12/Mar/2002:16:03:05] failure (11168): Internal error: unexpected 
exception thrown from the servlet init function (servlet 
class=org.apache.cocoon.servlet.CocoonServlet): 
javax.xml.transform.TransformerFactoryConfigurationError: Provider for 
javax.xml.transform.TransformerFactory cannot be found, Stack: 
javax.xml.transform.TransformerFactoryConfigurationError: Provider for 
javax.xml.transform.TransformerFactory cannot be found
 at java.lang.Throwable.fillInStackTrace(Native Method)
 at java.lang.Throwable.fillInStackTrace(Compiled Code)
 at java.lang.Throwable.init(Compiled Code)
 at java.lang.Error.init(Error.java:50)
 at 
javax.xml.transform.TransformerFactoryConfigurationError.init(Unknown 
Source)
 at javax.xml.transform.TransformerFactory.newInstance(Unknown Source)
 at Unloaded Method
 at org.apache.cocoon.Cocoon.contextualize(Cocoon.java:183)
 at 
org.apache.cocoon.servlet.CocoonServlet.createCocoon(CocoonServlet.java:1189)
 at org.apache.cocoon.servlet.CocoonServlet.init(CocoonServlet.java:399)
 at 
com.netscape.server.http.servlet.NSServletEntity.load(NSServletEntity.java:377)
 at 
com.netscape.server.http.servlet.NSServletEntity.update(NSServletEntity.java:149)
 at 
com.netscape.server.http.servlet.NSServletRunner.Service(NSServletRunner.java:469)

Anyone understands this exception:
javax.xml.transform.TransformerFactoryConfigurationError: Provider for 
javax.xml.transform.TransformerFactory cannot be found




-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html

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




Re: JDK 1.4, cocoon 2.0.2-dev, tomcat 4.0.3

2002-03-11 Thread Olivier Rossel

Claas Thiele wrote:

Can I start cocoon without X server with 1.4


Yes, start the JVM with following argument: -Djava.awt.headless=true

see also: http://java.sun.com/j2se/1.4/docs/guide/awt/AWTChanges.html#headless


Claas Thiele

It is very important that such informations are available on the page 
Installing Cocoon.
WHo's the guy who manages it? Or which CVS should be updated?

My pieces of advices about PJA for JDK1.3 and Tomcat, and this piece of 
advice about JDK1.4
MUST be added, IMHO.
Plus the way to manage JDK1.4, Tomcat 4.0.3-bin and c2-dev.



-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html

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




Re: [FYI] Success Story - Cocoon-based Web-CMS with Vignette-Integration

2002-03-09 Thread Olivier Rossel

Stefan Seifert wrote:

We developed in a big project roughly spanning the past 1,5 years a
Java-based Web Content Management System using Cocoon 2 with
Vignette-Integration.

The result of the first development phase (the live website) you can see
at
http://www.gruene-fraktion.de (german). The System was developed by
gedas for the 'parliamentary faction of Bündnis90/Die Grünen' (the
German Green Party).

Some technical/architectional information:
 - The live-site is powerd by a farm of 5 web-/application and database
servers
 - The whole Live-Website is generated by Cocoon 2.0.1
 - The data (metadata, XML/XHTML-Fragments, Image data) is stored in a
relational database
 - Each page delivery consists af a bunch of complex aggregated
XSP-Pages using ESQL, transformed with XSLT-Stylesheets for different
layouts
 - Output is done in HTML, HTML Print version, PDF, RTF, Text (all
generated from the same content) and JPEGs (for graphical menus). (In
the live-site you will see at this moment only HTML output - the other
formats are used live in the near future).
 - For some reasons the caching mechanisms of Cocoon where not used but
it was decided to run this high-traffic Website on Vignette, using the
Vignette-Caching-Mechanisms.
 - Vignette is used for some other special community-features like
Online-Voting
 - The Content Management System itself is a traditional JSP/Java-Based
n-tiered System running in IE5 and higher and Netscacpe 4.7 and higher,
using a java applet for authoring formatted XHTML fragements. Some
additional feaures: Complex User Roles, simple Workflow,
Image+Link-Management etc.
 - A sort of 'cache manager daemon' does on-demand-regeneration of
changed pages
 - The system supports the administration of several sites in the same
web farm with completely different layouts
 - The system is used by up to 200 editors who can edit content -
without having to know anything about HTML or XML.


In late 2000 we took a first look at Cocoon 1 and did some prototyping
and implemented the system using Cocoon 2 since it reached first beta.
We were very impressed by the features and architecture of cocoon. The
first architecture was planned as a vignette-only website, but because
the lack of sufficient XML-support in Vignette (and other reasons) we
decided to use Cocoon as core system and Vignette only for caching and
cluster management and never looked back!

Using the sitemap-concept of Cocoon 2 it was very easy to implement the
cryptic Vignette URL syntax like ..xyz/0,938,123,00.htm and Vignette
Integration was made very easy.

Thanks to all developers maintaining and extending cocoon!
Its an excellent system! (some wishes, of course, remain)

The Content Managemenet System itself is unfortunately closed-souce, but
perhaps we can give some of our cocoon-related know-how as 'power-user'
back to the community in the future.

Stefan

It sounds an impressive job.
I wonder if you developped your own X(HT)ML authoring applet?
I think this is the component that Cocoon is lacking for further 
evolutions in CMS applications.
Q42.nl plans to open-source version2 of their product.
XXE is a GREAT editor, but license is quite hard to manage with.
Your applet solution (if open-sourcing things is planned on your side) 
would be great.


-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html

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




Re: Yet another newbie boring question, sorry... (mounting - compila tion error)

2002-03-08 Thread Olivier Rossel

TREGAN Fabien wrote:

I'm trying to mount my subsitemap in C2 :

-Cocoon example are running well.

-in cocoon/sitemap.xmap i haded :
   map:match pattern=caw/*
   map:mount uri-prefix=caw check-reload=yes
src=caw/sitemap.xmap/
   /map:match

-in cocoon/caw/sitemap.xmap I have :

?xml version=1.0?
map:sitemap xmlns:map=http://apache.org/cocoon/sitemap/1.0;
  
   map:pipelines
   map:pipeline
   map:match pattern=*.xml
   map:generate src={1}.xml/
   map:transform src=simple.xsl/
   map:serialize/
   /map:match
   /map:pipeline
   /map:pipelines

/map:sitemap

-Result :
Generated .java file is uncomplete :

It ends with :
  /** Prepare patterns of PreparableMatchers. */
  public void prepareMatchers() throws Exception {

Wich give an exception...

Any idea ?

fabien.

org.apache.cocoon.ProcessingException: Language Exception:
org.apache.cocoon.components.language.LanguageException: Error compiling
sitemap_xmap:
Line 213, column 54:  '}' expected.
Line 0, column 0: 
1 error

   at
org.apache.cocoon.components.language.generator.ProgramGeneratorImpl.createR
esource(ProgramGeneratorImpl.java:338)
   at
org.apache.cocoon.components.language.generator.ProgramGeneratorImpl.load(Pr
ogramGeneratorImpl.java:294)
   at org.apache.cocoon.sitemap.Handler.run(Handler.java:270)
   at java.lang.Thread.run(Thread.java:484)
org.apache.cocoon.components.language.LanguageException: Error compiling
sitemap_xmap:
Line 213, column 54:  '}' expected.
Line 0, column 0: 
1 error

   at
org.apache.cocoon.components.language.programming.java.JavaLanguage.compile(
JavaLanguage.java:244)
   at
org.apache.cocoon.components.language.programming.CompiledProgrammingLanguag
e.load(CompiledProgrammingLanguage.java:197)
   at
org.apache.cocoon.components.language.generator.ProgramGeneratorImpl.generat
eResource(ProgramGeneratorImpl.java:386)
   at
org.apache.cocoon.components.language.generator.ProgramGeneratorImpl.createR
esource(ProgramGeneratorImpl.java:331)
   at
org.apache.cocoon.components.language.generator.ProgramGeneratorImpl.load(Pr
ogramGeneratorImpl.java:294)
   at org.apache.cocoon.sitemap.Handler.run(Handler.java:270)
   at java.lang.Thread.run(Thread.java:484)

-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html

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

We have has the same kind of problem.
We had to declarate a valid generator, a valid transfromer and a valid 
serializer at the beginning of the sitemap.
Then it went ok.



-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html

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




Re: Yet another newbie boring question, sorry... (mounting - com pila tion error)

2002-03-08 Thread Olivier Rossel

TREGAN Fabien wrote:

Thanks you, I added them all, it worked.

But I did'nt like that, so I removed them, and it still works... :)

[WHO sayed that Computer Sciences are Science ?]

You should be very cautious with sitemap caching.
Sometimes it caches stuff even if the sitemap has changed.

It does not happen all the times, but it happens :-)

My conclusion (at the moment) is that sitemap is relaoded at the second 
request you make. Not the first.
If anyone confirms...

PS: i am talking about the CVS version.


-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html

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




Re: HTTP 404 error and sitemap setting

2002-03-08 Thread Olivier Rossel

Mamadou Bobo Sylla wrote:

I have cleared the sub-directories of work, started
Tomcat but the error persists.

By the way both voice-email.xml and
voice-exam-result.xml receive parameters.

Any other suggestion?

I wonder if the serverpages generator accepts XML files as input.
Isn't it supposed to be XSP files (with xsp:page as the root element and 
the xsp namespace declared)?
Could the file generator be better?

What you can do also is to make the same pipeline for both files.
Here is the syntax:

map:match pattern=sic/xsp/*.xml
 map:generate type=serverpages
   src=sic/xsp/{1}.xml/
 map:transform type=xslt
src=sic/{1}.xsl/
 map:serialize type=xml/
/map:match

Try that with the serverpages generator and the file generator.



-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html

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




Re: upload dir

2002-03-07 Thread Olivier Rossel

Cocoon User wrote:

i'm using cocoon 2.0.rc2
with tomcat and apache

how can i change the upload for the upload.xsp?


thanks
kounis stavros
osmosis.gr

the upload dir is defined in your WEB-INF/web.xml
The upload dir is unique to your cocoon instance.



-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html

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




FOP strange rendering.

2002-03-06 Thread Olivier Rossel

It seems that FOP guys do not know why my DF renders like that:
some cells with a background make borders disappear.

You can have a look at:
http://www.anyware-tech.com/test.pdf

Cells labelled Paragraph, Reference, Title should have
black solid borders.

Anyone ever had this problem?


-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html

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




Re: FOP strange rendering.

2002-03-06 Thread Olivier Rossel

O'Flaherty, Colm wrote:

It looks like the foreground colour is overlaying the background border, for
what that's worth.

If you remove the foreground colour, does it work??

I use the background-color=lightgrey on the table-cell.
If I remove the attribute, the borders displays correctly.

Should I use another attribute in order to set the background color of 
the inner part of the cell?


-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html

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




Session management.

2002-03-05 Thread Olivier Rossel

I want to enable a session anytime a new user arrives on a given page, 
si I can use the ReadDOMSession/WriteDOMSession later
in the website.

Is there an action to simply enable a session. No validation, no 
nothing, just a session opened.
It seems that I can use the HttpRequest.getSession() to enable it, but 
it supposes that i code a XSP.

I am newbie at session management, and hope you can help.


-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html

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




Re: Merging Cocoon2 and a webapp, same context

2002-03-05 Thread Olivier Rossel

Florent Soulière wrote:

 OK, I have news with my problem: http://localhost:8080/examples/cocoon 
 works fine, actually, but every other URL in the form 
 http://localhost:8080/examples/cocoon/foobar seems to be resolved by 
 Tomcat instead of Cocoon with its sitemap!!! So for every request I 
 get Apache Tomcat/4.0.1 - HTTP Status 404.
 How can I force Cocoon resolving in place of Tomcat's???
 I thought that a servlet mapping with the URI /cocoon was enough... 
 but apparently not!

You need an explicit rule in the sitemap that matches completely the 
substring of the URL that is after the context name.
Something like
map:match pattern=**
 map:read src={0} type=text/html/
map:match

For that you will probably use wildcards (* and **).
Have a look at the default sitemap for an explanation.


-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html

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




Re: Sitemap question

2002-03-04 Thread Olivier Rossel

Stefano Bonnin wrote:

Hi, I have a simple question about cocoon 2 sitemap:

I defined a simple pipeline for my personal application.

When I try to run the web application Tomcat return me the following error:


**
Apache Tomcat/4.0.1 - HTTP Status 404 - Not Found




type Status report

message Not Found

description The requested resource (Not Found) is not available.


Something in my sitemap.xman doesn't work, but what? Where can I see in more
detail this error?

Thanks.

There is no error.
Just that the sitemap was completely parsed and no match between your 
URL and a pipeline match pattern could be found.
You should have a look at the match=... of your sitemap that should 
have responsed to your URL.
The sitemap receives not the full URL but only the substring that is 
after the context name in the URL.

Hope it helps.



-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html

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




Re: Sitemap question

2002-03-04 Thread Olivier Rossel

Stefano Bonnin wrote:

ok

How can I define a very simple pipeline that gets the initial URI and
present a simple HTML file?

you must understand that sitemap.xconf is the only relation between your 
URL and the files on your disk.
There is no direct mapping such as in Apache or usual web servers.
If you want to access a file, there must be a rule somewhere in your 
sitemap that handles it.
Or you will get (guess...) error 404.

For example:

in the cocoon directory I define the following subdirectory:

myApplication

and I put into this directory the following html file:

myfile.html

Now, I want that cocoon display this html file in the browser every time
that a user access to it.
This is (I think) the more stupid pipeline supported by cocoon.

Then, if I define the following sitemap.xmap:




map:pipeline
map:match pattern=
map:redirect-to uri=myApplication/myfile.html/
/map:match
/map:pipeline

The rule tells the browser to change its URL so it is:
http://serverName/contextName/myApplication/myfile.html


The browser then tries to connect to Cocoon with this URL.
You need a sitemap rule that handles it, or it is error404.

For example a rule can be:
map:match pattern=myApplication/*.html
 map:read src={0} type=text/html/
/map:match

It matches any URL that corresponds to a html file in the directory 
myApplication.
The map:read provides the data as is to the client, with no 
server-side transformation or parsing.
It is useful when you want to send static content, such as html files or 
image files (you can think of it as a direct mapping, as in Apache).
The {0} is replaced by the pattern that has been matched by the rule 
(easy to understand if you have a bit of knowledge with regexp).
And that's all folks.
Use that, and Cocoon will serve static HTML files correctly.


-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html

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




Re: Dynamic (Session) XML -- XSP -- XSL

2002-02-25 Thread Olivier Rossel

Jegadish wrote:

 Hi,
 I have a serious problem,Which I don't know how to solve.Please help 
 me to solve this problem.
 I have a Xml string (A) put in session by a servlet and a Xsp is 
 called.( without any XML file pre-existing )

  

 eg: (A)

  

 ARCHIVES 
 MESSAGES
 STARTMSGNO1/ STARTMSGNO
 ENDMSGNO10/ ENDMSGNO
 MOREMSGSFALSE/ MOREMSGS
 /MESSAGES
 /ARCHIVES

  

  

 The Xsp  pulls out the string (A) from session

 and it's ARCHIVES \MESSAGES\ MOREMSGS value is changed to TRUE .
 How can I call a Xsl to render the Xml (A) being modified in the Xsp.
 Thankz for any help
 Jegadish.P


I am not sure to understand really your problem.
You are in the classic process of XSP generation + XSL transformation + 
HTML (or whatever) serialization.
You should describe a pipeline in your sitemap.xconf that matches the 
URL that ends with the name of your xsp, and
describe which XSL is supposed to be used, and which serializer is launched.

I sent a previous message about the general philosophy of sitemaps:
http://marc.theaimsgroup.com/?l=xml-cocoon-usersm=101431445503415w=2



-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html

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




Re: No X or AWT blues

2002-02-22 Thread Olivier Rossel

Bert Van Kets wrote:

 Here's how I installed PJA:

 I copied the PJA jar files to the jre/lib/ext directory and added the 
 following line to the catalina.sh file

 CATALINA_OPTS='-Xbootclasspath/p:/usr/local/pja/lib/pja.jar 
 -Dawt.toolkit=com.eteks.awt.PJAToolkit 
 -Djava2d.font.usePlatformFont=false 
 -Djava.awt.graphicsenv=com.eteks.java2d.PJAGraphicsEnvironment 
 -Djava.awt.fonts=/usr/local/jdk1.3.1_02/jre/lib/fonts 
 -Duser.home=/usr/local/pja -cp 
 /usr/local/jdk1.3.1_02/jre/lib/ext/pjatools.jar'

 works fine on a headless SuSE 7.3 machine.  You might have to change 
 the paths a little. 

I do not see the point of coping pja.jar in any subdirectory of the JRE...
I think the -Xbootclasspath can point to any directory (as you mention 
it one line after!!!).

One other thing that I do not understand:
why do you use pjatools? it is not needed.



-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html

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




Having a function in a XSP.

2002-02-18 Thread Olivier Rossel

Supposing I repaet the same XSP fragment several times in my XSP page.
And I wish to factorize that with a function which receives 
parameters,  and
is a kind of XSP fragment.

Is it possible?
Can I create an inner class with methods inside a XSP?


-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html

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




ESQL doc.

2002-02-14 Thread Olivier Rossel

I read the archives of the mailing-list about ESQL and nested queries.
I read an interesting thing about ancestor in the declaration of inner 
requests.
But I can find no documentation at all, about that point.

Anyone has a link?
Any docs has been updated in addition to the page available at:
http://xml.apache.org/cocoon/userdocs/xsp/esql.html ?

My problem is to have something like:

query1 select foobar, foo, bar from table1;
for each foobar:  { 
   query2 select * from table2 where field1=current-value-of foobar;
for each barfoo (selected by the previous query, inside the '*'): {
query3 select * from table3 where field1=current-value-of barfoo;
}
get-columns-of query2
get-columns-foo-of query1
get-columns-bar-of query1
}

I do not plan to use a single complicated SQL request in order to have a 
flat XML
output.


-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html

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




Fixes for the X11 problem are failing!!!

2001-10-03 Thread Olivier Rossel

Gianugo Rabellino wrote:

Anthony,

If I manage to solve the problem, I'll get back to you, if not - has

anyone

got a solution - no way I can install X on our servers.


I think you'd better start with a fresh and sitemap: take out not only
the component references (including PDF) but even the samples, since
some of them rely on SVG.
I hope I can find the time to write a short note about this issue.

Besides, while I concur that this is an annoyance, an headeless X server
adds little or no overhead at all to the machines. You might want to
test an AWT version floating around (if I recall correctly it's called
pure Java AWT) that should not need X at all, but I'm not sure if it
works as a drop-in replacement (using -Xbootclasspath or some trick like
that) or if you have to change the imports and recompile.

**
Solution 1 : using PJA as an alternative to built-in AWT.
PJA does not require a X server to launch
***

Problem:

DEBUG   (2001-10-03) 19:24.23:382   [cocoon  ] (/cocoon/) 
Thread-17/DefaultComponentFactory: ComponentFactory creating new 
instance of org.apache.cocoon.serialization.XMLSerializer.
DEBUG   (2001-10-03) 19:24.23:382   [cocoon  ] (/cocoon/) 
Thread-17/DefaultComponentFactory: no logger attribute available, using 
standard logger
DEBUG   (2001-10-03) 19:24.23:382   [cocoon  ] (/cocoon/) 
Thread-17/PoolableComponentHandler: ComponentHandler initialized for: 
org.apache.cocoon.serialization.XMLSerializer
DEBUG   (2001-10-03) 19:24.23:383   [cocoon  ] (/cocoon/) 
Thread-17/ExcaliburComponentSelector: Adding 
org.apache.cocoon.serialization.XMLSerializer for svgxml
ERROR   (2001-10-03) 19:24.25:704   [cocoon  ] (/cocoon/) 
Thread-17/Handler: Error compiling sitemap
java.lang.ExceptionInInitializerError: java.lang.ClassCastException: 
com.eteks.java2d.PJAGraphicsEnvironment
at java.awt.Toolkit$2.run(Toolkit.java:510)
at java.security.AccessController.doPrivileged(Native Method)
at java.awt.Toolkit.getDefaultToolkit(Toolkit.java:489)
at java.awt.SystemColor.updateSystemColors(SystemColor.java:342)
at java.awt.SystemColor.clinit(SystemColor.java:335)
at 
org.apache.batik.css.value.DefaultSystemColorResolver.activeBorder(DefaultSystemColorResolver.java:27)
at 
org.apache.batik.css.value.ColorFactory.init(ColorFactory.java:75)
at 
org.apache.batik.css.value.CommonValueFactoryMap.init(CommonValueFactoryMap.java:39)
at 
org.apache.batik.css.svg.SVGValueFactoryMap.init(SVGValueFactoryMap.java:39)
at 
org.apache.batik.css.svg.SVGValueFactoryMap.init(SVGValueFactoryMap.java:32)
at 
org.apache.batik.dom.svg.SVGDOMImplementation.init(SVGDOMImplementation.java:79)
at 
org.apache.batik.dom.svg.SVGDOMImplementation.clinit(SVGDOMImplementation.java:59)
at 
org.apache.batik.dom.svg.SAXSVGDocumentFactory.init(SAXSVGDocumentFactory.java:59)
at org.apache.cocoon.xml.dom.SVGBuilder.init(SVGBuilder.java:44)
at 
org.apache.cocoon.serialization.SVGSerializer.init(SVGSerializer.java:46)
at java.lang.Class.newInstance0(Native Method)
at java.lang.Class.newInstance(Class.java:237)
at 
org.apache.avalon.excalibur.component.DefaultComponentFactory.newInstance(Unknown 
Source)
at 
org.apache.avalon.excalibur.pool.AbstractPool.newPoolable(Unknown Source)
at 
org.apache.avalon.excalibur.pool.AbstractPool.internalGrow(Unknown Source)
at 
org.apache.avalon.excalibur.pool.SoftResourceLimitingPool.grow(Unknown 
Source)
at 
org.apache.avalon.excalibur.pool.SoftResourceLimitingPool.initialize(Unknown 
Source)
at 
org.apache.avalon.excalibur.component.PoolableComponentHandler.initialize(Unknown 
Source)
at 
org.apache.avalon.excalibur.component.ExcaliburComponentSelector.addComponent(Unknown 
Source)
at 
org.apache.cocoon.sitemap.SitemapComponentSelector.addSitemapComponent(SitemapComponentSelector.java:91)
at 
org.apache.cocoon.sitemap.AbstractSitemap.load_component(AbstractSitemap.java:231)
at 
org.apache.cocoon.www.sitemap_xmap$Configurer.configSerializers(sitemap_xmap.java:1412)
at 
org.apache.cocoon.www.sitemap_xmap.configure(sitemap_xmap.java:829)
at 
org.apache.avalon.excalibur.component.DefaultComponentFactory.newInstance(Unknown 
Source)
at 
org.apache.avalon.excalibur.component.ThreadSafeComponentHandler.initialize(Unknown 
Source)
at 
org.apache.cocoon.components.language.generator.GeneratorSelector.addGenerator(GeneratorSelector.java:143)
at 
org.apache.cocoon.components.language.generator.ProgramGeneratorImpl.addCompiledComponent(ProgramGeneratorImpl.java:348)
at 
org.apache.cocoon.components.language.generator.ProgramGeneratorImpl.load(ProgramGeneratorImpl.java:183)
at org.apache.cocoon.sitemap.Handler.run(Handler.java:208)
at java.lang.Thread.run(Thread.java:484)


Here is the error I have when I install pja.jar in my 

Cocoon2 with no batik at all.

2001-10-02 Thread Olivier Rossel

Summary for the lucky ones who have a X11 server on their web server:

A X11 display i required in order to initialize batik correctly.
A X11 display is typically not available on a webserver machine.
So there are various tricks to obtain one (mainly a virtual X11 server)

Of course, my administrator does not think that a X11 server will ever 
hit his machine,
any time during this 3rd millenium.

What's the answer?
Php, Jsp?
NO

One mail on the list seems to say that a proper sitemap.xmap can avoid
any call to any batik routine, so you can remove the batik-libs.jar.
What a great news!!!
Did anyone made that?
Is his sitemap.xmap available somewhere?

Is it true? Or am I condemned to the neanderthal world of servlets?

Any help is welcome.

PS: this X server problem is really a mess!!!


-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html

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