You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@bookkeeper.apache.org by suman p <su...@gmail.com> on 2013/01/03 12:15:58 UTC
COMPOSITE exception
Hello,
I am doing samples using hedwig. I am trying to create a subscription for
a topic using following code.
HedWigClient client = new HedwigClient(conf)
Subscriber sub = client.getSubscriber()
if(!sub.hasSubscription(topic, subscription)) {
sub.subscriber(topic, subscription, CreateOrAttach.CREATE_OR_ATTACH)
}
I am getting following exception. I looked at source code, but not able to
understand under what conditions hedwig server throws "COMPOSITE"
exception as shown below. Can some please help in understanding the issue.
org.apache.hedwig.exceptions.PubSubException$ServiceDownException: Server
responded with a status code of: COMPOSITE
at
org.apache.hedwig.client.handlers.SubscribeResponseHandler.handleSubscribeResponse(SubscribeResponseHandler.java:158)
at
org.apache.hedwig.client.netty.ResponseHandler.messageReceived(ResponseHandler.java:158)
at
org.jboss.netty.channel.SimpleChannelHandler.handleUpstream(SimpleChannelHandler.java:100)
at
org.jboss.netty.channel.DefaultChannelPipeline.sendUpstream(DefaultChannelPipeline.java:545)
at
org.jboss.netty.channel.DefaultChannelPipeline$DefaultChannelHandlerContext.sendUpstream(DefaultChannelPipeline.java:754)
at
org.jboss.netty.channel.Channels.fireMessageReceived(Channels.java:302)
at
org.jboss.netty.handler.codec.oneone.OneToOneDecoder.handleUpstream(OneToOneDecoder.java:76)
at
org.jboss.netty.channel.DefaultChannelPipeline.sendUpstream(DefaultChannelPipeline.java:545)
at
org.jboss.netty.channel.DefaultChannelPipeline$DefaultChannelHandlerContext.sendUpstream(DefaultChannelPipeline.java:754)
at
org.jboss.netty.channel.Channels.fireMessageReceived(Channels.java:302)
at
org.jboss.netty.handler.codec.frame.FrameDecoder.unfoldAndFireMessageReceived(FrameDecoder.java:317)
at
org.jboss.netty.handler.codec.frame.FrameDecoder.callDecode(FrameDecoder.java:299)
at
org.jboss.netty.handler.codec.frame.FrameDecoder.messageReceived(FrameDecoder.java:216)
at
org.jboss.netty.channel.SimpleChannelUpstreamHandler.handleUpstream(SimpleChannelUpstreamHandler.java:80)
at
org.jboss.netty.channel.DefaultChannelPipeline.sendUpstream(DefaultChannelPipeline.java:545)
at
org.jboss.netty.channel.DefaultChannelPipeline.sendUpstream(DefaultChannelPipeline.java:540)
at
org.jboss.netty.channel.Channels.fireMessageReceived(Channels.java:274)
at
org.jboss.netty.channel.Channels.fireMessageReceived(Channels.java:261)
at
org.jboss.netty.channel.socket.nio.NioWorker.read(NioWorker.java:349)
at
org.jboss.netty.channel.socket.nio.NioWorker.processSelectedKeys(NioWorker.java:280)
at
org.jboss.netty.channel.socket.nio.NioWorker.run(NioWorker.java:200)
at
org.jboss.netty.util.ThreadRenamingRunnable.run(ThreadRenamingRunnable.java:108)
at
org.jboss.netty.util.internal.DeadLockProofWorker$1.run(DeadLockProofWorker.java:44)
at
java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
at java.lang.Thread.run(Thread.java:619)
Regards,
Suman
Re: COMPOSITE exception
Posted by suman p <su...@gmail.com>.
Thanks for the update, I am looking forward for the 4.2.0 release
Regards,
Suman
On 5 January 2013 01:30, Sijie Guo <gu...@gmail.com> wrote:
> Suman,
>
> there is a JIRA already resolve the CompositeException into meaningful
> output : https://issues.apache.org/jira/browse/BOOKKEEPER-394
>
> This fix would be rolled out in 4.2.0 release recently.
>
> -Sijie
>
>
> On Fri, Jan 4, 2013 at 4:32 AM, suman p <su...@gmail.com> wrote:
>
>> Ok, i figured out the issue. One of my book keeper server is down (i
>> have only 3 book keeper servers), so hedwig is failing with the Message
>> "Not enough book keepers", but the client side error message i am getting is
>>
>> org.apache.hedwig.exceptions.PubSubException$ServiceDownException:
>> Server responded with a status code of: COMPOSITE.
>>
>> Above error message on client side is really misleading.
>>
>> BTW, i am using release-4.1.0, when is the next release scheduled??
>>
>> Regards,
>> Suman
>>
>>
>> On 3 January 2013 23:53, Ivan Kelly <iv...@apache.org> wrote:
>>
>>> Hi suman,
>>>
>>> What version of hedwig is this? trunk? What do the logs say? You
>>> should find them in hedwig-server/logs if you are using trunk and
>>> start the server with hedwig-daemon.sh, otherwise they should be
>>> printed to the console.
>>>
>>> -Ivan
>>>
>>>
>>> > HedWigClient client = new HedwigClient(conf)
>>> >
>>> > Subscriber sub = client.getSubscriber()
>>> >
>>> > if(!sub.hasSubscription(topic, subscription)) {
>>> > sub.subscriber(topic, subscription, CreateOrAttach.CREATE_OR_ATTACH)
>>> > }
>>>
>>>
>>
>
Re: COMPOSITE exception
Posted by Sijie Guo <gu...@gmail.com>.
Suman,
there is a JIRA already resolve the CompositeException into meaningful
output : https://issues.apache.org/jira/browse/BOOKKEEPER-394
This fix would be rolled out in 4.2.0 release recently.
-Sijie
On Fri, Jan 4, 2013 at 4:32 AM, suman p <su...@gmail.com> wrote:
> Ok, i figured out the issue. One of my book keeper server is down (i have
> only 3 book keeper servers), so hedwig is failing with the Message "Not
> enough book keepers", but the client side error message i am getting is
>
> org.apache.hedwig.exceptions.PubSubException$ServiceDownException: Server
> responded with a status code of: COMPOSITE.
>
> Above error message on client side is really misleading.
>
> BTW, i am using release-4.1.0, when is the next release scheduled??
>
> Regards,
> Suman
>
>
> On 3 January 2013 23:53, Ivan Kelly <iv...@apache.org> wrote:
>
>> Hi suman,
>>
>> What version of hedwig is this? trunk? What do the logs say? You
>> should find them in hedwig-server/logs if you are using trunk and
>> start the server with hedwig-daemon.sh, otherwise they should be
>> printed to the console.
>>
>> -Ivan
>>
>>
>> > HedWigClient client = new HedwigClient(conf)
>> >
>> > Subscriber sub = client.getSubscriber()
>> >
>> > if(!sub.hasSubscription(topic, subscription)) {
>> > sub.subscriber(topic, subscription, CreateOrAttach.CREATE_OR_ATTACH)
>> > }
>>
>>
>
Re: COMPOSITE exception
Posted by Flavio Junqueira <fp...@yahoo.com>.
Hi Suman,
According to the queue of issues for 4.2.0, we should be able to have 4.2.0 out soon. We have currently 4 issues left to resolve:
https://issues.apache.org/jira/browse/BOOKKEEPER/fixforversion/12320244
-Flavio
On Jan 4, 2013, at 1:32 PM, suman p <su...@gmail.com> wrote:
> Ok, i figured out the issue. One of my book keeper server is down (i have only 3 book keeper servers), so hedwig is failing with the Message "Not enough book keepers", but the client side error message i am getting is
>
> org.apache.hedwig.exceptions.PubSubException$ServiceDownException: Server responded with a status code of: COMPOSITE.
>
> Above error message on client side is really misleading.
>
> BTW, i am using release-4.1.0, when is the next release scheduled??
>
> Regards,
> Suman
>
>
> On 3 January 2013 23:53, Ivan Kelly <iv...@apache.org> wrote:
> Hi suman,
>
> What version of hedwig is this? trunk? What do the logs say? You
> should find them in hedwig-server/logs if you are using trunk and
> start the server with hedwig-daemon.sh, otherwise they should be
> printed to the console.
>
> -Ivan
>
>
> > HedWigClient client = new HedwigClient(conf)
> >
> > Subscriber sub = client.getSubscriber()
> >
> > if(!sub.hasSubscription(topic, subscription)) {
> > sub.subscriber(topic, subscription, CreateOrAttach.CREATE_OR_ATTACH)
> > }
>
>
Re: COMPOSITE exception
Posted by suman p <su...@gmail.com>.
Ok, i figured out the issue. One of my book keeper server is down (i have
only 3 book keeper servers), so hedwig is failing with the Message "Not
enough book keepers", but the client side error message i am getting is
org.apache.hedwig.exceptions.PubSubException$ServiceDownException: Server
responded with a status code of: COMPOSITE.
Above error message on client side is really misleading.
BTW, i am using release-4.1.0, when is the next release scheduled??
Regards,
Suman
On 3 January 2013 23:53, Ivan Kelly <iv...@apache.org> wrote:
> Hi suman,
>
> What version of hedwig is this? trunk? What do the logs say? You
> should find them in hedwig-server/logs if you are using trunk and
> start the server with hedwig-daemon.sh, otherwise they should be
> printed to the console.
>
> -Ivan
>
>
> > HedWigClient client = new HedwigClient(conf)
> >
> > Subscriber sub = client.getSubscriber()
> >
> > if(!sub.hasSubscription(topic, subscription)) {
> > sub.subscriber(topic, subscription, CreateOrAttach.CREATE_OR_ATTACH)
> > }
>
>
Re: COMPOSITE exception
Posted by Ivan Kelly <iv...@apache.org>.
Hi suman,
What version of hedwig is this? trunk? What do the logs say? You
should find them in hedwig-server/logs if you are using trunk and
start the server with hedwig-daemon.sh, otherwise they should be
printed to the console.
-Ivan
> HedWigClient client = new HedwigClient(conf)
>
> Subscriber sub = client.getSubscriber()
>
> if(!sub.hasSubscription(topic, subscription)) {
> sub.subscriber(topic, subscription, CreateOrAttach.CREATE_OR_ATTACH)
> }