User Defined Variables and PerfMon Metrics Collector

642 views
Skip to first unread message

cyril

unread,
Mar 13, 2012, 5:56:02 AM3/13/12
to jmeter-plugins
HI,

Maybe, I miss something but I can't use my user defined variable in
the field "Host /IP" in Perfmon Metrics Collector plugin. I try to use
${xxxx} syntax but it's not replaced by its value.

There is a way to do that ?

Andrey Pohilko

unread,
Mar 13, 2012, 6:23:11 AM3/13/12
to jmeter-...@googlegroups.com
Actually it should work. Are you completely sure you use correct variable?

вторник, 13 марта 2012 г. 13:56:02 UTC+4 пользователь cyril написал:

cyril

unread,
Mar 13, 2012, 8:55:12 AM3/13/12
to jmeter-plugins
On Mar 13, 11:23 am, Andrey Pohilko <a...@apc.kg> wrote:
> Actually it should work. Are you completely sure you use correct variable?

I have this error in log file, it can't translate ${cs_client_ip}

2012/03/13 13:43:51 INFO - kg.apc.perfmon.client.TransportFactory:
Can't connect UDP transport for host: ${cs_client_ip}:4444
java.net.SocketException: Unresolved address
at java.net.DatagramSocket.connect(Unknown Source)
at
kg.apc.perfmon.client.TransportFactory.UDPInstance(TransportFactory.java:
113)
at
kg.apc.perfmon.client.TransportFactory.getTransport(TransportFactory.java:
32)
at
kg.apc.jmeter.perfmon.PerfMonCollector.getConnector(PerfMonCollector.java:
193)
at
kg.apc.jmeter.perfmon.PerfMonCollector.initiateConnector(PerfMonCollector.java:
175)
at
kg.apc.jmeter.perfmon.PerfMonCollector.initiateConnectors(PerfMonCollector.java:
152)
at
kg.apc.jmeter.perfmon.PerfMonCollector.testStarted(PerfMonCollector.java:
110)
at
org.apache.jmeter.samplers.RemoteSampleListenerImpl.testStarted(RemoteSampleListenerImpl.java:
65)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown
Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at sun.rmi.server.UnicastServerRef.dispatch(Unknown Source)
at sun.rmi.transport.Transport$1.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at sun.rmi.transport.Transport.serviceCall(Unknown Source)
at sun.rmi.transport.tcp.TCPTransport.handleMessages(Unknown
Source)
at sun.rmi.transport.tcp.TCPTransport
$ConnectionHandler.run0(Unknown Source)
at sun.rmi.transport.tcp.TCPTransport
$ConnectionHandler.run(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor
$Worker.runTask(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown
Source)
at java.lang.Thread.run(Unknown Source)

Andrey Pohilko

unread,
Mar 13, 2012, 10:02:23 AM3/13/12
to jmeter-...@googlegroups.com
Note that connection being opened very early in test, so you have to define the variable at Test Plan level.

вторник, 13 марта 2012 г. 16:55:12 UTC+4 пользователь cyril написал:

cyril

unread,
Mar 13, 2012, 11:04:21 AM3/13/12
to jmeter-plugins
On Mar 13, 3:02 pm, Andrey Pohilko <a...@apc.kg> wrote:
> Note that connection being opened very early in test, so you have to define
> the variable at Test Plan level.

I do it in the test Plan level. I put my test plan here:
http://dl.dropbox.com/u/741084/tmp.jmx

lpontes

unread,
May 9, 2012, 11:07:51 AM5/9/12
to jmeter-plugins
I'm having a similar problem, but only when doing remote testing:
"kg.apc.perfmon.client.TransportFactory: Can't connect UDP transport
for host: ${dbserver}:4444 java.net.SocketException: Unresolved
address"
where "${dbserver}" is defined in a "User Defined Variables" item, at
the top of my thread group.
When I run the test locally, the "PerfMon Metrics Collector" can
resolve ${dbserver}.

cyril

unread,
May 23, 2012, 3:39:32 AM5/23/12
to jmeter-plugins
ok, I only use the remote testing :'(

It's a bug. Must I open a bug ticket ??

Andrey Pohilko

unread,
May 23, 2012, 4:39:06 AM5/23/12
to jmeter-...@googlegroups.com



yep, open one



















































































































































среда, 23 мая 2012 г., 11:39:32 UTC+4 пользователь cyril написал:
среда, 23 мая 2012 г., 11:39:32 UTC+4 пользователь cyril написал:

jpgeek

unread,
Jul 4, 2012, 5:30:02 AM7/4/12
to jmeter-...@googlegroups.com
I am hitting exactly the same problem.  Does the jmeter-plugin do variable interpretation?

For example,  in an HTTP Request sampler I use a variable name ${remoteHost} which is set in a CSV Data Set Config element.  It works correctly there, however copying and pasting the value into a jp@gc - UDP Request just tries to make requests directly to the string "${remoteHost}".

Is this the expected functionality?

gael.g...@gmail.com

unread,
Jan 16, 2014, 10:56:11 AM1/16/14
to jmeter-...@googlegroups.com
Ok, I up this thread because I got the same problem.

Has it been fixed in the latest version of jmeter? I use Jmeter 2.9 and perfmon cannot find my server variables in remote testing.

gael.g...@gmail.com

unread,
Jan 20, 2014, 9:44:46 AM1/20/14
to jmeter-...@googlegroups.com, gael.g...@gmail.com
I updated the issue there after some investigation.
http://code.google.com/p/jmeter-plugins/issues/detail?id=151

Andrey Pohilko

unread,
Jan 20, 2014, 10:16:28 AM1/20/14
to jmeter-...@googlegroups.com, gael.g...@gmail.com
Thanks for your investigations. So it looks like it is JMeter core bug?

понедельник, 20 января 2014 г., 18:44:46 UTC+4 пользователь gael.g...@gmail.com написал:

gael.g...@gmail.com

unread,
Jan 20, 2014, 10:23:49 AM1/20/14
to jmeter-...@googlegroups.com, gael.g...@gmail.com
I think so. I investigated for only one short hour, I guess main developpers could confirm it's a core jmeter bug.

shoo...@gmail.com

unread,
Mar 23, 2015, 10:22:05 PM3/23/15
to jmeter-...@googlegroups.com, cyril....@gmail.com
Hitting the same problem with latest Perfmon plugin v1.2.1 and JMeter v2.13
It doesn't work on test plan level nor thread group level.
I've tried placing in the very first position in both test plan level and thread group level.
${xxx_xxx_xxx} and ${xxx} syntax all fails, but manually enter the IP will work.

cyril於 2012年3月13日星期二 UTC+8下午5時56分02秒寫道:
Reply all
Reply to author
Forward
0 new messages