Neo4j 1.9.2,SDN 2.3.0.M1,SpringFramework 3.2.3.RELEASE。
我对我的应用程序运行压力测试,该应用程序包含两个使用异步处理来交换消息的微服务。源服务是Neo4J。
一般流程 商店〜> MESSAGE->过程〜>消息〜>检索
在商店中,我在单个事务中持久保存startnode,endnode和基于属性的关系。都好。消息切换是异步的。
我正在测试上面的流程,在非线程JUnit测试中触发了约1000个请求。
在检索步骤期间可能会有一两次,有时从不,我得到以下堆栈跟踪:
Caused by: org.neo4j.graphdb.NotFoundException: '__type__' property not found for RelationshipImpl #3027 of type 9 between Node[1009] and Node[1516].
at org.neo4j.kernel.impl.core.Primitive.newPropertyNotFoundException(Primitive.java:193)
at org.neo4j.kernel.impl.core.Primitive.getProperty(Primitive.java:188)
at org.neo4j.kernel.impl.core.RelationshipImpl.getProperty(RelationshipImpl.java:29)
at org.neo4j.kernel.impl.core.RelationshipProxy.getProperty(RelationshipProxy.java:114)
at org.springframework.data.neo4j.support.typerepresentation.AbstractIndexingTypeRepresentationStrategy.readAliasFrom(AbstractIndexingTypeRepresentationStrategy.java:107)
at org.springframework.data.neo4j.support.mapping.TRSTypeAliasAccessor.readAliasFrom(TRSTypeAliasAccessor.java:36)
at org.springframework.data.neo4j.support.mapping.TRSTypeAliasAccessor.readAliasFrom(TRSTypeAliasAccessor.java:26)
at org.springframework.data.convert.DefaultTypeMapper.readType(DefaultTypeMapper.java:101)
at org.springframework.data.convert.DefaultTypeMapper.getDefaultedTypeToBeUsed(DefaultTypeMapper.java:164)
at org.springframework.data.convert.DefaultTypeMapper.readType(DefaultTypeMapper.java:141)
at org.springframework.data.neo4j.support.mapping.Neo4jEntityConverterImpl.read(Neo4jEntityConverterImpl.java:76)
at org.springframework.data.neo4j.support.mapping.Neo4jEntityPersister$CachedConverter.read(Neo4jEntityPersister.java:170)
at org.springframework.data.neo4j.support.mapping.Neo4jEntityPersister.createEntityFromState(Neo4jEntityPersister.java:192)
at org.springframework.data.neo4j.support.Neo4jTemplate.findOne(Neo4jTemplate.java:155)
at com.auditbucket.engine.repo.neo4j.dao.AuditDaoNeo.getChange(AuditDaoNeo.java:239)
at com.auditbucket.engine.service.AuditService.handleSearchResult(AuditService.java:411)
at sun.reflect.GeneratedMethodAccessor78.invoke(Unknown Source)
我很确定它与SDN / Neo4J库有关。这种关系不存在,因为它的创建和Id是通过消息Q发送的。很难看出事务是如何提交的。包括代码块以保持完整性
....
AuditChange change = auditDAO.save(fUser, input, txRef);
AuditLog log = auditDAO.addLog(header, change, fortressWhen);
input.setStatus(AuditLogInputBean.LogStatus.OK);
if (searchActive) {
// Used to reconcile that the change was actually indexed
sd.setLogId(log.getId());
searchGateway.makeChangeSearchable(sd);
}
return input;