Adding actions to iControlREST transaction
I followed the steps in Chapter 5 of the iControl REST User guide but am unable to get any actions added to a transaction.
The step in "Create a transaction" sub-section that adds a create pool action to the transaction does not work. The text indicates a POST to /mgmt/tm/transaction with create pool JSON but return code is a HTTP 400 using the following curl commands: curl -u xx:xx -k -H "Content-Type: application/json" -X POST https://localhost/mgmt/tm/transaction -d {} curl -u xx:xx -k -H "Content-Type: application/json" -H "X-F5-REST-Coordination-ID: 1411760620" -o C:\Temp\Temp.json -X POST https://localhost:443/mgmt/tm/transaction -d "{\"name\":\"TEST.POOL\",\"partition\":\"webprod\"}"
Response JSON:
{
"code" : 400,
"message" : "A transaction id 1411760620 for the user has already created.",
"errorStack" : []
}
I thought this might be a typo in the guide so I changed the second curl command use /mgmt/tm/ltm/pool: curl -u xx:xx -k -H "Content-Type: application/json" -H "X-F5-REST-Coordination-ID: 1411760620" -o C:\Temp\Temp.json -X POST https://localhost:443/mgmt/tm/ltm/pool -d "{\"name\":\"TEST.POOL\",\"partition\":\"webprod\"}"
The response JSON is a HTTP 200, but it returns the newly created pool details instead of the successfully added to transaction response indicated in the user guide. Also, the create pool command is executed immediately instead of when the transaction is committed. If I execute a command to rollback the transaction, the newly created pool is not removed.
Anyone have any luck getting transactions to work successfully through iControlREST? Also, does anyone know how to change the transaction timeout value through iControlREST?
Notes:
* CURL commands were executed using curl 7.34.1-DEV for Windows
* F5 is BIG-IP 11.5.1 Build 4.53.128 Engineering Hotfix HF4
* F5 device name and user/pwd altered for privacy
Regards,
Greg Bui