Forum Discussion

Twirrim_94896's avatar
Twirrim_94896
Icon for Nimbostratus rankNimbostratus
Dec 15, 2011

Feature suggestion: Change monitor type, or show associations

I'm writing a series of tools to use in-house (but also open source) for managing our F5s, but hit up against an interesting situation.

 

 

I need to change the type of a monitor from TTYPE_HTTPS to TTYPE_HTTP. The only way to do that appears to be to un-associate the monitor from the pool it's associated with, delete the monitor, and re-create it in the new type.

 

 

 

It would be great if it was possible to change types between HTTPS and HTTP, but if not (and possibly for future uses I'm not aware of yet), it would be helpful if it was possible to interrogate a monitor to get a list of pools it's associated with. Otherwise it looks like I have to loop through and check against each pool. In our case that'd be 80+ API calls, vs a possible 1.

 

1 Reply

  • Hamish's avatar
    Hamish
    Icon for Cirrocumulus rankCirrocumulus
    You don't need 80+ API calls to get the monitors for all your pools. You can simply make one call (get_monitor_associations) and include all the pools you're interested in (But I admit that's not very resource friendly. But friendlier than 80+ calls)

     

     

    Failing that... You could pull the config and parse it...

     

     

    I suspect that for an API call to do what you'd want, it would have to do that anyway. Since a monitor is really only associated with a pool in the conifg. In reality, I think a monitor is associated with poolmembers... (IIRC I had a discussion like this a few years back with support).

     

     

    H