You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ode.apache.org by Aaron Anderson <aa...@acm.org> on 2010/04/03 02:33:36 UTC

Re: JPA DAO refactoring.

Hi Jeff,

Here is a quick update on the JPA refactoring. I was finally able to discover the reason why one the of the Axis war tests was failing. It was due to the openjpa.FlushBeforeQueries setting being set to false and a JPA CorrelatorDAO persistent query being evaluated in memory as opposed to being executed on the database. OpenJPA was actually performing a DB query but it was not passing on any of the JPA Query parameters. Since there could be multiple transaction occurring simultaneously in the engine it is probably better to synchronize on the database as opposed to the JPA entity cache. 

Now many more of the tests are passing but a few are left to be fixed. Some of the failed tests were due to the change I made to exclude the Hibernate derby database from the war file so I will probably need to back that change out. I am pretty confident that the core runtime engine is stable now after all my changes and the rest of the work to get the tests all passing again should just be maven tweaks.

Regards,

Aaron





________________________________
From: Jeff Yu <je...@gmail.com>
To: dev@ode.apache.org
Sent: Tue, March 30, 2010 12:18:57 AM
Subject: Re: JPA DAO refactoring.

Hi Aaron,

comments inline.

On Tue, Mar 30, 2010 at 2:31 AM, Aaron Anderson <aa...@acm.org>wrote:

> Hi Jeff,
>
> Thanks for the response. I noticed that the integration tests were in the
> svn trunk so I updated it to run the tests and while there were failed test
> cases more passed than the git JPA branch so I introduced a regression issue
> of some sorts. I will work on getting the branch into the same state as the
> trunk.
>

OK, thanks.


>
> If possible I would like to leave all the testng integration tests as is.
> If they do need to be modified I imagine I would only need to clean up
> better after test execution in the test tear down. I don t believe the tests
> can run in parallel due to port conflicts.
>

+1


>
> Is there any documentation on the invocation sequences on the engine or any
> hints on tracking down execution problems? I noticed there are multiple
> layers of callables and futures and due to short timeouts I am having a hard
> time tracking invocations through the call stacks.
>

To see what happens when a SOAP message for a deployed BPEL process is
received by ODE, please look into the class org.apache.ode.axis2.ODEService.
In the method onAxisMessageExchange every incomming message is processed.
Within this method the method invoke of the class
org.apache.ode.bpel.engine.MyRoleMessageExchangeImpl is invoked, then go to
the BpelEngineImpl.onScheduledJob() method.

you could set the mex.timeout according to
http://ode.apache.org/user-guide.html#UserGuide-EndpointConfiguration

--Jeff


>
> Regards,
>
> Aaron
>
>
-- 
Cheers,
Jeff Yu

----------------
blog: http://jeff.familyyu.net

Re: JPA DAO refactoring.

Posted by Jeff Yu <je...@gmail.com>.
Hi Aaron,

Your great patch has been applied in the ode trunk. I've commented the
axis2-war's InstanceManagementTest.testAllListInstances test method for now,
as it fails.
Also I've updated the xalan groupId from org.apache.ode to xalan, and using
the 2.7.1 version to avoid the bpel-compiler module test case failure.

You can check out the latest trunk code, and to see if you have any
comments.

Thanks for your great work. ;-)

Regards
Jeff

On Fri, Apr 30, 2010 at 10:56 PM, Jeff Yu <je...@gmail.com> wrote:

> Hi Aaron,
>
> This is great... when I update the latest code, I found maven build failed
> on the bpel-compiler module, did you see this problem?
>
> May be caused by JBoss's repository upgrade, I am going to update it and
> see if it is the problem.
>
> Regards
> Jeff
>
>
> On Fri, Apr 30, 2010 at 12:26 AM, Aaron Anderson <ni...@yahoo.com>wrote:
>
>> Hi Jeff,
>>
>> In that case I believe I have completed all the JPA refactoring.
>>
>> Regards,
>>
>> Aaron
>>
>>
>>
>>
>> ________________________________
>> From: Jeff Yu <je...@gmail.com>
>> To: dev@ode.apache.org
>> Sent: Mon, April 26, 2010 9:45:11 AM
>> Subject: Re: JPA DAO refactoring.
>>
>> Hi Aaron,
>>
>> I don't think the ProcessAndInstanceManagementImpl supports in-memory
>> processes, (
>> http://ode.apache.org/user-guide.html#UserGuide-Inmemoryexecution). So I
>> think we can just put an @ignore annotation for this test case.
>>
>> Regards
>> Jeff
>>
>> On Sat, Apr 24, 2010 at 12:25 AM, Aaron Anderson <aaronanderson@acm.org
>> >wrote:
>>
>> > Hi Jeff,
>> >
>> > I got side tracked with some other stuff but I was able to take a look
>> at
>> > the failed testListInstances test in the
>> > org.apache.ode.axis2.managemen.InstanceManagementTest axis2-war test
>> class.
>> > The reason this test is failing is that the  DynPartnerResponder.bpel
>> > process in the DynPartner.zip file is deployed as an in-memory process.
>> Thus
>> > when the ProcessAndInstanceManagementImpl invokes the JPA
>> BpelDAOConnection
>> > the process instances do not exist in the database and an empty list is
>> > returned.
>> >
>> > My question is should the ProcessAndInstanceManagementImpl
>> implementation
>> > support querying in-memory processes or is this test no longer valid and
>> can
>> > be commented out?
>> >
>> > Thanks,
>> >
>> > Aaron
>> >
>> >
>> >
>> >
>> > ________________________________
>> > From: Jeff Yu <je...@gmail.com>
>> > To: dev@ode.apache.org
>> > Sent: Mon, April 12, 2010 10:15:56 PM
>> > Subject: Re: JPA DAO refactoring.
>> >
>> > Hi Aaron,
>> >
>> > With latest jpa branch, all of modules can be run successfully, now I
>> only
>> > see the axis2-war module having 6 failed test cases. Good work.
>> >
>> > Regards
>> > Jeff
>> >
>> > On Tue, Apr 13, 2010 at 1:04 AM, Aaron Anderson <aaronanderson@acm.org
>> > >wrote:
>> >
>> > > Hi Jeff,
>> > >
>> > > All the BPEL tests ran fine on my machine so I am unsure of why they
>> > failed
>> > > on yours. As for the dependency issue, I did introduce some test
>> scoped
>> > > dependencies to extract the BPEL tests for the axis2-war file tests
>> since
>> > > some of the resources are reused. Because the dependency was in the
>> test
>> > > scope I wouldn't think that would affect maven builds with tests
>> skipped
>> > but
>> > > perhaps the maven dependency resolver is not that intelligent. When I
>> am
>> > > done with all my changes I will clean out my local maven repository
>> and
>> > > build everything from scratch using JDK 1.5 to make sure the build
>> works
>> > > fine. In the mean time I updated the JPA branch and now there are only
>> a
>> > few
>> > > tests failing (5) and 12 skipped. Hopefully I will get everything
>> running
>> > > this week.
>> > >
>> > > Regards,
>> > >
>> > > Aaron
>> > >
>> > >
>> > >
>> > >
>> > > ________________________________
>> > > From: Jeff Yu <je...@gmail.com>
>> > > To: dev@ode.apache.org
>> > > Sent: Thu, April 8, 2010 5:47:39 AM
>> > > Subject: Re: JPA DAO refactoring.
>> > >
>> > > Hi Aaron,
>> > >
>> > > I've checked the latest code, also checked in the JPAConnection name
>> > issue,
>> > > (I've updated it into JpaConnection).
>> > >
>> > > After that, I've run the 'mvn clean install' from top-level, and got
>> > > following jar missing. I am wondering if you forgot to commit some
>> > changes?
>> > >
>> > > Results :
>> > >
>> > > Failed tests:
>> > >
>> > >
>> > >
>> >
>> testFailureWithManualRecovery(org.apache.ode.bpel.runtime.ActivityRecoveryTest)
>> > >
>> > >
>> > >
>> >
>> testFailureWithFaultAction(org.apache.ode.bpel.runtime.ActivityRecoveryTest)
>> > >
>> > >
>> > >
>> >
>> testFailureWithCancelAction(org.apache.ode.bpel.runtime.ActivityRecoveryTest)
>> > >
>> > >
>> > >
>> >
>> testFailureHandlingInheritence(org.apache.ode.bpel.runtime.ActivityRecoveryTest)
>> > >  testInstanceSummary(org.apache.ode.bpel.runtime.ActivityRecoveryTest)
>> > >
>> > > Tests run: 26, Failures: 5, Errors: 0, Skipped: 0
>> > >
>> > > If I ran the 'mvn clean install -Dmaven.test.skip=true", I would got
>> > > following complain..
>> > >
>> > > [INFO]
>> > >
>> ------------------------------------------------------------------------
>> > > [ERROR] BUILD ERROR
>> > > [INFO]
>> > >
>> ------------------------------------------------------------------------
>> > > [INFO] Unable to find artifact.
>> > >
>> > > Embedded error: Unable to download the artifact from any repository
>> > >
>> > > Try downloading the file manually from the project website.
>> > >
>> > > Then, install it using the command:
>> > >    mvn install:install-file -DgroupId=org.apache.ode
>> > > -DartifactId=ode-bpel-test -Dversion=2.0-SNAPSHOT -Dclassifier=tests
>> > > -Dpackaging=jar -Dfile=/path/to/file
>> > >
>> > > Alternatively, if you host your own repository you can deploy the file
>> > > there:
>> > >    mvn deploy:deploy-file -DgroupId=org.apache.ode
>> > > -DartifactId=ode-bpel-test -Dversion=2.0-SNAPSHOT -Dclassifier=tests
>> > > -Dpackaging=jar -Dfile=/path/to/file -Durl=[url] -DrepositoryId=[id]
>> > >
>> > >
>> > >  org.apache.ode:ode-bpel-test:jar:2.0-SNAPSHOT
>> > >
>> > >
>> > >
>> > > other comments inline.
>> > >
>> > > regards
>> > > Jeff
>> > >
>> > > On Wed, Apr 7, 2010 at 11:24 AM, Aaron Anderson <
>> nickmalthus@yahoo.com
>> > > >wrote:
>> > >
>> > > > Hi Jeff,
>> > > >
>> > > > I checked in my changes to the axis2-war maven POM to setup the
>> axis2
>> > > > WS-Security tests properly and now all those tests are passing. In
>> the
>> > > JPA
>> > > > github branch there are still 19 failed tests and 12 skipped ones
>> with
>> > > 108
>> > > > passing now. It is taking me more time than expected to correct the
>> > > failed
>> > > > tests cases since the TestNG error logs get overwritten on each test
>> > > > invocation so I can only fix one test at a time.
>> > > >
>> > > > Here are the things I would still like to address before I feel the
>> > > branch
>> > > > is ready:
>> > > >
>> > > > 1) I would like to revisit my decision to put the JTA transaction
>> > methods
>> > > > on the DAOConnections. I did it at first because the store already
>> had
>> > > them
>> > > > and I thought encapsulating all the JTA operations in the DAO
>> > > implementation
>> > > > would simplify things. However, the ODE Runtime needs to manage JTA
>> > > > operations to support transactional web service invocations and to
>> also
>> > > > coordinate operations across DAOConnections. With this in mind it is
>> > > better
>> > > > to make the DAOConnection implementations "JTA Aware" so that if
>> they
>> > are
>> > > > suppose to partake in a transaction they will do so otherwise each
>> DAO
>> > > > operation will be treated as atomic. I will plan on removing those
>> > > > transactional methods from the DAO interface and then back out my
>> minor
>> > > > changes to the ODE runtime and correct the tests so they all pass.
>> > > >
>> > >
>> > > makes sense to me.
>> > >
>> > >
>> > > >
>> > > > 2) The JPA BpelDAOConnectionImpl does not currently implement the
>> > > > FilteredInstanceDeletable interface so the runtime CronScheduler
>> will
>> > not
>> > > > delete completed instances when using JPA. I will update the
>> > > implementation
>> > > > to support that interface.
>> > > >
>> > >
>> > > Did you see a jira for this? otherwise could you please file a jira,
>> so
>> > > that
>> > > we will include this in our future's release note.
>> > >
>> > >
>> > > >
>> > > > 3) I would like to investigate issue ODE-428 to see if that is still
>> > and
>> > > > issue and if so push down the query to the database level.
>> > > >
>> > >
>> > > looks great, if this is a big task, I prefer that we go back to this
>> > issue
>> > > after we applied current work to trunk code. If it is a small fix,
>> then
>> > it
>> > > is definitely ok to me.
>> > >
>> > >
>> > > >
>> > > > 4) Make the proper corrections to make all the axis2-war file tests
>> > pass.
>> > > >
>> > > > Regards,
>> > > >
>> > > > Aaron
>> > > >
>> > > >
>> > > >
>> > >
>> > > --
>> > > Cheers,
>> > > Jeff Yu
>> > >
>> > > ----------------
>> > > blog: http://jeff.familyyu.net
>> > >
>> >
>> >
>> >
>> > --
>> > Cheers,
>> > Jeff Yu
>> >
>> > ----------------
>> > blog: http://jeff.familyyu.net
>> >
>>
>>
>>
>> --
>> Cheers,
>> Jeff Yu
>>
>> ----------------
>> blog: http://jeff.familyyu.net
>>
>
>
>
> --
> Cheers,
> Jeff Yu
>
> ----------------
> blog: http://jeff.familyyu.net
>
>


