Hi, Can someone help on this topic? Thank you Enrico
Il Mer 27 Lug 2016 12:26 Enrico Olivelli - Diennea < enrico.olive...@diennea.com> ha scritto: > Hi, > I'm running Kafka launching KafkaServerStartable inside my JVM (I'm using > version 0.10.0.0). > > I'm accessing the internal KafkaServer field using reflection > Field serverField = kafkaServer.getClass().getDeclaredField("server"); > serverField.setAccessible(true); > KafkaServer server = (KafkaServer) serverField.get(kafkaServer); > byte state = server.brokerState().currentState(); > > What is the best way to ask KafkaServer its state ? > > I see that the 'brokerState' is not very useful > Sometimes the server stops working, for instance due to ZK session > expiration, but the broker remains in RunningAsBroker state. > > Second question ? If it is not possibile to dig into Broker status (and in > fact I would prefer not to do), is there some flag to auto-kill the broker > in case of serious problems (ZK, Disk space....) > > I can send some logs, but I prefer to treat it as a blackbox, as far as it > is possible > > Thank you > > > -- > Enrico Olivelli > Software Development Manager @Diennea > Tel.: (+39) 0546 066100 - Int. 925 > Viale G.Marconi 30/14 - 48018 Faenza (RA) > > MagNews - E-mail Marketing Solutions > http://www.magnews.it > Diennea - Digital Marketing Solutions > http://www.diennea.com > > > ________________________________ > > Iscriviti alla nostra newsletter per rimanere aggiornato su digital ed > email marketing! http://www.magnews.it/newsletter/ > > The information in this email is confidential and may be legally > privileged. If you are not the intended recipient please notify the sender > immediately and destroy this email. Any unauthorized, direct or indirect, > disclosure, copying, storage, distribution or other use is strictly > forbidden. > -- -- Enrico Olivelli