tickerProvider.setOnTickerArrivalListener(ticks -> { if (ticks.isEmpty()) { log.warn("No ticks are being received currently."); } tickerProcessor.process(ticks); });
I am getting empty ticks (The ticker connection is subscribed for valid instruments) and also on create/update order, I am not receiving order updates.
logs for above code:
2022-08-22 21:21:36.327 INFO 16851 --- [ ReadingThread] c.k.s.clients.KiteTickerProvider : Ticker connection established for 64458 instruments. 2022-08-22 21:21:37.619 WARN 16851 --- [ ReadingThread] c.k.s.clients.KiteTickerProvider : No ticks are being received currently. 2022-08-22 21:21:40.617 WARN 16851 --- [ ReadingThread] c.k.s.clients.KiteTickerProvider : No ticks are being received currently.
I haven't changed any code since 12 aug (last time it was working fine).
Thank you Srijan. This was very helpful. The error was like you mentioned. Because of large size of instruments, the message size was big and so the connection was terminating.
You should always post the error you are getting.
How can anyone help you without it??
logs for above code:
I haven't changed any code since 12 aug (last time it was working fine).
You have to check for error under on error callback:
https://github.com/zerodha/javakiteconnect/blob/836822ba12a43fe695d9b6e7ce36c437c09f3e42/sample/src/Examples.java#L584
Or,run javakiteconnect with debug logs on and paste the logs .
Make sure to hide your app details.
Also,are you actually subscribing to 64458 instruments??
Only 3000 per websocket connection are allowed.