• 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

java plugin framework

 
Ranch Hand
Posts: 118
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi All,

I have been asked to developed several java applications , one of such application will be the core application and the others should be
as pluggins of this application

I have search in the net and i found the following :
1)jpf (java plugin framework) but i found that no more development and also has less resources
2)OSGI ,but am I will not use spring in any of my applications

I am really in need for your feedback , comments , suggestions .....
 
Rancher
Posts: 43081
77
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

1)jpf (java plugin framework) but i found that no more development and also has less resources


What do you mean by "has less resources"? Does JPF not do what you need done?

2)OSGI ,but am I will not use spring in any of my applications


OSGi is not in any way dependent on Spring. Wherever you got that impression, it's incorrect.
 
Suresh Khant
Ranch Hand
Posts: 118
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks Ulf Dittmer for your reply,

What do you mean by "has less resources"? Does JPF not do what you need done?


I mean you can not find a complete example , as well as Less documents about jpf



OSGi is not in any way dependent on Spring. Wherever you got that impression, it's incorrect.


So can i use it to create plugins without the need for spring ?



Which one of them jpf/OSGi is suitable for my requirements (which I have described in the previous post) ?
 
Ulf Dittmer
Rancher
Posts: 43081
77
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

So can i use it to create plugins without the need for spring ?


Yes

Which one of them jpf/OSGi is suitable for my requirements (which I have described in the previous post) ?


You have said very little about your requirements, certainly not enough to answer this question. From what you've said, it's conceivable that even something as simple as what I wrote about here might be sufficient.
 
Suresh Khant
Ranch Hand
Posts: 118
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks Ulf Dittmer for your reply ,

You have said very little about your requirements, certainly not enough to answer this question



I want to create several web java applications , of course deploy their .war files on jboss application server , one of such applications will be the core application and the others should be as pluggins of this core application ,

plugin exists once its war file deployed.
plugin does not exist once its war file undeployed.


for example the core application will be like a web page which lists all the available plugins ( the applications which their war files have been deployed to the server)
 
Ulf Dittmer
Rancher
Posts: 43081
77
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
It would be quite odd to think of a web app as a "plugin". Web apps exist in their own right; if their functionality should only exist as part of some other web app, then deploying them as web app is not appropriate.

You may want to investigate the concepts of OSGi bundles and services. Those can be used to implement functionality in the context of a larger app (JPF may have similar concepts).
 
Suresh Khant
Ranch Hand
Posts: 118
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks for your reply ,
I have checked the example at the link http://www.javaranch.com/journal/200607/Journal200607.jsp#a1 (which you have referred me in the previous post) , The example is very nice ,

The plugins are .class files

I have the following questions regarding the example :

1) Is it possible to make the plugins as .jar files instead of .class files ?
2) Which one you have used jpf or OSGi to create the examples , it seems that you have your own way , you have not used any one of them , Is it Right ?
 
Ulf Dittmer
Rancher
Posts: 43081
77
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
#1: yes, jar or zip files would be possible. They'd complicate the I/O code, but not a whole lot, and would be functionally equivalent.

#2: yes, I cooked up my own scheme, which is much less functional than either jpf or osgi. I wouldn't use jpf since it seems dead. Osgi looks like the wave of the future in this space.
 
Suresh Khant
Ranch Hand
Posts: 118
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks Ulf Dittmer for your reply ,

#1: yes, jar or zip files would be possible. They'd complicate the I/O code, but not a whole lot, and would be functionally equivalent.



I would like to draw your attention that my requirements will be : each plugin will be as .jar file (each jar file contains of multiple classes) so we will have multiple .jar files each jar file represents a plugin.
In a summary :
1. I want to create core application which contains of plugins ( each plugin as .jar file)
2. Each jar file might contains multiple classes
3. Adding/removing plugins is nothing but adding/deleting .jar file to/from a particular location.

So is it possible to modify your example according to my requirements ?
I do appreciate your advise , suggestion and feedback ?
 
Ulf Dittmer
Rancher
Posts: 43081
77
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
It is possible to modify my example to work that way, but it would take quite a bit of work to make it suitable for a production environment. If you're serious about this, check out OSGi, make your plugins OSGi Bundles (or Services), and then you can use Apache Karaf for this.
 
This tiny ad will self destruct in five seconds.
a bit of art, as a gift, the permaculture playing cards
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic