It's all about the answers!

Ask a question

Using Item Connector Framework


Ankur Sharma (151194) | asked Oct 21 '08, 8:59 a.m.
Hi

We are using Item connector framework for making connector for our defect tracking system. I have a few queries regarding Item connector framework.(https://jazz.net/wiki/bin/view/Main/ItemConnectorCreation) The following are the queires:

1. In Item connector client, there are two implementation choices : as a 'plain java application' or as an 'eclipse plug-in'. Which of these two implementations we should follow? Any idea how is it done in CQ connector ? Note that as per jazz tutorial it is recommended that we should go for 'java application' implementation.

2. While synchronizing from Jazz to External repository (NOT from External repository to jazz), the synchronization process can be started either explicitly or after a fixed interval of time. Is there any other other way to invoke synchronization process e.g. on the basis of event etc. (as this can done while synchronizing from external repository to Jazz).

3. We are not able to find javadoc/code for 'Jazz Plain Java Client libraries'. It would be helpful if we can have some link for it.

Regards
Ankur Sharma

47 answers



permanent link
Ankur Sharma (151194) | answered Apr 16 '09, 1:42 p.m.
Our external system does use LDAP and jazz will also use LDAP. Also in our case, users will use Jazz in almost all the cases rather than external system once connector is deployed, so all the external users need login access to jazz server.

So If I understand well, all the users will be created manually in Jazz first, give them proper permissions, add them to required team areas. Now user synchronization will create proxies regarding these already exiting users in jazz and subsequently will synchronize any changes in user information. But In case if there is some user which is not found in jazz server but was there in external system, the user synchronization will not be able to create the new user data in jazz. Also in case of "external modifier", item connector can override earlier configured permissions to that user role and extra required permissions will be granted to that role.

I want your comments on my understanding. Anything extra which we can take advantage of the fact that both jazz and external system uses same LDAP ?

-Ankur

permanent link
John Vasta (2.6k15) | answered Apr 16 '09, 2:55 p.m.
FORUM MODERATOR / JAZZ DEVELOPER

So If I understand well, all the users will be created manually in Jazz first, give them proper permissions, add them to required team areas. Now user synchronization will create proxies regarding these already exiting users in jazz and subsequently will synchronize any changes in user information. But In case if there is some user which is not found in jazz server but was there in external system, the user synchronization will not be able to create the new user data in jazz.


That's not quite right; the new user data will be created in Jazz, but it won't be created in your LDAP registry, so that user will not be able to login to Jazz.


Also in case of "external modifier", item connector can override earlier configured permissions to that user role and extra required permissions will be granted to that role.


No, not at all; the connector never changes anything having to do with roles or permissions. An "external modifier" property means that the property value identifies a Jazz user, and the connector should execute incoming synchronization under the identity of that user, rather than the identity that the external connector client logs in as. Essentially, it impersonates that user so that the same user that modified an external object is recorded as the user that modified the Jazz object, and that user's role is used to determine whether the Jazz object can be modified (according to your process permissions scheme).


I want your comments on my understanding. Anything extra which we can take advantage of the fact that both jazz and external system uses same LDAP ?


I can't think of anything extra.

permanent link
Ankur Sharma (151194) | answered Apr 20 '09, 4:53 a.m.
Hi John,

As in case of Defect work items, we can find in 'external connection' synchronization status link, which can be opened and verified that a defect is linked to some external defect and what synchronization status it has. But I couldn't find anything similar for 'User'. Basically how can I verify that any particular user is linked to some external user or not ?

-Ankur

permanent link
John Vasta (2.6k15) | answered Apr 20 '09, 9:13 a.m.
FORUM MODERATOR / JAZZ DEVELOPER
There is no direct way to see the connection between items other than work items, and external objects. You can indirectly see the connection between a Jazz Contributor item and an external object by opening the synchronization status for a work item that references the Contributor item in some property that is being synchronized (e.g. "Created By" or "Owned By"), and see that there is a corresponding external value for that property.

Feel free to submit an enhancement request, if you'd like.

Hi John,

As in case of Defect work items, we can find in 'external connection' synchronization status link, which can be opened and verified that a defect is linked to some external defect and what synchronization status it has. But I couldn't find anything similar for 'User'. Basically how can I verify that any particular user is linked to some external user or not ?

-Ankur

permanent link
Ankur Sharma (151194) | answered Apr 21 '09, 10:34 a.m.
Hi John,

I am facing a strange exception while testing my code on our remote server. Everything worked fine on local server but on remote server its giving me this exception
Jazz Team Repository Exception: 'Synchronize with External Objects' failed. Permission denied.

com.ibm.team.process.common.advice.TeamOperationCanceledException: 'Synchronize with External Objects' failed. Permission denied.
at com.ibm.team.process.internal.common.advice.runtime.OperationAdviceManager.advise(OperationAdviceManager.java:351)
at com.ibm.team.process.internal.common.util.AbstractProcess.doAdvise(AbstractProcess.java:181)
at com.ibm.team.process.internal.service.ServerProcess.access$1(ServerProcess.java:1)
at com.ibm.team.process.internal.service.ServerProcess$2.run(ServerProcess.java:116)
at com.ibm.team.repository.service.internal.TransactionService$1.run(TransactionService.java:99)
at com.ibm.team.repository.service.internal.rdb.RepositoryDatabase$Transaction.run(RepositoryDatabase.java:455)
at com.ibm.team.repository.service.internal.rdb.RepositoryDatabase.runTransaction(RepositoryDatabase.java:286)
at com.ibm.team.repository.service.internal.rdb.RepositoryDatabase.runInTransaction(RepositoryDatabase.java:241)
at com.ibm.team.repository.service.internal.TransactionService.runInTransaction(TransactionService.java:74)
at com.ibm.team.repository.service.internal.TransactionService.runInTransaction(TransactionService.java:63)
at sun.reflect.GeneratedMethodAccessor110.invoke(null)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:618)
at org.eclipse.soda.sat.core.internal.record.ExportProxyServiceRecord.invoke(ExportProxyServiceRecord.java:375)
at org.eclipse.soda.sat.core.internal.record.ExportProxyServiceRecord.access$0(ExportProxyServiceRecord.java:361)
at org.eclipse.soda.sat.core.internal.record.ExportProxyServiceRecord$ExportedServiceInvocationHandler.invoke(ExportProxyServiceRecord.java:55)
at $Proxy35.runInTransaction(null)
at com.ibm.team.process.internal.service.ProcessService.runInTransaction(ProcessService.java:2501)
at com.ibm.team.process.internal.service.ProcessService.runInTransaction(ProcessService.java:2508)
at com.ibm.team.process.internal.service.ServerProcess.adviseAndExecute(ServerProcess.java:114)
at com.ibm.team.interop.service.internal.InteropService.saveExternalState(InteropService.java:526)
at sun.reflect.GeneratedMethodAccessor189.invoke(null)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:618)
at org.eclipse.soda.sat.core.internal.record.ExportProxyServiceRecord.invoke(ExportProxyServiceRecord.java:375)
at org.eclipse.soda.sat.core.internal.record.ExportProxyServiceRecord.access$0(ExportProxyServiceRecord.java:361)
at org.eclipse.soda.sat.core.internal.record.ExportProxyServiceRecord$ExportedServiceInvocationHandler.invoke(ExportProxyServiceRecord.java:55)
at $Proxy99.saveExternalState(null)
at sun.reflect.GeneratedMethodAccessor189.invoke(null)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:618)
at com.ibm.team.repository.servlet.AbstractTeamServerServlet.handleMethod(AbstractTeamServerServlet.java:1133)
at com.ibm.team.repository.servlet.AbstractTeamServerServlet.executeMethod(AbstractTeamServerServlet.java:883)
at com.ibm.team.repository.servlet.AbstractTeamServerServlet.doPost(AbstractTeamServerServlet.java:685)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:710)
at com.ibm.team.repository.servlet.AbstractTeamServerServlet.service(AbstractTeamServerServlet.java:1436)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
at org.eclipse.equinox.http.registry.internal.ServletManager$ServletWrapper.service(ServletManager.java:180)
at org.eclipse.equinox.http.servlet.internal.ServletRegistration.handleRequest(ServletRegistration.java:90)
at org.eclipse.equinox.http.servlet.internal.ProxyServlet.processAlias(ProxyServlet.java:111)
at org.eclipse.equinox.http.servlet.internal.ProxyServlet.service(ProxyServlet.java:75)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
at org.eclipse.equinox.servletbridge.BridgeServlet.service(BridgeServlet.java:115)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:269)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:210)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:174)
at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:525)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:117)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:108)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:151)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:870)
at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:665)
at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:528)
at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:81)
at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:685)
at java.lang.Thread.run(Thread.java:810)
at com.ibm.team.repository.common.internal.marshal.util.MarshallerUtil.decodeExceptions(MarshallerUtil.java:326)
at com.ibm.team.repository.common.internal.marshal.util.MarshallerUtil.decodeExceptions(MarshallerUtil.java:296)
at com.ibm.team.repository.common.internal.marshal.util.MarshallerUtil.decodeFault(MarshallerUtil.java:261)
at com.ibm.team.repository.transport.client.RemoteTeamService.constructExceptionFromFault(RemoteTeamService.java:546)
at com.ibm.team.repository.transport.client.RemoteTeamService.executeMethod(RemoteTeamService.java:461)
at com.ibm.team.repository.transport.client.RemoteTeamService.invoke(RemoteTeamService.java:184)
at com.ibm.team.repository.transport.client.ServiceInvocationHandler.invoke(ServiceInvocationHandler.java:43)
at $Proxy12.saveExternalState(Unknown Source)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:79)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:618)
at com.ibm.team.repository.client.internal.ServiceInterfaceProxy.invokeServiceCall(ServiceInterfaceProxy.java:149)
at com.ibm.team.repository.client.internal.ServiceInterfaceProxy.invoke(ServiceInterfaceProxy.java:84)
at $Proxy12.saveExternalState(Unknown Source)
at com.ibm.team.interop.client.internal.InteropManager.doSave(InteropManager.java:1124)
at com.ibm.team.interop.client.internal.InteropManager.saveExternalState(InteropManager.java:523)
at com.ibm.sdwb.connector.workitem.jazz.JazzGateway.synchronizeCMVCTypes(JazzGateway.java:264)
at com.ibm.sdwb.connector.workitem.jazz.JazzGateway.syncEachState(JazzGateway.java:376)
at com.ibm.sdwb.connector.workitem.interop.IncomingSync.syncDefects(IncomingSync.java:214)
at com.ibm.sdwb.connector.workitem.interop.IncomingSync.sync(IncomingSync.java:144)
at com.ibm.sdwb.connector.workitem.interop.IncomingSync.main(IncomingSync.java:87)
Name: Synchronize with External Objects
Id: com.ibm.team.interop.server.synchronize
Severity: ERROR
Summary: Permission Denied
Description: You don't have permission to perform the following actions:
Save external data (incoming/saveState)
Severity: ERROR


