Forum Discussion

Maximilien_Rieh's avatar
Maximilien_Rieh
Icon for Nimbostratus rankNimbostratus
Oct 22, 2014

iControl Rest API: Node description reliability problems

Hi,

We're orchestrating f5 loadbalancers through the iControl rest API and we seem to be running into strange behaviour.

A GET against

/mgmt/tm/ltm/node/NODENAME
returns information about that node. The JSON usually looks like this (shortened):

{
 'kind': 'tm:ltm:node:nodestate',
 'name': '/partition_we_use/hostname',
 'state': 'down',
 'session': 'user-disabled',
 [...]
}

But sometimes the

session
key is just missing. I couldn't find an API contract but it seems wrong to me to just randomly leave a field out of the response.

Any ideas what might be wrong? Colleagues have seen it show up occasionally, and I was not able to reproduce it yet (and it's only affecting some nodes).

2 Replies

  • Hi,

     

    I've tried to reproduce this but haven't seen the session key missing. What version are you on? You might try to add "_return_fields" to the GET request to fields you wish to retrive? That might do the trick?

     

    • Mattias_Anderss's avatar
      Mattias_Anderss
      Icon for Nimbostratus rankNimbostratus
      Sorry, not "_return_fields" but "$select". For example: /mgmt/tm/ltm/node?ver=11.5.0&$select=session,name { "kind": "tm:ltm:node:nodecollectionstate", "selfLink": "https://localhost/mgmt/tm/ltm/node?$select=session%2Cname&expandSubcollections=true&ver=11.5.0", "items": [ { "name": "node1", "session": "monitor-enabled" }]}