-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
5 changed files
with
33 additions
and
92 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
18 changes: 12 additions & 6 deletions
18
...-jms/src/main/java/io/quarkiverse/messaginghub/pooled/jms/it/CustomConnectionFactory.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,22 @@ | ||
package io.quarkiverse.messaginghub.pooled.jms.it; | ||
|
||
import jakarta.enterprise.context.Dependent; | ||
import jakarta.enterprise.context.ApplicationScoped; | ||
import jakarta.enterprise.inject.Produces; | ||
import jakarta.jms.ConnectionFactory; | ||
|
||
import org.apache.activemq.artemis.jms.client.ActiveMQConnectionFactory; | ||
import org.eclipse.microprofile.config.ConfigProvider; | ||
|
||
import io.quarkiverse.messaginghub.pooled.jms.PooledJmsWrapper; | ||
import io.quarkus.arc.properties.UnlessBuildProperty; | ||
|
||
@Dependent | ||
@UnlessBuildProperty(name = "quarkus.artemis.enabled", stringValue = "true") | ||
public class CustomConnectionFactory extends ActiveMQConnectionFactory { | ||
public CustomConnectionFactory() { | ||
super(ConfigProvider.getConfig().getValue("artemis.custom.url", String.class)); | ||
public class CustomConnectionFactory { | ||
|
||
@Produces | ||
@UnlessBuildProperty(name = "quarkus.artemis.enabled", stringValue = "true") | ||
@ApplicationScoped | ||
public ConnectionFactory createConnectionFactory(PooledJmsWrapper wrapper) { | ||
String url = ConfigProvider.getConfig().getValue("artemis.custom.url", String.class); | ||
return wrapper.wrapConnectionFactory(new ActiveMQConnectionFactory(url)); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
77 changes: 0 additions & 77 deletions
77
runtime/src/main/java/io/quarkiverse/messaginghub/pooled/jms/PooledJmsDecorator.java
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters