Add authoraization in Jmeter load testing with JMeter jms point to point queue

StackOverflow https://stackoverflow.com/questions/23382040

  •  12-07-2023
  •  | 
  •  

문제

I am using jmeter jms point to point queue for load testing.

But I am getting the following error: javax.naming.NamingException: Failed to create remoting connection [Root exception is java.lang.RuntimeException: javax.security.sasl.SaslException: Authentication failed: all available authentication mechanisms failed]

I am using jmeter 2.11 version

I add user name and password in jndi properties. But still it is not working. Here is the configuration i am using:

QueueConnectionFactory: RemoteConnectionFactory

initial context factory: org.jboss.naming.remote.client.InitialContextFactory
url : remote://localhost:4447

JNDI Prpperties: username: .............. password: ...........

도움이 되었습니까?

해결책

Your Jndi properties seem wrong, check this:

Login / password props are :

  • java.naming.security.principal

The identity of the principal for authenticating the caller to the service. For more information, see the Java API documentation for javax.naming.Context.SECURITY_PRINCIPAL.

  • java.naming.security.credentials

The credentials of the principal for authenticating the caller to the service. For more information, see the Java API documentation for javax.naming.Context.SECURITY_CREDENTIALS.

다른 팁

I have encountered similar problem while using jmeter for solace, hope this help to someone having similar issue.

For solace jms testing need to use jndi properties since there is no place holder for VPN name. JNDI properties file will look something like this:

java.naming.factory.initial=com.solacesystems.jndi.SolJNDIInitialContextFactory
java.naming.provider.url=&lt;IP:port&gt;<br>
Solace_JMS_VPN=&lt;VPN Name&gt;<br>
java.naming.security.principal=&lt;username&gt;<br>
java.naming.security.credentials=&lt;password&gt;

Here the jndi properties has to be packaged as a jar file and placed in the jmeter lib folder in order to be picked at runtime.

jar cvf my-jndi-properties.jar jndi.properties

Hope this helps.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top