1 Reply Latest reply on Apr 29, 2011 8:24 PM by smohr

    Axis2 Web Service example Please

    mikeloria

      I am very excited about the potential of PI web services especially since I deal with different platforms and different languages. I am very interested in using java axis2 as my client library. The samples that I found on vcampus is axis 1  which is very different and an older methodology. I have been struggling with this for a few days and really need an example.

       

      I have been able to create the stubs and a client class that compiles but I am having trouble with using the data response and the GetPISnapshotData class.

       

      It would be greatly appreciated if someone could just do a console app showing the usages of at at  least the methods of:

       

      getPIArchiveData

       

      getPISnapshotData

       

      insertPIData

       

      It would be great to show them all if time permits and for completeness

       

      I have been just creating the the single stub classes by using:

       

      wsdl2java -uri http://XXXXXXX:8080/PIWebServices/PITimeSeries.svc?wsdl -o <path/to/output>

       

      I have no trouble creating the stubs and referencing the stub classes and methods and running the client. I am just having trouble understanding how to use them.

       

       

       

      Thank you so much in advance.

        • Re: Axis2 Web Service example Please
          smohr

          If I'm reading Eclipse correctly, the sample from vCampus for PI Web Services 2010 R2 uses Axis2 v. 1.4.  That said, the class framework used shouldn't change how our methods are called and how the return classes are used.  The sample used synchronous calls to GetPIArchiveData (yes, the Axis proxies do lower-case the first letter of our methods for some reason); perhaps you have been looking at asynchronous classes in Axis?

           

          I am not planning any new Java samples in the near-term.  If you post a few more details, however, perhaps we can help get you pointed in the right direction.