Forum Discussion

Magnum_IP's avatar
Magnum_IP
Icon for Nimbostratus rankNimbostratus
Sep 19, 2014

HTTP Monitor with multiple requests

I have been challenged to create a monitor to manage an application. I need to create a monitor that will log into an application and then make a further request.

 

So...

 

I have the POST request together to login and the request that the authenticated user has to then make, I just can't figure out how to order/relate these in the simplest way.

 

I'm probably missing the obvious here but has anybody got any thoughts?

 

Regards,

 

N

 

5 Replies

  • Hi Notorious BIGIP

     

    Have you looked at the following Codeshare for Monitors

     

    https://devcentral.f5.com/wiki/AdvDesignConfig.CodeShare.ashx

     

    Thanks, CB

     

  • Bhattman,

     

    I actually didn't know about the Monitor Codeshare ;-) I think the Super HTTP Monitor https://devcentral.f5.com/wiki/AdvDesignConfig.SuperHTTPMonitor.ashx is answer I was looking for.

     

    Thanks for the point in the right direction ;-)

     

    N

     

  • NP. Please come back if you are having trouble with the code. There are many here would can assist

     

  • Bhattman,

     

    There was one issue with the monitor and it was to do with the SCRIPTNAME variable, the script pulls this in from the calling monitor e.g. /Common/myMonitor A problem then occurs as the script attempts to use this variable as part of the tmpfile name e.g. /var/run//Common/myMonitor/... and the script fails. In short I don't think this script has been updated to accommodate the new object naming that cam in in late v10.

     

    I have one more question you might be able to answer. I understand that superHTTP is about chaining multiple requests together but do you know if the script would follow a redirect or whether I would have to hard code this? I am presuming I have to hard code at this stage.

     

    Thanks,

     

    Notorious

     

  • Just tested to see if the script naturally follows redirects and it doesn't so you just need to hard code a request for the redirected location ;-)