JAVA-24962 - Modifications to make client work with EJB deployed in Wildfly. (#15753)

This commit is contained in:
Amit Pandey 2024-02-19 19:26:56 +05:30 committed by GitHub
parent bac8dd0536
commit a407c2f015
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 14 additions and 2 deletions

View File

@ -50,6 +50,18 @@
<groupId>io.undertow</groupId>
<artifactId>undertow-servlet</artifactId>
</dependency>
<dependency>
<groupId>org.wildfly</groupId>
<artifactId>wildfly-naming-client</artifactId>
</dependency>
<dependency>
<groupId>org.jboss</groupId>
<artifactId>jboss-ejb-client</artifactId>
</dependency>
<dependency>
<groupId>org.wildfly.common</groupId>
<artifactId>wildfly-common</artifactId>
</dependency>
</dependencies>
<build>

View File

@ -21,7 +21,7 @@ public class SpringEjbClientApplication {
Properties jndiProps = new Properties();
jndiProps.put("java.naming.factory.initial", "org.jboss.naming.remote.client.InitialContextFactory");
jndiProps.put("jboss.naming.client.ejb.context", true);
jndiProps.put("java.naming.provider.url", "http-remoting://localhost:8080");
jndiProps.put("java.naming.provider.url", "remote+http://localhost:8080");
return new InitialContext(jndiProps);
}
@ -37,7 +37,7 @@ public class SpringEjbClientApplication {
@SuppressWarnings("rawtypes")
private String getFullName(Class classType) {
String moduleName = "spring-ejb-remote/";
String moduleName = "ejb:/spring-ejb-remote/";
String beanName = classType.getSimpleName();
String viewClassName = classType.getName();