我从Liferay论坛复制 - 在2周内没有得到答案。 http://www.liferay.com/community/forums/-/message_boards/message/9384663Liferay交易方式
我在寻找文档/博客如何进行Liferay交易。
的Liferay 6.0.6 PostgreSQL的
我有JAX-WS Web服务挂钩。 我只使用Liferay服务。
例如插入文档并对其进行标记
fileEntry = DLFileEntryServiceUtil.addFileEntry(groupId, folderId, filename, filename, description, changeLog, "extraSettings", buffer, serviceContext);
AssetEntry assetEntry = AssetEntryLocalServiceUtil.getEntry(DLFileEntry.class.getName(), fileEntry.getFolderId());
AssetTagUtil.addAssetEntry(assetTagObj.getPrimaryKey(), assetEntry.getPrimaryKey());
我需要设置事务。
我的类注释
@MTOM
@WebService(targetNamespace="http://services.portal.xyz/",serviceName="AuditResultService",name = "AuditResult", endpointInterface = "xyz.portal.services.AuditResultWS")
@Transactional(isolation = Isolation.DEFAULT, readOnly = false, rollbackFor = {PortalException.class, SystemException.class, InvalidParameterException.class, NoSuchEntryException.class})
@Transactional是Liferay的一个
方法是用
@WebMethod
WS只有注释的伟大工程,但没有交易 - 创建和NoSuchEntryException文件后,文件留在Liferay。
下面试图根据论坛主题: http://www.liferay.com/community/forums/-/message_boards/message/9019161
portal-ext.properties
transaction.manager.impl=org.springframework.transaction.jta.JtaTransactionManager
transaction.manager.property.allowCustomIsolationLevels=true
transaction.manager.property.globalRollbackOnParticipationFailure=true
我没有在我的钩弹簧的配置做任何事情。
我试图改变隔离等没有成功。
请有任何指导?
非常感谢您