Re: Complicated setup

2002-12-06 Thread Simeon Walker
Hi,

I've come to this thread a few days late but I thought I would mention
how I did it as no body else here seems to have done it this way.

In tomcat the Cocoon servlet is mounted at the root, i.e. no prefix.

I started out using mod_jk and used JkMount for ech of the top level
sections of our website. This looked like it worked and left apache
to handle all other URL's (images,css,big file downloads etc).

But when I came to implement i18n I found that the browsers acccept-language
request headers did not make it though to Cocoon :-(

I got around this by having tomcat (one of the 4.0 milestones at the time)
listen on an http port 127.0.0.1:8080 and using mod_proxy in apache.
In this way I could get all the headers passed to Cocoon and it all
works.

So, in httpd.conf I have:

# this handle some servlets and svg paths to Cocoon

	JkWorkersFile /etc/tomcat/jk/workers.properties
	JkLogLevel error
	JkLogFile /var/log/apache/mod_jk.log
	JkMount /svg/* ajp13
	JkMount /servlet/* ajp13
	JkMount /testpilot/*.tp3 ajp13


# handle redirects sent from Cocoon

	ProxyPassReverse / http://127.0.0.1:8080/



	RewriteEngine on
	RewriteLog /var/log/apache/rewrite.log
	RewriteLogLevel 1
	# I snipped out some legacy url re-writing here...

	# This handles the home page
	RewriteRule ^/$ http://127.0.0.1:8080/ [P]

	# This handles each top level section
	RewriteRule /(search|auth|login|school|people|gazette|teaching|research|admin)/(.*) 
http://127.0.0.1:8080/$1/$2 [P]
	# Note: mozilla did the wrapping here!


That's about it.

Maybe some time I should try the latest tomcat and mod_jk to see if
the problem with the language headers still exists. Currently I'm using
Cocoon 2.0.4-dev and tomcat 4.0.5.

Sim


On 12/03/02 14:34, Jeremy Quinn wrote:
Hi All

Can anyone advise me on getting this complicated setup right?

We have a website that will have some stuff served by Cocoon and some 
served by Apache.

It is not easy to separate them out because we need to retain legacy 
URLs. Likewise, it is not possible to give Cocoon served material a URL 
prefix, primarily because we need Cocoon to serve the home page of the 
site.

 From Cocoon:

/
/index
/general/*
/archive/*
/x-space/*
etc. (about 10 items)

 From Apache:

/images/*
/movies/*
/audio/*
/x-spaceprojects/*
/harlem/*
etc. (also about 10 items)


And then we need Slide-based WebDAV access to the Cocoon based material, 
with Cocoon generating from the Slide repository . and this I have 
still never had working .

If necessary we /could/:
a) place all static content in a single directory and redirect (legacy 
URLs) into it from Cocoon.
b) use virtual-hosts, one for Cocoon and one for the static stuff and 
redirect from Cocoon. But redirecting to images etc. is not that great ;)

I am getting confused with all the options .. virtual-hosts, 
web-app, JK, JK2 connectors and all the options in them!

Have any of you lot tried any of this before?
How did you approach it?

Many thanks for any help


regards Jeremy








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

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

--
Simeon Walker,  email: [EMAIL PROTECTED]
School of Biological Sciences,  phone: +44 (0)1248 383702
University of Wales, Bangor,fax: +44 (0)1248 382569
Gwynedd, LL57 2UW, UK.  www: http://biology.bangor.ac.uk/



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

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




Re: [SUMMARY] Complicated setup

2002-12-06 Thread Jeremy Quinn

On Thursday, Dec 5, 2002, at 23:01 Europe/London, Charles Yates wrote:


  # Problem: now EVERYTHING is served by cocoon. No way to serve
static/legacy content by Apache!


A small quibble, but this isn't true.  You can set up an alias in
httpd.conf, for example:

Alias /images/ "/usr/java/tomcat/webapps/cocoon/resources/images/"


Options Indexes Multiviews
AllowOverride None
Order allow,deny
Allow from all



 Then any request to '/images/someimagefile will be served by
apache, even with cocoon context at '/'.  At least this works for me
apache 2.0.43 mod_webapp 1.2.  This is also how I handle pdfs.
 On the other hand, Leo's excellent summary has got me thinking I
should switch to mod_jk2 . . .


I just tried this with jk_mod.

With " JkMount /* " it will not work (and that's the one I need). 
TomCat gets the ball.

Using mod_jk 1.2.0, Apache 1.3.27

regards Jeremy


-
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: [SUMMARY] Complicated setup

2002-12-05 Thread Charles Yates
>   # Problem: now EVERYTHING is served by cocoon. No way to serve  
>static/legacy content by Apache!

A small quibble, but this isn't true.  You can set up an alias in
httpd.conf, for example:

Alias /images/ "/usr/java/tomcat/webapps/cocoon/resources/images/"


Options Indexes Multiviews
AllowOverride None
Order allow,deny
Allow from all



 Then any request to '/images/someimagefile will be served by
apache, even with cocoon context at '/'.  At least this works for me
apache 2.0.43 mod_webapp 1.2.  This is also how I handle pdfs.
 On the other hand, Leo's excellent summary has got me thinking I
should switch to mod_jk2 . . .

Charles





-
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: [SUMMARY] Complicated setup

2002-12-05 Thread Mark Eggers
Folks, I added the following information to the Wikki
pages.

There are some binaries available, as well as source
packages for the various Tomcat connectors. The
connectors are now in their own project, called
jakarta-tomcat-connectors. Unfortunately there is no
home page within jakarta.apache.org that I can find,
and the online documentation does not point you to the
connector download area.

All of the connectors can be found under the following
general location:

http://jakarta.apache.org/builds/jakarta-tomcat-connectors

Explore under this directory for the latest binaries
and source packages for all of the connectors.

I hope this helps.

/mde/

just my two cents . . . .

__
Do you Yahoo!?
Yahoo! Mail Plus - Powerful. Affordable. Sign up now.
http://mailplus.yahoo.com

-
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: [SUMMARY] Complicated setup

2002-12-05 Thread Geoff Howard
I really got the impression that mod_webapp and warp
are on the way out, which was an important factor for
me even though I wasn't deploying on windows.  You may
consider mentioning at least the rumor?

Geoff

--- leo leonid <[EMAIL PROTECTED]> wrote:

> mod_webapp communicates via the new WARP protocol,
> using Tomcats  
> WarpConnector. You can easily mount whole
> webapps/contexts.
> 
>   + easy setup
> 
>   - not as stable as JK1.2
>   - poor differentiation concerning mounts
>   - no load balancing
>   - not suitable for Windows
>   - not suitable for Jetty
> 
> Sample: mounting cocoon as
> http://host.domain.tld/cocoon/
> 
>   WebAppConnection warpConnection warp localhost:8008
>   WebAppDeploy cocoon warpConnection /cocoon/
> 
> Sample: mounting cocoon as http://host.domain.tld/
> 
>   WebAppConnection warpConnection warp localhost:8008
>   WebAppDeploy cocoon warpConnection /
> 
>   # Problem: now EVERYTHING is served by cocoon. No
> way to serve  
> static/legacy content by Apache!
> 
> docs:
>
http://jakarta.apache.org/tomcat/tomcat-4.1-doc/config/
> 
> connectors.html
>   
>
http://jakarta.apache.org/tomcat/tomcat-4.1-doc/config/webapp.html
> 
> 
> (B)  
>
mod_jk__
> 
> 
> 
> mod_jk communicates via ajp1.3 protocol using an
> Ajp13Connector
> 
>   + very stable
>   + supports load balancing
>   + works with Jetty
> 
>   - long winded setup
>   - poor syntax in mount directives
>   - Maintenance of mounts needs changes to httpd.conf
> 
> 
> 
> mod_jk is configured by a configuration file named
> workers.properties:
> 
>   ### sample for workers.properties ###
> 
>   workers.apache_log=/usr/local/apache2/logs/
>   workers.tomcat_home=/usr/jakarta/catalina
>   workers.java_home=/usr/java/current
>   ps=/
>   # Define 3 workers, 2 real ajp13 and one being a
> loadbalancing worker
>   worker.list=worker1 worker2
>   # Set properties for worker1 (ajp13)
>   worker.worker1.type=ajp13
>   worker.worker1.host=host1.domain.tld
>   worker.worker1.port=8009
>   worker.worker1.lbfactor=50
>   worker.worker1.cachesize=10
>   worker.worker1.cache_timeout=600
>   worker.worker1.socket_keepalive=1
>   worker.worker1.socket_timeout=300
>   # Set properties for worker2 (ajp13)
>   worker.worker2.type=ajp13
>   worker.worker2.host=host2.domain.tld
>   worker.worker2.port=8009
>   worker.worker2.lbfactor=50
>   worker.worker2.cachesize=10
>   worker.worker2.cache_timeout=600
>   worker.worker2.socket_keepalive=1
>   worker.worker2.socket_timeout=300
>   # Set properties for worker3 (lb) which use worker1
> and worker2
>   worker.worker3.balanced_workers=worker1,worker2
> 
>    end of sample ###
> 
> in you httpd.conf you put your mount directives like
> 
>   # mounting only the index
>   JkMount /  worker2
>   # further, for example for mounting all html files
>   JkMount /*.html  worker2
>   # further, for example for mounting everything in
> dir
>   JkMount /dir/*  worker2
> 
> Things that unfortunately *DON’T* work!
> 
>   JkMount */dir/  worker2
>   JkMount **/dir/  worker2
>   JkMount /dir1/**/dir/  worker2
>   JkMount /dir1/*/dir/*/*.html  worker2
>   JkMount /!(images|movies|audio)* worker2
> 
> docs: 
>
http://www.onjava.com/pub/a/onjava/2002/11/20/tomcat.html
>   
>
http://jakarta.apache.org/tomcat/tomcat-4.1-doc/jk2/index.html
>   
> 
> (c)  
>
mod_jk2_
> 
> 
> 
> The very new JK2 communicates via ajp1.3/ajp1.4
> using  
> CoyoteConnector+JkCoyoteHandler.
> 
>   + supports load balancing
>   + supports in-process
>   + works with Jetty
>   + supports fast unix-sockets
>   + fine grained configuration
>   + easy to maintain mounts (no need to edit
> httpd.conf)
> 
>   - jk2 is not as stable as mod_jk (correct me if I
> am wrong, I did not  
> try the latest versions)
>   - lack of documentation
>   - hard to build from cvs (IMO) - no binaries
> available AFAIK
> 
> mod_jk2 is configured by a configuration file named 
> 
> workers2.properties. There you define hosts, ports,
> workers, uri  
> mapping etc:
> 
>   ### sample for workers2.properties monting cocoon
> as host.domain.tld/  
> ###
> 
>   [shm]
>   file=/usr/jakarta/catalina/work/jk2.shm
>   size=1048576
> 
>   # Example socket channel, override port and host.
>   [channel.socket:host.domain.tld:8009]
>   port=8009
>   host=127.0.0.1
> 
>   # define the worker
>   [ajp13:ministrant.leonid:8009]
>   channel=channel.socket: host.domain.tld:8009
> 
>   # Uri mapping
>   [uri:ministrant.leonid/*]
>   worker=ajp13: host.domain.tld:8009
>   context=/cocoon
> 
>    end of sample ###
> 

Re: [SUMMARY] Complicated setup

2002-12-05 Thread Jens Lorenz
Jeremy Quinn wrote:

Hi,


Hi Leo

That was an excellent summary!


I can only agree and turned Leo's mail into a Wiki page by adding a 
small amount of Wiki markup.

http://outerthought.net/wiki/Wiki.jsp?page=CocoonAndApache




Best regards,


Jens

--

Jens Lorenz

interface:projects GmbH \\|//
Tolkewitzer Strasse 49  (o o)
01277 Dresden   oOOo~(_)~oOOo
Germany


-
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: [SUMMARY] Complicated setup

2002-12-05 Thread leo leonid

On Thursday, December 5, 2002, at 04:34 PM, Jeremy Quinn wrote:


Hi Leo

That was an excellent summary!


thanks :)



The only thing I would add was that if you try to use mod_jk like this:

JkMount /* worker



ok, and maybe the hint that every mount directive must start with a '/'


it completely blocks the use of Apache for _any_ static content, 
making it very difficult (or at least, verbose) to use in certain 
circumstances.

Does mod_jk2 suffer from the same limitation?


I don't use it at the moment, so I don't know all jk2 uri-mapping 
possibilities and limitation in detail. I took a quick look on
http://marc.theaimsgroup.com/?l=tomcat-user&w=2&r=1&s=%5Buri%3A&q=b
where I found some kind of announcement of a 2.02 release that will 
supports RE's.
This will make us all happy, especially Andrew Savory :)

Many thanks for all your help

regards Jeremy

On Thursday, Dec 5, 2002, at 14:56 Europe/London, leo leonid wrote:


If you want to connect Cocoon with Apache httpd in order to serve 
static/legacy content directly from Apache you have three 
possibilities ATM (apart from the obsolete Jserv):




-
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]>





-
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: [SUMMARY] Complicated setup

2002-12-05 Thread Jeremy Quinn
Hi Leo

That was an excellent summary!

The only thing I would add was that if you try to use mod_jk like this:

JkMount /* worker

it completely blocks the use of Apache for _any_ static content, making 
it very difficult (or at least, verbose) to use in certain 
circumstances.

Does mod_jk2 suffer from the same limitation?

Many thanks for all your help

regards Jeremy

On Thursday, Dec 5, 2002, at 14:56 Europe/London, leo leonid wrote:

If you want to connect Cocoon with Apache httpd in order to serve 
static/legacy content directly from Apache you have three 
possibilities ATM (apart from the obsolete Jserv):




-
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]>




[SUMMARY] Complicated setup

2002-12-05 Thread leo leonid
If you want to connect Cocoon with Apache httpd in order to serve  
static/legacy content directly from Apache you have three possibilities  
ATM (apart from the obsolete Jserv):

a) mod_webapp
b) mod_jk
c) mod_jk2


(A)  
mod_webapp__ 


mod_webapp communicates via the new WARP protocol, using Tomcats  
WarpConnector. You can easily mount whole webapps/contexts.

	+ easy setup

	- not as stable as JK1.2
	- poor differentiation concerning mounts
	- no load balancing
	- not suitable for Windows
	- not suitable for Jetty

Sample: mounting cocoon as http://host.domain.tld/cocoon/

	WebAppConnection warpConnection warp localhost:8008
	WebAppDeploy cocoon warpConnection /cocoon/

Sample: mounting cocoon as http://host.domain.tld/

	WebAppConnection warpConnection warp localhost:8008
	WebAppDeploy cocoon warpConnection /

	# Problem: now EVERYTHING is served by cocoon. No way to serve  
static/legacy content by Apache!

docs:	http://jakarta.apache.org/tomcat/tomcat-4.1-doc/config/ 
connectors.html
		http://jakarta.apache.org/tomcat/tomcat-4.1-doc/config/webapp.html


(B)  
mod_jk__ 


mod_jk communicates via ajp1.3 protocol using an Ajp13Connector

	+ very stable
	+ supports load balancing
	+ works with Jetty

	- long winded setup
	- poor syntax in mount directives
	- Maintenance of mounts needs changes to httpd.conf



mod_jk is configured by a configuration file named workers.properties:

	### sample for workers.properties ###

	workers.apache_log=/usr/local/apache2/logs/
	workers.tomcat_home=/usr/jakarta/catalina
	workers.java_home=/usr/java/current
	ps=/
	# Define 3 workers, 2 real ajp13 and one being a loadbalancing worker
	worker.list=worker1 worker2
	# Set properties for worker1 (ajp13)
	worker.worker1.type=ajp13
	worker.worker1.host=host1.domain.tld
	worker.worker1.port=8009
	worker.worker1.lbfactor=50
	worker.worker1.cachesize=10
	worker.worker1.cache_timeout=600
	worker.worker1.socket_keepalive=1
	worker.worker1.socket_timeout=300
	# Set properties for worker2 (ajp13)
	worker.worker2.type=ajp13
	worker.worker2.host=host2.domain.tld
	worker.worker2.port=8009
	worker.worker2.lbfactor=50
	worker.worker2.cachesize=10
	worker.worker2.cache_timeout=600
	worker.worker2.socket_keepalive=1
	worker.worker2.socket_timeout=300
	# Set properties for worker3 (lb) which use worker1 and worker2
	worker.worker3.balanced_workers=worker1,worker2

	 end of sample ###

in you httpd.conf you put your mount directives like

	# mounting only the index
	JkMount /  worker2
	# further, for example for mounting all html files
	JkMount /*.html  worker2
	# further, for example for mounting everything in dir
	JkMount /dir/*  worker2

Things that unfortunately *DON’T* work!

	JkMount */dir/  worker2
	JkMount **/dir/  worker2
	JkMount /dir1/**/dir/  worker2
	JkMount /dir1/*/dir/*/*.html  worker2
	JkMount /!(images|movies|audio)* worker2

docs: 	http://www.onjava.com/pub/a/onjava/2002/11/20/tomcat.html
		http://jakarta.apache.org/tomcat/tomcat-4.1-doc/jk2/index.html
	

(c)  
mod_jk2_ 


The very new JK2 communicates via ajp1.3/ajp1.4 using  
CoyoteConnector+JkCoyoteHandler.

	+ supports load balancing
	+ supports in-process
	+ works with Jetty
	+ supports fast unix-sockets
	+ fine grained configuration
	+ easy to maintain mounts (no need to edit httpd.conf)

	- jk2 is not as stable as mod_jk (correct me if I am wrong, I did not  
try the latest versions)
	- lack of documentation
	- hard to build from cvs (IMO) - no binaries available AFAIK

mod_jk2 is configured by a configuration file named  
workers2.properties. There you define hosts, ports, workers, uri  
mapping etc:

	### sample for workers2.properties monting cocoon as host.domain.tld/  
###

	[shm]
	file=/usr/jakarta/catalina/work/jk2.shm
	size=1048576

	# Example socket channel, override port and host.
	[channel.socket:host.domain.tld:8009]
	port=8009
	host=127.0.0.1

	# define the worker
	[ajp13:ministrant.leonid:8009]
	channel=channel.socket: host.domain.tld:8009

	# Uri mapping
	[uri:ministrant.leonid/*]
	worker=ajp13: host.domain.tld:8009
	context=/cocoon

	 end of sample ###

docs:	http://www.pubbitch.org/jboss/mod_jk2.html
		http://www.mortbay.com/jetty/doc/modjk.html
		http://jakarta.apache.org/tomcat/tomcat-4.1-doc/config/jk2.html
		http://jakarta.apache.org/tomcat/tomcat-4.1-doc/jk2/index.html
		
 


/Leo	
		


-
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: Complicated setup

2002-12-05 Thread Jeremy Quinn

On Thursday, Dec 5, 2002, at 12:05 Europe/London, Andrew Savory wrote:



On Thu, 5 Dec 2002, Jeremy Quinn wrote:


I mean something like:

JkMount /!(images|movies|audio)*





no, this doesn't work. seems to be psedocode, hard to implement :-/
with the limited jk mount directives


Thanks for the confirmation!


Yup, sorry, pseudocode. I've had my head deep in the O'Reilly Mastering
Regular Expressions book trying to find a way to implement it, with no
luck so far :-/


Yeah, I reckon it does not use real regexp.




It is all a rather disappointing mess IMHO!!


+1


WHY it is not possible to have a nice ordered list of URL handlers in
Apache like you can in Cocoon is beyond me ;)


Perhaps we should petition the httpd developers ;-)


Ugh!

I am trying to decide now whether to just leave Apache out of the 
equation altogether and either use readers in Cocoon to serve the 
static HTML, or use TomCat or Jetty directly.

The Apache -> mod_jk -> TomCat/Jetty setup, is just not designed with 
Servlets that serve '/' or '/*' in mind, specially if you also want to 
serve other stuff directly from Apache.

Furthermore, none of the tricks they talk about in the dox for mod_jk 
for serving static material out of the webapp via Apache even remotely 
work!

It is a major PIA IMHO!

Anyway, thanks for your help.

regards Jeremy





-
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: Complicated setup

2002-12-05 Thread Andrew Savory

On Thu, 5 Dec 2002, Jeremy Quinn wrote:

> >>> I mean something like:
> >>>
> >>> JkMount /!(images|movies|audio)*
> >>
> >>
> >
> > no, this doesn't work. seems to be psedocode, hard to implement :-/
> > with the limited jk mount directives
>
> Thanks for the confirmation!

Yup, sorry, pseudocode. I've had my head deep in the O'Reilly Mastering
Regular Expressions book trying to find a way to implement it, with no
luck so far :-/

> It is all a rather disappointing mess IMHO!!

+1

> WHY it is not possible to have a nice ordered list of URL handlers in
> Apache like you can in Cocoon is beyond me ;)

Perhaps we should petition the httpd developers ;-)


Andrew.

-- 
Andrew SavoryEmail: [EMAIL PROTECTED]
Managing Director  Tel:  +44 (0)870 741 6658
Luminas Internet Applications  Fax:  +44 (0)700 598 1135
This is not an official statement or order.Web:www.luminas.co.uk


-
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: Complicated setup

2002-12-05 Thread Jeremy Quinn

On Thursday, Dec 5, 2002, at 11:15 Europe/London, leo leonid wrote:



On Thursday, December 5, 2002, at 11:24 AM, Jeremy Quinn wrote:


Hi Andrew,


On Tuesday, Dec 3, 2002, at 17:43 Europe/London, Andrew Savory wrote:


Effectively I guess you want rules that pass everything but images,
movies, audio, x-spaceprojects, harlem etc to mod_jk. Anyone else 
know how
to do that? ;-)

I mean something like:

JkMount /!(images|movies|audio)*




no, this doesn't work. seems to be psedocode, hard to implement :-/ 
with the limited jk mount directives

Thanks for the confirmation!






Are you sure this syntax works?
I cannot get it to catch anything.
What version are you using?

This works:

	JkMount /*


you can use
	# mounting only the index
	JkMount /  worker2
	# further, for example for mounting all html files
	JkMount /*.html  worker2
	# further, for example for mounting everything in dir
	JkMount /dir/*  worker2


Yes, this is what I will have to resort to 
Back to that long list of Mounts ...



so mod_jk is working, but this does not let Apache serve anything.

thanks for any help

regards Jeremy
	



I'll start writing a SUMMARY on this topic.


That would be good!
It is all a rather disappointing mess IMHO!!

WHY it is not possible to have a nice ordered list of URL handlers in 
Apache like you can in Cocoon is beyond me ;)

many thanks

regards Jeremy


-
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: Complicated setup

2002-12-05 Thread leo leonid

On Thursday, December 5, 2002, at 11:24 AM, Jeremy Quinn wrote:


Hi Andrew,


On Tuesday, Dec 3, 2002, at 17:43 Europe/London, Andrew Savory wrote:


Effectively I guess you want rules that pass everything but images,
movies, audio, x-spaceprojects, harlem etc to mod_jk. Anyone else 
know how
to do that? ;-)

I mean something like:

JkMount /!(images|movies|audio)*




no, this doesn't work. seems to be psedocode, hard to implement :-/ 
with the limited jk mount directives


Are you sure this syntax works?
I cannot get it to catch anything.
What version are you using?

This works:

	JkMount /*


you can use
	# mounting only the index
	JkMount /  worker2
	# further, for example for mounting all html files
	JkMount /*.html  worker2
	# further, for example for mounting everything in dir
	JkMount /dir/*  worker2




so mod_jk is working, but this does not let Apache serve anything.

thanks for any help

regards Jeremy
	



I'll start writing a SUMMARY on this topic.
/Leo





-
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]>





-
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: Complicated setup

2002-12-05 Thread Jeremy Quinn
Hi Andrew,


On Tuesday, Dec 3, 2002, at 17:43 Europe/London, Andrew Savory wrote:


Effectively I guess you want rules that pass everything but images,
movies, audio, x-spaceprojects, harlem etc to mod_jk. Anyone else know 
how
to do that? ;-)

I mean something like:

JkMount /!(images|movies|audio)*



Are you sure this syntax works?
I cannot get it to catch anything.
What version are you using?

This works:

	JkMount /*

so mod_jk is working, but this does not let Apache serve anything.

thanks for any help

regards Jeremy
	



-
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: Complicated setup

2002-12-04 Thread Geoff Howard
i'm currently in warp/jk/jk2 hades right now, so I can
tell you that you are correct that jk2 uses a totally
different syntax and mod_jk.so doesn't use it.

Here's what I'm picking up from the last two days of
not getting anything to connect:

- warp is now essentially (but not officially)
abandoned because there is a fatal flaw discovered
that affects windows.
- jk 1.2 corresponds to mod_jk.so and is pretty good
and stable but isn't as
flexible/fast/other-good-adjectives as the new
darling.  In my experience, can be very tempermental
to get working sometimes, but generally seems easy. 
It's the safe choice at moment.
- jk2 (called mod_jk2.so i think) is backwards
compatible, but geared at apache2.x (multithreaded
capability is the key issue, IIUC) BUT is still not
considered mature.  It is being called "early
production quality" so would probably do for the
brave.  Unfortunately, I can't use it because it
requires some other modules to have been compiled in
to apache (1.3.x) previously.  If you can't rebuild
apache for some reason, check into this before wasting
time.

The documentation that does exist always seems to be
about the last, or the next version of the syntax but
not the one you are working with.  Not sure how they
pull that off so effectively. ;)

Geoff

--- Jeremy Quinn <[EMAIL PROTECTED]> wrote:
> 
> This is a different configuration syntax to the one
> I am using I think, 
> or are there two different syntaxes?
> 
> I am using mod_jk.so version 1.2.0, compiled
> locally.
> 
> I have an Apache .conf file, which loads the module,
> sets up 
> JkWorkersFile, JkMount etc. And a workers.properties
> file which sets up 
> one ajp13 worker.
> 
> There's a file like your sample below in my
> TomCat/conf called 
> jk2.properties, but I don't think I am using it.
> 
> Thanks for any help
> 
> regards Jeremy
> 
> On Wednesday, Dec 4, 2002, at 02:22 Europe/London,
> leo leonid wrote:
> 
> >> Do you mean this is where you differentiate
> between different 
> >> Servlets?
> >> Or do you do more than that in this file? I've
> never used one before,
> >> except probably the default.
> >
> > There you define hosts, ports, workers, uri
> mapping etc ... a sample
> >
> > [shm]
> > file=/usr/jakarta/catalina/work/jk2.shm
> > size=1048576
> >
> > # Example socket channel, override port and host.
> > [channel.socket:ministrant.leonid:8009]
> > port=8009
> > host=127.0.0.1
> >
> > # define the worker
> > [ajp13:ministrant.leonid:8009]
> > channel=channel.socket:ministrant.leonid:8009
> >
> > # Uri mapping
> > [uri:ministrant.leonid/*]
> > worker=ajp13:ministrant.leonid:8009
> > context=/cocoon
> >
> >
> 
> 
>
-
> 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]>
> 


__
Do you Yahoo!?
Yahoo! Mail Plus - Powerful. Affordable. Sign up now.
http://mailplus.yahoo.com

-
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: Complicated setup

2002-12-04 Thread Jeremy Quinn

This is a different configuration syntax to the one I am using I think, 
or are there two different syntaxes?

I am using mod_jk.so version 1.2.0, compiled locally.

I have an Apache .conf file, which loads the module, sets up 
JkWorkersFile, JkMount etc. And a workers.properties file which sets up 
one ajp13 worker.

There's a file like your sample below in my TomCat/conf called 
jk2.properties, but I don't think I am using it.

Thanks for any help

regards Jeremy

On Wednesday, Dec 4, 2002, at 02:22 Europe/London, leo leonid wrote:

Do you mean this is where you differentiate between different 
Servlets?
Or do you do more than that in this file? I've never used one before,
except probably the default.

There you define hosts, ports, workers, uri mapping etc ... a sample

[shm]
file=/usr/jakarta/catalina/work/jk2.shm
size=1048576

# Example socket channel, override port and host.
[channel.socket:ministrant.leonid:8009]
port=8009
host=127.0.0.1

# define the worker
[ajp13:ministrant.leonid:8009]
channel=channel.socket:ministrant.leonid:8009

# Uri mapping
[uri:ministrant.leonid/*]
worker=ajp13:ministrant.leonid:8009
context=/cocoon





-
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: Complicated setup

2002-12-03 Thread Skip Carter

> Can anyone advise me on getting this complicated setup right?
> 
> We have a website that will have some stuff served by Cocoon and some 
> served by Apache.
> 
> It is not easy to separate them out because we need to retain legacy 
> URLs. Likewise, it is not possible to give Cocoon served material a URL 
> prefix, primarily because we need Cocoon to serve the home page of the 
> site.
> 
>  From Cocoon:
> 
>   /
>   /index
>   /general/*
>   /archive/*
>   /x-space/*
>   etc. (about 10 items)
> 
>  From Apache:
> 
>   /images/*
>   /movies/*
>   /audio/*
>   /x-spaceprojects/*
>   /harlem/*
>   etc. (also about 10 items)


I was able to move a large site (lots of legacy content and multiple virtual 
servers)
  over to serve everything thru Cocoon without changing any of the existing 
URLs.
  The apache.conf file looks like:


  ServerName www1.myserver.com


   WebAppConnection comConnection warp www1.myserver.com:8008
   WebAppDeploy cocoon   comConnection /




The Tomcat server.xml file has the cocoon directory as the default root:





The only tricky part was handling the legacy CGI, that was handled by having 
another virtual server
and then redirecting to it in the Cocoon sitemap.xmap file:

   
http://www2.myserver.com/cgi-bin/{1}"/>
   





-- 
 Dr. Everett (Skip) Carter  Phone: 831-641-0645 FAX:  831-641-0647
 Taygeta Scientific Inc.INTERNET: [EMAIL PROTECTED]
 1340 Munras Ave., Suite 314WWW: http://www.taygeta.com
 Monterey, CA. 93940












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

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




Re: Complicated setup

2002-12-03 Thread leo leonid

Jeremy Quinn writes:

> 
> On Tuesday, Dec 3, 2002, at 17:57 Europe/London, leo leonid wrote:
> 
> >
> > On Tuesday, December 3, 2002, at 05:52 PM, Jeremy Quinn wrote:
> >
> >>
> >> On Tuesday, Dec 3, 2002, at 15:31 Europe/London, leo leonid wrote:
> >>
> >>>
> >>> On Tuesday, December 3, 2002, at 03:34 PM, Jeremy Quinn wrote:
> >>>
> >>>> Hi All
> >>>>
> >>>> Can anyone advise me on getting this complicated setup right?
> >>
> >> 
> >>
> >>>>
> >>>> Many thanks for any help
> >>>
> >>>
> >>> I had a very similar situation, I solved it by regarding the suffix. 
> >>> In my Apache DocumentRoot are all directories with static content. I 
> >>> only mount the following
> >>>
> >>> JkMount /  worker2
> >>> JkMount /*.html  worker2
> >>> JkMount /*.xml  worker2
> >>>
> >>
> >> Is 'JK2' the best one to be using now?
> >> I am a bit confused between mod_webapp (warp) and JK[n] TBH.
> >>
> >
> > I actually use JK1.2 ajp13 connector (works fine with Jetty, too)
> >
> 
> OK, that's good the hear.
> I am testing on MacOSX, and that's the only version available ATM.
> 
> > I formerly used mod_webapp, which is simple to setup, but less 
> > flexible in managing the urispace. Apart from this it does not support 
> > load-balancing and has it has turned out to be not as stable as my 
> > current solution.
> >
> 
> OK, I have used mod_webapp before for simpler stuff, and it has been 
> stable.
> 
> > I experimented with jk2, too. Big advantage with jk2 is that you don't 
> > have to change the httpd.conf with every change in your mounts (you 
> > keep them in a separate file workers2.properties).
> 
> Do you mean this is where you differentiate between different Servlets? 
> Or do you do more than that in this file? I've never used one before, 
> except probably the default.

There you define hosts, ports, workers, uri mapping etc ... a sample

[shm]
file=/usr/jakarta/catalina/work/jk2.shm
size=1048576

# Example socket channel, override port and host.
[channel.socket:ministrant.leonid:8009]
port=8009
host=127.0.0.1

# define the worker
[ajp13:ministrant.leonid:8009]
channel=channel.socket:ministrant.leonid:8009

# Uri mapping
[uri:ministrant.leonid/*]
worker=ajp13:ministrant.leonid:8009
context=/cocoon




> 
> > But I had some very strange results with jk2, resources like images 
> > and css has been served in a random-like order after some hours with 
> > heavy load and my boring pages looked like artwork :-) maybe a cashing 
> > problem, never found the reason, so I switched back to jk1.2. (at that 
> > time jk2 was still alpha, maybe it is fine now, but AFAIK there is 
> > currently no solution with jk2 and Jetty)
> 
> You are using Jetty rather than TomCat?
> 
Yes, a big advantage while developing is that it starts and stops x-times
faster. And it is very stable for production use.
> >
> >
> >>> Sure you'll run into troubles if there are html files in the static 
> >>> directories, or you rename it to *.htm
> >>
> >> Can't change the urls ;)
> >>
> >>>
> >>> I you find a more flexible solution, please tell me.
> >>
> >> The problem here, is relying on suffixes . we cannot .
> >>
> >>
> >> As I remember, mapping '/' to mod_webapp stopped Apache from serving 
> >> ANYTHING.
> >>
> >
> > WebAppConnection warpConnection warp ministrant.leonid:8008
> > WebAppDeploy cocoon warpConnection /
> >
> > this works, but now EVERYTHING is handled by cocoon. (That's maybe 
> > what you mean)
> >
> 
> exactly
> 
> >
> >> But as you imply in your sample above, this is not the case with JK2?
> >>
> >> So I would be able to map a long list of folders to JK2 and have 
> >> everything else automatically handled by Apache?
> >>
> >> eg.
> >>
> >> JkMount / worker2
> >> JkMount /index worker2
> >> JkMount /index.* worker2
> >> JkMount /archive/* worker2
> >> JkMount /collaboration/* worker2
> >> JkMount /education/* worker2
> >> JkMount /general/* worker2
> >> JkMount /library/* worker2
> >> JkMount /news/* worker2
> >> JkMount /press/* worker2
> >> JkMount /publications/* worker2
> >> JkMount /season/* wor

Re: Complicated setup

2002-12-03 Thread Jeremy Quinn

On Tuesday, Dec 3, 2002, at 17:43 Europe/London, Andrew Savory wrote:



On Tue, 3 Dec 2002, Jeremy Quinn wrote:


Is 'JK2' the best one to be using now?
I am a bit confused between mod_webapp (warp) and JK[n] TBH.


I never got warp working, so I've always used Jk myself.


Sure you'll run into troubles if there are html files in the static
directories, or you rename it to *.htm


Can't change the urls ;)


And besides, we're geeks, so an elegant solution that doesn't require
modifying existing content would be desirable too ;-)



I concur ;)


As I remember, mapping '/' to mod_webapp stopped Apache from serving
ANYTHING.


True.


But as you imply in your sample above, this is not the case with JK2?


The samples above don't map '/' to mod_webapp, they only map selected
filetypes.



OK, which I can do for binary assets, but not for hypertext


So I would be able to map a long list of folders to JK2 and have
everything else automatically handled by Apache?


Sure, but we probably should try and achieve the opposite: I assume the
number of Cocoon resources will grow, whilst the "legacy" stuff will
remain constant (or at least constantly in the same place).


I see what you mean, I have no desire to have to register any of the 
urls ;)
It is difficult to tell which will change more, the Apache served or 
Cocoon served URI space. The Cocoon material represents the core of the 
organisation, the static material represents projects by out-side 
collaborators, and this is ongoing ...



JkMount / worker2
JkMount /index worker2
JkMount /index.* worker2






Is this going to work?

Will Cocoon 'receive' the whole URL, or just the bit picked up by the
'*'?


I'm not sure - I'd guess it'll have the whole URL somewhere in the
headers, but possibly not where you want it. Besides, the solution 
above
isn't very future-proof IMHO.

You also said:

We really want to get Apache serving this content if possible, it is
going to have less overhead and be faster, as I understand it.


I think your best solution is going to be in the Apache httpd.conf - 
maybe
Rewrite will do what you want. Can't figure out how to limit what is
passed on to Cocoon via JkMount though :-/


I have managed to get mod_rewrite to work occasionally, but it can be a 
struggle ;)

Effectively I guess you want rules that pass everything but images,
movies, audio, x-spaceprojects, harlem etc to mod_jk. Anyone else know 
how
to do that? ;-)

I mean something like:

JkMount /!(images|movies|audio)*

[smacks forehead]

Thank-you, of course.

looks like one approach could be this .

1) keep static hypertext to be served by Apache in /static/ (or 
whatever), providing a redirection for important legacy URLs from the 
top level Cocoon sitemap. Each of those static projects should ideally 
be using relative addressing internally.

ie.
	
	
		
	

2) in httpd.conf, set up mappings for the suffixes *.gif,*.jpg,*.mov 
etc.

	??? -- is this necessary?

3) in httpd.conf, set up a catch-the-rest mapping to JK

	JkMount /!(images|movies|audio|static)*


Making headway I think, many thanks for your help.

regards Jeremy


-
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: Complicated setup

2002-12-03 Thread Jeremy Quinn

On Tuesday, Dec 3, 2002, at 17:57 Europe/London, leo leonid wrote:



On Tuesday, December 3, 2002, at 05:52 PM, Jeremy Quinn wrote:



On Tuesday, Dec 3, 2002, at 15:31 Europe/London, leo leonid wrote:



On Tuesday, December 3, 2002, at 03:34 PM, Jeremy Quinn wrote:


Hi All

Can anyone advise me on getting this complicated setup right?






Many thanks for any help



I had a very similar situation, I solved it by regarding the suffix. 
In my Apache DocumentRoot are all directories with static content. I 
only mount the following

JkMount /  worker2
JkMount /*.html  worker2
JkMount /*.xml  worker2


Is 'JK2' the best one to be using now?
I am a bit confused between mod_webapp (warp) and JK[n] TBH.



I actually use JK1.2 ajp13 connector (works fine with Jetty, too)



OK, that's good the hear.
I am testing on MacOSX, and that's the only version available ATM.


I formerly used mod_webapp, which is simple to setup, but less 
flexible in managing the urispace. Apart from this it does not support 
load-balancing and has it has turned out to be not as stable as my 
current solution.


OK, I have used mod_webapp before for simpler stuff, and it has been 
stable.

I experimented with jk2, too. Big advantage with jk2 is that you don't 
have to change the httpd.conf with every change in your mounts (you 
keep them in a separate file workers2.properties).

Do you mean this is where you differentiate between different Servlets? 
Or do you do more than that in this file? I've never used one before, 
except probably the default.

But I had some very strange results with jk2, resources like images 
and css has been served in a random-like order after some hours with 
heavy load and my boring pages looked like artwork :-) maybe a cashing 
problem, never found the reason, so I switched back to jk1.2. (at that 
time jk2 was still alpha, maybe it is fine now, but AFAIK there is 
currently no solution with jk2 and Jetty)

You are using Jetty rather than TomCat?





Sure you'll run into troubles if there are html files in the static 
directories, or you rename it to *.htm

Can't change the urls ;)



I you find a more flexible solution, please tell me.


The problem here, is relying on suffixes . we cannot .


As I remember, mapping '/' to mod_webapp stopped Apache from serving 
ANYTHING.


WebAppConnection warpConnection warp ministrant.leonid:8008
WebAppDeploy cocoon warpConnection /

this works, but now EVERYTHING is handled by cocoon. (That's maybe 
what you mean)


exactly




But as you imply in your sample above, this is not the case with JK2?

So I would be able to map a long list of folders to JK2 and have 
everything else automatically handled by Apache?

eg.

JkMount / worker2
JkMount /index worker2
JkMount /index.* worker2
JkMount /archive/* worker2
JkMount /collaboration/* worker2
JkMount /education/* worker2
JkMount /general/* worker2
JkMount /library/* worker2
JkMount /news/* worker2
JkMount /press/* worker2
JkMount /publications/* worker2
JkMount /season/* worker2
JkMount /search/* worker2
JkMount /x-space/* worker2

Is this going to work?


Yes, this will work - with the drawback, that you probably have to 
update httpd.conf very often.

yeah, not much fun 


 It would be famous if the guys from jk would adopt the cocoon sitemap 
language. But at present the matching possibilities are very limited. 
*/dir/ or **/dir/* does not work :(


Oh would'nt it!

Reading the docs, for JK, (not sure if I understood them correctly), 
but configuring:

	JkOptions +ForwardDirectories

in conjunction with DirectoryIndex ??

quote:

"If ForwardDirectories is set to true and Apache doesn't find any files 
that match, the request will be forwarded to Tomcat for resolution. 
This is used in cases when Apache cannot see the index files on the 
file system for various reasons: Tomcat is running on a different 
machine, the JSP file has been precompiled etc. "

I do not know if this is relevant to my situation, whereby if an 
incoming URL does not match a file, the request is automatically sent 
to TomCat?

A setup like that would make it really easy!

What's more the client could decide at any time to statically render 
parts of the Cocoon site (that were not changing regularly) and have 
them served by Apache.

Do you have any experience of these directives?





Will Cocoon 'receive' the whole URL, or just the bit picked up by the 
'*'?


yes, the whole URL


good to hear!

Thanks, this has been very helpful.

regards Jeremy


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

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




RE: Complicated setup

2002-12-03 Thread Ryan Agler
No need to redirect, your problems can be solved with the AliasMatch
directive in httpd.conf:

AliasMatch ^(.*)/([^/]+\.gif)$ /path/to/images/$2
AliasMatch ^(.*)/([^/]+\.css)$ /path/to/css/$2

The above will match any .gif or .ccs, both legacy and cocoon, and serve
them from the same location.

HTH
+Ryan

-Original Message-
From: Jeremy Quinn [mailto:[EMAIL PROTECTED]] 
Sent: Tuesday, December 03, 2002 9:35 AM
To: [EMAIL PROTECTED]
Subject: Complicated setup

Hi All

Can anyone advise me on getting this complicated setup right?

We have a website that will have some stuff served by Cocoon and some 
served by Apache.

It is not easy to separate them out because we need to retain legacy 
URLs. Likewise, it is not possible to give Cocoon served material a URL 
prefix, primarily because we need Cocoon to serve the home page of the 
site.

 From Cocoon:

/
/index
/general/*
/archive/*
/x-space/*
etc. (about 10 items)

 From Apache:

/images/*
/movies/*
/audio/*
/x-spaceprojects/*
/harlem/*
etc. (also about 10 items)

And then we need Slide-based WebDAV access to the Cocoon based 
material, with Cocoon generating from the Slide repository . and 
this I have still never had working .

If necessary we /could/:
a) place all static content in a single directory and redirect (legacy 
URLs) into it from Cocoon.
b) use virtual-hosts, one for Cocoon and one for the static stuff and 
redirect from Cocoon. But redirecting to images etc. is not that great 
;)

I am getting confused with all the options .. virtual-hosts, 
web-app, JK, JK2 connectors and all the options in them!

Have any of you lot tried any of this before?
How did you approach it?

Many thanks for any help

regards Jeremy


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

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




Re: Complicated setup

2002-12-03 Thread leo leonid

On Tuesday, December 3, 2002, at 05:52 PM, Jeremy Quinn wrote:



On Tuesday, Dec 3, 2002, at 15:31 Europe/London, leo leonid wrote:



On Tuesday, December 3, 2002, at 03:34 PM, Jeremy Quinn wrote:


Hi All

Can anyone advise me on getting this complicated setup right?






Many thanks for any help



I had a very similar situation, I solved it by regarding the suffix. 
In my Apache DocumentRoot are all directories with static content. I 
only mount the following

JkMount /  worker2
JkMount /*.html  worker2
JkMount /*.xml  worker2


Is 'JK2' the best one to be using now?
I am a bit confused between mod_webapp (warp) and JK[n] TBH.



I actually use JK1.2 ajp13 connector (works fine with Jetty, too)

I formerly used mod_webapp, which is simple to setup, but less flexible 
in managing the urispace. Apart from this it does not support 
load-balancing and has it has turned out to be not as stable as my 
current solution.

I experimented with jk2, too. Big advantage with jk2 is that you don't 
have to change the httpd.conf with every change in your mounts (you 
keep them in a separate file workers2.properties). But I had some very 
strange results with jk2, resources like images and css has been served 
in a random-like order after some hours with heavy load and my boring 
pages looked like artwork :-) maybe a cashing problem, never found the 
reason, so I switched back to jk1.2. (at that time jk2 was still alpha, 
maybe it is fine now, but AFAIK there is currently no solution with jk2 
and Jetty)


Sure you'll run into troubles if there are html files in the static 
directories, or you rename it to *.htm

Can't change the urls ;)



I you find a more flexible solution, please tell me.


The problem here, is relying on suffixes . we cannot .


As I remember, mapping '/' to mod_webapp stopped Apache from serving 
ANYTHING.


WebAppConnection warpConnection warp ministrant.leonid:8008
WebAppDeploy cocoon warpConnection /

this works, but now EVERYTHING is handled by cocoon. (That's maybe what 
you mean)


But as you imply in your sample above, this is not the case with JK2?

So I would be able to map a long list of folders to JK2 and have 
everything else automatically handled by Apache?

eg.

JkMount / worker2
JkMount /index worker2
JkMount /index.* worker2
JkMount /archive/* worker2
JkMount /collaboration/* worker2
JkMount /education/* worker2
JkMount /general/* worker2
JkMount /library/* worker2
JkMount /news/* worker2
JkMount /press/* worker2
JkMount /publications/* worker2
JkMount /season/* worker2
JkMount /search/* worker2
JkMount /x-space/* worker2

Is this going to work?


Yes, this will work - with the drawback, that you probably have to 
update httpd.conf very often.
 It would be famous if the guys from jk would adopt the cocoon sitemap 
language. But at present the matching possibilities are very limited. 
*/dir/ or **/dir/* does not work :(



Will Cocoon 'receive' the whole URL, or just the bit picked up by the 
'*'?


yes, the whole URL


Thanks for your help.

regards Jeremy



/Leo


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

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




Re: Complicated setup

2002-12-03 Thread Andrew Savory

On Tue, 3 Dec 2002, Jeremy Quinn wrote:

> Is 'JK2' the best one to be using now?
> I am a bit confused between mod_webapp (warp) and JK[n] TBH.

I never got warp working, so I've always used Jk myself.

> > Sure you'll run into troubles if there are html files in the static
> > directories, or you rename it to *.htm
>
> Can't change the urls ;)

And besides, we're geeks, so an elegant solution that doesn't require
modifying existing content would be desirable too ;-)

> As I remember, mapping '/' to mod_webapp stopped Apache from serving
> ANYTHING.

True.

> But as you imply in your sample above, this is not the case with JK2?

The samples above don't map '/' to mod_webapp, they only map selected
filetypes.

> So I would be able to map a long list of folders to JK2 and have
> everything else automatically handled by Apache?

Sure, but we probably should try and achieve the opposite: I assume the
number of Cocoon resources will grow, whilst the "legacy" stuff will
remain constant (or at least constantly in the same place).

> JkMount / worker2
> JkMount /index worker2
> JkMount /index.* worker2
> JkMount /archive/* worker2
> JkMount /collaboration/* worker2
> JkMount /education/* worker2
> JkMount /general/* worker2
> JkMount /library/* worker2
> JkMount /news/* worker2
> JkMount /press/* worker2
> JkMount /publications/* worker2
> JkMount /season/* worker2
> JkMount /search/* worker2
> JkMount /x-space/* worker2
>
> Is this going to work?
>
> Will Cocoon 'receive' the whole URL, or just the bit picked up by the
> '*'?

I'm not sure - I'd guess it'll have the whole URL somewhere in the
headers, but possibly not where you want it. Besides, the solution above
isn't very future-proof IMHO.

You also said:

> We really want to get Apache serving this content if possible, it is
> going to have less overhead and be faster, as I understand it.

I think your best solution is going to be in the Apache httpd.conf - maybe
Rewrite will do what you want. Can't figure out how to limit what is
passed on to Cocoon via JkMount though :-/

Effectively I guess you want rules that pass everything but images,
movies, audio, x-spaceprojects, harlem etc to mod_jk. Anyone else know how
to do that? ;-)

I mean something like:

JkMount /!(images|movies|audio)*


Andrew.

-- 
Andrew SavoryEmail: [EMAIL PROTECTED]
Managing Director  Tel:  +44 (0)870 741 6658
Luminas Internet Applications  Fax:  +44 (0)700 598 1135
This is not an official statement or order.Web:www.luminas.co.uk



-
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: Complicated setup

2002-12-03 Thread Alex McLintock
At 16:52 03/12/02, Jeremy Quinn wrote:


Is 'JK2' the best one to be using now?
I am a bit confused between mod_webapp (warp) and JK[n] TBH.



If it is any consolation so am I.

I am using mod_webapp happily which I believe is the supposedly correct 
thing to use, but since the JK one is older it has more documentation 
pointing to it.

Alex





Openweb Analysts Ltd, London.
Software For Complex Websites http://www.OWAL.co.uk/
Open Source Software Companies please register here 
http://www.OWAL.co.uk/oss_support/


-
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: Complicated setup

2002-12-03 Thread Jeremy Quinn

On Tuesday, Dec 3, 2002, at 15:31 Europe/London, leo leonid wrote:



On Tuesday, December 3, 2002, at 03:34 PM, Jeremy Quinn wrote:


Hi All

Can anyone advise me on getting this complicated setup right?






Many thanks for any help



I had a very similar situation, I solved it by regarding the suffix. 
In my Apache DocumentRoot are all directories with static content. I 
only mount the following

JkMount /  worker2
JkMount /*.html  worker2
JkMount /*.xml  worker2


Is 'JK2' the best one to be using now?
I am a bit confused between mod_webapp (warp) and JK[n] TBH.


Sure you'll run into troubles if there are html files in the static 
directories, or you rename it to *.htm

Can't change the urls ;)



I you find a more flexible solution, please tell me.


The problem here, is relying on suffixes . we cannot .


As I remember, mapping '/' to mod_webapp stopped Apache from serving 
ANYTHING.

But as you imply in your sample above, this is not the case with JK2?

So I would be able to map a long list of folders to JK2 and have 
everything else automatically handled by Apache?

eg.

JkMount / worker2
JkMount /index worker2
JkMount /index.* worker2
JkMount /archive/* worker2
JkMount /collaboration/* worker2
JkMount /education/* worker2
JkMount /general/* worker2
JkMount /library/* worker2
JkMount /news/* worker2
JkMount /press/* worker2
JkMount /publications/* worker2
JkMount /season/* worker2
JkMount /search/* worker2
JkMount /x-space/* worker2

Is this going to work?

Will Cocoon 'receive' the whole URL, or just the bit picked up by the 
'*'?

Thanks for your help.

regards Jeremy






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

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



Re: Complicated setup

2002-12-03 Thread Jeremy Quinn

On Tuesday, Dec 3, 2002, at 15:03 Europe/London, Andrew Savory wrote:



On Tue, 3 Dec 2002, Jeremy Quinn wrote:


We have a website that will have some stuff served by Cocoon and some
served by Apache.


Is the stuff served by Apache static content, ie html, mpeg, avi, etc?


correct, but we cannot rely on suffixes for mapping (if that's what you 
were leading to )

Obviously static content served by Apache will have suffixes . the 
stuff served by Cocoon will not, but it does need to be able to handle 
situations where someone adds a suffix to the url (and redirects to the 
un-suffixed version of the same url).



It is not easy to separate them out because we need to retain legacy
URLs. Likewise, it is not possible to give Cocoon served material a 
URL
prefix, primarily because we need Cocoon to serve the home page of the
site.

Ok, I'd get Cocoon to serve the whole lot (assuming you want to 
gradually
replace legacy stuff with Cocoon anyway), but use the sitemap to "pass
through" the legacy bits.

We will not be converting the legacy stuff to Cocoon, they are 3rd 
party projects, hosted on the site because they have some relationship 
with the hosting organisation.



 From Apache:

	/images/*


eg:
  

  


	/movies/*


eg:
  

  


We really want to get Apache serving this content if possible, it is 
going to have less overhead and be faster, as I understand it.

But I do see your point, if the worst comes to the worst, we can serve 
all the static content (even HTML) using a 'reader'.

And then we need Slide-based WebDAV access to the Cocoon based
material, with Cocoon generating from the Slide repository . and
this I have still never had working .


Not used this, so can't help, sorry.


Still trying to find someone who's used this stuff ;)




a) place all static content in a single directory and redirect (legacy
URLs) into it from Cocoon.


I'd leave it where it is, and get Cocoon to do the hard work of dealing
with legacy urls.


Thanks for your suggestions.

regards Jeremy


-
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: Complicated setup

2002-12-03 Thread leo leonid

On Tuesday, December 3, 2002, at 03:34 PM, Jeremy Quinn wrote:


Hi All

Can anyone advise me on getting this complicated setup right?

We have a website that will have some stuff served by Cocoon and some 
served by Apache.

It is not easy to separate them out because we need to retain legacy 
URLs. Likewise, it is not possible to give Cocoon served material a 
URL prefix, primarily because we need Cocoon to serve the home page of 
the site.

From Cocoon:

	/
	/index
	/general/*
	/archive/*
	/x-space/*
	etc. (about 10 items)

From Apache:

	/images/*
	/movies/*
	/audio/*
	/x-spaceprojects/*
	/harlem/*
	etc. (also about 10 items)


And then we need Slide-based WebDAV access to the Cocoon based 
material, with Cocoon generating from the Slide repository . and 
this I have still never had working .

If necessary we /could/:
a) place all static content in a single directory and redirect (legacy 
URLs) into it from Cocoon.
b) use virtual-hosts, one for Cocoon and one for the static stuff and 
redirect from Cocoon. But redirecting to images etc. is not that great 
;)

I am getting confused with all the options .. virtual-hosts, 
web-app, JK, JK2 connectors and all the options in them!

Have any of you lot tried any of this before?
How did you approach it?

Many thanks for any help


regards Jeremy




I had a very similar situation, I solved it by regarding the suffix. In 
my Apache DocumentRoot are all directories with static content. I only 
mount the following

JkMount /  worker2
JkMount /*.html  worker2
JkMount /*.xml  worker2

Sure you'll run into troubles if there are html files in the static 
directories, or you rename it to *.htm

I you find a more flexible solution, please tell me.

/Leo


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

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



Re: Complicated setup

2002-12-03 Thread Andrew Savory

On Tue, 3 Dec 2002, Jeremy Quinn wrote:

> We have a website that will have some stuff served by Cocoon and some
> served by Apache.

Is the stuff served by Apache static content, ie html, mpeg, avi, etc?

> It is not easy to separate them out because we need to retain legacy
> URLs. Likewise, it is not possible to give Cocoon served material a URL
> prefix, primarily because we need Cocoon to serve the home page of the
> site.

Ok, I'd get Cocoon to serve the whole lot (assuming you want to gradually
replace legacy stuff with Cocoon anyway), but use the sitemap to "pass
through" the legacy bits.

>  From Apache:
>
>   /images/*

eg:
  

  

>   /movies/*

eg:
  

  

> And then we need Slide-based WebDAV access to the Cocoon based
> material, with Cocoon generating from the Slide repository . and
> this I have still never had working .

Not used this, so can't help, sorry.

> a) place all static content in a single directory and redirect (legacy
> URLs) into it from Cocoon.

I'd leave it where it is, and get Cocoon to do the hard work of dealing
with legacy urls.


Hope that helps,

Andrew.

-- 
Andrew SavoryEmail: [EMAIL PROTECTED]
Managing Director  Tel:  +44 (0)870 741 6658
Luminas Internet Applications  Fax:  +44 (0)700 598 1135
This is not an official statement or order.Web:www.luminas.co.uk


-
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]>




Complicated setup

2002-12-03 Thread Jeremy Quinn
Hi All

Can anyone advise me on getting this complicated setup right?

We have a website that will have some stuff served by Cocoon and some 
served by Apache.

It is not easy to separate them out because we need to retain legacy 
URLs. Likewise, it is not possible to give Cocoon served material a URL 
prefix, primarily because we need Cocoon to serve the home page of the 
site.

From Cocoon:

	/
	/index
	/general/*
	/archive/*
	/x-space/*
	etc. (about 10 items)

From Apache:

	/images/*
	/movies/*
	/audio/*
	/x-spaceprojects/*
	/harlem/*
	etc. (also about 10 items)


And then we need Slide-based WebDAV access to the Cocoon based 
material, with Cocoon generating from the Slide repository . and 
this I have still never had working .

If necessary we /could/:
a) place all static content in a single directory and redirect (legacy 
URLs) into it from Cocoon.
b) use virtual-hosts, one for Cocoon and one for the static stuff and 
redirect from Cocoon. But redirecting to images etc. is not that great 
;)

I am getting confused with all the options .. virtual-hosts, 
web-app, JK, JK2 connectors and all the options in them!

Have any of you lot tried any of this before?
How did you approach it?

Many thanks for any help


regards Jeremy








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

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