1 2 Previous Next 23 Replies Latest reply on Nov 24, 2011 12:58 AM by Misi Mladoniczky

    Ar System Java API

      Share:|

      Hi,

       

      I have downloaded the AR System 5.1 Java API from Remedy site. I found an example class called 'JavaDriver.java'. I tried executing the file by setting required jars and dll into class path, but it was thowing "Can't find dependent libraries" exception.

       

      When I check the AR System Java API, it shows "arrpc50.dll" is required to execute the program. But in the downloaded code, I have not see that dll but other dlls like "arapi50.dll, arjni50.dll, arutiljni50.dll, arxmlutil50.dll" are available.

       

      I searched in BMC site to download the "arrpc50.dll", but I didn't get.

       

      Can some help me where to download the dll or how to run the program. Is it really required to have the dll in class path?

       

      Regds,

      Venu Gattineni

        • 1. Ar System Java API
          Misi Mladoniczky

          Hi,

           

          When I publish the APIs, I normally try to add these to a bin-directory, but for the old 5.0.1 API I did not do so.

           

          To get the DLLs, I suggest that you install the user-tool for 5.0.1 on a machine, and pick the file from there.

           

          Let me know if you do not have that installer, and I will try to extract that file for you.

           

          AR System API Downloads (C, Java and Driver)

           

          Maybe you should try to upgrade the integration to a newer version...

           

                  Best Regards - Misi, RRR AB, http://rrr.se

          1 of 1 people found this helpful
          • 2. Re: Ar System Java API

            Hi Misi,

             

            Your answer is helpful to me and I am able to run the program with your suggestions. Thank you.

             

            I am new to Remedy AR System and some of the terminologies are new to me.

             

            When I run the program for a command like "ge" i.e. GetEntry, it is asks for a schema name. What is a schema?

             

            How do I fetch details of a ticket by using JAVA API? What command to use and what are the arguments to pass?

             

            Best Regds,

            Venu Gattineni

            • 3. Ar System Java API
              Misi Mladoniczky

              Hi,

               

              If it helped you fix your problem, you should mark it as "correct" rather than "helpful".

               

              In any event, a Schema is equal to a Form with the newer naming standard.

               

              A Form/Schema is can be viewed as table in a database, with access permissions, business rules and triggers attached to it. In addition to this, it contains the layout of the form.

               

              Look at the API-page for references and samples: AR System API

               

                      Best Regards - Misi, RRR AB, http://rrr.se

              • 4. Re: Ar System Java API

                Hi Misi,

                 

                Thanks for the help.

                 

                By using the JAVA API available, I am executing "GetEntry" by passing "Entry Id" on a schema called "Events". I am able to fetch the event details for almost all the events, but some specific events having status "New" are throwing an exception called "Entry not available database", But the same event I am able see in "Remedy System".

                 

                Why the API is not able to fetch "New" Event from System, Are these events will be part of different Schema?

                 

                Best Regds,

                Venu Gattineni

                • 5. Re: Ar System Java API
                  Misi Mladoniczky

                  Hi,

                   

                  If you see the event in AR User and not via the API, something very strange is going on.

                   

                  Especially if you are using the same user, and the entry has actually been saved in the database.

                   

                  Turn on API/FLTR/SQL logging on the server and perform one call from AR User and one call from your API-program and compare the results.

                   

                          Best Regards - Misi, RRR AB, http://rrr.se

                  • 6. Re: Ar System Java API

                    Hi Misi,

                     

                    When a new ticket is logged in AR System, Can I receive that ticket details in my third party application directly. I mean, Can AR System forward the ticket details to my external adapter, or atleast the logged ticket id. In the form of an alert or some other way.....

                     

                    I will implement a socket on the my application and wait for tickets from AR System. Is it possible?

                     

                    Best Regds,

                    Venu Gattineni

                    • 7. Re: Ar System Java API
                      Misi Mladoniczky

                      Hi,

                       

                      The easiest way would probably to create a small executable, placed on your server.

                       

                      You can then do a run-process command from a filter: /x/y/newticketnotifier $1$

                       

                      You can also create a Web Service interface instead of just listening to a socket, and the built in Web Service functionality can be used. This is also done via a filter.

                       

                      If you can wait some seconds before your program gets notified, you can poll for the new tickets yourself. If you use the ticket-id as search criteria, you will not have an issue with performance:

                       

                      You must do a GetListEntry (gle) to get new tickets using the following qualifier:

                      ('1' > "HighestPreviousID")

                       

                      You can then use the resulting list of new IDs to forward your HighestPreviousID-variable for the next search, as well as doing 0-x GetEntry (ge) calls, one for each ID returned.

                       

                      Fire one of these calls every 60 seconds, or whatever you feel to be appropriate.

                       

                              Best Regards - Misi, RRR AB, http://rrr.se

                      1 of 1 people found this helpful
                      • 8. Re: Ar System Java API

                        Hi Misi,

                         

                        Thanks for the promt response. The approach suggested by you is helpful. Thank You.

                         

                        I have another query: How do I update some fields in the Tickets using JAVA API. Like I want to change the Status of a ticket to Closed from Java API.

                         

                        Is it possible do that, If yes, How do to achieve that?

                         

                         

                        Best Regs,
                        Venu Gattineni

                        • 9. Ar System Java API
                          Misi Mladoniczky

                          Hi,

                           

                          There are different versions of the Java API, that is quite different from each other. You use a very old version that seems very similar to the C-API that I know very well.

                           

                          You need to perform a SetEntry (se) call to update a ticket.

                           

                          Note that you should pass only those field/values that has actually been changed.

                           

                                  Best Regards - Misi, RRR AB, http://rrr.se

                          • 10. Re: Ar System Java API

                            Hi Misi,

                             

                            As suggested by You, I am using setEntry to upate ticket details. Using this I am able to update Ticket "Acknowledge By" Field, but not Ticket Status. Even though I changed the status to 'closed' using setEntry method i.e. setting to '2'. It was still showing me "New" Status in AR System. But when i fetch ticket details using getEntry it was showing status as 2.

                             

                            What are the possible status available in Remedy System? And what are their Enums? How to change the status of a ticket? Please suggest me on this.

                             

                            Best Regds,

                            Venu Gattineni

                            • 11. Re: Ar System Java API
                              Misi Mladoniczky

                              Hi,

                               

                              Usually status values are numbered with a zero index depending on the number of values. If 'closed' has position 3 it should have the numeric value '2'. Make sure you set it to a numeric value, and not a string.

                               

                              You say that GetEntry gives you a 2, is not that what you want???

                               

                              The first GetEntry should give you 0 if it is New, and then you do a SetEntry to 2, and a new GetEntry which gives you the same 2 back. Is that not what is happening?

                               

                              Where do you still see 'New'???

                               

                                      Best Regards - Misi, RRR AB, http://rrr.se

                              • 12. Re: Ar System Java API

                                Hi Misi,

                                 

                                I am setting "Status to 2" by using setEntry, and I am getting using getEntry, and it showing status as 2. But in AR System, status is shown as "NEW"

                                 

                                Please check the higlighted parts in screen shot.

                                 

                                Best Regds,

                                Venu Gattineni

                                • 13. Ar System Java API
                                  Misi Mladoniczky

                                  Hi,

                                   

                                  I can not be sure that it is the same ticket unless I see the Request ID (field id 1) on both sides.

                                   

                                  It is also not possible for me to see if you have reloaded the ticket in the client or not. To be 100% sure, relogin to the client and view the ticket again.

                                   

                                          Best Regards - Misi, RRR AB, http://rrr.se

                                  • 14. Re: Ar System Java API

                                    Hi Misi,

                                     

                                    I logged out and logged in again to the AR System User, but still it was showing ticket in "NEW" status.

                                     

                                    I am fteching the same Ticket Number in command line and in AR System User. Ticket Number: 4801644 and Entry Number:000000004801630

                                     

                                    Please check the screen shot. I highlighted in "Pink" colour. I hope "Field Id - 1000000007" is "Ticket Number" in database.

                                     

                                    Best Regds,

                                    Venu Gattineni

                                    1 2 Previous Next