cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - Learn all about PTC Community Badges. Engage with PTC and see how many you can earn! X

Java API: Traffic, Performance and Memory issues while getting item history

AndreyVi
4-Participant

Java API: Traffic, Performance and Memory issues while getting item history

Hello,

 

I'm seeking help to accomplish the following

 

TASK:

 

Incrementally transfer history records of an item from PTC Integrity to an external database. Besides that, extract only a subset of fields, contained in the history records.

 

DESIRED APPROACH:

 

- Get the timestamps of existing history records of the item in PTC Integrity,

- Get the timestamps of the history records already stored in the external database,

- Determine which timestamps from PTC Integrity are missing in the external database,

- Get the missing history records from PTC Integrity one by one and store them in the external database

 

PROBLEMS:

 

- The only way to get the history records seems to be using an "im viewissue --showHistory" call.

- Using this call, it doesn't seem to be possible to reduce the output to a subset of fields contained in the item.

 

This leads to:

 

- Necessity to retrieve complete history of the item, including all history records and all fields.

- The Java API reads and instantiates the returned WorkItem object completely, before the client code can access it.

 

- For bigger items with long history this results in:

* Extremely long running operations

* Excessive traffic (hundreds of MB), excessive uncontrolled memory consumption

* Excessive and uncontrolled memory consumption by the Java API library (up to 100GB)

 

QUESTIONS:

 

1. Is there a way to get just timestamps of the history records for an item, without any other fields?

2. Is there a way to get only a subset of the history records for an item, for example by date range?

3. Is there a way to reduce the output of the "im viewissue" command to a subset of fields, like with "im issues"?

4. Is it possible to read the XML output of the PTC Integrity server directly (like in AbstractCmdRunner.executeWithXML(), which is not a part of the public API)?

 

Thank you very much in advance, any help is highly appreciated!

 

- Andrey

 

 

2 REPLIES 2
AndreyVi
4-Participant
(To:AndreyVi)

KartikOak
15-Moonstone
(To:AndreyVi)

Hi,

       Have you file a PTC Support ticket on the performance & memory issues?

 

Regards

Kartik

Announcements


Top Tags