-- 
Cheers,
Jeff Yu

----------------
blog: http://jeff.familyyu.net

Re: JPA DAO refactoring.

Posted by Jeff Yu <je...@gmail.com>.
Hi Aaron,

This is great... when I update the latest code, I found maven build failed
on the bpel-compiler module, did you see this problem?

May be caused by JBoss's repository upgrade, I am going to update it and see
if it is the problem.

Regards
Jeff

On Fri, Apr 30, 2010 at 12:26 AM, Aaron Anderson <ni...@yahoo.com>wrote:

> Hi Jeff,
>
> In that case I believe I have completed all the JPA refactoring.
>
> Regards,
>
> Aaron
>
>
>
>
> ________________________________
> From: Jeff Yu <je...@gmail.com>
> To: dev@ode.apache.org
> Sent: Mon, April 26, 2010 9:45:11 AM
> Subject: Re: JPA DAO refactoring.
>
> Hi Aaron,
>
> I don't think the ProcessAndInstanceManagementImpl supports in-memory
> processes, (
> http://ode.apache.org/user-guide.html#UserGuide-Inmemoryexecution). So I
> think we can just put an @ignore annotation for this test case.
>
> Regards
> Jeff
>
> On Sat, Apr 24, 2010 at 12:25 AM, Aaron Anderson <aaronanderson@acm.org
> >wrote:
>
> > Hi Jeff,
> >
> > I got side tracked with some other stuff but I was able to take a look at
> > the failed testListInstances test in the
> > org.apache.ode.axis2.managemen.InstanceManagementTest axis2-war test
> class.
> > The reason this test is failing is that the  DynPartnerResponder.bpel
> > process in the DynPartner.zip file is deployed as an in-memory process.
> Thus
> > when the ProcessAndInstanceManagementImpl invokes the JPA
> BpelDAOConnection
> > the process instances do not exist in the database and an empty list is
> > returned.
> >
> > My question is should the ProcessAndInstanceManagementImpl implementation
> > support querying in-memory processes or is this test no longer valid and
> can
> > be commented out?
> >
> > Thanks,
> >
> > Aaron
> >
> >
> >
> >
> > ________________________________
> > From: Jeff Yu <je...@gmail.com>
> > To: dev@ode.apache.org
> > Sent: Mon, April 12, 2010 10:15:56 PM
> > Subject: Re: JPA DAO refactoring.
> >
> > Hi Aaron,
> >
> > With latest jpa branch, all of modules can be run successfully, now I
> only
> > see the axis2-war module having 6 failed test cases. Good work.
> >
> > Regards
> > Jeff
> >
> > On Tue, Apr 13, 2010 at 1:04 AM, Aaron Anderson <aaronanderson@acm.org
> > >wrote:
> >
> > > Hi Jeff,
> > >
> > > All the BPEL tests ran fine on my machine so I am unsure of why they
> > failed
> > > on yours. As for the dependency issue, I did introduce some test scoped
> > > dependencies to extract the BPEL tests for the axis2-war file tests
> since
> > > some of the resources are reused. Because the dependency was in the
> test
> > > scope I wouldn't think that would affect maven builds with tests
> skipped
> > but
> > > perhaps the maven dependency resolver is not that intelligent. When I
> am
> > > done with all my changes I will clean out my local maven repository and
> > > build everything from scratch using JDK 1.5 to make sure the build
> works
> > > fine. In the mean time I updated the JPA branch and now there are only
> a
> > few
> > > tests failing (5) and 12 skipped. Hopefully I will get everything
> running
> > > this week.
> > >
> > > Regards,
> > >
> > > Aaron
> > >
> > >
> > >
> > >
> > > ________________________________
> > > From: Jeff Yu <je...@gmail.com>
> > > To: dev@ode.apache.org
> > > Sent: Thu, April 8, 2010 5:47:39 AM
> > > Subject: Re: JPA DAO refactoring.
> > >
> > > Hi Aaron,
> > >
> > > I've checked the latest code, also checked in the JPAConnection name
> > issue,
> > > (I've updated it into JpaConnection).
> > >
> > > After that, I've run the 'mvn clean install' from top-level, and got
> > > following jar missing. I am wondering if you forgot to commit some
> > changes?
> > >
> > > Results :
> > >
> > > Failed tests:
> > >
> > >
> > >
> >
> testFailureWithManualRecovery(org.apache.ode.bpel.runtime.ActivityRecoveryTest)
> > >
> > >
> > >
> >
> testFailureWithFaultAction(org.apache.ode.bpel.runtime.ActivityRecoveryTest)
> > >
> > >
> > >
> >
> testFailureWithCancelAction(org.apache.ode.bpel.runtime.ActivityRecoveryTest)
> > >
> > >
> > >
> >
> testFailureHandlingInheritence(org.apache.ode.bpel.runtime.ActivityRecoveryTest)
> > >  testInstanceSummary(org.apache.ode.bpel.runtime.ActivityRecoveryTest)
> > >
> > > Tests run: 26, Failures: 5, Errors: 0, Skipped: 0
> > >
> > > If I ran the 'mvn clean install -Dmaven.test.skip=true", I would got
> > > following complain..
> > >
> > > [INFO]
> > >
> ------------------------------------------------------------------------
> > > [ERROR] BUILD ERROR
> > > [INFO]
> > >
> ------------------------------------------------------------------------
> > > [INFO] Unable to find artifact.
> > >
> > > Embedded error: Unable to download the artifact from any repository
> > >
> > > Try downloading the file manually from the project website.
> > >
> > > Then, install it using the command:
> > >    mvn install:install-file -DgroupId=org.apache.ode
> > > -DartifactId=ode-bpel-test -Dversion=2.0-SNAPSHOT -Dclassifier=tests
> > > -Dpackaging=jar -Dfile=/path/to/file
> > >
> > > Alternatively, if you host your own repository you can deploy the file
> > > there:
> > >    mvn deploy:deploy-file -DgroupId=org.apache.ode
> > > -DartifactId=ode-bpel-test -Dversion=2.0-SNAPSHOT -Dclassifier=tests
> > > -Dpackaging=jar -Dfile=/path/to/file -Durl=[url] -DrepositoryId=[id]
> > >
> > >
> > >  org.apache.ode:ode-bpel-test:jar:2.0-SNAPSHOT
> > >
> > >
> > >
> > > other comments inline.
> > >
> > > regards
> > > Jeff
> > >
> > > On Wed, Apr 7, 2010 at 11:24 AM, Aaron Anderson <nickmalthus@yahoo.com
> > > >wrote:
> > >
> > > > Hi Jeff,
> > > >
> > > > I checked in my changes to the axis2-war maven POM to setup the axis2
> > > > WS-Security tests properly and now all those tests are passing. In
> the
> > > JPA
> > > > github branch there are still 19 failed tests and 12 skipped ones
> with
> > > 108
> > > > passing now. It is taking me more time than expected to correct the
> > > failed
> > > > tests cases since the TestNG error logs get overwritten on each test
> > > > invocation so I can only fix one test at a time.
> > > >
> > > > Here are the things I would still like to address before I feel the
> > > branch
> > > > is ready:
> > > >
> > > > 1) I would like to revisit my decision to put the JTA transaction
> > methods
> > > > on the DAOConnections. I did it at first because the store already
> had
> > > them
> > > > and I thought encapsulating all the JTA operations in the DAO
> > > implementation
> > > > would simplify things. However, the ODE Runtime needs to manage JTA
> > > > operations to support transactional web service invocations and to
> also
> > > > coordinate operations across DAOConnections. With this in mind it is
> > > better
> > > > to make the DAOConnection implementations "JTA Aware" so that if they
> > are
> > > > suppose to partake in a transaction they will do so otherwise each
> DAO
> > > > operation will be treated as atomic. I will plan on removing those
> > > > transactional methods from the DAO interface and then back out my
> minor
> > > > changes to the ODE runtime and correct the tests so they all pass.
> > > >
> > >
> > > makes sense to me.
> > >
> > >
> > > >
> > > > 2) The JPA BpelDAOConnectionImpl does not currently implement the
> > > > FilteredInstanceDeletable interface so the runtime CronScheduler will
> > not
> > > > delete completed instances when using JPA. I will update the
> > > implementation
> > > > to support that interface.
> > > >
> > >
> > > Did you see a jira for this? otherwise could you please file a jira, so
> > > that
> > > we will include this in our future's release note.
> > >
> > >
> > > >
> > > > 3) I would like to investigate issue ODE-428 to see if that is still
> > and
> > > > issue and if so push down the query to the database level.
> > > >
> > >
> > > looks great, if this is a big task, I prefer that we go back to this
> > issue
> > > after we applied current work to trunk code. If it is a small fix, then
> > it
> > > is definitely ok to me.
> > >
> > >
> > > >
> > > > 4) Make the proper corrections to make all the axis2-war file tests
> > pass.
> > > >
> > > > Regards,
> > > >
> > > > Aaron
> > > >
> > > >
> > > >
> > >
> > > --
> > > Cheers,
> > > Jeff Yu
> > >
> > > ----------------
> > > blog: http://jeff.familyyu.net
> > >
> >
> >
> >
> > --
> > Cheers,
> > Jeff Yu
> >
> > ----------------
> > blog: http://jeff.familyyu.net
> >
>
>
>
> --
> Cheers,
> Jeff Yu
>
> ----------------
> blog: http://jeff.familyyu.net
>



