You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@deltaspike.apache.org by Rafael Meireles <ra...@gmail.com> on 2014/04/08 13:33:46 UTC

Extended Persistent Context

Hello everyone, I would like to know if you think about create an option
that exists in seam 2, that I can open the entitymanager for many requests?

Re: Extended Persistent Context

Posted by Gerhard Petracek <ge...@gmail.com>.
hi rafael,

i guess you are deploying your application in an ee-server.
in such a case you have to be aware of [1] (see the usage with
@PersistenceUnit EntityManagerFactory).
the rest (= wrapping the EntityManager) is the same.

regards,
gerhard

[1] http://deltaspike.apache.org/jpa.html



2014-04-11 2:01 GMT+02:00 Rafael Meireles <ra...@gmail.com>:

> Do you know if the functionality of the link above only works with the
> Conversation scope?
>
>
> 2014-04-09 0:09 GMT-03:00 Gerhard Petracek <ge...@gmail.com>:
>
> > hi rafael,
> >
> > please provide a demo-application which illustrates the issue.
> > back then it worked and since your own disposer calls #close, it should
> > still work.
> >
> > regards,
> > gerhard
> >
> >
> >
> > 2014-04-09 2:04 GMT+02:00 Rafael Meireles <ra...@gmail.com>:
> >
> > > I looked this link when I started my project, but this solution doesn't
> > > work. This solution just create a entity manager with the
> conversational
> > > scope and the entity manager stay serialized, but with this solution,
> the
> > > entity manager doesn't stay open during the conversation.
> > >
> > > About the best practice of the extended persistence context, here we
> > have a
> > > project in production with seam 2, JSF 1.2, EJB 3 and JPA 1, running
> in a
> > > JBoss Application Server and this system is used by many people in the
> > > state of Ceará, Brazil. We have around 300 - 400 users concurrent and
> the
> > > Application Servers are in Cluster.
> > >
> > > Can you explain better, this:
> > > "the Deltaspike /CDI style is very nice to work"
> > >
> > >
> > > 2014-04-08 9:01 GMT-03:00 Gerhard Petracek <gerhard.petracek@gmail.com
> >:
> > >
> > > > hi,
> > > >
> > > > please have a look at [1].
> > > >
> > > > regards,
> > > > gerhard
> > > >
> > > > [1]
> > > >
> > > >
> > >
> >
> https://cwiki.apache.org/confluence/display/EXTCDI/JPA+Usage#JPAUsage-ExtendedPersistenceContexts
> > > >
> > > >
> > > >
> > > > 2014-04-08 13:37 GMT+02:00 Karl Kildén <ka...@gmail.com>:
> > > >
> > > > > I am also curious about best practice for this (right now) and
> > perhaps
> > > in
> > > > > the future. The thing is the Deltaspike /CDI style is very nice to
> > work
> > > > > with and it would be a preferred API for me.
> > > > >
> > > > >
> > > > > On 8 April 2014 13:33, Rafael Meireles <ra...@gmail.com>
> > > wrote:
> > > > >
> > > > > > Hello everyone, I would like to know if you think about create an
> > > > option
> > > > > > that exists in seam 2, that I can open the entitymanager for many
> > > > > requests?
> > > > > >
> > > > >
> > > >
> > >
> > >
> > >
> > > --
> > > Atenciosamente,
> > > --------------------------------------------
> > > Rafael Meireles Caetano
> > > Arquiteto Java EE
> > > Sefaz - CE
> > > Fone: +55 85 8811-1806
> > >
> >
>
>
>
> --
> Atenciosamente,
> --------------------------------------------
> Rafael Meireles Caetano
> Arquiteto Java EE
> Sefaz - CE
> Fone: +55 85 8811-1806
>

Re: Extended Persistent Context

Posted by Rafael Meireles <ra...@gmail.com>.
Do you know if the functionality of the link above only works with the
Conversation scope?