Though I have given all the required permission to the user who is running sync process. Also I am not using 'modifiedBy' parameter. So is this some 'weird' error due to connector framework or I am somewhere wrong ? Can somehow user mapping lead to this kind of exception because previously I haven't face such problem on other remote servers.
Infact I am able to successfully run the incoming sync for 'user' workitem with same set of permission, user, projectArea, this exception is coming for only 'defect' workitem.
-Ankur

permanent link
Ankur Sharma (151194) | answered Apr 21 '09, 12:57 p.m.
Hi John

I did some more homework on this problem and I found that this issue is 'Server' specific, because same code is running fine with another remote server. But still if you can give some hint why the problem is on this particular server, that would be helpful.

-Ankur

permanent link
John Vasta (2.6k15) | answered Apr 23 '09, 12:02 p.m.
FORUM MODERATOR / JAZZ DEVELOPER
Well, this is pretty much what it says - the user identity that is trying to initiate incoming synchronization does not have the permission to do so, in the project area containing the synchronization rules. That user must be a member of the project area, assigned a process role that has been granted the needed permissions in the Team Configuration area of the project area configuration.

Hi John

I did some more homework on this problem and I found that this issue is 'Server' specific, because same code is running fine with another remote server. But still if you can give some hint why the problem is on this particular server, that would be helpful.

-Ankur

permanent link
Ankur Sharma (151194) | answered Apr 24 '09, 7:03 a.m.
No the actual problem is something different. As I told earlier, I have given all the required permissions to the sync process user. Actually the problem occurs whenever we deploy the external repository manager on the server. Somehow there is a mismatch between external repository manager plugin versions and server version, which in turn is causing these license issues.

-Ankur

permanent link
Ankur Sharma (151194) | answered May 05 '09, 5:57 a.m.
Hi John

While synchronizing users, some of the users are not getting synchronization status OK but instead they are getting synchronization status 'Uninitialized'. What does this status means and how I can make it OK status ?

-Ankur

permanent link
John Vasta (2.6k15) | answered May 05 '09, 10:41 a.m.
FORUM MODERATOR / JAZZ DEVELOPER
The Uninitialized status means that a proxy was created in Jazz for an external object, but no data for it has been synchronized. If your client created the proxy objects, you'll have to investigate why it didn't synchronize in any data. If you open the synchronization status, are there any error messages?

Hi John

While synchronizing users, some of the users are not getting synchronization status OK but instead they are getting synchronization status 'Uninitialized'. What does this status means and how I can make it OK status ?

-Ankur

Your answer


Register or 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.