This worked PERFECTLY! Thanks! Short, Clean and exactly what I wanted! Thanks a lot!
Konstantinos On Thursday 20 May 2004 23:38, Nelson Minar wrote: > Argh! Don't use system properties, or ThreadLocals, or the like. > > >> I suggest having the Handler store the data in the Axis > >> MessageContext, then read it back out in the Service. > > > >Can you give me an example? > > In your Handler: > > public void invoke(MessageContext context) throws AxisFault { > Object data = ...; > context.setProperty("MyData", data); > } > > In your service method: > > public foo myService(int a, String b) { > MessageContext context = MessageContext.getCurrentContext(); > Object data = context.getProperty("MyData"); > } > > > Underneath the scenes MessageContext.getCurrentContext() is > actually using a ThreadLocal to do things. But let Axis do that > itself, no need to do your own.