Hi,
i try to invoke some ejb from a WildFly 13 Server on my local WildFly 26.
i use the remoting subsystem to invoke the ejbs, but i get the error "EJBCLIENT000079: Unable to discover destination"
if i do a hard coded bean look up from my application, then everything is ok and the ejb is invoked.
i think the problem is the change of the provider url from WildFly 13 to WildFly 26
WildFly 13: https://"+ip+":"+port+"/wildfly-services
WildFly 26: remote+https://"+ip+":"+port+"/wildfly-services
the hard coded look up is like
private I_EJBArchiverRemote lookupFix(String module2Name) throws Exception
{
final Hashtable<String, String> jndiProperties = new Hashtable<String, String>();
jndiProperties.put(Context.URL_PKG_PREFIXES, "org.jboss.ejb.client.naming");
jndiProperties.put(Context.INITIAL_CONTEXT_FACTORY, "org.wildfly.naming.client.WildFlyInitialContextFactory");
jndiProperties.put(Context.PROVIDER_URL,"
https://SERVER-016:40100/wildfly-services" );
jndiProperties.put(Context.SECURITY_PRINCIPAL,"ejb");
jndiProperties.put(Context.SECURITY_CREDENTIALS,"");
final Context context = new InitialContext(jndiProperties);
final String appName = "";
final String moduleName = "SManager";
final String distinctName = "";
final String beanName = "EJBArchiverRemote";
final String viewClassName = I_EJBArchiverRemote.class.getName();
// let's do the lookup
System.out.println("ejb:" + appName + "/" + moduleName + "/" + distinctName + "/" + beanName + "!" + viewClassName);
return (I_EJBArchiverRemote) context.lookup("ejb:" + appName + "/" + moduleName + "/" + distinctName + "/" + beanName + "!" + viewClassName);
}
the remoting in standalone.xml is configured
<subsystem xmlns="urn:jboss:domain:remoting:4.0">
<http-connector name="http-remoting-connector" connector-ref="https2" sasl-authentication-factory="application-sasl-authentication"/>
<outbound-connections>
<remote-outbound-connection name="smanager-connection" outbound-socket-binding-ref="smanager" authentication-context="remote_authentication">
<properties>
<property name="SASL_POLICY_NOANONYMOUS" value="false"/>
<property name="SSL_ENABLED" value="true"/>
</properties>
</remote-outbound-connection>
</outbound-connections>
</subsystem>
the elytron subsystem
<subsystem xmlns="urn:wildfly:elytron:15.0" final-providers="combined-providers" disallowed-providers="OracleUcrypto">
<authentication-client>
<authentication-configuration name="auth-conf" authentication-name="ejb" host="SERVER-016" protocol="remote+https" port="40100" realm="ApplicationRealm" forwarding-mode="authentication" sasl-mechanism-selector="DIGEST-MD5">
<credential-reference store="credential" alias="74h1xni74v"/>
</authentication-configuration>
<authentication-context name="remote_authentication">
<match-rule match-host="SERVER-016" authentication-configuration="auth-conf"/>
</authentication-context>
</authentication-client>
<credential-stores>
<credential-store name="credential" relative-to="jboss.server.config.dir" location="mycredstore.cs" create="true">
<credential-reference clear-text="password"/>
</credential-store>
</credential-stores>
attached the server logs
connect_ok: hard coded ejb lookup
connect_nok: lookup over remoting subsystem
i already tried with the protocol="https" but without succes.
how can i set the provider url appropiate in the standalone.xml to make the invocation work?
thanks for help
regards
Sascha