[
https://issues.jboss.org/browse/SRAMP-389?page=com.atlassian.jira.plugin....
]
Eric Wittmann commented on SRAMP-389:
-------------------------------------
I have confirmed that the problem is due to the JAXB context being created every time we
get the Artifact JAXB object from the Entry. This only happens for atom Feeds, and
therefore only happens when the user needs to extract custom properties from an Entry in
an Atom Feed. I believe a fix is needed in RestEasy to configure the Entry objects in an
Atom Feed to include a JAXBContextFinder. This will allow the Entry to use that finder
rather than create a new JAXB Context.
Performance issue in s-ramp client when using custom properties in
query results
--------------------------------------------------------------------------------
Key: SRAMP-389
URL:
https://issues.jboss.org/browse/SRAMP-389
Project: S-RAMP
Issue Type: Bug
Security Level: Public(Everyone can see)
Affects Versions: 0.4.0 - Tomcat Support
Reporter: Eric Wittmann
Assignee: Eric Wittmann
Fix For: 0.5.0.Final
There is a feature in s-ramp queries where the client can request that each artifact
returned by a query also include a specific subset of the artifact's custom
properties. This is in addition to the standard set of meta-data that is always returned
when a query is performed.
We currently use this feature in the dtgov WorkflowQueryService class to return the
'query' and 'workflow' custom properties (so they can be displayed in the
UI list).
Getting these custom properties while processing the result set is very slow (see
ArtifactSummary::getCustomPropertyValue).
I haven't actually verified this, but I *believe* the reason this is slow is because
a new JAXB context is created for each ArtifactSummary in the query result list. Creating
a JAXB context is a heavy weight operation.
If this is truly the cause, we should try to share the JAXB context in some way. We need
to determine whether it is thread-safe, in which case we should have a single JAXB context
(singleton). If not, we should create it on a ThreadLocal.
--
This message was sent by Atlassian JIRA
(v6.2.6#6264)