2014-04-09 0:09 GMT-03:00 Gerhard Petracek <ge...@gmail.com>:

> hi rafael,
>
> please provide a demo-application which illustrates the issue.
> back then it worked and since your own disposer calls #close, it should
> still work.
>
> regards,
> gerhard
>
>
>
> 2014-04-09 2:04 GMT+02:00 Rafael Meireles <ra...@gmail.com>:
>
> > I looked this link when I started my project, but this solution doesn't
> > work. This solution just create a entity manager with the conversational
> > scope and the entity manager stay serialized, but with this solution, the
> > entity manager doesn't stay open during the conversation.
> >
> > About the best practice of the extended persistence context, here we
> have a
> > project in production with seam 2, JSF 1.2, EJB 3 and JPA 1, running in a
> > JBoss Application Server and this system is used by many people in the
> > state of Ceará, Brazil. We have around 300 - 400 users concurrent and the
> > Application Servers are in Cluster.
> >
> > Can you explain better, this:
> > "the Deltaspike /CDI style is very nice to work"
> >
> >
> > 2014-04-08 9:01 GMT-03:00 Gerhard Petracek <ge...@gmail.com>:
> >
> > > hi,
> > >
> > > please have a look at [1].
> > >
> > > regards,
> > > gerhard
> > >
> > > [1]
> > >
> > >
> >
> https://cwiki.apache.org/confluence/display/EXTCDI/JPA+Usage#JPAUsage-ExtendedPersistenceContexts
> > >
> > >
> > >
> > > 2014-04-08 13:37 GMT+02:00 Karl Kildén <ka...@gmail.com>:
> > >
> > > > I am also curious about best practice for this (right now) and
> perhaps
> > in
> > > > the future. The thing is the Deltaspike /CDI style is very nice to
> work
> > > > with and it would be a preferred API for me.
> > > >
> > > >
> > > > On 8 April 2014 13:33, Rafael Meireles <ra...@gmail.com>
> > wrote:
> > > >
> > > > > Hello everyone, I would like to know if you think about create an
> > > option
> > > > > that exists in seam 2, that I can open the entitymanager for many
> > > > requests?
> > > > >
> > > >
> > >
> >
> >
> >
> > --
> > Atenciosamente,
> > --------------------------------------------
> > Rafael Meireles Caetano
> > Arquiteto Java EE
> > Sefaz - CE
> > Fone: +55 85 8811-1806
> >
>



-- 
Atenciosamente,
--------------------------------------------
Rafael Meireles Caetano
Arquiteto Java EE
Sefaz - CE
Fone: +55 85 8811-1806

Re: Extended Persistent Context

Posted by Gerhard Petracek <ge...@gmail.com>.
hi rafael,

please provide a demo-application which illustrates the issue.
back then it worked and since your own disposer calls #close, it should
still work.

regards,
gerhard



2014-04-09 2:04 GMT+02:00 Rafael Meireles <ra...@gmail.com>:

> I looked this link when I started my project, but this solution doesn't
> work. This solution just create a entity manager with the conversational
> scope and the entity manager stay serialized, but with this solution, the
> entity manager doesn't stay open during the conversation.
>
> About the best practice of the extended persistence context, here we have a
> project in production with seam 2, JSF 1.2, EJB 3 and JPA 1, running in a
> JBoss Application Server and this system is used by many people in the
> state of Ceará, Brazil. We have around 300 - 400 users concurrent and the
> Application Servers are in Cluster.
>
> Can you explain better, this:
> "the Deltaspike /CDI style is very nice to work"
>
>
> 2014-04-08 9:01 GMT-03:00 Gerhard Petracek <ge...@gmail.com>:
>
> > hi,
> >
> > please have a look at [1].
> >
> > regards,
> > gerhard
> >
> > [1]
> >
> >
> https://cwiki.apache.org/confluence/display/EXTCDI/JPA+Usage#JPAUsage-ExtendedPersistenceContexts
> >
> >
> >
> > 2014-04-08 13:37 GMT+02:00 Karl Kildén <ka...@gmail.com>:
> >
> > > I am also curious about best practice for this (right now) and perhaps
> in
> > > the future. The thing is the Deltaspike /CDI style is very nice to work
> > > with and it would be a preferred API for me.
> > >
> > >
> > > On 8 April 2014 13:33, Rafael Meireles <ra...@gmail.com>
> wrote:
> > >
> > > > Hello everyone, I would like to know if you think about create an
> > option
> > > > that exists in seam 2, that I can open the entitymanager for many
> > > requests?
> > > >
> > >
> >
>
>
>
> --
> Atenciosamente,
> --------------------------------------------
> Rafael Meireles Caetano
> Arquiteto Java EE
> Sefaz - CE
> Fone: +55 85 8811-1806
>