-- 
Cheers,
Jeff Yu

----------------
blog: http://jeff.familyyu.net

Re: JPA DAO refactoring.

Posted by Aaron Anderson <ni...@yahoo.com>.
Hi Jeff,

In that case I believe I have completed all the JPA refactoring.

Regards,

Aaron




________________________________
From: Jeff Yu <je...@gmail.com>
To: dev@ode.apache.org
Sent: Mon, April 26, 2010 9:45:11 AM
Subject: Re: JPA DAO refactoring.

Hi Aaron,

I don't think the ProcessAndInstanceManagementImpl supports in-memory
processes, (
http://ode.apache.org/user-guide.html#UserGuide-Inmemoryexecution). So I
think we can just put an @ignore annotation for this test case.

Regards
Jeff

On Sat, Apr 24, 2010 at 12:25 AM, Aaron Anderson <aa...@acm.org>wrote:

> Hi Jeff,
>
> I got side tracked with some other stuff but I was able to take a look at
> the failed testListInstances test in the
> org.apache.ode.axis2.managemen.InstanceManagementTest axis2-war test class.
> The reason this test is failing is that the  DynPartnerResponder.bpel
> process in the DynPartner.zip file is deployed as an in-memory process. Thus
> when the ProcessAndInstanceManagementImpl invokes the JPA BpelDAOConnection
> the process instances do not exist in the database and an empty list is
> returned.
>
> My question is should the ProcessAndInstanceManagementImpl implementation
> support querying in-memory processes or is this test no longer valid and can
> be commented out?
>
> Thanks,
>
> Aaron
>
>
>
>
> ________________________________
> From: Jeff Yu <je...@gmail.com>
> To: dev@ode.apache.org
> Sent: Mon, April 12, 2010 10:15:56 PM
> Subject: Re: JPA DAO refactoring.
>
> Hi Aaron,
>
> With latest jpa branch, all of modules can be run successfully, now I only
> see the axis2-war module having 6 failed test cases. Good work.
>
> Regards
> Jeff
>
> On Tue, Apr 13, 2010 at 1:04 AM, Aaron Anderson <aaronanderson@acm.org
> >wrote:
>
> > Hi Jeff,
> >
> > All the BPEL tests ran fine on my machine so I am unsure of why they
> failed
> > on yours. As for the dependency issue, I did introduce some test scoped
> > dependencies to extract the BPEL tests for the axis2-war file tests since
> > some of the resources are reused. Because the dependency was in the test
> > scope I wouldn't think that would affect maven builds with tests skipped
> but
> > perhaps the maven dependency resolver is not that intelligent. When I am
> > done with all my changes I will clean out my local maven repository and
> > build everything from scratch using JDK 1.5 to make sure the build works
> > fine. In the mean time I updated the JPA branch and now there are only a
> few
> > tests failing (5) and 12 skipped. Hopefully I will get everything running
> > this week.
> >
> > Regards,
> >
> > Aaron
> >
> >
> >
> >
> > ________________________________
> > From: Jeff Yu <je...@gmail.com>
> > To: dev@ode.apache.org
> > Sent: Thu, April 8, 2010 5:47:39 AM
> > Subject: Re: JPA DAO refactoring.
> >
> > Hi Aaron,
> >
> > I've checked the latest code, also checked in the JPAConnection name
> issue,
> > (I've updated it into JpaConnection).
> >
> > After that, I've run the 'mvn clean install' from top-level, and got
> > following jar missing. I am wondering if you forgot to commit some
> changes?
> >
> > Results :
> >
> > Failed tests:
> >
> >
> >
> testFailureWithManualRecovery(org.apache.ode.bpel.runtime.ActivityRecoveryTest)
> >
> >
> >
> testFailureWithFaultAction(org.apache.ode.bpel.runtime.ActivityRecoveryTest)
> >
> >
> >
> testFailureWithCancelAction(org.apache.ode.bpel.runtime.ActivityRecoveryTest)
> >
> >
> >
> testFailureHandlingInheritence(org.apache.ode.bpel.runtime.ActivityRecoveryTest)
> >  testInstanceSummary(org.apache.ode.bpel.runtime.ActivityRecoveryTest)
> >
> > Tests run: 26, Failures: 5, Errors: 0, Skipped: 0
> >
> > If I ran the 'mvn clean install -Dmaven.test.skip=true", I would got
> > following complain..
> >
> > [INFO]
> > ------------------------------------------------------------------------
> > [ERROR] BUILD ERROR
> > [INFO]
> > ------------------------------------------------------------------------
> > [INFO] Unable to find artifact.
> >
> > Embedded error: Unable to download the artifact from any repository
> >
> > Try downloading the file manually from the project website.
> >
> > Then, install it using the command:
> >    mvn install:install-file -DgroupId=org.apache.ode
> > -DartifactId=ode-bpel-test -Dversion=2.0-SNAPSHOT -Dclassifier=tests
> > -Dpackaging=jar -Dfile=/path/to/file
> >
> > Alternatively, if you host your own repository you can deploy the file
> > there:
> >    mvn deploy:deploy-file -DgroupId=org.apache.ode
> > -DartifactId=ode-bpel-test -Dversion=2.0-SNAPSHOT -Dclassifier=tests
> > -Dpackaging=jar -Dfile=/path/to/file -Durl=[url] -DrepositoryId=[id]
> >
> >
> >  org.apache.ode:ode-bpel-test:jar:2.0-SNAPSHOT
> >
> >
> >
> > other comments inline.
> >
> > regards
> > Jeff
> >
> > On Wed, Apr 7, 2010 at 11:24 AM, Aaron Anderson <nickmalthus@yahoo.com
> > >wrote:
> >
> > > Hi Jeff,
> > >
> > > I checked in my changes to the axis2-war maven POM to setup the axis2
> > > WS-Security tests properly and now all those tests are passing. In the
> > JPA
> > > github branch there are still 19 failed tests and 12 skipped ones with
> > 108
> > > passing now. It is taking me more time than expected to correct the
> > failed
> > > tests cases since the TestNG error logs get overwritten on each test
> > > invocation so I can only fix one test at a time.
> > >
> > > Here are the things I would still like to address before I feel the
> > branch
> > > is ready:
> > >
> > > 1) I would like to revisit my decision to put the JTA transaction
> methods
> > > on the DAOConnections. I did it at first because the store already had
> > them
> > > and I thought encapsulating all the JTA operations in the DAO
> > implementation
> > > would simplify things. However, the ODE Runtime needs to manage JTA
> > > operations to support transactional web service invocations and to also
> > > coordinate operations across DAOConnections. With this in mind it is
> > better
> > > to make the DAOConnection implementations "JTA Aware" so that if they
> are
> > > suppose to partake in a transaction they will do so otherwise each DAO
> > > operation will be treated as atomic. I will plan on removing those
> > > transactional methods from the DAO interface and then back out my minor
> > > changes to the ODE runtime and correct the tests so they all pass.
> > >
> >
> > makes sense to me.
> >
> >
> > >
> > > 2) The JPA BpelDAOConnectionImpl does not currently implement the
> > > FilteredInstanceDeletable interface so the runtime CronScheduler will
> not
> > > delete completed instances when using JPA. I will update the
> > implementation
> > > to support that interface.
> > >
> >
> > Did you see a jira for this? otherwise could you please file a jira, so
> > that
> > we will include this in our future's release note.
> >
> >
> > >
> > > 3) I would like to investigate issue ODE-428 to see if that is still
> and
> > > issue and if so push down the query to the database level.
> > >
> >
> > looks great, if this is a big task, I prefer that we go back to this
> issue
> > after we applied current work to trunk code. If it is a small fix, then
> it
> > is definitely ok to me.
> >
> >
> > >
> > > 4) Make the proper corrections to make all the axis2-war file tests
> pass.
> > >
> > > Regards,
> > >
> > > Aaron
> > >
> > >
> > >
> >
> > --
> > Cheers,
> > Jeff Yu
> >
> > ----------------
> > blog: http://jeff.familyyu.net
> >
>
>
>
> --
> Cheers,
> Jeff Yu
>
> ----------------
> blog: http://jeff.familyyu.net
>



