nifi-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From James McMahon <>
Subject Syntax to access freeSpace from REST API
Date Tue, 20 Nov 2018 18:47:27 GMT
Hello. In the json that is returned by a RESTful API call to system
diagnostics, I can access the free space for the flowFile repo something
like this:


But the content repo stats seem to be buried deeper in the structure, and
are also enclosed by a [,] that is not found in the flow file repo stats.
Using a syntax like that I've shown above does not return the value to me.
What is the syntax to use in an UpdateAttribute processor to grab that
content repo free space value, so that I can save it to an attribute?

Here is the structure returned by the API call:


                      {"totalNonHeap":"338.38 MB",


                       "usedNonHeap":"326.16 MB",


                       "freeNonHeap":"12.22 MB",


                       "maxNonHeap":"-1 bytes",


                       "totalHeap":"6 GB",


                       "usedHeap":"3.17 GB",


                       "freeHeap":"2.83 GB",


                       "maxHeap":"6 GB",








                       {"freeSpace":"44.39 GB",

                        "totalSpace":"79.99 GB",

                        "usedSpace":"35.59 GB",






                          {"identifier":"default","*freeSpace"*:"44.39 GB",

                           "totalSpace":"79.99 GB","usedSpace":"35.59 GB",






                            {"name":"G1 Young Generation",




                            {"name":"G1 Old Generation","collectionCount":0,



                            "statsLastRefreshed":"03:05:01 UTC"}



Thanks in advance for your help. -Jim

View raw message