Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
40 changes: 20 additions & 20 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -22,25 +22,25 @@

<groupId>org.fusesource.stompjms</groupId>
<artifactId>stompjms-project</artifactId>
<version>1.20-SNAPSHOT</version>
<version>1.21</version>
<packaging>pom</packaging>

<name>${project.artifactId}</name>
<description>
STOMP-JMS is a JMS implementation using STOMP as the wire protocol
</description>

<properties>
<forge-project-id>stompjms</forge-project-id>
<forge-project-id-uc>STOMPJMS</forge-project-id-uc>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>

<junit-version>4.7</junit-version>
<slf4j-version>1.6.1</slf4j-version>
<hawtbuf-version>1.9</hawtbuf-version>
<hawtdispatch-version>1.20</hawtdispatch-version>
<apollo-version>1.6</apollo-version>
<activemq-version>5.9.0</activemq-version>
<junit-version>4.13.2</junit-version>
<slf4j-version>1.7.36</slf4j-version>
<hawtbuf-version>1.11</hawtbuf-version>
<hawtdispatch-version>1.22</hawtdispatch-version>
<apollo-version>1.7.1</apollo-version>
<activemq-version>6.1.3</activemq-version>
<mvnplugins-version>1.15</mvnplugins-version>
<mockito.version>1.9.5</mockito.version>
</properties>
Expand Down Expand Up @@ -84,14 +84,6 @@
<url>http://github.com/fusesource/stompjms/tree/master</url>
</scm>

<distributionManagement>
<site>
<id>website.fusesource.org</id>
<name>website</name>
<url>dav:http://fusesource.com/forge/dav/${forge-project-id}/maven/${project.version}</url>
</site>
</distributionManagement>

<developers>
<developer>
<id>rajdavies</id>
Expand All @@ -115,7 +107,7 @@
<plugin>
<groupId>org.apache.felix</groupId>
<artifactId>maven-bundle-plugin</artifactId>
<version>1.0.0</version>
<version>5.1.9</version>
<extensions>true</extensions>
<configuration>
<instructions>
Expand Down Expand Up @@ -149,8 +141,8 @@
<artifactId>maven-compiler-plugin</artifactId>
<version>2.1</version>
<configuration>
<source>1.5</source>
<target>1.5</target>
<source>11</source>
<target>11</target>
</configuration>
</plugin>
<plugin>
Expand Down Expand Up @@ -261,8 +253,16 @@

<modules>
<module>stompjms-client</module>
<module>stompjms-website</module>
<!--<module>stompjms-website</module>-->
<module>stompjms-activemq-test</module>
</modules>

<distributionManagement>
<repository>
<id>clojars</id>
<name>Clojars repository</name>
<url>https://clojars.org/repo</url>
</repository>
</distributionManagement>

</project>
16 changes: 11 additions & 5 deletions stompjms-activemq-test/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -17,12 +17,12 @@
<parent>
<groupId>org.fusesource.stompjms</groupId>
<artifactId>stompjms-project</artifactId>
<version>1.20-SNAPSHOT</version>
<version>1.21</version>
</parent>

<groupId>org.fusesource.stompjms</groupId>
<artifactId>stompjms-activemq-test</artifactId>
<version>1.20-SNAPSHOT</version>
<version>1.21</version>

<name>${project.artifactId}</name>
<description>Tests the stompjms client against ActiveMQ</description>
Expand All @@ -32,14 +32,14 @@
<dependency>
<groupId>org.fusesource.stompjms</groupId>
<artifactId>stompjms-client</artifactId>
<version>1.20-SNAPSHOT</version>
<version>1.21-SNAPSHOT</version>
<scope>test</scope>
</dependency>

<dependency>
<groupId>org.apache.geronimo.specs</groupId>
<artifactId>geronimo-jms_1.1_spec</artifactId>
<version>1.1</version>
<version>1.1.1</version>
<scope>test</scope>
</dependency>

Expand All @@ -66,7 +66,13 @@
<dependency>
<groupId>com.thoughtworks.xstream</groupId>
<artifactId>xstream</artifactId>
<version>1.4.4</version>
<version>1.4.20</version>
</dependency>

<dependency>
<groupId>jakarta.jms</groupId>
<artifactId>jakarta.jms-api</artifactId>
<version>3.1.0</version>
</dependency>

<!-- to enable the webconsole in the apollo broker -->
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
import org.apache.activemq.broker.TransportConnector;
import org.fusesource.stomp.jms.StompJmsConnectionFactory;

import javax.jms.*;
import jakarta.jms.*;