-- 
Cheers,
Jeff Yu

----------------
blog: http://jeff.familyyu.net

Re: JPA DAO refactoring.

Posted by Jeff Yu <je...@gmail.com>.
Hi Aaron,

I don't think the ProcessAndInstanceManagementImpl supports in-memory
processes, (
http://ode.apache.org/user-guide.html#UserGuide-Inmemoryexecution). So I
think we can just put an @ignore annotation for this test case.

Regards
Jeff

On Sat, Apr 24, 2010 at 12:25 AM, Aaron Anderson <aa...@acm.org>wrote:

> Hi Jeff,
>
> I got side tracked with some other stuff but I was able to take a look at
> the failed testListInstances test in the
> org.apache.ode.axis2.managemen.InstanceManagementTest axis2-war test class.
> The reason this test is failing is that the  DynPartnerResponder.bpel
> process in the DynPartner.zip file is deployed as an in-memory process. Thus
> when the ProcessAndInstanceManagementImpl invokes the JPA BpelDAOConnection
> the process instances do not exist in the database and an empty list is
> returned.
>
> My question is should the ProcessAndInstanceManagementImpl implementation
> support querying in-memory processes or is this test no longer valid and can
> be commented out?
>
> Thanks,
>
> Aaron
>
>
>
>
> ________________________________
> From: Jeff Yu <je...@gmail.com>
> To: dev@ode.apache.org
> Sent: Mon, April 12, 2010 10:15:56 PM
> Subject: Re: JPA DAO refactoring.
>
> Hi Aaron,
>
> With latest jpa branch, all of modules can be run successfully, now I only
> see the axis2-war module having 6 failed test cases. Good work.
>
> Regards
> Jeff
>
> On Tue, Apr 13, 2010 at 1:04 AM, Aaron Anderson <aaronanderson@acm.org
> >wrote:
>
> > Hi Jeff,
> >
> > All the BPEL tests ran fine on my machine so I am unsure of why they
> failed
> > on yours. As for the dependency issue, I did introduce some test scoped
> > dependencies to extract the BPEL tests for the axis2-war file tests since
> > some of the resources are reused. Because the dependency was in the test
> > scope I wouldn't think that would affect maven builds with tests skipped
> but
> > perhaps the maven dependency resolver is not that intelligent. When I am
> > done with all my changes I will clean out my local maven repository and
> > build everything from scratch using JDK 1.5 to make sure the build works
> > fine. In the mean time I updated the JPA branch and now there are only a
> few
> > tests failing (5) and 12 skipped. Hopefully I will get everything running
> > this week.
> >
> > Regards,
> >
> > Aaron
> >
> >
> >
> >
> > ________________________________
> > From: Jeff Yu <je...@gmail.com>
> > To: dev@ode.apache.org
> > Sent: Thu, April 8, 2010 5:47:39 AM
> > Subject: Re: JPA DAO refactoring.
> >
> > Hi Aaron,
> >
> > I've checked the latest code, also checked in the JPAConnection name
> issue,
> > (I've updated it into JpaConnection).
> >
> > After that, I've run the 'mvn clean install' from top-level, and got
> > following jar missing. I am wondering if you forgot to commit some
> changes?
> >
> > Results :
> >
> > Failed tests:
> >
> >
> >
> testFailureWithManualRecovery(org.apache.ode.bpel.runtime.ActivityRecoveryTest)
> >
> >
> >
> testFailureWithFaultAction(org.apache.ode.bpel.runtime.ActivityRecoveryTest)
> >
> >
> >
> testFailureWithCancelAction(org.apache.ode.bpel.runtime.ActivityRecoveryTest)
> >
> >
> >
> testFailureHandlingInheritence(org.apache.ode.bpel.runtime.ActivityRecoveryTest)
> >  testInstanceSummary(org.apache.ode.bpel.runtime.ActivityRecoveryTest)
> >
> > Tests run: 26, Failures: 5, Errors: 0, Skipped: 0
> >
> > If I ran the 'mvn clean install -Dmaven.test.skip=true", I would got
> > following complain..
> >
> > [INFO]
> > ------------------------------------------------------------------------
> > [ERROR] BUILD ERROR
> > [INFO]
> > ------------------------------------------------------------------------
> > [INFO] Unable to find artifact.
> >
> > Embedded error: Unable to download the artifact from any repository
> >
> > Try downloading the file manually from the project website.
> >
> > Then, install it using the command:
> >    mvn install:install-file -DgroupId=org.apache.ode
> > -DartifactId=ode-bpel-test -Dversion=2.0-SNAPSHOT -Dclassifier=tests
> > -Dpackaging=jar -Dfile=/path/to/file
> >
> > Alternatively, if you host your own repository you can deploy the file
> > there:
> >    mvn deploy:deploy-file -DgroupId=org.apache.ode
> > -DartifactId=ode-bpel-test -Dversion=2.0-SNAPSHOT -Dclassifier=tests
> > -Dpackaging=jar -Dfile=/path/to/file -Durl=[url] -DrepositoryId=[id]
> >
> >
> >  org.apache.ode:ode-bpel-test:jar:2.0-SNAPSHOT
> >
> >
> >
> > other comments inline.
> >
> > regards
> > Jeff
> >
> > On Wed, Apr 7, 2010 at 11:24 AM, Aaron Anderson <nickmalthus@yahoo.com
> > >wrote:
> >
> > > Hi Jeff,
> > >
> > > I checked in my changes to the axis2-war maven POM to setup the axis2
> > > WS-Security tests properly and now all those tests are passing. In the
> > JPA
> > > github branch there are still 19 failed tests and 12 skipped ones with
> > 108
> > > passing now. It is taking me more time than expected to correct the
> > failed
> > > tests cases since the TestNG error logs get overwritten on each test
> > > invocation so I can only fix one test at a time.
> > >
> > > Here are the things I would still like to address before I feel the
> > branch
> > > is ready:
> > >
> > > 1) I would like to revisit my decision to put the JTA transaction
> methods
> > > on the DAOConnections. I did it at first because the store already had
> > them
> > > and I thought encapsulating all the JTA operations in the DAO
> > implementation
> > > would simplify things. However, the ODE Runtime needs to manage JTA
> > > operations to support transactional web service invocations and to also
> > > coordinate operations across DAOConnections. With this in mind it is
> > better
> > > to make the DAOConnection implementations "JTA Aware" so that if they
> are
> > > suppose to partake in a transaction they will do so otherwise each DAO
> > > operation will be treated as atomic. I will plan on removing those
> > > transactional methods from the DAO interface and then back out my minor
> > > changes to the ODE runtime and correct the tests so they all pass.
> > >
> >
> > makes sense to me.
> >
> >
> > >
> > > 2) The JPA BpelDAOConnectionImpl does not currently implement the
> > > FilteredInstanceDeletable interface so the runtime CronScheduler will
> not
> > > delete completed instances when using JPA. I will update the
> > implementation
> > > to support that interface.
> > >
> >
> > Did you see a jira for this? otherwise could you please file a jira, so
> > that
> > we will include this in our future's release note.
> >
> >
> > >
> > > 3) I would like to investigate issue ODE-428 to see if that is still
> and
> > > issue and if so push down the query to the database level.
> > >
> >
> > looks great, if this is a big task, I prefer that we go back to this
> issue
> > after we applied current work to trunk code. If it is a small fix, then
> it
> > is definitely ok to me.
> >
> >
> > >
> > > 4) Make the proper corrections to make all the axis2-war file tests
> pass.
> > >
> > > Regards,
> > >
> > > Aaron
> > >
> > >
> > >
> >
> > --
> > Cheers,
> > Jeff Yu
> >
> > ----------------
> > blog: http://jeff.familyyu.net
> >
>
>
>
> --
> Cheers,
> Jeff Yu
>
> ----------------
> blog: http://jeff.familyyu.net
>



