It's all about the answers!

Ask a question

Changing mutiple Jazz UserIDs for RTC


Pierre Charbonneau (113) | asked Sep 21 '16, 5:19 p.m.
edited Sep 21 '16, 5:26 p.m.

Good Evening,

I am going to try to describe what I am trying to accomplish the best I can. We have a requirement to change all of our Jazz UserIDs. I know how to modify the UserIDs manually however we have over 500 users and doing this all manually would take to long. I reached out to IBM and they gave me a link to a sample using the Java API link : https://rsjazz.wordpress.com/2012/10/12/changing-the-jazz-user-id-using-the-rtc-plain-java-client-libraries/ I am following this sample however I have ran into several errors with missing com.ibm repositories while trying to compile using the command line so I did download the plain java client libraries and unzip them to the folder where my java files are and still same error. I am wondering if someone can give me some guidance with this. I know the sample talks about using Eclipse however I thought I could just use the command line. Any help would be great!!

2 answers



permanent link
Ralph Schoon (63.1k33645) | answered Sep 22 '16, 2:05 a.m.
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER
edited Sep 22 '16, 2:06 a.m.
As all of the blog posts on that site, the one you refer to has a chapter for newbies:

If you just get started with extending Rational Team Concert, or create API based automation, start with the post Learning To Fly: Getting Started with the RTC Java API’s and follow the linked resources.

I'd suggest to take the time to read through the post and follow the advice to set up your development environment.
For your scenario you don't have to set up the SDK, just the plain java client libraries. Setting up the SDK however allows looking at the API.

You should be able to compile with just the plain java client libraries in the path, even without Eclipse. Consider to use the JDK that ships with the RTC Eclipse client for this.

The plain Java Client libraries contain a readme that explains a bit how to compile.

Comments
Pierre Charbonneau commented Sep 22 '16, 3:49 p.m. | edited Sep 22 '16, 3:59 p.m.

I was tackling this again today with errors. I guess I failed to mention in my post yesterday that Eclipse is not installed in my staging in my Staging environment and that is why I need to do this all at the command prompt. Today I read through the post again and tried the following: I redownloaded the plain java libraries in to a au folder of my main RTC folder called lib I than I was able to run the javac CsVFileReader.java no issues however when I tried running the javac  -cp c:\RTC\lib\ ChangeUserID. Java I get com.ibm.client is not found and other error to other packages so I went and looked and did not see the jar files that refer to the errors. Also while reviewing the code i don't see where I would reference my jazz server jets but I think it would prompt me. Again I appreciate all your help lift has been a bit since I played with JAva certainly my first time developing against RTC 


Donald Nong commented Sep 22 '16, 9:27 p.m. | edited Sep 22 '16, 9:28 p.m.

You need to specify each individual .jar files with the -cp parameter. It's quite painful when you have lots of .jar files, and that's why Eclipse comes in handy.
http://docs.oracle.com/javase/7/docs/technotes/tools/windows/javac.html


Ralph Schoon commented Sep 23 '16, 2:18 a.m. | edited Sep 23 '16, 2:22 a.m.
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER

That is not correct, you can just specify a folder. This is the batch file I use for the Extensions Workshop.

I also explain that at the end of https://rsjazz.wordpress.com/2013/03/20/understanding-and-using-the-rtc-java-client-api/ which is one of the articles mentioned in  Learning To Fly: Getting Started with the RTC Java API’s which I suggest reading.

But Eclipse allows you to see the code and search examples, which is why you shuld set it up and use it as explained in Learning To Fly: Getting Started with the RTC Java API’s. Otherwise you will ask people over and over for API calls.

It is also way easier to run and debug all this in Eclipse.

So, really, read that and perform the actions.


Donald Nong commented Sep 23 '16, 2:26 a.m.

Ralph, does "javac" treats the "-cp" parameter the same way as "java"? I haven't used "javac" for many years, so either my memory just fails me or there were some changes in newer versions of Java.


Pierre Charbonneau commented Sep 23 '16, 2:36 p.m.

Hi,

So I have decided to go through the RTC Extensions workshop and Step 3 in 1.1 talks about installing the RTC Eclipse ands test server to which we already have that installed in our environment so can I skip 1.1 and regarding 1.2 is this where i would add the plain java client libraries instead of the SDK ? the reason I ask this is because I see can only select one of the checkboxes. I would also like to thank you for all your help !! 


permanent link
Donald Nong (14.5k414) | answered Sep 22 '16, 1:50 a.m.
You'd better use Eclipse to do the job, as you can even download the Eclipse project from the blog. The RTC Eclipse client is good enough for this task.

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.