File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Web Services and the fly likes 1 schema file or multiple schema files Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Web Services
Bookmark "1 schema file or multiple schema files" Watch "1 schema file or multiple schema files" New topic
Author

1 schema file or multiple schema files

Pankaj Kumarkk
Ranch Hand

Joined: Apr 17, 2011
Posts: 108
Hi,
I am setting up a web services project. One questions which I have to take decision on is "should I maintain 1 schema file or multiple schema file"

Advantages of 1 schema file:
1. Easier to control: Schema definitions should be managed in a controlled manner as a small change can impact multiple services. Having 1 schema file helps manage schema file easily
2. Promotes reuse

Advantages of multiple schema file:
1. Can componentize schemas based on functional components. Thus easier to present smaller schema to client apps based on services they use.
2. Can present specific schema to the customers
3. Promotes reuse

I am tending towards below:
Start with a small number of schema (say a commonschema.xsd and applicationschema.xsd) and then divide applicationschema.xsd into multiple based on if there are clients which uses partial functionality.

I am looking at suggestions/opinions regarding this approach. Also if there are any other advantages each of approach(1 schema vs multiple schema) have
Ivan Krizsan
Ranch Hand

Joined: Oct 04, 2006
Posts: 2198
    
    1
Hi!
I suspect there is not much to add - you have a good grasp of the problem and have proposed a very reasonable strategy!
Remember that not only XML schemas, but also WSDL files can be split into multiple files. For instance, one WSDL file may specify the abstract interface of the web service while another specifies the more concrete aspects, such as the endpoint address etc.
Best wishes!


My free books and tutorials: http://www.slideshare.net/krizsan
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: 1 schema file or multiple schema files