-- 
Cheers,
Jeff Yu

----------------
blog: http://jeff.familyyu.net

Re: JPA DAO refactoring.

Posted by Aaron Anderson <aa...@acm.org>.
Hi Jeff,

I got side tracked with some other stuff but I was able to take a look at the failed testListInstances test in the org.apache.ode.axis2.managemen.InstanceManagementTest axis2-war test class. The reason this test is failing is that the  DynPartnerResponder.bpel process in the DynPartner.zip file is deployed as an in-memory process. Thus when the ProcessAndInstanceManagementImpl invokes the JPA BpelDAOConnection the process instances do not exist in the database and an empty list is returned. 

My question is should the ProcessAndInstanceManagementImpl implementation support querying in-memory processes or is this test no longer valid and can be commented out?

Thanks,

Aaron




________________________________
From: Jeff Yu <je...@gmail.com>
To: dev@ode.apache.org
Sent: Mon, April 12, 2010 10:15:56 PM
Subject: Re: JPA DAO refactoring.

Hi Aaron,

With latest jpa branch, all of modules can be run successfully, now I only
see the axis2-war module having 6 failed test cases. Good work.

Regards
Jeff

On Tue, Apr 13, 2010 at 1:04 AM, Aaron Anderson <aa...@acm.org>wrote:

> Hi Jeff,
>
> All the BPEL tests ran fine on my machine so I am unsure of why they failed
> on yours. As for the dependency issue, I did introduce some test scoped
> dependencies to extract the BPEL tests for the axis2-war file tests since
> some of the resources are reused. Because the dependency was in the test
> scope I wouldn't think that would affect maven builds with tests skipped but
> perhaps the maven dependency resolver is not that intelligent. When I am
> done with all my changes I will clean out my local maven repository and
> build everything from scratch using JDK 1.5 to make sure the build works
> fine. In the mean time I updated the JPA branch and now there are only a few
> tests failing (5) and 12 skipped. Hopefully I will get everything running
> this week.
>
> Regards,
>
> Aaron
>
>
>
>
> ________________________________
> From: Jeff Yu <je...@gmail.com>
> To: dev@ode.apache.org
> Sent: Thu, April 8, 2010 5:47:39 AM
> Subject: Re: JPA DAO refactoring.
>
> Hi Aaron,
>
> I've checked the latest code, also checked in the JPAConnection name issue,
> (I've updated it into JpaConnection).
>
> After that, I've run the 'mvn clean install' from top-level, and got
> following jar missing. I am wondering if you forgot to commit some changes?
>
> Results :
>
> Failed tests:
>
>
> testFailureWithManualRecovery(org.apache.ode.bpel.runtime.ActivityRecoveryTest)
>
>
> testFailureWithFaultAction(org.apache.ode.bpel.runtime.ActivityRecoveryTest)
>
>
> testFailureWithCancelAction(org.apache.ode.bpel.runtime.ActivityRecoveryTest)
>
>
> testFailureHandlingInheritence(org.apache.ode.bpel.runtime.ActivityRecoveryTest)
>  testInstanceSummary(org.apache.ode.bpel.runtime.ActivityRecoveryTest)
>
> Tests run: 26, Failures: 5, Errors: 0, Skipped: 0
>
> If I ran the 'mvn clean install -Dmaven.test.skip=true", I would got
> following complain..
>
> [INFO]
> ------------------------------------------------------------------------
> [ERROR] BUILD ERROR
> [INFO]
> ------------------------------------------------------------------------
> [INFO] Unable to find artifact.
>
> Embedded error: Unable to download the artifact from any repository
>
> Try downloading the file manually from the project website.
>
> Then, install it using the command:
>    mvn install:install-file -DgroupId=org.apache.ode
> -DartifactId=ode-bpel-test -Dversion=2.0-SNAPSHOT -Dclassifier=tests
> -Dpackaging=jar -Dfile=/path/to/file
>
> Alternatively, if you host your own repository you can deploy the file
> there:
>    mvn deploy:deploy-file -DgroupId=org.apache.ode
> -DartifactId=ode-bpel-test -Dversion=2.0-SNAPSHOT -Dclassifier=tests
> -Dpackaging=jar -Dfile=/path/to/file -Durl=[url] -DrepositoryId=[id]
>
>
>  org.apache.ode:ode-bpel-test:jar:2.0-SNAPSHOT
>
>
>
> other comments inline.
>
> regards
> Jeff
>
> On Wed, Apr 7, 2010 at 11:24 AM, Aaron Anderson <nickmalthus@yahoo.com
> >wrote:
>
> > Hi Jeff,
> >
> > I checked in my changes to the axis2-war maven POM to setup the axis2
> > WS-Security tests properly and now all those tests are passing. In the
> JPA
> > github branch there are still 19 failed tests and 12 skipped ones with
> 108
> > passing now. It is taking me more time than expected to correct the
> failed
> > tests cases since the TestNG error logs get overwritten on each test
> > invocation so I can only fix one test at a time.
> >
> > Here are the things I would still like to address before I feel the
> branch
> > is ready:
> >
> > 1) I would like to revisit my decision to put the JTA transaction methods
> > on the DAOConnections. I did it at first because the store already had
> them
> > and I thought encapsulating all the JTA operations in the DAO
> implementation
> > would simplify things. However, the ODE Runtime needs to manage JTA
> > operations to support transactional web service invocations and to also
> > coordinate operations across DAOConnections. With this in mind it is
> better
> > to make the DAOConnection implementations "JTA Aware" so that if they are
> > suppose to partake in a transaction they will do so otherwise each DAO
> > operation will be treated as atomic. I will plan on removing those
> > transactional methods from the DAO interface and then back out my minor
> > changes to the ODE runtime and correct the tests so they all pass.
> >
>
> makes sense to me.
>
>
> >
> > 2) The JPA BpelDAOConnectionImpl does not currently implement the
> > FilteredInstanceDeletable interface so the runtime CronScheduler will not
> > delete completed instances when using JPA. I will update the
> implementation
> > to support that interface.
> >
>
> Did you see a jira for this? otherwise could you please file a jira, so
> that
> we will include this in our future's release note.
>
>
> >
> > 3) I would like to investigate issue ODE-428 to see if that is still and
> > issue and if so push down the query to the database level.
> >
>
> looks great, if this is a big task, I prefer that we go back to this issue
> after we applied current work to trunk code. If it is a small fix, then it
> is definitely ok to me.
>
>
> >
> > 4) Make the proper corrections to make all the axis2-war file tests pass.
> >
> > Regards,
> >
> > Aaron
> >
> >
> >
>
> --
> Cheers,
> Jeff Yu
>
> ----------------
> blog: http://jeff.familyyu.net
>



