• 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

Restful Webservices on fly(dynamically)

 
Ranch Hand
Posts: 225
IBM DB2 Eclipse IDE Spring
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Folks,

I would like introduce some dynamic cabability of exposing the spring bean as restful services

scenario is

1) i need to read the list of spring bean id's from fileat runtime( or during the loading time of web app)
2) based on bean id's i fetch from step 1 , i need to some how expose the beans as restful services

is there a way to acieve the same ?
 
Ranch Hand
Posts: 426
Eclipse IDE Fedora Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Yes, you can, but it's not turn-key or plug-and-play. You need to write the code to perform the initialization and re-initialization.
 
Ranch Hand
Posts: 2108
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Ganesh Gowtham,

May I know in what situation would such dynamism be ideal?
 
Ganesh Gowtham
Ranch Hand
Posts: 225
IBM DB2 Eclipse IDE Spring
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Scenraio is something of this sort ...

In our project we have couple of Spring beans save POJO ( service layer which talks to dao ...)

During the spring context startup, i would like to expose configured beans as Restful services ...

As @Lance said, i need to tweak or extend or customise the spring loading stuff to acieve the same ...

Any examples or WIKI or idea would be really appreciated.

 
Ranch Hand
Posts: 171
Hibernate Spring Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Apache CXF can help you here. you just need to give some configurations saying which all beans are to be made available as a web-service.
 
Anurag Verma
Ranch Hand
Posts: 171
Hibernate Spring Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
There is a good open source library available now named as WSCreator, it will help in creating SOAP & REST webservices dynamically. search for WSCreator in sourceforge.net or mvnrepository.com
 
Consider Paul's rocket mass heater.
reply
    Bookmark Topic Watch Topic
  • New Topic