Re: Re: Antwort: RE: Calling C2 from command line: problem with Oracle driver

2001-12-06 Thread Adrian Geissel

Hi,

Have you looked at the way that Cocoon generates it's own documentation from
a commandline invocation?

This may be what you are looking for in terms of generating off-line
content.

Hope this helps
Adrian

- Original Message -
From: <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Thursday, December 06, 2001 10:31 AM
Subject: Re: Re: Antwort: RE: Calling C2 from command line: problem with
Oracle driver


> Hello list,
>
> > > Why would you want to run Cocoon without Tomcat?  What can Cocoon do
> > without a servlet engine?
> >
> > It is possible because Cocoon2 is made on an abstraction that can make
it
> > interface with different containers.
> > Currently there are two abstactions (Environment) available: command
line
> > and servlet.
> > So yes, it can function on itself, no, it can't respond to http requests
by
> > itself for now.
> > Command line executes all the things in the sitemap and generates the
> > resulting files on the filesystem.
>
> Once again, to make it clear, what I want to achieve...
>
> I have built a web application, which presents the informations concerning
a
> life insurance contract on our intranet.
> The web page is called like
> "file://http:server/cocoon/Contract.xsp?contract_id=1234567
>
> For looking at single contracts everything is fine.
>
> But now I want to generate all these "info sheets" for many hundreds of
> contracts and send the results to an other department, which has no
possibility
> to access our intranet.
>
> Therefor I want to "call" Cocoon with a "todo list", which could look like
this:
>   Contract.xsp?contract_id=1112234
>   Contract.xsp?contract_id=1112236
>   Contract.xsp?contract_id=1112237
>   Contract.xsp?contract_id=1112324
>   Contract.xsp?contract_id=1123534
>   Contract.xsp?contract_id=1467301
>   Contract.xsp?contract_id=1668709
>   ...
>
> Now Cocoon has to generate the html files for each uri and save it
somewhere.
>
> My intermediate results are:
>   1) Cocoon can be called from the command line by using the "run.sh"
script in
> the Cocoon root directory.
>
>   2) It is possible to configure the Cocoon call with parameters. Execute
"sh
> run.sh -h" for a list of Parms and options.
>
>   3) I have configured the run time environment in a way, that the command
line
> version takes the same sitemap files and web application files as the
servlet
> version called by tomcat.
>
> And now there is only one question left:
>   How can I tell the command line environment to load and initialize the
classes
> needed for the Oracle database access?
>   In the servlet version this is done be specifying an "init-param" in the
> web.xml
>   file with the param-name "load-class".
>
> And here I'm stuck!
>
> I think, the implementation of the class org.apache.cocoon.Main needs some
> extension, to give a possibility to the user to achieve the same things,
as
> init-param in web.xml does in the servlet case.
>
> Thanks
> Christoph
>
>
>
> -
> 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: Re: Antwort: RE: Calling C2 from command line: problem with Oracle driver

2001-12-06 Thread Luke Studley

If it works from http why not just write a simple http client and a batch
file / shell script to call the servlet engine and output the results to
file?

You can use java.net.* to do this quite easily, or you might want to look at
http://jakarta.apache.org/commons/httpclient/index.html

Luke


-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] 
Sent: 06 December 2001 10:31
To: [EMAIL PROTECTED]
Subject: Re: Re: Antwort: RE: Calling C2 from command line: problem with
Oracle driver

Hello list,

> > Why would you want to run Cocoon without Tomcat?  What can Cocoon do
> without a servlet engine?
>
> It is possible because Cocoon2 is made on an abstraction that can make it
> interface with different containers.
> Currently there are two abstactions (Environment) available: command line
> and servlet.
> So yes, it can function on itself, no, it can't respond to http requests
by
> itself for now.
> Command line executes all the things in the sitemap and generates the
> resulting files on the filesystem.

Once again, to make it clear, what I want to achieve...

I have built a web application, which presents the informations concerning a
life insurance contract on our intranet.
The web page is called like
"//http:server/cocoon/Contract.xsp?contract_id=1234567

For looking at single contracts everything is fine.

But now I want to generate all these "info sheets" for many hundreds of
contracts and send the results to an other department, which has no
possibility
to access our intranet.

Therefor I want to "call" Cocoon with a "todo list", which could look like
this:
  Contract.xsp?contract_id=1112234
  Contract.xsp?contract_id=1112236
  Contract.xsp?contract_id=1112237
  Contract.xsp?contract_id=1112324
  Contract.xsp?contract_id=1123534
  Contract.xsp?contract_id=1467301
  Contract.xsp?contract_id=1668709
  ...

Now Cocoon has to generate the html files for each uri and save it
somewhere.

My intermediate results are:
  1) Cocoon can be called from the command line by using the "run.sh" script
