cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ross Burton <>
Subject Re: [PATCH] resource: URL handling (cleaned-up code)
Date Tue, 31 Oct 2000 19:14:09 GMT
Ovidiu Predescu wrote:

> The following patch cleans up the way Cocoon handles the resource: URLs. This
> allows the resource: URL to be used everywhere as it is now a first class URL.
> To be able to use it, you need to add the following line in
> (for other servlet containers the setup should be similar):
> wrapper.bin.parameters=-Djava.protocol.handler.pkgs=org.apache.cocoon.protocol

Isn't it possible to set this property when Cocoon starts?  In Tomcat 4
this code is called:

private static final String PROTOCOL_PACKAGES =
private static final String PROTOCOL_HANDLER =

private void initHandler() {
	String packages = System.getProperty(PROTOCOL_PACKAGES);
	if (packages == null)
		packages = PROTOCOL_HANDLER;
	else if (packages.indexOf(PROTOCOL_HANDLER) < 0)
		packages += "|" + PROTOCOL_HANDLER;
	System.setProperty(PROTOCOL_PACKAGES, packages);

Is this possible inside Cocoon?  I'm interested in this as Cocoon 2
needs jar: and cocoon: URL handlers, but am hearing conflicting reports
about how to do this.  Does anyone know if servlets are allowed to
modifiy this property?

Ross Burton

View raw message