hallo Leute,
ich bin am verzeifeln.
Bitte Hilft mir.
Ich Arbeite mit Netbeans 6.0.1 MySQL 5 und JBoss 4.2.2
Ich bekomme immer folgende Exception in diesem Abschnitt:
hier die jbossmq-destinations-service.xml
Wie man sieht habe ich kein SecurityManager angegeben. Und alle Elemente sind im JNDI Baum richtig abgebildet.
Trotz allem mal der defaul securityManager jbossmq:
und als letztes noch die jms_roles Tabelle in meiner mysqlDB
und die jms_users
Ich hoffe das mir einer Antwortet der mir helfen kann :-(
Aber ich danke jetzt schonmal jeglicher Hilfe
ich bin am verzeifeln.
Bitte Hilft mir.
Ich Arbeite mit Netbeans 6.0.1 MySQL 5 und JBoss 4.2.2
Ich bekomme immer folgende Exception in diesem Abschnitt:
Code:
public PolicyMessageListener() throws Exception {
Context jndiContext = getInitialContext();
TopicConnectionFactory factory = (TopicConnectionFactory) jndiContext
.lookup("ConnectionFactory");
Topic topic = (Topic) jndiContext.lookup("topic/newPolicy");
Connection connect = factory.createTopicConnection();
Session session = connect.createSession(false,Session.AUTO_ACKNOWLEDGE);
MessageConsumer consumer = session.createConsumer(topic);
consumer.setMessageListener(this);
connect.start();
}
Code:
Exception in thread "main" javax.jms.JMSSecurityException: User: null is NOT authenticated
at org.jboss.mq.security.SecurityManager.authenticate(SecurityManager.java:230)
at org.jboss.mq.security.ServerSecurityInterceptor.authenticate(ServerSecurityInterceptor.java:66)
hier die jbossmq-destinations-service.xml
Code:
<mbean code="org.jboss.mq.server.jmx.Topic"
name="jboss.mq.destination:service=Topic,name=newPolicy">
<depends optional-attribute-name="DestinationManager">jboss.mq:service=DestinationManager</depends>
</mbean>
Wie man sieht habe ich kein SecurityManager angegeben. Und alle Elemente sind im JNDI Baum richtig abgebildet.
Trotz allem mal der defaul securityManager jbossmq:
Code:
<!-- Security domain for JBossMQ -->
<application-policy name = "jbossmq">
<authentication>
<login-module code = "org.jboss.security.auth.spi.DatabaseServerLoginModule"
flag = "required">
<module-option name = "unauthenticatedIdentity">guest</module-option>
<module-option name = "dsJndiName">java:/DefaultDS</module-option>
<module-option name = "principalsQuery">SELECT PASSWD FROM JMS_USERS WHERE USERID=?</module-option>
<module-option name = "rolesQuery">SELECT ROLEID, 'Roles' FROM JMS_ROLES WHERE USERID=?</module-option>
</login-module>
</authentication>
</application-policy>
und als letztes noch die jms_roles Tabelle in meiner mysqlDB
Code:
ROLEID USERID
durpublisher dynsub
publisher dynsub
guest guest
j2ee guest
john guest
durpublisher john
publisher john
subscriber john
noacc nobody
und die jms_users
Code:
USERID PASSWD
dynsub synsub
guest guest
j2ee j2ee
john needle
nobody nobody
Ich hoffe das mir einer Antwortet der mir helfen kann :-(
Aber ich danke jetzt schonmal jeglicher Hilfe