File tree Expand file tree Collapse file tree
jms/src/main/java/io/helidon/messaging/connectors/jms
java/io/helidon/messaging/connectors/wls
resources/META-INF/helidon Expand file tree Collapse file tree Original file line number Diff line number Diff line change 3636import static io .helidon .messaging .connectors .jms .JmsConnector .JNDI_JMS_FACTORY_ATTRIBUTE ;
3737import static io .helidon .messaging .connectors .jms .JmsConnector .JNDI_JMS_FACTORY_DEFAULT ;
3838import static io .helidon .messaging .connectors .jms .JmsConnector .JNDI_PROPS_ATTRIBUTE ;
39+ import static io .helidon .messaging .connectors .jms .JmsConnector .NAMED_FACTORY_ATTRIBUTE ;
3940
4041/**
4142 * Context related to one actual connection being constructed by JMS connector.
@@ -68,7 +69,8 @@ public class ConnectionContext {
6869 }
6970
7071 boolean isJndi () {
71- return config .get (JNDI_ATTRIBUTE ).exists ();
72+ return config .get (JNDI_ATTRIBUTE ).exists ()
73+ && !config .get (NAMED_FACTORY_ATTRIBUTE ).exists ();
7274 }
7375
7476 Optional <? extends ConnectionFactory > lookupFactory () {
Original file line number Diff line number Diff line change @@ -97,12 +97,14 @@ static <T> T executeInIsolation(IsolationSupplier<T> supplier) {
9797
9898 boolean inWlsJar (String name ) {
9999 // Load jms exceptions from inside the thin jar to avoid deserialization issues
100- if (name .startsWith ("javax.jms" ) && name .endsWith ("Exception" )) {
100+ if ((name .startsWith ("javax.jms" ) || name .startsWith ("jakarta.jms" ))
101+ && name .endsWith ("Exception" )) {
101102 return true ;
102103 }
103104
104- // Load only javax JMS API from outside, so cast works
105+ // Load only javax and jakarta JMS API from outside, so cast works
105106 return !name .startsWith ("javax.jms" )
107+ && !name .startsWith ("jakarta.jms" )
106108 && !name .equals (IsolatedContextFactory .class .getName ());
107109 }
108110
Original file line number Diff line number Diff line change 1414# limitations under the License.
1515#
1616
17- pattern =weblogic.**;java.util.**;java.lang.**;java.io.**;java.rmi.**
17+ pattern =weblogic.**;java.util.**;java.lang.**;java.io.**;java.rmi.**;javax.naming.**
You can’t perform that action at this time.
0 commit comments