• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Clarification on mustUnderstand and role attributes of SOAP header blocks

 
Ranch Hand
Posts: 558
2
Hibernate Spring Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi All,

While reading through the SOAP nodes and header blocks, I read through mustUnderstand and role attributes of SOAP envelope schema. It is mentioned that applications can define their own roles as an addition to the standard next, none, ulitmateReceiver. Does anybody come across such examples? I tried to look for one, but was not successful.

Also, assume that a header block bears the role as "next" and mustUnderstand = "1" in such cases, the next available node in path, should either process it or generate a fault. If it generates a fault, a SOAP fault is sent back to the sender. If it processes the header, then it would remove that header block and fowards the modified SOAP message to the next node. Is my understanding correct so far?

In the usecase of fault generation, I think that particular SOAP fault would again go through all the nodes defined in its path before reaching the original sender. Is this true ?

I'm adding another question to my original post. Under SOAP role attribute description (http://www.w3.org/TR/soap12-part1/#soaprole), it is mentioned that


SOAP senders SHOULD NOT generate, but SOAP receivers MUST accept, the SOAP role attribute information item with a value of "http://www.w3.org/2003/05/soap-envelope/role/ultimateReceiver".



Does the above statement mean, that a SOAP sender should not explicitly indicate the role as "ultimateReciever" and if no role mentioned, then it implies "ultimateReceiver". Can an intermediary set the role to "ultimateReceiver", if not the original sender? Is there any logical reason for not allowing the sender to specify the role as "ultimateReceiver".


If relaying the message, a SOAP intermediary MAY omit a SOAP role attribute information item if its value is "http://www.w3.org/2003/05/soap-envelope/role/ultimateReceiver"



If a sender is NOT permitted to set "ultimateReceiver", why would intermediaries would see the attribute value as "ultimateReceiver".
 
Ranch Hand
Posts: 2198
1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi!
First, I suspect that examples of headers being passed through intermediaries are not common due to this being an uncommon scenario. It is also a more complicated scenario. In my work, I see mostly direct communication between a client and a service.

Kumar Raja wrote:Also, assume that a header block bears the role as "next" and mustUnderstand = "1" in such cases, the next available node in path, should either process it or generate a fault. If it generates a fault, a SOAP fault is sent back to the sender. If it processes the header, then it would remove that header block and fowards the modified SOAP message to the next node. Is my understanding correct so far?


Yes.
First note: As far as I remember, the direction of a fault message is the reverse of the direction of the message that caused the fault. Thus the fault would be sent back to the previous intermediary SOAP node, if there is such a node, not directly to the originator of the request.
Second note: A header block must be removed, but may be re-inserted by a SOAP node processing the header block. This can be seen as the header block being modified by the node.

An advice: Try posting fewer questions in each post. Perhaps one or two questions, at most. I feel it will become easier to answer such posts.
Best wishes!
 
Kumar Raja
Ranch Hand
Posts: 558
2
Hibernate Spring Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks for the answers Ivan.


Ivan Krizsan wrote:Hi!
An advice: Try posting fewer questions in each post. Perhaps one or two questions, at most. I feel it will become easier to answer such posts.
Best wishes!



Also, for sure I will keep this in mind. I knew that most of my posts would usually have multiple questions, because I did not want to stretch my questions over multiple posts for cohesivness. But never realized that, it may reduce the readability. I will keep your advise in mind, in my next posts.
 
Don't get me started about those stupid light bulbs.
reply
    Bookmark Topic Watch Topic
  • New Topic