Win a copy of Kotlin in Action this week in the Kotlin forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

WebService NameSpace doubt  RSS feed

 
SoumyaGh Ghosh
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am creating a java webservice. For that I am using @WebService annotation and @WebMethod for defining endpoint and service respectively.

In both place I have option to provide targetNameSpace. Can targetNameSpace be different at @WebService level and @WebMethod level.

Reference is: In one XSD there is two services with one namespace and another XSD I have one service with different nameSpace. But I need to have one endPoint for all the services. Is it allowed? What is the best practice?
 
g tsuji
Ranch Hand
Posts: 697
3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am creating a java webservice. For that I am using @WebService annotation and @WebMethod for defining endpoint and service respectively.

In both place I have option to provide targetNameSpace. Can targetNameSpace be different at @WebService level and @WebMethod level.

The answer is negative. Not because the validation would emit some sort of error purporting that they are not the same, but because its sameness is built into the spec and implementation.
The statement "In both place I have option to provide targetNameSpace." is incorrect. The @WebMethod does not have the targetNamespace property ...

Reference is: In one XSD there is two services with one namespace and another XSD I have one service with different nameSpace. But I need to have one endPoint for all the services. Is it allowed? What is the best practice?

That, I don't even understand the terminologies and questions, or maybe, because of the way you phrase it.
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!