-- 
Cheers,
Jeff Yu

----------------
blog: http://jeff.familyyu.net

Re: JPA DAO refactoring.

Posted by Jeff Yu <je...@gmail.com>.
Hi Aaron,

With latest jpa branch, all of modules can be run successfully, now I only
see the axis2-war module having 6 failed test cases. Good work.

Regards
Jeff

On Tue, Apr 13, 2010 at 1:04 AM, Aaron Anderson <aa...@acm.org>wrote:

> Hi Jeff,
>
> All the BPEL tests ran fine on my machine so I am unsure of why they failed
> on yours. As for the dependency issue, I did introduce some test scoped
> dependencies to extract the BPEL tests for the axis2-war file tests since
> some of the resources are reused. Because the dependency was in the test
> scope I wouldn't think that would affect maven builds with tests skipped but
> perhaps the maven dependency resolver is not that intelligent. When I am
> done with all my changes I will clean out my local maven repository and
> build everything from scratch using JDK 1.5 to make sure the build works
> fine. In the mean time I updated the JPA branch and now there are only a few
> tests failing (5) and 12 skipped. Hopefully I will get everything running
> this week.
>
> Regards,
>
> Aaron
>
>
>
>
> ________________________________
> From: Jeff Yu <je...@gmail.com>
> To: dev@ode.apache.org
> Sent: Thu, April 8, 2010 5:47:39 AM
> Subject: Re: JPA DAO refactoring.
>
> Hi Aaron,
>
> I've checked the latest code, also checked in the JPAConnection name issue,
> (I've updated it into JpaConnection).
>
> After that, I've run the 'mvn clean install' from top-level, and got
> following jar missing. I am wondering if you forgot to commit some changes?
>
> Results :
>
> Failed tests:
>
>
> testFailureWithManualRecovery(org.apache.ode.bpel.runtime.ActivityRecoveryTest)
>
>
> testFailureWithFaultAction(org.apache.ode.bpel.runtime.ActivityRecoveryTest)
>
>
> testFailureWithCancelAction(org.apache.ode.bpel.runtime.ActivityRecoveryTest)
>
>
> testFailureHandlingInheritence(org.apache.ode.bpel.runtime.ActivityRecoveryTest)
>  testInstanceSummary(org.apache.ode.bpel.runtime.ActivityRecoveryTest)
>
> Tests run: 26, Failures: 5, Errors: 0, Skipped: 0
>
> If I ran the 'mvn clean install -Dmaven.test.skip=true", I would got
> following complain..
>
> [INFO]
> ------------------------------------------------------------------------
> [ERROR] BUILD ERROR
> [INFO]
> ------------------------------------------------------------------------
> [INFO] Unable to find artifact.
>
> Embedded error: Unable to download the artifact from any repository
>
> Try downloading the file manually from the project website.
>
> Then, install it using the command:
>    mvn install:install-file -DgroupId=org.apache.ode
> -DartifactId=ode-bpel-test -Dversion=2.0-SNAPSHOT -Dclassifier=tests
> -Dpackaging=jar -Dfile=/path/to/file
>
> Alternatively, if you host your own repository you can deploy the file
> there:
>    mvn deploy:deploy-file -DgroupId=org.apache.ode
> -DartifactId=ode-bpel-test -Dversion=2.0-SNAPSHOT -Dclassifier=tests
> -Dpackaging=jar -Dfile=/path/to/file -Durl=[url] -DrepositoryId=[id]
>
>
>  org.apache.ode:ode-bpel-test:jar:2.0-SNAPSHOT
>
>
>
> other comments inline.
>
> regards
> Jeff
>
> On Wed, Apr 7, 2010 at 11:24 AM, Aaron Anderson <nickmalthus@yahoo.com
> >wrote:
>
> > Hi Jeff,
> >
> > I checked in my changes to the axis2-war maven POM to setup the axis2
> > WS-Security tests properly and now all those tests are passing. In the
> JPA
> > github branch there are still 19 failed tests and 12 skipped ones with
> 108
> > passing now. It is taking me more time than expected to correct the
> failed
> > tests cases since the TestNG error logs get overwritten on each test
> > invocation so I can only fix one test at a time.
> >
> > Here are the things I would still like to address before I feel the
> branch
> > is ready:
> >
> > 1) I would like to revisit my decision to put the JTA transaction methods
> > on the DAOConnections. I did it at first because the store already had
> them
> > and I thought encapsulating all the JTA operations in the DAO
> implementation
> > would simplify things. However, the ODE Runtime needs to manage JTA
> > operations to support transactional web service invocations and to also
> > coordinate operations across DAOConnections. With this in mind it is
> better
> > to make the DAOConnection implementations "JTA Aware" so that if they are
> > suppose to partake in a transaction they will do so otherwise each DAO
> > operation will be treated as atomic. I will plan on removing those
> > transactional methods from the DAO interface and then back out my minor
> > changes to the ODE runtime and correct the tests so they all pass.
> >
>
> makes sense to me.
>
>
> >
> > 2) The JPA BpelDAOConnectionImpl does not currently implement the
> > FilteredInstanceDeletable interface so the runtime CronScheduler will not
> > delete completed instances when using JPA. I will update the
> implementation
> > to support that interface.
> >
>
> Did you see a jira for this? otherwise could you please file a jira, so
> that
> we will include this in our future's release note.
>
>
> >
> > 3) I would like to investigate issue ODE-428 to see if that is still and
> > issue and if so push down the query to the database level.
> >
>
> looks great, if this is a big task, I prefer that we go back to this issue
> after we applied current work to trunk code. If it is a small fix, then it
> is definitely ok to me.
>
>
> >
> > 4) Make the proper corrections to make all the axis2-war file tests pass.
> >
> > Regards,
> >
> > Aaron
> >
> >
> >
>
> --
> Cheers,
> Jeff Yu
>
> ----------------
> blog: http://jeff.familyyu.net
>



-- 
Cheers,
Jeff Yu

----------------
blog: http://jeff.familyyu.net

Re: JPA DAO refactoring.

Posted by Aaron Anderson <aa...@acm.org>.
Hi Jeff,