Re: Extended Persistent Context

Posted by Rafael Meireles <ra...@gmail.com>.
I looked this link when I started my project, but this solution doesn't
work. This solution just create a entity manager with the conversational
scope and the entity manager stay serialized, but with this solution, the
entity manager doesn't stay open during the conversation.

About the best practice of the extended persistence context, here we have a
project in production with seam 2, JSF 1.2, EJB 3 and JPA 1, running in a
JBoss Application Server and this system is used by many people in the
state of Ceará, Brazil. We have around 300 - 400 users concurrent and the
Application Servers are in Cluster.

Can you explain better, this:
"the Deltaspike /CDI style is very nice to work"


2014-04-08 9:01 GMT-03:00 Gerhard Petracek <ge...@gmail.com>:

> hi,
>
> please have a look at [1].
>
> regards,
> gerhard
>
> [1]
>
> https://cwiki.apache.org/confluence/display/EXTCDI/JPA+Usage#JPAUsage-ExtendedPersistenceContexts
>
>
>
> 2014-04-08 13:37 GMT+02:00 Karl Kildén <ka...@gmail.com>:
>
> > I am also curious about best practice for this (right now) and perhaps in
> > the future. The thing is the Deltaspike /CDI style is very nice to work
> > with and it would be a preferred API for me.
> >
> >
> > On 8 April 2014 13:33, Rafael Meireles <ra...@gmail.com> wrote:
> >
> > > Hello everyone, I would like to know if you think about create an
> option
> > > that exists in seam 2, that I can open the entitymanager for many
> > requests?
> > >
> >
>



-- 
Atenciosamente,
--------------------------------------------
Rafael Meireles Caetano
Arquiteto Java EE
Sefaz - CE
Fone: +55 85 8811-1806

Re: Extended Persistent Context

Posted by Gerhard Petracek <ge...@gmail.com>.
hi,

please have a look at [1].

regards,
gerhard

[1]
https://cwiki.apache.org/confluence/display/EXTCDI/JPA+Usage#JPAUsage-ExtendedPersistenceContexts



2014-04-08 13:37 GMT+02:00 Karl Kildén <ka...@gmail.com>:

> I am also curious about best practice for this (right now) and perhaps in
> the future. The thing is the Deltaspike /CDI style is very nice to work
> with and it would be a preferred API for me.
>
>
> On 8 April 2014 13:33, Rafael Meireles <ra...@gmail.com> wrote:
>
> > Hello everyone, I would like to know if you think about create an option
> > that exists in seam 2, that I can open the entitymanager for many
> requests?
> >
>

Re: Extended Persistent Context

Posted by Karl Kildén <ka...@gmail.com>.
I am also curious about best practice for this (right now) and perhaps in
the future. The thing is the Deltaspike /CDI style is very nice to work
with and it would be a preferred API for me.


On 8 April 2014 13:33, Rafael Meireles <ra...@gmail.com> wrote:

> Hello everyone, I would like to know if you think about create an option
> that exists in seam 2, that I can open the entitymanager for many requests?
>