提交 86da532c 编写于 作者: O o2null

Merge branch 'fix/callabletimeout' into 'wrdp'

修改copier的说明

See merge request o2oa/o2oa!2284
......@@ -282,6 +282,7 @@ public class PersistenceXmlHelper {
properties.put("openjpa.QueryCompilationCache", "false");
properties.put("openjpa.LockManager", "none");
properties.put("openjpa.jdbc.ResultSetType", "scroll-insensitive");
//使用false,使用ture支持多线程访问,但是是通过lock同步执行的.
properties.put("openjpa.Multithreaded", "false");
/* 如果启用本地初始化会导致classLoad的问题 */
properties.put("openjpa.DynamicEnhancementAgent", "false");
......
......@@ -50,7 +50,8 @@ public class WrapCopier<T, W> {
}
copyFields.stream().forEach(f -> {
try {
if (StringUtils.equals(f, JpaObject.IDCOLUMN)) {
//openjpa在访问主键(getId()会执行pcGetId())会发起一个锁定所以在这里对id(xid column)进行单独的处理
if (StringUtils.equals(f, JpaObject.id_FIELDNAME)) {
Field field = FieldUtils.getField(orig.getClass(), f, true);
if (null != field) {
Object o = FieldUtils.readField(field, orig, true);
......
......@@ -1275,4 +1275,23 @@ public class WorkAction extends StandardJaxrsAction {
asyncResponse.resume(ResponseFactory.getEntityTagActionResultResponse(request, result));
}
@JaxrsMethodDescribe(value = "V2_根据Work或workCompleted取得内容.", action = V2GetWorkOrWorkCompleted2.class)
@GET
@Path("v2/workorworkcompleted2/{workOrWorkCompleted}")
@Produces(HttpMediaType.APPLICATION_JSON_UTF_8)
@Consumes(MediaType.APPLICATION_JSON)
public void V2GetWorkOrWorkCompleted2(@Suspended final AsyncResponse asyncResponse,
@Context HttpServletRequest request,
@JaxrsParameterDescribe("工作标识") @PathParam("workOrWorkCompleted") String workOrWorkCompleted) {
ActionResult<V2GetWorkOrWorkCompleted2.Wo> result = new ActionResult<>();
EffectivePerson effectivePerson = this.effectivePerson(request);
try {
result = new V2GetWorkOrWorkCompleted2().execute(effectivePerson, workOrWorkCompleted);
} catch (Exception e) {
logger.error(e, effectivePerson, request, null);
result.error(e);
}
asyncResponse.resume(ResponseFactory.getEntityTagActionResultResponse(request, result));
}
}
\ No newline at end of file
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册