All the BPEL tests ran fine on my machine so I am unsure of why they failed on yours. As for the dependency issue, I did introduce some test scoped dependencies to extract the BPEL tests for the axis2-war file tests since some of the resources are reused. Because the dependency was in the test scope I wouldn't think that would affect maven builds with tests skipped but perhaps the maven dependency resolver is not that intelligent. When I am done with all my changes I will clean out my local maven repository and build everything from scratch using JDK 1.5 to make sure the build works fine. In the mean time I updated the JPA branch and now there are only a few tests failing (5) and 12 skipped. Hopefully I will get everything running this week. 

Regards,

Aaron




________________________________
From: Jeff Yu <je...@gmail.com>
To: dev@ode.apache.org
Sent: Thu, April 8, 2010 5:47:39 AM
Subject: Re: JPA DAO refactoring.

Hi Aaron,

I've checked the latest code, also checked in the JPAConnection name issue,
(I've updated it into JpaConnection).

After that, I've run the 'mvn clean install' from top-level, and got
following jar missing. I am wondering if you forgot to commit some changes?

Results :

Failed tests:

testFailureWithManualRecovery(org.apache.ode.bpel.runtime.ActivityRecoveryTest)

testFailureWithFaultAction(org.apache.ode.bpel.runtime.ActivityRecoveryTest)

testFailureWithCancelAction(org.apache.ode.bpel.runtime.ActivityRecoveryTest)

testFailureHandlingInheritence(org.apache.ode.bpel.runtime.ActivityRecoveryTest)
  testInstanceSummary(org.apache.ode.bpel.runtime.ActivityRecoveryTest)

Tests run: 26, Failures: 5, Errors: 0, Skipped: 0

If I ran the 'mvn clean install -Dmaven.test.skip=true", I would got
following complain..

[INFO]
------------------------------------------------------------------------
[ERROR] BUILD ERROR
[INFO]
------------------------------------------------------------------------
[INFO] Unable to find artifact.

Embedded error: Unable to download the artifact from any repository

Try downloading the file manually from the project website.

Then, install it using the command:
    mvn install:install-file -DgroupId=org.apache.ode
-DartifactId=ode-bpel-test -Dversion=2.0-SNAPSHOT -Dclassifier=tests
-Dpackaging=jar -Dfile=/path/to/file

Alternatively, if you host your own repository you can deploy the file
there:
    mvn deploy:deploy-file -DgroupId=org.apache.ode
-DartifactId=ode-bpel-test -Dversion=2.0-SNAPSHOT -Dclassifier=tests
-Dpackaging=jar -Dfile=/path/to/file -Durl=[url] -DrepositoryId=[id]


  org.apache.ode:ode-bpel-test:jar:2.0-SNAPSHOT



other comments inline.

regards
Jeff

On Wed, Apr 7, 2010 at 11:24 AM, Aaron Anderson <ni...@yahoo.com>wrote:

> Hi Jeff,
>
> I checked in my changes to the axis2-war maven POM to setup the axis2
> WS-Security tests properly and now all those tests are passing. In the JPA
> github branch there are still 19 failed tests and 12 skipped ones with 108
> passing now. It is taking me more time than expected to correct the failed
> tests cases since the TestNG error logs get overwritten on each test
> invocation so I can only fix one test at a time.
>
> Here are the things I would still like to address before I feel the branch
> is ready:
>
> 1) I would like to revisit my decision to put the JTA transaction methods
> on the DAOConnections. I did it at first because the store already had them
> and I thought encapsulating all the JTA operations in the DAO implementation
> would simplify things. However, the ODE Runtime needs to manage JTA
> operations to support transactional web service invocations and to also
> coordinate operations across DAOConnections. With this in mind it is better
> to make the DAOConnection implementations "JTA Aware" so that if they are
> suppose to partake in a transaction they will do so otherwise each DAO
> operation will be treated as atomic. I will plan on removing those
> transactional methods from the DAO interface and then back out my minor
> changes to the ODE runtime and correct the tests so they all pass.
>

makes sense to me.


>
> 2) The JPA BpelDAOConnectionImpl does not currently implement the
> FilteredInstanceDeletable interface so the runtime CronScheduler will not
> delete completed instances when using JPA. I will update the implementation
> to support that interface.
>

Did you see a jira for this? otherwise could you please file a jira, so that
we will include this in our future's release note.


>
> 3) I would like to investigate issue ODE-428 to see if that is still and
> issue and if so push down the query to the database level.
>

looks great, if this is a big task, I prefer that we go back to this issue
after we applied current work to trunk code. If it is a small fix, then it
is definitely ok to me.


>
> 4) Make the proper corrections to make all the axis2-war file tests pass.
>
> Regards,
>
> Aaron
>
>
>

-- 
Cheers,
Jeff Yu

----------------
blog: http://jeff.familyyu.net

Re: JPA DAO refactoring.

Posted by Jeff Yu <je...@gmail.com>.
Hi Aaron,

I've checked the latest code, also checked in the JPAConnection name issue,
(I've updated it into JpaConnection).

After that, I've run the 'mvn clean install' from top-level, and got
following jar missing. I am wondering if you forgot to commit some changes?

Results :

Failed tests:

testFailureWithManualRecovery(org.apache.ode.bpel.runtime.ActivityRecoveryTest)

testFailureWithFaultAction(org.apache.ode.bpel.runtime.ActivityRecoveryTest)

testFailureWithCancelAction(org.apache.ode.bpel.runtime.ActivityRecoveryTest)

testFailureHandlingInheritence(org.apache.ode.bpel.runtime.ActivityRecoveryTest)
  testInstanceSummary(org.apache.ode.bpel.runtime.ActivityRecoveryTest)

Tests run: 26, Failures: 5, Errors: 0, Skipped: 0

If I ran the 'mvn clean install -Dmaven.test.skip=true", I would got
following complain..

[INFO]
------------------------------------------------------------------------
[ERROR] BUILD ERROR
[INFO]
------------------------------------------------------------------------
[INFO] Unable to find artifact.

Embedded error: Unable to download the artifact from any repository

Try downloading the file manually from the project website.

Then, install it using the command:
    mvn install:install-file -DgroupId=org.apache.ode
-DartifactId=ode-bpel-test -Dversion=2.0-SNAPSHOT -Dclassifier=tests
-Dpackaging=jar -Dfile=/path/to/file

Alternatively, if you host your own repository you can deploy the file
there:
    mvn deploy:deploy-file -DgroupId=org.apache.ode
-DartifactId=ode-bpel-test -Dversion=2.0-SNAPSHOT -Dclassifier=tests
-Dpackaging=jar -Dfile=/path/to/file -Durl=[url] -DrepositoryId=[id]


  org.apache.ode:ode-bpel-test:jar:2.0-SNAPSHOT



other comments inline.

regards
Jeff

On Wed, Apr 7, 2010 at 11:24 AM, Aaron Anderson <ni...@yahoo.com>wrote:

> Hi Jeff,
>
> I checked in my changes to the axis2-war maven POM to setup the axis2
> WS-Security tests properly and now all those tests are passing. In the JPA
> github branch there are still 19 failed tests and 12 skipped ones with 108
> passing now. It is taking me more time than expected to correct the failed
> tests cases since the TestNG error logs get overwritten on each test
> invocation so I can only fix one test at a time.
>
> Here are the things I would still like to address before I feel the branch
> is ready:
>
> 1) I would like to revisit my decision to put the JTA transaction methods
> on the DAOConnections. I did it at first because the store already had them
> and I thought encapsulating all the JTA operations in the DAO implementation
> would simplify things. However, the ODE Runtime needs to manage JTA
> operations to support transactional web service invocations and to also
> coordinate operations across DAOConnections. With this in mind it is better
> to make the DAOConnection implementations "JTA Aware" so that if they are
> suppose to partake in a transaction they will do so otherwise each DAO
> operation will be treated as atomic. I will plan on removing those
> transactional methods from the DAO interface and then back out my minor
> changes to the ODE runtime and correct the tests so they all pass.
>

makes sense to me.


>
> 2) The JPA BpelDAOConnectionImpl does not currently implement the
> FilteredInstanceDeletable interface so the runtime CronScheduler will not
> delete completed instances when using JPA. I will update the implementation
> to support that interface.
>

Did you see a jira for this? otherwise could you please file a jira, so that
we will include this in our future's release note.


>
> 3) I would like to investigate issue ODE-428 to see if that is still and
> issue and if so push down the query to the database level.
>

looks great, if this is a big task, I prefer that we go back to this issue
after we applied current work to trunk code. If it is a small fix, then it
is definitely ok to me.


>
> 4) Make the proper corrections to make all the axis2-war file tests pass.
>
> Regards,
>
> Aaron
>
>
>

