It's all about the answers!

Ask a question

teamRepository.login throws exception with RTC 2.0


Thomas Starz (1812015) | asked May 29 '09, 4:56 p.m.
I have a little Java program that adds work items to a team repository. This program was written for RTC 1.0. Here is an excerpt of what I am doing:

teamRepository = TeamPlatform.getTeamRepositoryService().getTeamRepository( login.getRepositoryURI());

teamRepository.registerLoginHandler( new LoginHandler( login.getUserID(), login.getPassword()));

teamRepository.login( null);


When trying to log in to a 2.0 repository, an exception occurs:

com.ibm.team.repository.transport.client.AuthenticationException: CRJAZ0129I Unexpected response from /jazz/j_security_check. Expected a 302 response code, but got 400. Please check your server configuration.
at com.ibm.team.repository.transport.client.ClientHttpUtil.executeHttpMethod(ClientHttpUtil.java:229)
at com.ibm.team.repository.transport.client.RemoteTeamService.executeCancelableHttpMethod(RemoteTeamService.java:514)
at com.ibm.team.repository.transport.client.RemoteTeamService.invokePost(RemoteTeamService.java:504)
at com.ibm.team.repository.transport.client.RemoteTeamService.executeMethod(RemoteTeamService.java:449)
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 $Proxy0.describe(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 $Proxy0.describe(Unknown Source)
at com.ibm.team.repository.client.internal.TeamRepository$4.run(TeamRepository.java:1342)
at com.ibm.team.repository.client.internal.TeamRepository$4.run(TeamRepository.java:1)
at com.ibm.team.repository.client.internal.TeamRepository$3.run(TeamRepository.java:1129)
at com.ibm.team.repository.common.transport.CancelableCaller.call(CancelableCaller.java:76)
at com.ibm.team.repository.client.internal.TeamRepository.callCancelableService(TeamRepository.java:1122)
at com.ibm.team.repository.client.internal.TeamRepository.internalLogin(TeamRepository.java:1335)
at com.ibm.team.repository.client.internal.TeamRepository.login(TeamRepository.java:536)
at com.ibm.tivoli.rtc.ExcelRtcParser.connectToRepository(ExcelRtcParser.java:219)
at com.ibm.tivoli.rtc.ExcelRtcParser.main(ExcelRtcParser.java:329)

9 answers



permanent link
Matt Lavin (2.7k2) | answered Jun 01 '09, 11:47 a.m.
FORUM MODERATOR / JAZZ DEVELOPER
Are you using RTC 1.0 client code against a RTC 2.0 server? There were
some small changes needed in the client when moving to 2.0, so you
should try using the 2.0 client if you aren't already.

-
Matt Lavin
Jazz Server Team


On Fri, 2009-05-29 at 21:07 +0000, starz wrote:
I have a little Java program that adds work items to a team
repository. This program was written for RTC 1.0. Here is an excerpt
of what I am doing:

teamRepository =
TeamPlatform.getTeamRepositoryService().getTeamRepository(
login.getRepositoryURI());

teamRepository.registerLoginHandler( new LoginHandler(
login.getUserID(), login.getPassword()));

teamRepository.login( null);


When trying to log in to a 2.0 repository, an exception occurs:

com.ibm.team.repository.transport.client.AuthenticationException:
CRJAZ0129I Unexpected response from /jazz/j_security_check. Expected
a 302 response code, but got 400. Please check your server
configuration.
at
com.ibm.team.repository.transport.client.ClientHttpUtil.executeHttpMethod(ClientHttpUtil.java:229)
at
com.ibm.team.repository.transport.client.RemoteTeamService.executeCancelableHttpMethod(RemoteTeamService.java:514)
at
com.ibm.team.repository.transport.client.RemoteTeamService.invokePost(RemoteTeamService.java:504)
at
com.ibm.team.repository.transport.client.RemoteTeamService.executeMethod(RemoteTeamService.java:449)
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 $Proxy0.describe(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 $Proxy0.describe(Unknown Source)
at
com.ibm.team.repository.client.internal.TeamRepository$4.run(TeamRepository.java:1342)
at
com.ibm.team.repository.client.internal.TeamRepository$4.run(TeamRepository.java:1)
at
com.ibm.team.repository.client.internal.TeamRepository$3.run(TeamRepository.java:1129)
at
com.ibm.team.repository.common.transport.CancelableCaller.call(CancelableCaller.java:76)
at
com.ibm.team.repository.client.internal.TeamRepository.callCancelableService(TeamRepository.java:1122)
at
com.ibm.team.repository.client.internal.TeamRepository.internalLogin(TeamRepository.java:1335)
at
com.ibm.team.repository.client.internal.TeamRepository.login(TeamRepository.java:536)
at
com.ibm.tivoli.rtc.ExcelRtcParser.connectToRepository(ExcelRtcParser.java:219)
at com.ibm.tivoli.rtc.ExcelRtcParser.main(ExcelRtcParser.java:329)

permanent link
Thomas Starz (1812015) | answered Jun 01 '09, 5:04 p.m.
I am using the 2.0 client, but I use a bunch of libraries (for example, com.ibm.team.workitem.client and so forth) that are older. Questions now is where do I get new versions of these additional libraries from (they are obviously not contained in the client download)?

Thanks a lot for your help!

- Thomas

permanent link
Matt Lavin (2.7k2) | answered Jun 02 '09, 9:10 p.m.
FORUM MODERATOR / JAZZ DEVELOPER
The RTC client download should contain all the 2.0 clients. Is the RTC
client missing plugins you expected?

-
Matt Lavin
Jazz Server Team


On Mon, 2009-06-01 at 21:07 +0000, starz wrote:
I am using the 2.0 client, but I use a bunch of libraries (for
example, com.ibm.team.workitem.client and so forth) that are older.
Questions now is where do I get new versions of these additional
libraries from (they are obviously not contained in the client
download)?

Thanks a lot for your help!

- Thomas

permanent link
Thomas Starz (1812015) | answered Jun 03 '09, 12:48 p.m.
I may have missed it but I do not find packages like com.ibm.team.workitem.client* or com.ibm.team.workitem.common* in the client. I had the following include libs specified for RTC 1.0 and have a set of libs that contain these classes. The 1.0 client does not have them either:
import com.ibm.team.process.client.IProcessClientService;
import com.ibm.team.process.common.IProjectArea;
import com.ibm.team.process.common.ITeamArea;
import com.ibm.team.process.common.ITeamAreaHandle;
import com.ibm.team.repository.client.IItemManager;
import com.ibm.team.repository.client.ITeamRepository;
import com.ibm.team.repository.client.TeamPlatform;
import com.ibm.team.repository.client.internal.ItemManager;
import com.ibm.team.repository.common.IContributor;
import com.ibm.team.repository.common.IContributorHandle;
import com.ibm.team.repository.common.TeamRepositoryException;
import com.ibm.team.workitem.client.IWorkItemClient;
import com.ibm.team.workitem.common.model.ICategory;
import com.ibm.team.workitem.common.model.ICategoryHandle;

permanent link
Matt Lavin (2.7k2) | answered Jun 04 '09, 4:42 p.m.
FORUM MODERATOR / JAZZ DEVELOPER
Something must be wrong because I know that the 2.0 does still use
com.ibm.team.repository.client.ITeamRepository and it is exposed from
the same plugin as in 1.0.

What client are you downloading?

-
Matt Lavin
Jazz Server Team


On Wed, 2009-06-03 at 16:52 +0000, starz wrote:
I may have missed it but I do not find packages like
com.ibm.team.workitem.client* or com.ibm.team.workitem.common* in the
client. I had the following include libs specified for RTC 1.0 and
have a set of libs that contain these classes. The 1.0 client does
not have them either:
import com.ibm.team.process.client.IProcessClientService;
import com.ibm.team.process.common.IProjectArea;
import com.ibm.team.process.common.ITeamArea;
import com.ibm.team.process.common.ITeamAreaHandle;
import com.ibm.team.repository.client.IItemManager;
import com.ibm.team.repository.client.ITeamRepository;
import com.ibm.team.repository.client.TeamPlatform;
import com.ibm.team.repository.client.internal.ItemManager;
import com.ibm.team.repository.common.IContributor;
import com.ibm.team.repository.common.IContributorHandle;
import com.ibm.team.repository.common.TeamRepositoryException;
import com.ibm.team.workitem.client.IWorkItemClient;
import com.ibm.team.workitem.common.model.ICategory;
import com.ibm.team.workitem.common.model.ICategoryHandle;

permanent link
Michele Pegoraro (1.8k14119103) | answered Jun 05 '09, 9:01 a.m.
I have the same error using Snippet1.java from JavaPlainAPI. The snippet was running on RTC 2.0 M3 and now return this error on RTC 2.0 RC1.
Has something changed?

Something must be wrong because I know that the 2.0 does still use
com.ibm.team.repository.client.ITeamRepository and it is exposed from
the same plugin as in 1.0.

What client are you downloading?

-
Matt Lavin
Jazz Server Team


On Wed, 2009-06-03 at 16:52 +0000, starz wrote:
I may have missed it but I do not find packages like
com.ibm.team.workitem.client* or com.ibm.team.workitem.common* in the
client. I had the following include libs specified for RTC 1.0 and
have a set of libs that contain these classes. The 1.0 client does
not have them either:
import com.ibm.team.process.client.IProcessClientService;
import com.ibm.team.process.common.IProjectArea;
import com.ibm.team.process.common.ITeamArea;
import com.ibm.team.process.common.ITeamAreaHandle;
import com.ibm.team.repository.client.IItemManager;
import com.ibm.team.repository.client.ITeamRepository;
import com.ibm.team.repository.client.TeamPlatform;
import com.ibm.team.repository.client.internal.ItemManager;
import com.ibm.team.repository.common.IContributor;
import com.ibm.team.repository.common.IContributorHandle;
import com.ibm.team.repository.common.TeamRepositoryException;
import com.ibm.team.workitem.client.IWorkItemClient;
import com.ibm.team.workitem.common.model.ICategory;
import com.ibm.team.workitem.common.model.ICategoryHandle;

permanent link
Thomas Starz (1812015) | answered Jun 05 '09, 6:22 p.m.
Something must be wrong because I know that the 2.0 does still use
com.ibm.team.repository.client.ITeamRepository and it is exposed from
the same plugin as in 1.0.


Where do I find com.ibm.team.repository.client.ITeamRepository? Is it in the client package? If yes, can you please point me to it?

For 1.0, I used a couple of classes that were not found in the client. Maybe they are there but I have not found them.
Therefore, I downloaded (I forgot from where) for example, jar files like com.ibm.team.workitem.client_0.6.1.I200810081652.jar.
From this file, for example, among others, I use the class com.ibm.team.workitem.client.IWorkItemClient.class that I do not find anywhere in the standard client package, neither in the 1.0 client nor in the 2.0 client.

Therefore I had all these jars (the mentioned file is only one sample from a total of 55 jars) in my project for 1.0.

For 2.0, I understand that the classes from these jar-files I downloaded do not work any more but therefore I need updated ones. They do not seem to be in the client package, at least I do not find them. Where can I get them from?

permanent link
Thomas Starz (1812015) | answered Jun 12 '09, 4:07 a.m.
Can anyone please help me finding the libraries I need?
Thanks a lot!
- Thomas

permanent link
Patrick Streule (4.9k21) | answered Jun 12 '09, 4:54 a.m.
JAZZ DEVELOPER
Can anyone please help me finding the libraries I need?
Thanks a lot!
- Thomas

The Plain Java Librararies are available on the Downloads page of jazz.net:
https://jazz.net/downloads/rational-team-concert/milestones/2.0RC2?p=allDownloads

The direct link for RC2 is:
https://jazz.net/downloads/rational-team-concert/milestones/2.0RC2/JazzPlainJavaClient-2.0RC2.zip

--
Regards,
Patrick
Jazz Work Item Team

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.