- CheckMates
- :
- Products
- :
- Developers
- :
- API / CLI Discussion
- :
- Web API issue
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Mute
- Printer Friendly Page
Are you a member of CheckMates?
×- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Web API issue
Maybe silly question but I haven't found a solution (just a workaround):
Currently I am working on a script to populate a given network group with networks from an IPAM system (Infoblox). Everything working good except that I get an error ("Runtime error: an eclipse error has occurred enable logging on EclipseLinkExceptionHandler to see full error") if I issue a logout after the publish request.
Workaround is a "sleep 5" between the two requests. Itchy.
I assume the logout comes too fast after publish. Is there a way to get a "okay I'm finished now" from the server or to configure some kind of delay with the publish request? Anyone here having the same issue? Am I doing something seriously wrong?
Thanks in advance!
Michael
Accepted Solutions
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hey Michael, some API functions are asynchronous and will return a task ID that you need to poll to check for completion. I've got an example of it working here https://github.com/chkp-stuartgreen/policy-automation-poc/blob/main/packages/simplecpapi.py . But once that task completes successfully (or fails, depending on what you need) you should be good to continue.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hey Michael, some API functions are asynchronous and will return a task ID that you need to poll to check for completion. I've got an example of it working here https://github.com/chkp-stuartgreen/policy-automation-poc/blob/main/packages/simplecpapi.py . But once that task completes successfully (or fails, depending on what you need) you should be good to continue.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Stuart, this is exactly what I've been missing. Thanks a lot!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Stuart, I made it. Outcome at https://github.com/dj0nz/cptools/blob/main/import_from_infoblox.sh. Once again, thank you!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
@dj0Nz Hey there, do you want to add this as an item to our ToolBox collection? If yes, please send me a message at vloukine@checkpoint.com.