-- 
Cheers,
Jeff Yu

----------------
blog: http://jeff.familyyu.net

Re: JPA DAO refactoring.

Posted by Aaron Anderson <ni...@yahoo.com>.
Hi Jeff,

I checked in my changes to the axis2-war maven POM to setup the axis2 WS-Security tests properly and now all those tests are passing. In the JPA github branch there are still 19 failed tests and 12 skipped ones with 108 passing now. It is taking me more time than expected to correct the failed tests cases since the TestNG error logs get overwritten on each test invocation so I can only fix one test at a time.

Here are the things I would still like to address before I feel the branch is ready:

1) I would like to revisit my decision to put the JTA transaction methods on the DAOConnections. I did it at first because the store already had them and I thought encapsulating all the JTA operations in the DAO implementation would simplify things. However, the ODE Runtime needs to manage JTA operations to support transactional web service invocations and to also coordinate operations across DAOConnections. With this in mind it is better to make the DAOConnection implementations "JTA Aware" so that if they are suppose to partake in a transaction they will do so otherwise each DAO operation will be treated as atomic. I will plan on removing those transactional methods from the DAO interface and then back out my minor changes to the ODE runtime and correct the tests so they all pass.

2) The JPA BpelDAOConnectionImpl does not currently implement the FilteredInstanceDeletable interface so the runtime CronScheduler will not delete completed instances when using JPA. I will update the implementation to support that interface.

3) I would like to investigate issue ODE-428 to see if that is still and issue and if so push down the query to the database level.

4) Make the proper corrections to make all the axis2-war file tests pass.

Regards,

Aaron




________________________________
From: Jeff Yu <je...@gmail.com>
To: dev@ode.apache.org
Sent: Tue, April 6, 2010 1:13:09 AM
Subject: Re: JPA DAO refactoring.

Hi Aaron,

Thanks for the update. It looks good. I will look into the axis2-war pom
file, and to try against the ode trunk. Thinking that maybe we can applied
this change (enable the axis2-war testing) to trunk separately.

Regards
Jeff

On Sat, Apr 3, 2010 at 11:33 AM, Aaron Anderson <aa...@acm.org>wrote:

> Hi Jeff,
>
> Here is a quick update on the JPA refactoring. I was finally able to
> discover the reason why one the of the Axis war tests was failing. It was
> due to the openjpa.FlushBeforeQueries setting being set to false and a JPA
> CorrelatorDAO persistent query being evaluated in memory as opposed to being
> executed on the database. OpenJPA was actually performing a DB query but it
> was not passing on any of the JPA Query parameters. Since there could be
> multiple transaction occurring simultaneously in the engine it is probably
> better to synchronize on the database as opposed to the JPA entity cache.
>
> Now many more of the tests are passing but a few are left to be fixed. Some
> of the failed tests were due to the change I made to exclude the Hibernate
> derby database from the war file so I will probably need to back that change
> out. I am pretty confident that the core runtime engine is stable now after
> all my changes and the rest of the work to get the tests all passing again
> should just be maven tweaks.
>
> Regards,
>
> Aaron
>
>
>
>
>
> ________________________________
> From: Jeff Yu <je...@gmail.com>
> To: dev@ode.apache.org
> Sent: Tue, March 30, 2010 12:18:57 AM
> Subject: Re: JPA DAO refactoring.
>
> Hi Aaron,
>
> comments inline.
>
> On Tue, Mar 30, 2010 at 2:31 AM, Aaron Anderson <aaronanderson@acm.org
> >wrote:
>
> > Hi Jeff,
> >
> > Thanks for the response. I noticed that the integration tests were in the
> > svn trunk so I updated it to run the tests and while there were failed
> test
> > cases more passed than the git JPA branch so I introduced a regression
> issue
> > of some sorts. I will work on getting the branch into the same state as
> the
> > trunk.
> >
>
> OK, thanks.
>
>
> >
> > If possible I would like to leave all the testng integration tests as is.
> > If they do need to be modified I imagine I would only need to clean up
> > better after test execution in the test tear down. I don t believe the
> tests
> > can run in parallel due to port conflicts.
> >
>
> +1
>
>
> >
> > Is there any documentation on the invocation sequences on the engine or
> any
> > hints on tracking down execution problems? I noticed there are multiple
> > layers of callables and futures and due to short timeouts I am having a
> hard
> > time tracking invocations through the call stacks.
> >
>
> To see what happens when a SOAP message for a deployed BPEL process is
> received by ODE, please look into the class
> org.apache.ode.axis2.ODEService.
> In the method onAxisMessageExchange every incomming message is processed.
> Within this method the method invoke of the class
> org.apache.ode.bpel.engine.MyRoleMessageExchangeImpl is invoked, then go to
> the BpelEngineImpl.onScheduledJob() method.
>
> you could set the mex.timeout according to
> http://ode.apache.org/user-guide.html#UserGuide-EndpointConfiguration
>
> --Jeff
>
>
> >
> > Regards,
> >
> > Aaron
> >
> >
> --
> Cheers,
> Jeff Yu
>
> ----------------
> blog: http://jeff.familyyu.net
>



-- 
Cheers,
Jeff Yu

----------------
blog: http://jeff.familyyu.net

Re: JPA DAO refactoring.

Posted by Jeff Yu <je...@gmail.com>.
Hi Aaron,

Thanks for the update. It looks good. I will look into the axis2-war pom
file, and to try against the ode trunk. Thinking that maybe we can applied
this change (enable the axis2-war testing) to trunk separately.

Regards
Jeff

On Sat, Apr 3, 2010 at 11:33 AM, Aaron Anderson <aa...@acm.org>wrote:

> Hi Jeff,
>
> Here is a quick update on the JPA refactoring. I was finally able to
> discover the reason why one the of the Axis war tests was failing. It was
> due to the openjpa.FlushBeforeQueries setting being set to false and a JPA
> CorrelatorDAO persistent query being evaluated in memory as opposed to being
> executed on the database. OpenJPA was actually performing a DB query but it
> was not passing on any of the JPA Query parameters. Since there could be
> multiple transaction occurring simultaneously in the engine it is probably
> better to synchronize on the database as opposed to the JPA entity cache.
>
> Now many more of the tests are passing but a few are left to be fixed. Some
> of the failed tests were due to the change I made to exclude the Hibernate
> derby database from the war file so I will probably need to back that change
> out. I am pretty confident that the core runtime engine is stable now after
> all my changes and the rest of the work to get the tests all passing again
> should just be maven tweaks.
>
> Regards,
>
> Aaron
>
>
>
>
>
> ________________________________
> From: Jeff Yu <je...@gmail.com>
> To: dev@ode.apache.org
> Sent: Tue, March 30, 2010 12:18:57 AM
> Subject: Re: JPA DAO refactoring.
>
> Hi Aaron,
>
> comments inline.
>
> On Tue, Mar 30, 2010 at 2:31 AM, Aaron Anderson <aaronanderson@acm.org
> >wrote:
>
> > Hi Jeff,
> >
> > Thanks for the response. I noticed that the integration tests were in the
> > svn trunk so I updated it to run the tests and while there were failed
> test
> > cases more passed than the git JPA branch so I introduced a regression
> issue
> > of some sorts. I will work on getting the branch into the same state as
> the
> > trunk.
> >
>
> OK, thanks.
>
>
> >
> > If possible I would like to leave all the testng integration tests as is.
> > If they do need to be modified I imagine I would only need to clean up
> > better after test execution in the test tear down. I don t believe the
> tests
> > can run in parallel due to port conflicts.
> >
>
> +1
>
>
> >
> > Is there any documentation on the invocation sequences on the engine or
> any
> > hints on tracking down execution problems? I noticed there are multiple
> > layers of callables and futures and due to short timeouts I am having a
> hard
> > time tracking invocations through the call stacks.
> >
>
> To see what happens when a SOAP message for a deployed BPEL process is
> received by ODE, please look into the class
> org.apache.ode.axis2.ODEService.
> In the method onAxisMessageExchange every incomming message is processed.
> Within this method the method invoke of the class
> org.apache.ode.bpel.engine.MyRoleMessageExchangeImpl is invoked, then go to
> the BpelEngineImpl.onScheduledJob() method.
>
> you could set the mex.timeout according to
> http://ode.apache.org/user-guide.html#UserGuide-EndpointConfiguration
>
> --Jeff
>
>
> >
> > Regards,
> >
> > Aaron
> >
> >
> --
> Cheers,
> Jeff Yu
>
> ----------------
> blog: http://jeff.familyyu.net
>



-- 
Cheers,
Jeff Yu

----------------
blog: http://jeff.familyyu.net