If you can get hold of the pure HTTP response in .NET (which I doubt) then you could set the HTTP status code to 200. This way the exception will be handled correctly by Flash Player (and that's how the Flex WS proxy handle this, too)
 
Another way would be to use servlet/ISAPI filters for this. With servlet filters this should be straightforward, not sure about ISAPI filters however.
 
Dirk.


From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On Behalf Of Daniel Tuppeny
Sent: Tuesday, June 20, 2006 3:22 PM
To: flexcoders@yahoogroups.com
Subject: RE: [flexcoders] Access SOAP fault code

We're using .NET web services, no cold fusion.
 
Looks like we'll have to wrap all responses in try/catch, and return an object with an error property, and the actual data as another property. Disgusting :-(
 


From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On Behalf Of Carson Hager
Sent: 20 June 2006 14:11
To: flexcoders@yahoogroups.com; flexcoders@yahoogroups.com
Subject: RE: [flexcoders] Access SOAP fault code

Preaching to the choir. :)  Believe me...we feel the same way.  From everything we have heard from Adobe, this will not be addressed within the player within this release.
 
That being said, does CF support anything like filters in J2EE that allow you to do things like alter the contents of all responses before they leave the server?  If so, you can simply change that HTTP status code to 200 for all CFC requests that have resulted in SOAP faults.
 
Just to clarify, Adobe told  us informally that they would be coming up with various server side solutions that would take care of this for you. You would have to check with them to see if they are doing this for Cold Fusion.
 
 
Carson
 


From: flexcoders@yahoogroups.com on behalf of Daniel Tuppeny
Sent: Tue 6/20/2006 9:06 AM
To: flexcoders@yahoogroups.com
Subject: RE: [flexcoders] Access SOAP fault code

This sounds pretty worrying. We're using SOAP without any server/proxy. So we won't be able to get the SOAP exceptions at all?
 
That sounds like rather a fundamental flaw. It means we're unable to give the user any sensible messages, because we don't have the exception type. Is this not being fixed for the final release? :-(
 
 

From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On Behalf Of Carson Hager
Sent: 20 June 2006 13:29
To: flexcoders@yahoogroups.com; flexcoders@yahoogroups.com
Subject: RE: [flexcoders] Access SOAP fault code

This is currently a limitation in the Flash Player ( all versions ).  SOAP faults require HTTP 500 to returned. When the FP sees a 500, it stops reading data from the socket.  The current workaround is to use the proxy or to use some other mechanism to change the HTTP status code to 200 before the FP receives it. Yes I realize that this is pretty poor and has serious limitations.
 
One last note, Adobe is evidently working on something akin to the proxy that does this for you on your server. Clearly, this won't help you when accessing web services one machines over which you have no control.
 

Carson
 
 


From: flexcoders@yahoogroups.com on behalf of m88e24
Sent: Tue 6/20/2006 3:58 AM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] Access SOAP fault code

Scenario:

Flash players talks directly to a SOAP web service, no proxy is used.
The proxy attribute of the WebService element is set to "false". A
specific web service operation generates an application level user
exception and the faultcode and faultstring is returned in the SOAP
body. The FaultEvent object received by the fault handler function
does not contain the faultcode and the faultstring from the SOAP
message. The faultDetail in the FaultEvent object is of type "ioError"
and the error text is "Error #2032: Stream error …….." . Whilst the
actual SOAP faultcode is "soapenv:Server.userException" and the SOAP
faultstring is "coldfusion.xml.rpc.CFCInvocationException:
[coldfusion.runtime.UndefinedElementException : Element SPELER.ID is
undefined in SESSION."

This is custom exception thrown by a remote function in a ColdFusion
CFC. This is not an ioError.

A TCPmonitor shows the correct message request and response with the
faultstring and faultcode as expected.

How can the actual SOAP faultcode and faultstring be retrieved from
the FaultEvent or in any other way. Why is the fault description in
the FaultEvent object totally different from the actual SOAP fault
message. It is not a transport error so why does the FaultEvent shows
an ioError. It is an application level exception and as such returned
to the Flash application encapsulated in the SOAP body.

Any suggestions, thank you


[Inbound Mail Scanned by MessageLabs]

______________________________________________________________________
This email has been scanned by the MessageLabs Email Security System.
For more information please visit http://www.messagelabs.com/email
______________________________________________________________________


[Inbound Mail Scanned by MessageLabs]

______________________________________________________________________
This email has been scanned by the MessageLabs Email Security System.
For more information please visit http://www.messagelabs.com/email
______________________________________________________________________
__._,_.___

--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com





SPONSORED LINKS
Web site design development Computer software development Software design and development
Macromedia flex Software development best practice


YAHOO! GROUPS LINKS




__,_._,___

Reply via email to