• 1 reply
  • Latest Post - ‏2013-11-13T18:29:18Z by JCanipe
33 Posts

Pinned topic Retrieve content using getContent servlet

‏2013-11-06T19:52:14Z | getcontent wcmjavaviewer

Greetings. Currently using P8 5.1 FP3 on zLinux. I have a need to retrieve content using the getContent servlet but I do not want to invoke WcmJavaViewer.jsp. When I invoke the getContent servlet I get back a URL referencing the WcmJavaViewer.jsp, and then the content is rendered. Is there a parameter I can pass to the getContent servlet that will basically bring back the binary image only? I am trying to test getContent programmatically and I am only interested in the binary data. I am currently using the following:



Thank you.

  • JCanipe
    33 Posts

    Re: Retrieve content using getContent servlet


    Here is the way that is working for me when using Apache JMeter. First you make two initial http calls to Workplace,

    1. http://P8-XT-server/setCredentials/op=getUserToken... (to get the user token)

    2. http://P8-XT-server/WorkplaceXT/getContent?ut=the-user-token&id=objectid-of-document&objectStoreName=name....&mode=download  (Using the user token to retrieve an object ID.

    Once you have done the above, you hang onto the cookie (Http cookie Manager if using JMeter), and you make subsequent getContent calls (like the one above) except you DO NOT pass in the &ut=usertoken anymore.

    I iterate through a list of object IDs to retrieve. Works great using JMeter.