create a plan programatically
Rachid Halloul (1●4●4)
| asked Dec 19 '12, 1:13 p.m.
edited Jul 19 '16, 3:39 a.m. by Ralph Schoon (63.5k●3●36●46)
I was able to create the plan and access it from eclipse without any issue, but when I tried to load the plan in a browser , I got the following error
Error - The plan is not available in the repository. private void createPlan() throws TeamRepositoryException, UnsupportedEncodingException{ ProjectArea projectArea = (ProjectArea) getProjectName(); IIterationPlanService planService = (IIterationPlanService) ((IClientLibraryContext) repo).getServiceInterface(IIterationPlanService.class); IIterationPlanRecord planRecord= (IIterationPlanRecord) IIterationPlanRecord.ITEM_TYPE.createItem(); IAuditableCommon audit = (IAuditableCommon) repo.getClientLibrary(IAuditableCommon.class); planRecord.setName(cbPlanIteration.getSelectedItem() + " Plan"); planRecord.setIteration(getIterationName()); planRecord.setPlanType("Sprint Backlog"); planRecord.setOwner(getTeamAreaName()); IContributor contributor = (IContributor) IContributor.ITEM_TYPE.createItem(); IWikiPage wiki = (IWikiPage) IWikiPage.ITEM_TYPE.createItem(); wiki.setName(""); wiki.setWikiID(IIterationPlanRecord.OVERVIEW_PAGE_ID); wiki.setCreator(contributor); wiki.setOwner(planRecord); planRecord.setContextId(planRecord.getItemId()); planService.save(projectArea, planRecord, wiki); } Any Idea ? |
Accepted answer
Ralph Schoon (63.5k●3●36●46)
| answered Dec 19 '12, 5:02 p.m.
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER edited Jul 18 '16, 3:57 p.m.
There is currently no public API to work with plans. That is one of the work items with priority in the current backlog.
https://rsjazz.wordpress.com/2015/06/11/creating-plans-with-the-plain-java-client-api/ what I know. Ralph Schoon selected this answer as the correct answer
Comments HI Ralph do you know if there are API's now to do this or is there some other way to pass in a list of teams and a sprint and have RTC create the plans for those teams? Thank you in advanced. there ARE apis, cause product development uses them. They are not documented, which means they can/will change.
Plus, some parts are not in the Plain Java API https://rsjazz.wordpress.com/2015/06/11/creating-plans-with-the-plain-java-client-api/ uses API that is part of the RTC Eclipse client SDK and not the Plain Java Client Libraries.
|
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
Hello Mr. Rachid,