Wicket 6 + EJB

classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

Wicket 6 + EJB

Michael Zhavzharov
Hello Everyone.

I have a question about how to include EJB into my wicket web application.
When I was looking for solution for this problem in google, I have found two ways to solve it:
1) Extend my Application class from org.jboss.weld.wicket.WeldApplication and then simply add @Inject annotation to my bean.

or

2) Use getComponentInstantiationListeners().add((IComponentInstantiationListener) new JavaEEComponentInjector(this)); in init method in my Application class and then add @EJB annotation to my bean

But libraries that I need to do this became depracated in this version of Wicket (v.6) and don't work at all.

Can somebody give me an advice how to solve my problem?

Thank's.

Michael.
Reply | Threaded
Open this post in threaded view
|

Re: Wicket 6 + EJB

heapifyman
https://github.com/wicketstuff/core/wiki/Java-EE-Inject
allows injecting EJBs, etc. in wicket-6 applications.




2012/9/24 Michael Zhavzharov <[hidden email]>

> Hello Everyone.
>
> I have a question about how to include EJB into my wicket web application.
> When I was looking for solution for this problem in google, I have found
> two
> ways to solve it:
> 1) Extend my Application class from org.jboss.weld.wicket.WeldApplication
> and then simply add @Inject annotation to my bean.
>
> or
>
> 2) Use
> getComponentInstantiationListeners().add((IComponentInstantiationListener)
> new JavaEEComponentInjector(this)); in init method in my Application class
> and then add @EJB annotation to my bean
>
> But libraries that I need to do this became depracated in this version of
> Wicket (v.6) and don't work at all.
>
> Can somebody give me an advice how to solve my problem?
>
> Thank's.
>
> Michael.
>
>
>
> --
> View this message in context:
> http://apache-wicket.1842946.n4.nabble.com/Wicket-6-EJB-tp4652286.html
> Sent from the Users forum mailing list archive at Nabble.com.
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [hidden email]
> For additional commands, e-mail: [hidden email]
>
>
Reply | Threaded
Open this post in threaded view
|

Re: Wicket 6 + EJB

Bruno Borges
Prefer to use the wicket-cdi module.


*Bruno Borges*
(11) 99564-9058
*www.brunoborges.com*



On Mon, Sep 24, 2012 at 1:33 PM, heapifyman <[hidden email]> wrote:

> https://github.com/wicketstuff/core/wiki/Java-EE-Inject
> allows injecting EJBs, etc. in wicket-6 applications.
>
>
>
>
> 2012/9/24 Michael Zhavzharov <[hidden email]>
>
> > Hello Everyone.
> >
> > I have a question about how to include EJB into my wicket web
> application.
> > When I was looking for solution for this problem in google, I have found
> > two
> > ways to solve it:
> > 1) Extend my Application class from org.jboss.weld.wicket.WeldApplication
> > and then simply add @Inject annotation to my bean.
> >
> > or
> >
> > 2) Use
> >
> getComponentInstantiationListeners().add((IComponentInstantiationListener)
> > new JavaEEComponentInjector(this)); in init method in my Application
> class
> > and then add @EJB annotation to my bean
> >
> > But libraries that I need to do this became depracated in this version of
> > Wicket (v.6) and don't work at all.
> >
> > Can somebody give me an advice how to solve my problem?
> >
> > Thank's.
> >
> > Michael.
> >
> >
> >
> > --
> > View this message in context:
> > http://apache-wicket.1842946.n4.nabble.com/Wicket-6-EJB-tp4652286.html
> > Sent from the Users forum mailing list archive at Nabble.com.
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: [hidden email]
> > For additional commands, e-mail: [hidden email]
> >
> >
>
Reply | Threaded
Open this post in threaded view
|

Re: Wicket 6 + EJB

Michael Zhavzharov
In reply to this post by heapifyman
Thank you, heapifyman!

Your post solved my problem!
Reply | Threaded
Open this post in threaded view
|

Re: Wicket 6 + EJB

Michael Zhavzharov
In reply to this post by Bruno Borges
Thank you, Bruno!

I will choose from this two frameworks.