/**
* <p>
Expand Down
32 changes: 27 additions & 5 deletions stompjms-client/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -17,18 +17,26 @@
<parent>
<groupId>org.fusesource.stompjms</groupId>
<artifactId>stompjms-project</artifactId>
<version>1.20-SNAPSHOT</version>
<version>1.21</version>
</parent>

<groupId>org.fusesource.stompjms</groupId>
<artifactId>stompjms-client</artifactId>
<version>1.20-SNAPSHOT</version>
<version>1.22</version>
<packaging>bundle</packaging>

<name>${project.artifactId}</name>
<description>
STOMP-JMS is a JMS implementation using STOMP as the wire protocol
</description>


<licenses>
<license>
<name>Common Development and Distribution License (CDDL)</name>
<url>http://www.opensource.org/licenses/cddl1</url>
</license>
</licenses>

<dependencies>

Expand All @@ -46,10 +54,16 @@
<dependency>
<groupId>org.apache.geronimo.specs</groupId>
<artifactId>geronimo-jms_1.1_spec</artifactId>
<version>1.1</version>
<version>1.1.1</version>
<optional>true</optional>
</dependency>

<dependency>
<groupId>jakarta.jms</groupId>
<artifactId>jakarta.jms-api</artifactId>
<version>3.1.0</version>
</dependency>

<dependency>
<groupId>org.apache.activemq</groupId>
<artifactId>apollo-selector</artifactId>
Expand All @@ -60,7 +74,7 @@
<dependency>
<groupId>com.thoughtworks.xstream</groupId>
<artifactId>xstream</artifactId>
<version>1.3.1</version>
<version>1.4.20</version>
<optional>true</optional>
</dependency>

Expand All @@ -87,7 +101,7 @@
<dependency>
<groupId>org.eclipse.jetty.aggregate</groupId>
<artifactId>jetty-all-server</artifactId>
<version>7.1.6.v20100715</version>
<version>8.2.0.v20160908</version>
<scope>test</scope>
</dependency>
<dependency>
Expand Down Expand Up @@ -177,5 +191,13 @@
</plugin>
</plugins>
</build>

<distributionManagement>
<repository>
<id>clojars</id>
<name>Clojars repository</name>
<url>https://clojars.org/repo</url>
</repository>
</distributionManagement>

</project>
Original file line number Diff line number Diff line change
Expand Up @@ -178,17 +178,10 @@ public void run() {
}

public boolean offer(StompFrame frame) {
return this.offer(frame, true);
}

public boolean offer(StompFrame frame, boolean addContentLength) {
getDispatchQueue().assertExecuting();
if( this.transport.full() ) {
return false;
} else {
if( addContentLength && SEND.equals(frame.action()) ) {
frame.addContentLengthHeader();
}
return this.transport.offer(frame);
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -194,10 +194,6 @@ public void write(DataOutput out) throws IOException {
write(out, true);
}

public void addContentLengthHeader() {
addHeader(CONTENT_LENGTH, new AsciiBuffer(Integer.toString(content.length())));
}

public int size() {
int rc = action.length() + 1;
if( headerList!=null ) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@

import org.fusesource.hawtbuf.AsciiBuffer;

import javax.jms.JMSException;
import jakarta.jms.JMSException;
import java.util.Map;

import static org.fusesource.stomp.client.Constants.*;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,9 @@
import org.fusesource.hawtbuf.Buffer;
import org.fusesource.stomp.codec.StompFrame;

import javax.jms.JMSException;
import javax.jms.TemporaryQueue;
import javax.jms.TemporaryTopic;
import jakarta.jms.JMSException;
import jakarta.jms.TemporaryQueue;
import jakarta.jms.TemporaryTopic;

import java.util.Map;
import java.util.UUID;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@

import java.util.Map;

import javax.jms.JMSException;
import jakarta.jms.JMSException;

import org.fusesource.hawtbuf.AsciiBuffer;
import org.fusesource.stomp.codec.StompFrame;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,8 @@
import java.util.concurrent.atomic.AtomicBoolean;
import java.util.concurrent.atomic.AtomicInteger;

import javax.jms.ExceptionListener;
import javax.jms.JMSException;
import jakarta.jms.ExceptionListener;
import jakarta.jms.JMSException;
import javax.net.ssl.SSLContext;

import org.fusesource.hawtbuf.AsciiBuffer;
Expand All @@ -53,6 +53,7 @@
import org.fusesource.stomp.client.Stomp;
import org.fusesource.stomp.codec.StompFrame;
import org.fusesource.stomp.jms.message.StompJmsMessage;
import org.fusesource.stomp.jms.message.StompJmsTextMessage;
import org.fusesource.stomp.jms.util.StompTranslator;

public class StompChannel {
Expand Down Expand Up @@ -215,7 +216,9 @@ public void sendMessage(StompJmsMessage copy, AsciiBuffer txid, boolean sync) th
copy.onSend();
StompFrame frame = copy.getFrame();
frame.action(SEND);
frame.headerMap().put(CONTENT_LENGTH, new AsciiBuffer(Integer.toString(frame.content().length)));
if (!(copy instanceof StompJmsTextMessage)) {
frame.headerMap().put(CONTENT_LENGTH, new AsciiBuffer(Integer.toString(frame.content().length)));
}
if (txid != null) {
frame.headerMap().put(TRANSACTION, txid);
}
Expand Down
Loading