moodle-performance-comparison icon indicating copy to clipboard operation
moodle-performance-comparison copied to clipboard

Typed variable declaration : Object constructor

Open kstefanini opened this issue 8 years ago • 4 comments

Hello,

After user warmup, i've many of them:

2016/07/11 12:10:18 ERROR - jmeter.util.BeanShellInterpreter: Error invoking bsh method: source Sourced file: /home/killian/Documents/moodle/moodle-performance-comparison-master/recorder.bsf : Typed variable declaration : Object constructor 
2016/07/11 12:10:18 WARN  - jmeter.visualizers.BeanShellListener: Problem in BeanShell script org.apache.jorphan.util.JMeterException: Error invoking bsh method: source    Sourced file: /home/killian/Documents/moodle/moodle-performance-comparison-master/recorder.bsf : Typed variable declaration : Object constructor 
2016/07/11 12:10:18 INFO  - jmeter.threads.JMeterThread: Thread finished: Moodle Test 2-407 
2016/07/11 12:10:18 ERROR - jmeter.util.BeanShellInterpreter: Error invoking bsh method: source Sourced file: /home/killian/Documents/moodle/moodle-performance-comparison-master/recorder.bsf : Typed variable declaration : Object constructor 
2016/07/11 12:10:18 WARN  - jmeter.visualizers.BeanShellListener: Problem in BeanShell script org.apache.jorphan.util.JMeterException: Error invoking bsh method: source    Sourced file: /home/killian/Documents/moodle/moodle-performance-comparison-master/recorder.bsf : Typed variable declaration : Object constructor 
2016/07/11 12:10:18 INFO  - jmeter.threads.JMeterThread: Thread finished: Moodle Test 2-643 
2016/07/11 12:10:18 ERROR - jmeter.util.BeanShellInterpreter: Error invoking bsh method: source Sourced file: /home/killian/Documents/moodle/moodle-performance-comparison-master/recorder.bsf : Typed variable declaration : Object constructor 
2016/07/11 12:10:18 WARN  - jmeter.visualizers.BeanShellListener: Problem in BeanShell script org.apache.jorphan.util.JMeterException: Error invoking bsh method: source    Sourced file: /home/killian/Documents/moodle/moodle-performance-comparison-master/recorder.bsf : Typed variable declaration : Object constructor 
2016/07/11 12:10:18 INFO  - jmeter.threads.JMeterThread: Thread finished: Moodle Test 2-375 

Can you help me with that please? :)

I'm using ubuntu 15.10 & jmeter 3.0 from editor downloadable archive (not package). My test plan: testplan_201607111203_1807.jmx.tar.gz

Thanks for your time !

kstefanini avatar Jul 11 '16 10:07 kstefanini

Hi,

Experiencing the exact same bug, using :

  • Java version "1.8.0_91"
  • jmeter-3.0.
  • Ubuntu 16.04

Any help would be greatly appreciated. Thank you.

matcho avatar Aug 16 '16 12:08 matcho

Solved.

In my case the error was caused by FileWriter fstream = new FileWriter(filenamepath, true); not being able to open runs/tmpfilename.php for writing.

This is because I wasn't running JMeter from the moodle-performance-comparison folder.

Not a bug, my mistake. But the beanshell errors are clearly hard to understand - doesn't even give the source code line :-/

Mathias

matcho avatar Aug 16 '16 14:08 matcho

I also got the same Error: Object constructor: SOLVED

But Thanks to @matcho, I got a clue from the comment posted by @matcho above and in my case the problem was that the file in which I was trying to write data was "Already Open" in WPS Office.

So, make sure that the file into which you are trying to write data is Not Already Open or Being Accessed by Some other program or Editor.

anuragkumar490 avatar May 30 '17 11:05 anuragkumar490

Sorry guys for not responding to this before. It seems that both @kstefanini and @matcho use jmeter 3.0. This tool has not been tested using that jmeter version so there is probably a not backwards compatible change. As a short term solution I would recommend you to use one of the jmeter versions the tool was tested on (https://github.com/moodlehq/moodle-performance-comparison/blob/master/TROUBLESHOOTING.md#jmeter-dependencies)

You are very welcomed to send a fix to add jmeter 3.x compatibility

dmonllao avatar Oct 25 '17 08:10 dmonllao