51Testing软件测试论坛
标题:
Loadrunner测试jms 回放时出错
[打印本页]
作者:
Simoncbx
时间:
2013-3-14 09:11
标题:
Loadrunner测试jms 回放时出错
本帖最后由 Simoncbx 于 2013-3-14 19:59 编辑
公司有个项目用的是C/S架构JMS,用loadrunner中的JAVA Record Replay协议录制脚本,回放时出错
这是部分录制的代码:
_remoteinvocation7 = (org.springframework.remoting.support.RemoteInvocation)lr.deserialize(_string7,6); // RMIComponent
_object7 = _rmiinvocationhandler13.invoke((org.springframework.remoting.support.RemoteInvocation)_remoteinvocation7);
}
{
_string8 = "org.springframework.remoting.support.RemoteInvocation __CURRENT_OBJECT = {" +
"java.lang.Object arguments[] = {" +
"}" +
"java.util.Map attributes = _NULL_" +
"java.lang.String methodName = #getJmsUserManagerHashtable#" +
"java.lang.Class parameterTypes[] = {" +
"}" +
"}";
_remoteinvocation8 = (org.springframework.remoting.support.RemoteInvocation)lr.deserialize(_string8,7); // RMIComponent
_object8 = _rmiinvocationhandler11.invoke((org.springframework.remoting.support.RemoteInvocation)_remoteinvocation8);
}
{
_string9 = "org.springframework.remoting.support.RemoteInvocation __CURRENT_OBJECT = {" +
"java.lang.Object arguments[] = {" +
"}" +
"java.util.Map attributes = _NULL_" +
"java.lang.String methodName = #isUseJms#" +
"java.lang.Class parameterTypes[] = {" +
"}" +
"}";
_remoteinvocation9 = (org.springframework.remoting.support.RemoteInvocation)lr.deserialize(_string9,8); // RMIComponent
_object9 = _rmiinvocationhandler11.invoke((org.springframework.remoting.support.RemoteInvocation)_remoteinvocation9);
}
{
// _connection1 = <undefined>.createConnection();
}
{
_connection1.start();
}
{
// _connection2 = <undefined>.createConnection();
}
{
_session1 = _connection1.createSession(true, 1);
}
{
_session2 = _connection2.createSession(false, 1);
}
{
// _messageproducer1 = _session2.createProducer((javax.jms.Destination)((org.apache.activemq.command.ActiveMQTopic)<undefined>));
}
{
// _messageconsumer1 = _session1.createConsumer((javax.jms.Destination)((org.apache.activemq.command.ActiveMQTopic)<undefined>), (java.lang.String)null, false);
}
{
_string10 = "com.singlee.core.jms.SingleeJMSMessageBean __CURRENT_OBJECT = {" +
"int orderCode = #201#" +
"java.lang.String message = #_NULL_#" +
"java.lang.String sendBr = #00#" +
"java.lang.String sendHostName = #BXCHAN-THINK#" +
"java.lang.String sendIP = #10.2.163.32#" +
"java.lang.String sendOper = #SYS1#" +
"java.lang.String toOper = #_NULL_#" +
"}";
_singleejmsmessagebean1 = (com.singlee.core.jms.SingleeJMSMessageBean)lr.deserialize(_string10,9); // RMIComponent
_objectmessage1 = _session2.createObjectMessage((java.io.Serializable)_singleejmsmessagebean1);
}
{
boolean __retval = _session2.getTransacted();
if(__retval != false)
return lr.FAIL;
}
{
boolean __retval = _session2.getTransacted();
if(__retval != false)
return lr.FAIL;
}
{
_session2.close();
}
{
_connection2.close();
}
{
_string11 = "org.springframework.remoting.support.RemoteInvocation __CURRENT_OBJECT = {" +
"java.lang.Object arguments[] = {" +
"}" +
"java.util.Map attributes = _NULL_" +
"java.lang.String methodName = #queryBranchProcessDate#" +
"java.lang.Class parameterTypes[] = {" +
"}" +
"}";
_remoteinvocation10 = (org.springframework.remoting.support.RemoteInvocation)lr.deserialize(_string11,10); // RMIComponent
_object10 = _rmiinvocationhandler2.invoke((org.springframework.remoting.support.RemoteInvocation)_remoteinvocation10);
}
{
// _connection3 = <undefined>.createConnection();
}
{
_session3 = _connection3.createSession(false, 1);
}
{
// _messageproducer2 = _session3.createProducer((javax.jms.Destination)((org.apache.activemq.command.ActiveMQTopic)<undefined>));
}
{
boolean __retval = _session1.getTransacted();
if(__retval != true)
return lr.FAIL;
}
{
boolean __retval = _session1.getTransacted();
if(__retval != true)
return lr.FAIL;
}
{
boolean __retval = _session1.getTransacted();
if(__retval != true)
return lr.FAIL;
}
{
boolean __retval = _session1.getTransacted();
if(__retval != true)
return lr.FAIL;
}
回放时的错误信息是:
Starting iteration 1.
Starting action Actions.
Error: System.err: java.lang.NullPointerException Error
System.err: at Actions.action(Actions.java:247) Error
Error: java.lang.NullPointerException
Error:
Abort was called from an action.
Ending Vuser...
Starting action vuser_end.
Ending action vuser_end.
Vuser Terminated.
有人能帮忙解决一下不
作者:
Simoncbx
时间:
2013-3-14 19:35
有人用loadrunner测试过JMS吗?
作者:
Simoncbx
时间:
2013-3-14 19:43
help~
作者:
TestingGirlzxh
时间:
2013-7-22 14:03
请问用loadrunner怎样实现jms服务的测试,不会啊?
作者:
TestingGirlzxh
时间:
2013-7-23 16:29
请问楼主是咋测试的?最近也遇到这种问题,求指导啊!
欢迎光临 51Testing软件测试论坛 (http://bbs.51testing.com/)
Powered by Discuz! X3.2