in
the Cocoon root directory.

  2) It is possible to configure the Cocoon call with parameters. Execute
"sh
run.sh -h" for a list of Parms and options.

  3) I have configured the run time environment in a way, that the command
line
version takes the same sitemap files and web application files as the
servlet
version called by tomcat.

And now there is only one question left:
  How can I tell the command line environment to load and initialize the
classes
needed for the Oracle database access?
  In the servlet version this is done be specifying an "init-param" in the
web.xml
  file with the param-name "load-class".

And here I'm stuck!

I think, the implementation of the class org.apache.cocoon.Main needs some
extension, to give a possibility to the user to achieve the same things, as
init-param in web.xml does in the servlet case.

Thanks
Christoph



-
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: Re: Antwort: RE: Calling C2 from command line: problem with Oracle driver

2001-12-06 Thread Christoph . Oberle

Hello list,

> > Why would you want to run Cocoon without Tomcat?  What can Cocoon do
> without a servlet engine?
>
> It is possible because Cocoon2 is made on an abstraction that can make it
> interface with different containers.
> Currently there are two abstactions (Environment) available: command line
> and servlet.
> So yes, it can function on itself, no, it can't respond to http requests by
> itself for now.
> Command line executes all the things in the sitemap and generates the
> resulting files on the filesystem.

Once again, to make it clear, what I want to achieve...

I have built a web application, which presents the informations concerning a
life insurance contract on our intranet.
The web page is called like
"//http:server/cocoon/Contract.xsp?contract_id=1234567

For looking at single contracts everything is fine.

But now I want to generate all these "info sheets" for many hundreds of
contracts and send the results to an other department, which has no possibility
to access our intranet.

Therefor I want to "call" Cocoon with a "todo list", which could look like this:
  Contract.xsp?contract_id=1112234
  Contract.xsp?contract_id=1112236
  Contract.xsp?contract_id=1112237
  Contract.xsp?contract_id=1112324
  Contract.xsp?contract_id=1123534
  Contract.xsp?contract_id=1467301
  Contract.xsp?contract_id=1668709
  ...

Now Cocoon has to generate the html files for each uri and save it somewhere.

My intermediate results are:
  1) Cocoon can be called from the command line by using the "run.sh" script in
the Cocoon root directory.

  2) It is possible to configure the Cocoon call with parameters. Execute "sh
run.sh -h" for a list of Parms and options.

  3) I have configured the run time environment in a way, that the command line
version takes the same sitemap files and web application files as the servlet
version called by tomcat.

And now there is only one question left:
  How can I tell the command line environment to load and initialize the classes
needed for the Oracle database access?
  In the servlet version this is done be specifying an "init-param" in the
web.xml
  file with the param-name "load-class".

And here I'm stuck!

I think, the implementation of the class org.apache.cocoon.Main needs some
extension, to give a possibility to the user to achieve the same things, as
init-param in web.xml does in the servlet case.

Thanks
Christoph



-
Please check that your question has not already been answered in the
FAQ before posting. 

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




Re: Antwort: RE: Calling C2 from command line: problem with Oracle driver

2001-12-05 Thread Nicola Ken Barozzi


- Original Message -
From: "David Rosenstrauch" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Wednesday, December 05, 2001 3:37 PM
Subject: Re: Antwort: RE: Calling C2 from command line: problem with Oracle
driver


> At 08:49 PM 12/4/01 +0100, you wrote:
> >My question is:
> >
> >I want to call Cocoon2 from then command line WITHOUT Tomcat.
>
>
> A number of people have asked about how to do this, and I'm just curious:
>
> Why would you want to run Cocoon without Tomcat?  What can Cocoon do
without a servlet engine?

It is possible because Cocoon2 is made on an abstraction that can make it
interface with different containers.
Currently there are two abstactions (Environment) available: command line
and servlet.
So yes, it can function on itself, no, it can't respond to http requests by
itself for now.
Command line executes all the things in the sitemap and generates the
resulting files on the filesystem.
If you want to make an Environment for Avalon-Phoenix you are welcome!

Nicola Ken Barozzi These are the days of miracle and wonder...
  ...so don't cry baby, don't cry
<[EMAIL PROTECTED]> Paul Simon


-
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: Antwort: RE: Calling C2 from command line: problem with Oracle driver

2001-12-05 Thread David Rosenstrauch

At 08:49 PM 12/4/01 +0100, you wrote:
>My question is:
>
>I want to call Cocoon2 from then command line WITHOUT Tomcat.


A number of people have asked about how to do this, and I'm just curious:

Why would you want to run Cocoon without Tomcat?  What can Cocoon do without a servlet 
engine?


DR


-
Please check that your question has not already been answered in the
FAQ before posting. 

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