jmeter-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From UBIK LOAD PACK Support <>
Subject New __g (Groovy based) function as an alternative for __BeanShell for performance, easiness and up to dateness
Date Thu, 11 Aug 2016 21:52:41 GMT

Currently whenever you want to make some processing and a JMeter
function is not available for it, you can only use __BeanShell
For example:
- substring
- length
- Maths functions
- + hundreds of examples where you need the power of Java without
wanting to use a JSR223TestElement.

Unfortunately Beanshell performances are horrid compared to Groovy
ones for example besides the fact that Groovy is now integrated in
JMeter, maintained by Apache and very popular and that Beanshell is
nearly abandoned.

As an example, we attached a Test Plan showing the performance difference.

TG-Groovy Enabled only:

Generate Summary Results =  20000 in 00:00:00 = 41666.7/s Avg:     0
Min:     0 Max:     2 Err:     0 (0.00%)

TG-Beanshell enabled only:
Generate Summary Results +  17444 in 00:00:13 = 1312.6/s Avg:     0
Min:     0 Max:     2 Err:     0 (0.00%) Active: 10 Started: 10
Finished: 0
Generate Summary Results +   2556 in 00:00:02 = 1296.1/s Avg:     0
Min:     0 Max:     1 Err:     0 (0.00%) Active: 0 Started: 10
Finished: 10
Generate Summary Results =  20000 in 00:00:15 = 1310.4/s Avg:     0
Min:     0 Max:     2 Err:     0 (0.00%)

This simple benchmark shows that this new __g function is 31 to 32
times faster than __BeanShell.

So we propose to add this function that will work the same way as Beanshell.

We have submitted under a new __g
function for Groovy which is the equivalent of __BeanShell.

Note we could make this function totally generic by adding an argument for
the language to use but it would add a new parameter, and we aim at
encouraging best practices which are to use fastest languages.
But of course this can be amended


@ubikloadpack Team

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message