• Post Reply Bookmark Topic Watch Topic
  • New Topic

Should server side of web service validate the xml using the XSD (worried about performance)?  RSS feed

 
Kathy Dupont
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'm new to web services but I've read that validating the XML using the XSD is slow and shouldn't be used in production but it seems a lot of applications do it. Our web service needs to be very fast. So is it better to not validate the xml using the XSD and just put all the validation in the application code? OR to just do course grain validation with the XSD and then fine grain with the application code (but I would assume even with this you still have the performance hit)? The validation I am thinking for the XSD would just be the lengths of fields and mins occurs/max occurs type validations. Just high level items. What is the best practice for how this is handled?

Also, even if you don't validate the XML with the XSD, I am assuming that you could still put all of the min occurs/max occurs and fields lengths in the XSD even if you don't use it to validate the XML so that the consumer of the web service has the format of what is expected in the XML?

Thanks for any assistance that can be provided!
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!