You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@jmeter.apache.org by bu...@apache.org on 2018/09/09 12:50:32 UTC

[Bug 62700] New: Introduce groovy.init.file to allow calling a groovy script on JMeter startup

https://bz.apache.org/bugzilla/show_bug.cgi?id=62700

            Bug ID: 62700
           Summary: Introduce groovy.init.file to allow calling a groovy
                    script on JMeter startup
           Product: JMeter
           Version: 4.0
          Hardware: All
                OS: All
            Status: NEW
          Severity: enhancement
          Priority: P2
         Component: Main
          Assignee: issues@jmeter.apache.org
          Reporter: p.mouawad@ubik-ingenierie.com
  Target Milestone: ---

This feature is available currently as Beanshell :

- beanshell.init.file

It has been requested through:

-
http://mail-archives.apache.org/mod_mbox/jmeter-dev/201808.mbox/%3CCAH9qxHacKG_Mf-HG%3DcvOnPZ-VY4e2k32HEfP12cWNGbbxEkCqg%40mail.gmail.com%3E

-- 
You are receiving this mail because:
You are the assignee for the bug.

[Bug 62700] Introduce groovy.init.file to allow calling a groovy script on JMeter startup

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=62700

--- Comment #5 from Felix Schumacher <fe...@internetallee.de> ---
Created attachment 36142
  --> https://bz.apache.org/bugzilla/attachment.cgi?id=36142&action=edit
Make init file more generic

Use Philippe's remark to make the init file setup more robust.

-- 
You are receiving this mail because:
You are the assignee for the bug.

[Bug 62700] Introduce groovy.init.file to allow calling a groovy script on JMeter startup

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=62700

Philippe Mouawad <p....@ubik-ingenierie.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|---                         |FIXED
           Keywords|                            |FixedInTrunk
                 CC|                            |p.mouawad@ubik-ingenierie.c
                   |                            |om
   Target Milestone|---                         |JMETER_5.0

--- Comment #1 from Philippe Mouawad <p....@ubik-ingenierie.com> ---
Author: pmouawad
Date: Sun Sep  9 13:09:21 2018
New Revision: 1840406

URL: http://svn.apache.org/viewvc?rev=1840406&view=rev
Log:
Bug 62700 - Introduce groovy.init.file to allow calling a groovy script on
JMeter startup
Bugzilla Id: 62700

Modified:
    jmeter/trunk/bin/jmeter.properties
    jmeter/trunk/src/core/org/apache/jmeter/JMeter.java
    jmeter/trunk/xdocs/changes.xml
    jmeter/trunk/xdocs/usermanual/properties_reference.xml

-- 
You are receiving this mail because:
You are the assignee for the bug.

[Bug 62700] Introduce groovy.init.file to allow calling a groovy script on JMeter startup

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=62700

--- Comment #2 from Felix Schumacher <fe...@internetallee.de> ---
Created attachment 36141
  --> https://bz.apache.org/bugzilla/attachment.cgi?id=36141&action=edit
Make init file more generic

Try to find the correct script engine by looking at the extension of the init
file (change the property name to jsr223.init.file at the same time)

-- 
You are receiving this mail because:
You are the assignee for the bug.

[Bug 62700] Introduce groovy.init.file to allow calling a groovy script on JMeter startup

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=62700

Felix Schumacher <fe...@internetallee.de> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         Resolution|---                         |FIXED
             Status|REOPENED                    |RESOLVED

--- Comment #6 from Felix Schumacher <fe...@internetallee.de> ---
Date: Thu Sep 13 18:36:46 2018
New Revision: 1840847

URL: http://svn.apache.org/viewvc?rev=1840847&view=rev
Log:
Allow full JSR-223 for init scripts in JMeter startup

Use jsr223.init.file to allow calling a JSR-223 script on JMeter startup
instead of the envisioned groovy.init.file property.

The engine to use for the init script will be determined by the extension
of the filename. If the filename has no extension or if no engine
can be found for that extension, Groovy will be tried.

Bugzilla Id: 62700

Modified:
    jmeter/trunk/bin/jmeter.properties
    jmeter/trunk/src/core/org/apache/jmeter/JMeter.java
    jmeter/trunk/xdocs/changes.xml
    jmeter/trunk/xdocs/usermanual/properties_reference.xml

-- 
You are receiving this mail because:
You are the assignee for the bug.

[Bug 62700] Introduce groovy.init.file to allow calling a groovy script on JMeter startup

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=62700

--- Comment #3 from UbikLoadPack support <su...@ubikloadpack.com> ---
(In reply to Felix Schumacher from comment #2)
> Created attachment 36141 [details]
> Make init file more generic
> 
> Try to find the correct script engine by looking at the extension of the
> init file (change the property name to jsr223.init.file at the same time)

Thanks for patch.

What do you think of defaulting to Groovy if engine is not found and logging a
warn message saying "We'll interpret your file as groovy ..."

-- 
You are receiving this mail because:
You are the assignee for the bug.

[Bug 62700] Introduce groovy.init.file to allow calling a groovy script on JMeter startup

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=62700

UbikLoadPack support <su...@ubikloadpack.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|RESOLVED                    |REOPENED
         Resolution|FIXED                       |---
           Keywords|FixedInTrunk                |

-- 
You are receiving this mail because:
You are the assignee for the bug.

[Bug 62700] Introduce groovy.init.file to allow calling a groovy script on JMeter startup

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=62700

--- Comment #4 from Felix Schumacher <fe...@internetallee.de> ---
(In reply to UbikLoadPack support from comment #3)
> (In reply to Felix Schumacher from comment #2)
> > Created attachment 36141 [details]
> > Make init file more generic
> > 
> > Try to find the correct script engine by looking at the extension of the
> > init file (change the property name to jsr223.init.file at the same time)
> 
> Thanks for patch.
> 
> What do you think of defaulting to Groovy if engine is not found and logging
> a warn message saying "We'll interpret your file as groovy ..."

As groovy interprets quite a lot of java, groovy (and probably a bit of
javascript) and it is our favourite scripting language, that might be a good
idea.

-- 
You are receiving this mail because:
You are the assignee for the bug.