5 Replies Latest reply on Sep 18, 2014 8:33 PM by jorgewong

    PI Web API Performance

    GPaterson

      I'm creating a dashboard that is element relative and uses our buliding names as the user input. My dashboard has 3 gauges with Chilled Water, Steam and Electric. My AF tree looks like this:

       

      BuildingA

       

      --Building power

       

      ----Chilled Water

       

      ----Steam

       

      ----Electric

       

      BuildingB

       

      --Building power

       

      ----Chilled Water

       

      ----Steam

       

      ----Electric

       

      I have limited programing background, so I might be approaching this wrong, but in order for my dashboard to be robust I'm using the Building name as my starting point within the web API. So in order for me to return Chilled Water I first hit get my building's URI, then the Energy URI, then the Chilled Water URI, then the Attributes URI, then I can finally get my value. So I have to hit 4 URIs to get my value and I have to do that for all 3 devices. From what I can tell, this is the bottleneck in my application. Each page takes about 6-10 seconds to load.

       

       

       

      So my question, am I doing this right? And if so, is there an easy way to cache some of these URIs of the my actual attributes so that it only takes time to traverse the tree on the first click for that building?