Optimize logging and HTTP filter

Same as #2276, but now for 2.0-maint branch:
This PR primarily fixes so that isDebugEnabled is cached for Jetty and Neo4j calls. During testing with ApacheBench it was found that this gave 200%-1000% performance improvement on REST API calls, due to the excessive number of debug logging calls made by Jetty.

HighPerformanceCache.put had a debug log call with toString() that did not first check for isDebugEnabled, which caused a pretty heavy string calculation to happen even if debugging was not enabled. This has been fixed.

The second commit removes the security filter if no rules are configured.