Jazz Forum Welcome to the Jazz Community Forum Connect and collaborate with IBM Engineering experts and users

Why am I getting Null Application id Returned for Project Area Creation Using Java API ?

For the following Project Area Creation code:

ITeamRepository repo = TeamPlatform.getTeamRepositoryService().getTeamRepository(rtcURL);

IProcessItemService service = (IProcessItemService) repo.getClientLibrary(IProcessItemService.class);

IProcessDefinition processDefinition = service.findProcessDefinition(processId, IProcessItemService.ALL_PROPERTIES , MONITOR);

IProjectArea project = service.createProjectArea();

            project.setName(name);
            project.setProcessDefinition(processDefinition);
            service.save(project, MONITOR);

(Logging and all is taken care in code, not mentioned here)

Below exception is thrown:

Invalid application id 'null'. A valid registered fronting application id must be provided to access the JTS.

Please let me know if anyone faced and solved this.

Thanks
Vab

0 votes


Accepted answer

Permanent link

I have already shared an example of code that works for me and a lot of others - it is actually shipped as WorkshopSetup with the extensions workshop. See the descripotion here: https://rsjazz.wordpress.com/2013/09/18/deploying-templates-and-creating-projects-using-the-plain-java-clients-library/



 
I am pretty sure that you try to use the API against the wrong application

Note: The code must be run against the CCM ( https://server:port/ccm ) and not JTS https://server:port/jts). 

The error seems to be from JTS and not CCM so try to change the URL to CCM.




Vaibhav S selected this answer as the correct answer

0 votes

Comments

 PS: you are not using OSLC you are using the plain Java client libraies.

Thank you Ralph. Replaced CCM with JTS in URL. It works fine now.

Your answer

Register or log in to post 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.

Search context
Follow this question

By Email: 

Once you sign in you will be able to subscribe for any updates here.

By RSS:

Answers
Answers and Comments
Question details
× 10,937
× 1,700

Question asked: Mar 13 '17, 2:15 a.m.

Question was seen: 2,653 times

Last updated: Mar 13 '17, 5:29 a.m.

Confirmation Cancel Confirm