activemq-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Jamie G." <jamie.goody...@gmail.com>
Subject Re: how to unsubscribe a frame using apache apollo?
Date Mon, 20 Apr 2015 13:28:18 GMT
Here's a brief sample code:

Stomp stomp = new Stomp("localhost", 61613);

Future<FutureConnection> future = stomp.connectFuture();

FutureConnection connection = future.await();

AsciiBuffer id = connection.nextId();

StompFrame unsubscribe = new StompFrame(UNSUBSCRIBE);

unsubscribe.addHeader(ID, id);

Future<Void> unsubscribeFuture = connection.send(unsubscribe);

unsubscribeFuture.await();


It might be missing some steps - but should contain most of the basics.

Cheers,
Jamie

On Sun, Apr 19, 2015 at 11:16 PM, 刘焕 <liuhuan2002767@126.com> wrote:
> I want to send a stomp frame in order to unsubscribe a certain topic. By reading documents,
I find it possible via sending a "UNSUBSCRIBE"stomp frame ,but I don't how to achieve it 
by programming in JAVA.What should I do?
> Thank you!
>
>
> (I'm a Chinese.So,I am not good at English.)

Mime
View raw message