Thursday 19 January 2017

Count von Count. I love to count.... normally


In trying to improve performance on one of my UI5 applications, I've spotted that there's a dozen or so calls to count the number of entries that sit in an entityset.


Now it's quite straightforward to switch this off using 

oDatamodel.setCountSupported(false)

from https://archive.sap.com/discussions/thread/3519523

However, WHY would I want a count of all this guff? I don't even know if it's being used yet, and even when it's being used, I just want the damn list. I can do a count of items in a list using javascript, it's one of the array properties!!??

Then it occurred to me, it's for the FIORI tiles, if you're using them : The beautiful poster-child of SAP's UX in all it's glory : 



Yeah, looks beautiful, but it's not in my design, so I'm going to get rid of these counts. Owing to the way JS pings these requests all off in parallel, I'm not expecting it to make much of a difference to performance, but at least it will make my console that much less cluttered.