How to get the details of selected item in MKS RM through JAVA API?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
How to get the details of selected item in MKS RM through JAVA API?
How to get the details of selected item in MKS RM through JAVA API?
I have use case to get the details (like issue id) for items selected in MKS RM through JAVA API.Can any one help in this regard.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Aman,
First I would recommend that you read the Event Triggers section of the Server Administration Guide. (Starting on page 306 http://www.ptc.com/WCMS/files/143622/en/ServerAdministrationGuide_Integrity_10_0.pdf)
Next, you can find documention for all our Java API beans in the documentation included with your Integrity server. Simply point your broswer to your Integrity server (typically http://hostname:7001) and then click on the link for Java API Documention.
If you can't find what you're looking for there, please let me know!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Jeremy,
I am looking at Java API Documentation that could be found on integrity server, but examples are missing. The same for Integrations Builder Guide.
I am particulary searching for examples around executing command using Interim Responses (in case of issues or viewissue) but I am not able to see an example.
executeWithInterim() method seems interesting, but where could I find an example of use?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
executeWithInterim
Response executeWithInterim(java.lang.String[] args, boolean enableCache) throws APIException
- Executes a command and returns an interim response. Using an interim response returns only a partially populated
Response
object. This allows a user more control over when to cancel a potentially long-running command.Command-level exceptions in the
Response
will not be thrown by this method. This is due to the nature of theResponse
hierarchy and the point at which command-levelAPIException
elements occur within the hierarchy.Using interim responses without caching allows for better memory management since only a small part of the
Response
object hierarchy is saved in memory at any given time. However, onceSubRoutine
s andWorkItem
s are read, they cannot be read again at a later time.The array must have the following order:
- Integrity application (si, im, etc.)
- Integrity application command (about, co, issues, etc.)
- [Optional] Options (--gui, -Y, etc.)
- [Optional] Selection of items to operate on (members, issue IDs, etc.)
- Parameters:
args
- The command with arguments.enableCache
- Indicates if the response should be cached internally for use at a later point in time. Note that onlyWorkItem
andSubRoutine
objects directly in theResponse
hierarchy are affected by this flag.- Returns:
- The response object that contains the results of the command.
- Throws:
APIException
- If there was an exception while running the command.
An example can be found at: https://github.com/jenkinsci/integrity-plugin/blob/master/src/main/java/hudson/scm/APISession.java
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Hello Jeremy
I was not able to understand the example of code you mention in your mail, so I was able to use interim response.
Could it be possible to get a very basic example including command run and proscessing of response in "executewithinterim" context?
It would help me lot to understand.
Thanks in advance for any support or help.
Marc.