It appears there are hard coded values for this speckled in various places throughout 
the source, and the default seems to be 16K 
(ManagedMemoryDataSource.MAX_MEMORY_DISK_CACHED).  This definitely seems like 
something that should be configurable.

It would be quick and easy to enable a JVM-wide setting for this, by adding a static 
getter/setter in the ManagedMemoryDataSource class and setting the value when an 
engine's <globalConfiguration> is read.  However, a better solution would be to allow 
the default to be set on a per-engine or per-service basis.  Please feel free to try 
this out and submit a patch.

(essentially at some point someone creates one of these things in the context of an 
engine invocation.  That means a MessageContext is active, which means properties are 
available.  The "attachments.MaxBytesBeforeCaching" property (or whatever) could be 
used, if present, to set the field rather than the default or hard coded values)

--Glen

> -----Original Message-----
> From: Eiji Yoshida [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, February 04, 2003 10:31 PM
> To: [EMAIL PROTECTED]
> Subject: attachment temporary files
> 
> 
> Hi, everyone
> 
> I have a question about attachment temporary files.
> When SOAP message wtih attachment is sent, Axis 
> generates the attachment files into 
> %TOMCAT_HOME%\axis\WEB-INF\attachments directory
> according to attachment size.
> If the size of attachment exceeds 1024B, its temporary file
> is generated.
> 
> I'd like to change the limitation of attachment size which
> is threshold of generating temporary files. 
> To change the limitation, I must modify axis source code?
> (ref. AttachmentPart.java, ManagedMemoryDataSource.java)
> 
> Or do anyone know the other solution?
> 
> Thanks in advance,
> 
> ------
> Yoshi
> 


Reply via email to