Win a copy of Mesos in Action this week in the Cloud/Virtualizaton forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Publishing web service from existing web application

 
Royston Nadar
Greenhorn
Posts: 6
Eclipse IDE Java Tomcat Server
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi all,

I have a web app, which is already deployed and running on tomcat. I need to create a web service, which will receive three parameters, and update two tables in the db. Can i create the service class within the same application and publish it as web service, or should i create brand new web application for this purpose alone?

Thanks.
 
Ivan Krizsan
Ranch Hand
Posts: 2198
1
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi!
Both your options are valid options.
If the web service will be coupled to the web application, then containing the web service in the web application may be a good idea.
If the web service is more independent, then publishing it in a web application of its own may be a better idea.
There are other factors as well, for instance if the web service is likely to change and the web application is not or vice versa, then separating the two may also be a good idea.
Best wishes!
 
Royston Nadar
Greenhorn
Posts: 6
Eclipse IDE Java Tomcat Server
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks for the detailed answer Ivan !
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic