This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Deleting queryByName result chunks

Hello,

I encountered the situation whereby a call to the /topology REST API endpoint (with a predefined query name in the body) resulted in chucked data.

But what is the deal with these chunks, more precisely their TimeToLive?  I understand how to get the actual data using the /topology/result/{id}/{chunk} endpoint, but what is the deal with the DELETE /topology/result/{id} endpoint?  Am I supposed to perform that action each time I get chunked results or is there an automatic cleaning build into UCMDB?  I don't find any setting that controls such an automated TTL for result chunks so I'm worrying about this.  The only settings that are query result chunk related are those for setting chunk size and max result size.

Regards

Dominik

Parents
  • Suggested Answer

    0  

    Dominik;

    Yes, the chunks get stored on the server for a default time before they expire.  You should follow this programatically:

    1. Run query to get chunked results.
    2. Retrieve number of chunks
    3. Cycle through chunks
      1. Retrieve data per chunk
      2. Delete chunks from memory
    4. Use the data how you wish

    -- Hope this helps!

    Keith Paschal

    UCMDB Worldwide Support Lead

  • 0 in reply to   

    Hi Keith,

    I have been doing some testing with a query that returns a result set id and where I make calls to get individual chunks.  My testing was focussed on determining the auto cleanup of the result sets.

    In DEV I ran the first base query on Friday and I was still able to get chunks on Tuesday afternoon.

    In UAT and PROD I ran the base query on Tuesday early morning and was still able to get chunks late afternoon (10 hours later).

    In UAT I repeated the base query making it possible to alternatively get chunks from the first and second result sets.

    This behaviour doesn't fill me with confidence about the cleanup mechanism (seen as result sets are kept in memory as I understood), is there no documentation on the matter?

    Using UCMDB 2021.11 btw.

    Regards,

    Dominik

Reply
  • 0 in reply to   

    Hi Keith,

    I have been doing some testing with a query that returns a result set id and where I make calls to get individual chunks.  My testing was focussed on determining the auto cleanup of the result sets.

    In DEV I ran the first base query on Friday and I was still able to get chunks on Tuesday afternoon.

    In UAT and PROD I ran the base query on Tuesday early morning and was still able to get chunks late afternoon (10 hours later).

    In UAT I repeated the base query making it possible to alternatively get chunks from the first and second result sets.

    This behaviour doesn't fill me with confidence about the cleanup mechanism (seen as result sets are kept in memory as I understood), is there no documentation on the matter?

    Using UCMDB 2021.11 btw.

    Regards,

    Dominik

Children