Skip to main content

Modular JSF with Glassfish

3 replies [Last post]
Lynx6
Offline
Joined: 2011-03-26
Points: 0

Hello everybody, I have a huge problem.

I'm trying to create a modular JSF app, like the plugin system in liferay, but less complex. My question is this:

Can I load/unload dynamically a JAR file (module or plugin that will be used for my app) using JSF 2 and Glassfish?

Any suggestion? I need use JSF (without osgi or spring). Thanks in advance...

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
jdlee
Offline
Joined: 2006-01-25
Points: 0

I know it's frowned upon to push your own work like this, but I gave
this post some time, and no one else responded, so I hope that gives me
a pass. :P

I recently presented a few approaches to do something like this, which
you can find in the Java Tech Journal
(http://jaxenter.com/jax-magazine/JTJ-2012-06) or on my blog
(http://blogs.steeplesoft.com/2012/07/writing-pluggable-java-ee-applicati...).
Same basic content, fwiw.

If I recall correctly, Adam Bien also addresses this in his book "Real
World Java EE Patterns-Rethinking Best Practices", which you can pick up
in Kindle format for only $10:
http://www.amazon.com/Real-World-Patterns-Rethinking-Practices-ebook/dp/...

I hope one of those helps. :)

On 11/16/2012 06:58 PM, forums@java.net wrote:
> Hello everybody, I have a huge problem. I'm trying to create a modular
> JSF
> app, like the plugin system in liferay, but less complex. My question is
> this: Can I load/unload dynamically a JAR file (module or plugin that
> will be
> used for my app) using JSF 2 and Glassfish? Any suggestion? I need use
> JSF
> (without osgi or spring). Thanks in advance...
>
> --
>
> [Message sent by forum member 'Lynx6']
>
> View Post: http://forums.java.net/node/892402
>
>

--
Jason Lee
Principal Member of Technical Staff
GlassFish Team

Oracle Corporation
Phone +1 405-216-3193
Blog http://blogs.steeplesoft.com

Lynx6
Offline
Joined: 2011-03-26
Points: 0

Thanks for your reply Jason. I had already implemented your idea before, but without using plummer. Right now I need resolve two things, first with EJB: the injected class is not working... and second, JSF use facelets cache, I need to release that resources (programmatically) because is locking the JAR file and I can't delete it when I close its classloader. I'm using for each JAR a different classloader, I need a solution to install/uninstall plugins. Meantime, if is not possible I will apply your first method undeploy/deploy the WAR file, I wouldn't like to do that...

Anonymous

Hello everybody, I have a huge problem. I'm trying to create a modular JSF
app, like the plugin system in liferay, but less complex. My question is
this: Can I load/unload dynamically a JAR file (module or plugin that will be
used for my app) using JSF 2 and Glassfish? Any suggestion? I need use JSF
(without osgi or spring). Thanks in advance...

--

[Message sent by forum member 'Lynx6']

View Post: http://forums.java.net/node/892402