File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Web Services and the fly likes stackoverflowerror with axis Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Web Services
Bookmark "stackoverflowerror with axis" Watch "stackoverflowerror with axis" New topic

stackoverflowerror with axis

taras khoma

Joined: Mar 14, 2011
Posts: 9

hi friends,

I need your help one more time.

I have axis2 web service which receives xml. client and web service are located on the same machine.
When I publish large xml(near 1Mb) I receive StackOverflowError. I enabled debug of axis on jboss
and see that my error happens every time after this:

Checking pre-condition for Phase "Security"
Invoking phase "Security"
Invoking Handler 'Apache Rampart inflow handler' in Phase 'Security'

I tried to search for axis 2 phases but didn't manage to figure out what to do with problem.

William Brogden
Author and all-around good cowpoke

Joined: Mar 22, 2000
Posts: 13036
What about the stack trace? Some clue as to where the stack is overflowing should show up in the logs.

How much memory are you giving the server?

Is this big XML being sent as part of the SOAP body or as an attachment?

taras khoma

Joined: Mar 14, 2011
Posts: 9

Thanks a lot for your answer William,

for server is arranged 4 Gb of Ram. I sent XML as part of SOAP body. But now I'm investigate how to archive it and send as attachment.
But on client I can't get MessageContext. I generate axis2 client stub by ant.

I use this code to get MessageContext but it receives null

This code invokes web service and I see that in ant generated consumeXml method MessageContext is initialized. But I need it before invocation of that method.
I agree. Here's the link:
subject: stackoverflowerror with axis
It's not a secret anymore!