Skip to main content

Validataing incoming SOAP messages with Glassfish V2

3 replies [Last post]
akulinsk
Offline
Joined: 2003-11-07

Hi all

I have a problem with implementing WS using NB 6 and Glassfish v2. We can send any wrong xml message to WS endpoint (SOAP over HTTP) and it is passed to lower framework layers instead of throwing some schema validation fault. In case of other app servers we used to get schema validation as soon as wrong message arrived. It is a serious problem for us, as some of our consumers are quite inadvanced and they build WS clients using string concatenation, not WS frameworks :( and they consume a lot of troubles when they get some lower level exceptions. I guess it has something in common with FI and processing optimization, but I need your help to switch validation on as it is more important at this point than performance.

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
oleksiys
Offline
Joined: 2006-01-25

Hello,

can you pls. show which "low-level" exception you're getting?

Thanks.
WBR.

akulinsk
Offline
Joined: 2003-11-07

We have a WS which calls Oracle procedure, we generate request using SOAP UI and then we damage request removing almost all elements so it does not validate against wsdl schema. But what happens is: the service implementation is called anyway. Eg. lets say that we have a xsd:string restriction saying that string must be at least 10 chars but we can sand any (including empty) String to service implementation and what we get is eg. java.lang.StringIndexOutOfBoundsException in service implementation class :( instead of xsd validation exception as message is not correct :(

oleksiys
Offline
Joined: 2006-01-25

I see.

Try to ask on forum of project metro [1].
Think, they will help you.

WBR.

[1] http://forums.java.net/jive/forum.jspa?forumID=46&start=0