OSLC API : Authentication methods?
For CCM
HttpUtils.sendGetForSecureDocument(server, requirementDoc, userId, password, httpclient);
For RM
HttpUtils.sendGetForSecureDocument(server, requirementDoc, userId, password, httpclient,JTS_Server);
Here I am Not able to understand why there is difference for CCM,RM with extra JTS_Server Parameter.
Why do we need JTS_Server parameter only for RM and not for CCM?
In my Application development I need to access both RM and CCM through OSLC, in that case I need to have two classes implementing these methods in HttpUtils class. If it is possible,I want to use one of methods for both RM,RQM which is the best?
|
Accepted answer
Due to historical reason, RM does not provide an /rm/j_security_check URL for authentication, and you have to use /jts/j_security_check for this purpose. Since the public URLs for JTS and RM do not necessarily have the same host, you need to specify the JTS host for RM authentication.
If you check the source code carefully, you should see implementation of the HttpUtils class varies in the CCM and RM samples - CCM handles the authentication in the sendGetForSecureDocument() function and RM handles in in the doRRCOAuth() function. Strictly speaking, they are not the same class. If you insist on a single HttpUtils class, you need to merge source code together and handle the authentication appropriately upon detecting the application variant (CCM, QM or RM) in the URL. You have the source code at your disposal so you should be able to do what you want. vijayakumar ramesh selected this answer as the correct answer
|
Your answer
Dashboards and work items are no longer publicly available, so some links may be invalid. We now provide similar information through other means. Learn more here.
Comments
Can you give a bit more context?
- What version of CLM are you using?
- Assume you code snippet above comes from the OSLC workshop?