Description:
Hi everyone, I'm building a project with Balana which is something about performance optimization. I've done some performance teting by using the sample code in image-filter. Basically, I created the PDP instance (which loads the policy from the disk) and XACML request, then evaluate the request against the policy for 1000 times, as shown in the following. The total execution time is about 1300ms. So I can conclude the throughput of Balana PDP in evaluation a request is around 1000/1300=770 requet. Is this correct?
PDP pdp = new PDP(new PDPConfig(attributeFinder, pdpConfig.getPolicyFinder(), null, true));long start = System.nanoTime();for (int i = 0; i < 10000; i++) {pdp.evaluate(request);}long elapsedTime = System.nanoTime() - start;System.out.println(elapsedTime/1000000);
I'm concered about this value because its much smaller from reported in some papers. For example, in paper [1], Table III reported that the throughput in evaluating a 10-rule policy is 200000. Considering it used a 4-core machine, the tps achieved by a single thread should still be 50K, which is much higher than what I got. So I guess maybe there is something I made wrong.
I attached the complete code for the test in the end.
Test run inside intellij
Build #IE-221.5591.62, built on May 22, 2022
Runtime version: 11.0.14.1+1-b2043.45 amd64
VM: OpenJDK 64-Bit Server VM by JetBrains s.r.o
Description: Hi everyone, I'm building a project with Balana which is something about performance optimization. I've done some performance teting by using the sample code in image-filter. Basically, I created the PDP instance (which loads the policy from the disk) and XACML request, then evaluate the request against the policy for 1000 times, as shown in the following. The total execution time is about 1300ms. So I can conclude the throughput of Balana PDP in evaluation a request is around 1000/1300=770 requet. Is this correct?
PDP pdp = new PDP(new PDPConfig(attributeFinder, pdpConfig.getPolicyFinder(), null, true));
long start = System.nanoTime();
for (int i = 0; i < 10000; i++) {
pdp.evaluate(request);
}
long elapsedTime = System.nanoTime() - start;
System.out.println(elapsedTime/1000000);
I'm concered about this value because its much smaller from reported in some papers. For example, in paper [1], Table III reported that the throughput in evaluating a 10-rule policy is 200000. Considering it used a 4-core machine, the tps achieved by a single thread should still be 50K, which is much higher than what I got. So I guess maybe there is something I made wrong.
I attached the complete code for the test in the end.
Thanks for any elaborations or suggestions!
[1] A Performance Analysis of the XACML Decision Process and the Impact of Caching https://www.researchgate.net/publication/283307011_A_Performance_Analysis_of_the_XACML_Decision_Process_and_the_Impact_of_Caching
Performance benchmark
Environment Distributor ID: Ubuntu Description: Ubuntu 20.04.4 LTS Release: 20.04 Codename: focal
openjdk version "1.8.0_312" OpenJDK Runtime Environment (build 1.8.0_312-8u312-b07-0ubuntu1~20.04-b07) OpenJDK 64-Bit Server VM (build 25.312-b07, mixed mode)
Apache Maven 3.6.3 Maven home: /usr/share/maven Java version: 1.8.0_312, vendor: Private Build, runtime: /usr/lib/jvm/java-8-openjdk-amd64/jre Default locale: en_US, platform encoding: UTF-8 OS name: "linux", version: "5.13.0-51-generic", arch: "amd64", family: "unix"
Test run inside intellij Build #IE-221.5591.62, built on May 22, 2022 Runtime version: 11.0.14.1+1-b2043.45 amd64 VM: OpenJDK 64-Bit Server VM by JetBrains s.r.o