- 使用 Spring Initializr 创建 Spring Boot 应用程序
- 在Spring Boot中配置Cassandra
- 在 Spring Boot 上配置 Tomcat 连接池
- 将Camel消息路由到嵌入WildFly的Artemis上
本文整理了Java中com.arjuna.ats.internal.jta.resources.arjunacore.XAOnePhaseResource
类的一些代码示例,展示了XAOnePhaseResource
类的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。XAOnePhaseResource
类的具体详情如下:
包路径:com.arjuna.ats.internal.jta.resources.arjunacore.XAOnePhaseResource
类名称:XAOnePhaseResource
[英]One Phase resource wrapper for XAResources.
[中]XAResources的单阶段资源包装器。
代码示例来源:origin: org.jboss.jbossts/jbossjta
/**
* Attempt to create an AbstractRecord wrapping the given XAResource. Return null if this fails, or
* is diallowed by the current configuration of multiple last resource behaviour.
*
* @param xaRes
* @param params
* @param xid
* @return
*/
private AbstractRecord createRecord(XAResource xaRes, Object[] params, Xid xid)
{
final AbstractRecord record;
if ((xaRes instanceof LastResourceCommitOptimisation)
|| ((LAST_RESOURCE_OPTIMISATION_INTERFACE != null) && LAST_RESOURCE_OPTIMISATION_INTERFACE
.isInstance(xaRes)))
{
record = new LastResourceRecord(new XAOnePhaseResource(xaRes, xid, params));
}
else
{
record = new XAResourceRecord(this, xaRes, xid, params);
}
return record;
}
代码示例来源:origin: jbosstm/narayana
throw generateUnpackError(new ClassNotFoundException());
throw generateUnpackError(sqle) ;
throw generateUnpackError(cnfe) ;
throw generateUnpackError(ioe) ;
throw generateUnpackError(cce) ;
代码示例来源:origin: org.jboss.narayana.jts/narayana-jts-idlj
/**
* Commit the one phase resource.
* @return TwoPhaseOutcome.FINISH_OK or TwoPhaseOutcome.FINISH_ERROR
*/
public int rollback()
{
try
{
xaResource.rollback(xid) ;
return TwoPhaseOutcome.FINISH_OK ;
}
catch (final XAException xae)
{
addDeferredThrowable(xae);
jtaLogger.i18NLogger.warn_resources_arjunacore_XAOnePhaseResource_rollbackexception(XAHelper.xidToString(xid), xae);
}
catch (final Throwable ex)
{
if (jtaLogger.logger.isTraceEnabled()) {
jtaLogger.logger.trace("XAOnePhaseResource.rollback(" + xid + ") " + ex.getMessage());
}
}
return TwoPhaseOutcome.FINISH_ERROR ;
}
代码示例来源:origin: jbosstm/narayana
@Test
public void testInvalid ()
{
XAOnePhaseResource xares = new XAOnePhaseResource();
assertEquals(xares.commit(), TwoPhaseOutcome.ONE_PHASE_ERROR);
assertEquals(xares.rollback(), TwoPhaseOutcome.FINISH_ERROR);
}
代码示例来源:origin: jbosstm/narayana
@Test
public void testCommit ()
{
SampleOnePhaseResource res = new SampleOnePhaseResource();
XidImple xid = new XidImple(new Uid());
XAOnePhaseResource xares = new XAOnePhaseResource(res, xid, null);
assertEquals(xares.commit(), TwoPhaseOutcome.FINISH_OK);
assertTrue(res.onePhaseCalled());
}
代码示例来源:origin: jbosstm/narayana
@Test
public void testPackUnpack () throws Exception
{
DummyXA res = new DummyXA(false);
XidImple xid = new XidImple(new Uid());
XAOnePhaseResource xares = new XAOnePhaseResource(res, xid, null);
OutputObjectState os = new OutputObjectState();
xares.pack(os);
InputObjectState is = new InputObjectState(os);
xares.unpack(is);
}
}
代码示例来源:origin: jbosstm/narayana
@Test
public void testPackUnpackError () throws Exception
{
SampleOnePhaseResource res = new SampleOnePhaseResource();
XidImple xid = new XidImple(new Uid());
XAOnePhaseResource xares = new XAOnePhaseResource(res, xid, null);
OutputObjectState os = new OutputObjectState();
try
{
xares.pack(os);
fail();
}
catch (final IOException ex)
{
}
}
代码示例来源:origin: jbosstm/narayana
@Test
public void testCommitHeuristic ()
{
SampleOnePhaseResource res = new SampleOnePhaseResource(SampleOnePhaseResource.ErrorType.heurcom);
XidImple xid = new XidImple(new Uid());
XAOnePhaseResource xares = new XAOnePhaseResource(res, xid, null);
assertEquals(xares.commit(), TwoPhaseOutcome.FINISH_OK);
assertTrue(res.forgetCalled());
}
代码示例来源:origin: jbosstm/narayana
@Test
public void test () throws Exception
{
DummyRecoverableXAConnection rc = new DummyRecoverableXAConnection();
Object[] obj = new Object[1];
SampleOnePhaseResource res = new SampleOnePhaseResource();
obj[XAResourceRecord.XACONNECTION] = rc;
XAOnePhaseResource xares = new XAOnePhaseResource(res, new XidImple(new Uid()), obj);
OutputObjectState os = new OutputObjectState();
xares.pack(os);
InputObjectState is = new InputObjectState(os);
xares.unpack(is);
}
代码示例来源:origin: jbosstm/narayana
@Test
public void testCommitHeuristic ()
{
SampleOnePhaseResource res = new SampleOnePhaseResource(ErrorType.heurcom);
XidImple xid = new XidImple(new Uid());
XAOnePhaseResource xares = new XAOnePhaseResource(res, xid, null);
assertEquals(xares.commit(), TwoPhaseOutcome.FINISH_OK);
assertTrue(res.forgetCalled());
}
代码示例来源:origin: jboss.jbossts/jbossjts
/**
* Attempt to create an AbstractRecord wrapping the given XAResource. Return null if this fails, or
* is diallowed by the current configuration of multiple last resource behaviour.
*
* @param xaRes
* @param params
* @param xid
* @return
*/
private AbstractRecord createRecord(XAResource xaRes, Object[] params, Xid xid)
{
final AbstractRecord record;
if ((xaRes instanceof LastResourceCommitOptimisation)
|| ((LAST_RESOURCE_OPTIMISATION_INTERFACE != null) && LAST_RESOURCE_OPTIMISATION_INTERFACE
.isInstance(xaRes)))
{
record = new LastResourceRecord(new XAOnePhaseResource(xaRes, xid, params));
}
else
{
record = new XAResourceRecord(this, xaRes, xid, params);
}
return record;
}
代码示例来源:origin: org.jboss.jbossts/jbossjta
throw generateUnpackError(new ClassNotFoundException());
throw generateUnpackError(sqle) ;
throw generateUnpackError(cnfe) ;
throw generateUnpackError(ioe) ;
throw generateUnpackError(cce) ;
代码示例来源:origin: org.jboss.narayana.jta/jta
/**
* Commit the one phase resource.
* @return TwoPhaseOutcome.FINISH_OK or TwoPhaseOutcome.FINISH_ERROR
*/
public int rollback()
{
try
{
xaResource.rollback(xid) ;
return TwoPhaseOutcome.FINISH_OK ;
}
catch (final XAException xae)
{
addDeferredThrowable(xae);
jtaLogger.i18NLogger.warn_resources_arjunacore_XAOnePhaseResource_rollbackexception(XAHelper.xidToString(xid), xae);
}
catch (final Throwable ex)
{
if (jtaLogger.logger.isTraceEnabled()) {
jtaLogger.logger.trace("XAOnePhaseResource.rollback(" + xid + ") " + ex.getMessage());
}
}
return TwoPhaseOutcome.FINISH_ERROR ;
}
代码示例来源:origin: jbosstm/narayana
@Test
public void testRollbackHeuristic ()
{
SampleOnePhaseResource res = new SampleOnePhaseResource(SampleOnePhaseResource.ErrorType.heurrb);
XidImple xid = new XidImple(new Uid());
XAOnePhaseResource xares = new XAOnePhaseResource(res, xid, null);
assertEquals(xares.commit(), TwoPhaseOutcome.ONE_PHASE_ERROR);
assertTrue(res.forgetCalled());
}
}
代码示例来源:origin: jbosstm/narayana
return new LastResourceRecord(new XAOnePhaseResource(xaRes, xid, params));
代码示例来源:origin: org.jboss.narayana.jts/narayana-jts-idlj
throw generateUnpackError(new ClassNotFoundException());
throw generateUnpackError(sqle) ;
throw generateUnpackError(cnfe) ;
throw generateUnpackError(ioe) ;
throw generateUnpackError(cce) ;
代码示例来源:origin: org.jboss.jbossts.jta/narayana-jta
/**
* Commit the one phase resource.
* @return TwoPhaseOutcome.FINISH_OK or TwoPhaseOutcome.FINISH_ERROR
*/
public int rollback()
{
try
{
xaResource.rollback(xid) ;
return TwoPhaseOutcome.FINISH_OK ;
}
catch (final XAException xae)
{
addDeferredThrowable(xae);
jtaLogger.i18NLogger.warn_resources_arjunacore_XAOnePhaseResource_rollbackexception(XAHelper.xidToString(xid), xae);
}
catch (final Throwable ex)
{
if (jtaLogger.logger.isTraceEnabled()) {
jtaLogger.logger.trace("XAOnePhaseResource.rollback(" + xid + ") " + ex.getMessage());
}
}
return TwoPhaseOutcome.FINISH_ERROR ;
}
代码示例来源:origin: jbosstm/narayana
@Test
public void testRollbackHeuristic ()
{
SampleOnePhaseResource res = new SampleOnePhaseResource(ErrorType.heurrb);
XidImple xid = new XidImple(new Uid());
XAOnePhaseResource xares = new XAOnePhaseResource(res, xid, null);
assertEquals(xares.commit(), TwoPhaseOutcome.ONE_PHASE_ERROR);
assertTrue(res.forgetCalled());
}
代码示例来源:origin: org.jboss.narayana.jta/jta
return new LastResourceRecord(new XAOnePhaseResource(xaRes, xid, params));
代码示例来源:origin: org.jboss.jbossts.jta/narayana-jta
throw generateUnpackError(new ClassNotFoundException());
throw generateUnpackError(sqle) ;
throw generateUnpackError(cnfe) ;
throw generateUnpackError(ioe) ;
throw generateUnpackError(cce) ;
我正在尝试开发一个连接到 Oracle 数据库的 Java EE 应用程序。我正在使用 ojdbc6 jar。我正在从属性文件中读取数据库信息。 package com.varun.util; imp
当我检查 JBoss 日志时,我看到了很多这样的错误 2012-03-29 12:01:27,358 WARN @ [com.arjuna.ats.jta.logging.loggerI18N] [
所以在我正在处理的一个项目中,我有一个由 TimerService 触发并执行更新某些数据的方法的 Seam 组件。此方法通常运行几秒钟,但有时可能需要几分钟。 我的问题是,如果此方法花费的时间太长,
本文整理了Java中com.arjuna.ats.jta.utils.XAHelper类的一些代码示例,展示了XAHelper类的具体用法。这些代码示例主要来源于Github/Stackoverflo
本文整理了Java中com.arjuna.ats.jta.xa.XidImple类的一些代码示例,展示了XidImple类的具体用法。这些代码示例主要来源于Github/Stackoverflow/M
本文整理了Java中com.arjuna.ats.jta.recovery.XAResourceRecovery类的一些代码示例,展示了XAResourceRecovery类的具体用法。这些代码示例主
本文整理了Java中com.arjuna.ats.jta.recovery.XAResourceRecoveryHelper类的一些代码示例,展示了XAResourceRecoveryHelper类的
本文整理了Java中com.arjuna.ats.jta.recovery.XAResourceOrphanFilter类的一些代码示例,展示了XAResourceOrphanFilter类的具体用法
本文整理了Java中com.arjuna.ats.jta.recovery.XARecoveryResource类的一些代码示例,展示了XARecoveryResource类的具体用法。这些代码示例主
本文整理了Java中com.arjuna.ats.internal.jta.XAResourceRecordMap类的一些代码示例,展示了XAResourceRecordMap类的具体用法。这些代码示
本文整理了Java中com.arjuna.ats.jta.recovery.XARecoveryResourceManager类的一些代码示例,展示了XARecoveryResourceManager
本文整理了Java中com.arjuna.ats.jta.resources.XAResourceMap类的一些代码示例,展示了XAResourceMap类的具体用法。这些代码示例主要来源于Githu
本文整理了Java中com.arjuna.ats.jta.xa.XAModifier类的一些代码示例,展示了XAModifier类的具体用法。这些代码示例主要来源于Github/Stackoverfl
我试图以 this here 的风格创建一个更复杂的跨域 Bean 验证.当我在验证我的实体实例时返回 false 时,问题很快就变成了一个问题,它被传递给了我的自定义 validator 。 因此,
本文整理了Java中com.arjuna.ats.internal.jta.utils.XAUtils类的一些代码示例,展示了XAUtils类的具体用法。这些代码示例主要来源于Github/Stack
本文整理了Java中com.arjuna.ats.internal.jta.resources.XAResourceErrorHandler类的一些代码示例,展示了XAResourceErrorHan
本文整理了Java中com.arjuna.ats.internal.jdbc.drivers.XADataSourceReflectionWrapper类的一些代码示例,展示了XADataSource
本文整理了Java中com.arjuna.ats.internal.jta.xa.XID类的一些代码示例,展示了XID类的具体用法。这些代码示例主要来源于Github/Stackoverflow/Ma
本文整理了Java中com.arjuna.ats.jta.utils.XAHelper.xidToString()方法的一些代码示例,展示了XAHelper.xidToString()的具体用法。这些
本文整理了Java中com.arjuna.ats.jta.utils.XAHelper.sameXID()方法的一些代码示例,展示了XAHelper.sameXID()的具体用法。这些代码示例主要来源
我是一名优秀的程序员,十分优秀!