cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Grzegorz Kossakowski <>
Subject Re: "upload-max-size" with no effect
Date Mon, 28 Jan 2008 13:35:02 GMT
Jean-Claude Vogel pisze:
> Thank a lot,
> I fact I don't know how to set static variables in the spring
> configuration of the block but I will look for it. If you can send a
> small example it would be great.

Jean, you probably have misunderstood what I meant. I didn't mean you need to set static variables
as it's quite insane to try to _change_ value of _static_ variable, don't you think? ;-)

You should look at the configure() method of MultipartConfigurationHelper class. There configuration
is obtained from properties in a way like this:
        value = settings.getProperty(KEY_UPLOADS_MAXSIZE);
        if (value != null) {

Where KEY_UPLOADS_MAXSIZE is defined at the top of the class:

    String KEY_UPLOADS_MAXSIZE = "org.apache.cocoon.uploads.maxsize";

So you just need to set this property. You can do this multiple ways[1]. I suggest creating
a file in src/main/resources/META-INF/cocoon/properties directory
of your block.


Grzegorz Kossakowski
Committer and PMC Member of Apache Cocoon

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message