Seam SVN: r14059 - branches/enterprise/JBPAPP_5_0/src/main/org/jboss/seam/async.
by seam-commits@lists.jboss.org
Author: manaRH
Date: 2011-02-25 08:24:10 -0500 (Fri, 25 Feb 2011)
New Revision: 14059
Modified:
branches/enterprise/JBPAPP_5_0/src/main/org/jboss/seam/async/Asynchronous.java
branches/enterprise/JBPAPP_5_0/src/main/org/jboss/seam/async/AsynchronousInvocation.java
Log:
JBPAPP-5410 - fixed regression causes by previous change in ejb tx synchronization
Modified: branches/enterprise/JBPAPP_5_0/src/main/org/jboss/seam/async/Asynchronous.java
===================================================================
--- branches/enterprise/JBPAPP_5_0/src/main/org/jboss/seam/async/Asynchronous.java 2011-02-25 11:39:21 UTC (rev 14058)
+++ branches/enterprise/JBPAPP_5_0/src/main/org/jboss/seam/async/Asynchronous.java 2011-02-25 13:24:10 UTC (rev 14059)
@@ -92,20 +92,8 @@
setup();
try
{
- new Work<Object>()
- {
- @Override
- protected Object work()
- {
- process();
- return null;
- }
- }.workInTransaction();
+ process();
}
- catch (Exception e)
- {
- log.error("Exception was thrown in asynchronous processing", e);
- }
finally
{
cleanup();
Modified: branches/enterprise/JBPAPP_5_0/src/main/org/jboss/seam/async/AsynchronousInvocation.java
===================================================================
--- branches/enterprise/JBPAPP_5_0/src/main/org/jboss/seam/async/AsynchronousInvocation.java 2011-02-25 11:39:21 UTC (rev 14058)
+++ branches/enterprise/JBPAPP_5_0/src/main/org/jboss/seam/async/AsynchronousInvocation.java 2011-02-25 13:24:10 UTC (rev 14059)
@@ -7,6 +7,7 @@
import org.jboss.seam.log.LogProvider;
import org.jboss.seam.log.Logging;
import org.jboss.seam.util.Reflections;
+import org.jboss.seam.util.Work;
/**
* An asynchronous method invocation.
@@ -47,19 +48,35 @@
@Override
protected void process()
{
- Object target = Component.getInstance(componentName);
-
- Method method;
try
{
- method = target.getClass().getMethod(methodName, argTypes);
+ new Work()
+ {
+
+ @Override
+ protected Object work()
+ {
+ Object target = Component.getInstance(componentName);
+
+ Method method;
+ try
+ {
+ method = target.getClass().getMethod(methodName, argTypes);
+ }
+ catch (NoSuchMethodException nsme)
+ {
+ throw new IllegalStateException(nsme);
+ }
+
+ Reflections.invokeAndWrap(method, target, args);
+ return null;
+ }
+ }.workInTransaction();
}
- catch (NoSuchMethodException nsme)
+ catch (Exception e)
{
- throw new IllegalStateException(nsme);
+ throw new RuntimeException(e);
}
-
- Reflections.invokeAndWrap(method, target, args);
}
}.run();
14 years
Seam SVN: r14058 - branches/enterprise/JBPAPP_5_0/build.
by seam-commits@lists.jboss.org
Author: manaRH
Date: 2011-02-25 06:39:21 -0500 (Fri, 25 Feb 2011)
New Revision: 14058
Modified:
branches/enterprise/JBPAPP_5_0/build/settings.xml
Log:
added maven2-brew repo
Modified: branches/enterprise/JBPAPP_5_0/build/settings.xml
===================================================================
--- branches/enterprise/JBPAPP_5_0/build/settings.xml 2011-02-25 08:08:24 UTC (rev 14057)
+++ branches/enterprise/JBPAPP_5_0/build/settings.xml 2011-02-25 11:39:21 UTC (rev 14058)
@@ -264,10 +264,10 @@
-->
<profile>
- <id>jboss-product-repository</id>
+ <id>jboss-mead-repository</id>
<repositories>
<repository>
- <id>jboss-product-repository</id>
+ <id>jboss-mead-repository</id>
<name>JBoss Product Maven Repository</name>
<url>http://download.devel.redhat.com/brewroot/repos/mead-shared-build/latest/...</url>
<layout>default</layout>
@@ -283,7 +283,7 @@
</repositories>
<pluginRepositories>
<pluginRepository>
- <id>jboss-product-repository</id>
+ <id>jboss-mead-repository</id>
<name>JBoss Product Maven Repository</name>
<url>http://download.devel.redhat.com/brewroot/repos/mead-shared-build/latest/...</url>
<layout>default</layout>
@@ -356,6 +356,41 @@
<!-- </repositories>-->
<!-- </profile>-->
+ <profile>
+ <id>jboss-product-repository</id>
+ <repositories>
+ <repository>
+ <id>jboss-product-repository</id>
+ <name>JBoss Product Maven Repository</name>
+ <url>http://repository.jboss.org/maven2-brew/</url>
+ <layout>default</layout>
+ <releases>
+ <enabled>true</enabled>
+ <updatePolicy>never</updatePolicy>
+ </releases>
+ <snapshots>
+ <enabled>false</enabled>
+ <updatePolicy>never</updatePolicy>
+ </snapshots>
+ </repository>
+ </repositories>
+ <pluginRepositories>
+ <pluginRepository>
+ <id>jboss-product-repository</id>
+ <name>JBoss Product Maven Repository</name>
+ <url>http://repository.jboss.org/maven2-brew/</url>
+ <layout>default</layout>
+ <releases>
+ <enabled>true</enabled>
+ <updatePolicy>never</updatePolicy>
+ </releases>
+ <snapshots>
+ <enabled>true</enabled>
+ <updatePolicy>never</updatePolicy>
+ </snapshots>
+ </pluginRepository>
+ </pluginRepositories>
+ </profile>
</profiles>
@@ -369,7 +404,8 @@
-->
<activeProfiles>
- <activeProfile>jboss-product-repository</activeProfile>
+ <activeProfile>jboss-product-repository</activeProfile>
+ <activeProfile>jboss-mead-repository</activeProfile>
<activeProfile>jboss-public-repository</activeProfile>
<!-- <activeProfile>jboss-snapshot-repository</activeProfile> -->
</activeProfiles>
14 years
Seam SVN: r14057 - in branches/enterprise/JBPAPP_5_0/src/main/org/jboss/seam: bpm and 1 other directory.
by seam-commits@lists.jboss.org
Author: manaRH
Date: 2011-02-25 03:08:24 -0500 (Fri, 25 Feb 2011)
New Revision: 14057
Modified:
branches/enterprise/JBPAPP_5_0/src/main/org/jboss/seam/async/Asynchronous.java
branches/enterprise/JBPAPP_5_0/src/main/org/jboss/seam/bpm/BusinessProcess.java
Log:
JBPAPP-5410
Modified: branches/enterprise/JBPAPP_5_0/src/main/org/jboss/seam/async/Asynchronous.java
===================================================================
--- branches/enterprise/JBPAPP_5_0/src/main/org/jboss/seam/async/Asynchronous.java 2011-02-22 16:13:01 UTC (rev 14056)
+++ branches/enterprise/JBPAPP_5_0/src/main/org/jboss/seam/async/Asynchronous.java 2011-02-25 08:08:24 UTC (rev 14057)
@@ -8,6 +8,7 @@
import org.jboss.seam.core.Init;
import org.jboss.seam.log.LogProvider;
import org.jboss.seam.log.Logging;
+import org.jboss.seam.util.Work;
/**
* Something that happens asynchronously, and with a full
@@ -57,10 +58,17 @@
{
try
{
- BusinessProcess.instance().resumeTask(taskId);
+ new Work<Object>()
+ {
+ @Override
+ protected Object work() throws Exception
+ {
+ BusinessProcess.instance().resumeTask(taskId);
+ return null;
+ }
+ }.workInTransaction();
}
catch (Exception e) {
- log.error("Exception was thrown in BusinessProcess.resumeTask", e);
throw new RuntimeException(e);
}
}
@@ -84,8 +92,20 @@
setup();
try
{
- process();
+ new Work<Object>()
+ {
+ @Override
+ protected Object work()
+ {
+ process();
+ return null;
+ }
+ }.workInTransaction();
}
+ catch (Exception e)
+ {
+ log.error("Exception was thrown in asynchronous processing", e);
+ }
finally
{
cleanup();
Modified: branches/enterprise/JBPAPP_5_0/src/main/org/jboss/seam/bpm/BusinessProcess.java
===================================================================
--- branches/enterprise/JBPAPP_5_0/src/main/org/jboss/seam/bpm/BusinessProcess.java 2011-02-22 16:13:01 UTC (rev 14056)
+++ branches/enterprise/JBPAPP_5_0/src/main/org/jboss/seam/bpm/BusinessProcess.java 2011-02-25 08:08:24 UTC (rev 14057)
@@ -285,7 +285,17 @@
}
else
{
- setProcessId( task.getTaskMgmtInstance().getProcessInstance().getId() );
+ try
+ {
+ setProcessId( task.getTaskMgmtInstance().getProcessInstance().getId() );
+ }
+ catch (Exception e)
+ {
+ //log.error("Exception while transition is in process!");
+ this.processId = null;
+ this.taskId = null;
+ throw new RuntimeException(e);
+ }
Events.instance().raiseEvent("org.jboss.seam.initTask." + task.getTask().getName());
return true;
}
14 years