albauer
(Alexander Bauer)
December 4, 2020, 10:22am
1
Hi,
I am using OH3 M4.
The Unifi Binding throws an “java.lang.IllegalArgumentException” and is not working “COMM:ERROR”.
Error:
Unhandled exception while refreshing the UniFi Controller unifi:controller:bauers - java.lang.IllegalArgumentException: Buffering capacity 2097152 exceeded
Unifi Controller: 6.0.41 (Build: atag_6.0.41_14327)
Compacting controllers database didn’t solve the issue.
Any ideas?
Alexander
Dibbler42
(Thomas Bail)
December 4, 2020, 11:05am
2
Could you post your configuration, since i updated to 6..0.4? controller i didi not get any connection.
albauer
(Alexander Bauer)
December 4, 2020, 11:56am
3
@Dibbler42
Thing is configured in textfile “unifi.things”:
Bridge unifi:controller:bauers "UniFi Controller" @ "Unifi" [ host="172.20.1.20", port=8443, username="xxxxx", password="yyyy", refresh=10 ] {
Thing client OnePlus2_Alexander "Alexander OnePlus2 Private" [ mac="c0:ee:xx:xx:xx:xx", considerHome=180 ]
}
Unifi controller can be reached from machine running openhab:
PING 172.20.1.20 (172.20.1.20) 56(84) bytes of data.
64 bytes from 172.20.1.20: icmp_seq=1 ttl=63 time=4.11 ms
64 bytes from 172.20.1.20: icmp_seq=2 ttl=63 time=4.04 ms
Alexander
Dibbler42
(Thomas Bail)
December 4, 2020, 12:45pm
4
Thanks for the configuration. Mine is of the same kind so that seams not the problem.
Controller is reachable, but
And no information in the logs. I will try that again with debug loglevel
Seaside
(Seaside)
December 4, 2020, 12:49pm
5
For cloudkey unifi os is a big change with firmware.2.0.18 and above. I have fixed this for the unifiprotect binding, see details here:
opened 04:51PM - 18 Mar 20 UTC
bug
Discussed here:
https://community.openhab.org/t/ubiquiti-unifi-binding-featur… e-discussion/14520/1013?u=mgbowman
Dibbler42
(Thomas Bail)
December 4, 2020, 1:20pm
6
That is maybe the reason. Is there a development build og the binding to test thing. I run Cloud Key 2 plus with 2.0.22 an controller 6.041
albauer
(Alexander Bauer)
December 4, 2020, 1:26pm
7
Hi,
I’m not using UDM/ UDM-Pro or CloudKey. My controller “lives” in his own VM.
Interestingly it woks on my OH 2.5 installation …
Just saw, that an issue has been filed:
opened 09:59PM - 05 Nov 20 UTC
bug
Hi,
I have been unable to use your binding for a while due to the error below… :
`21:54:33.763 [WARN ] [l.handler.UniFiControllerThingHandler] - Unhandled exception while refreshing the UniFi Controller unifi:controller:home - java.lang.IllegalArgumentException: Buffering capacity 2097152 exceeded
`
When I restart the binding I get this error and it continues in line with the polling frequency.
I have around 200 devices on my network.
Running latest UniFi versions and OH 2.5.9
Is there a work around or a way your binding car query just for known mac rather than all?
Seems to be equivalent/ possible same root cause:
opened 03:29PM - 05 Feb 20 UTC
closed 08:54AM - 26 Apr 20 UTC
bug
I am trying to connect openhab to my homematic setup (>100 HmIP Devices).
When… i started with less devices it worked just fine, but now i cannot add any(thing).
In the openhab events.log it tells me the device serial is not found on the gateway:
2020-02-05 16:20:03.830 [WARN ] [ernal.handler.HomematicBridgeHandler] - Device with address '[SERIAL]' not found on gateway 'CCU3'
Restarting the openhab2 service it throws the following error, which i think is the issue:
2020-02-05 16:20:03.810 [ERROR] [very.HomematicDeviceDiscoveryService] - java.lang.IllegalArgumentException: Buffering capacity 2097152 exceeded
java.io.IOException: java.lang.IllegalArgumentException: Buffering capacity 2097152 exceeded
at org.openhab.binding.homematic.internal.communicator.client.XmlRpcClient.sendMessage(XmlRpcClient.java:98) ~[?:?]
at org.openhab.binding.homematic.internal.communicator.client.XmlRpcClient.sendMessage(XmlRpcClient.java:102) ~[?:?]
at org.openhab.binding.homematic.internal.communicator.client.XmlRpcClient.sendMessage(XmlRpcClient.java:67) ~[?:?]
at org.openhab.binding.homematic.internal.communicator.client.RpcClient.listDevices(RpcClient.java:168) ~[?:?]
at org.openhab.binding.homematic.internal.communicator.AbstractHomematicGateway.getDeviceDescriptions(AbstractHomematicGateway.java:448) ~[?:?]
at org.openhab.binding.homematic.internal.communicator.AbstractHomematicGateway.loadAllDeviceMetadata(AbstractHomematicGateway.java:372) ~[?:?]
at org.openhab.binding.homematic.internal.discovery.HomematicDeviceDiscoveryService.lambda$0(HomematicDeviceDiscoveryService.java:210) ~[?:?]
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [?:1.8.0_232]
at java.util.concurrent.FutureTask.run(FutureTask.java:266) [?:1.8.0_232]
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:180) [?:1.8.0_232]
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:293) [?:1.8.0_232]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:1.8.0_232]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:1.8.0_232]
at java.lang.Thread.run(Thread.java:748) [?:1.8.0_232]
Caused by: java.util.concurrent.ExecutionException: java.lang.IllegalArgumentException: Buffering capacity 2097152 exceeded
at org.eclipse.jetty.client.util.FutureResponseListener.getResult(FutureResponseListener.java:118) ~[?:?]
at org.eclipse.jetty.client.util.FutureResponseListener.get(FutureResponseListener.java:101) ~[?:?]
at org.eclipse.jetty.client.HttpRequest.send(HttpRequest.java:685) ~[?:?]
at org.openhab.binding.homematic.internal.communicator.client.XmlRpcClient.sendMessage(XmlRpcClient.java:84) ~[?:?]
... 13 more
Caused by: java.lang.IllegalArgumentException: Buffering capacity 2097152 exceeded
at org.eclipse.jetty.client.util.BufferingResponseListener.onHeaders(BufferingResponseListener.java:83) ~[?:?]
at org.eclipse.jetty.client.ResponseNotifier.notifyHeaders(ResponseNotifier.java:98) ~[?:?]
at org.eclipse.jetty.client.ResponseNotifier.notifyHeaders(ResponseNotifier.java:90) ~[?:?]
at org.eclipse.jetty.client.HttpReceiver.responseHeaders(HttpReceiver.java:269) ~[?:?]
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.headerComplete(HttpReceiverOverHTTP.java:256) ~[?:?]
at org.eclipse.jetty.http.HttpParser.parseFields(HttpParser.java:1192) ~[?:?]
at org.eclipse.jetty.http.HttpParser.parseNext(HttpParser.java:1475) ~[?:?]
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.parse(HttpReceiverOverHTTP.java:172) ~[?:?]
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.process(HttpReceiverOverHTTP.java:135) ~[?:?]
at org.eclipse.jetty.client.http.HttpReceiverOverHTTP.receive(HttpReceiverOverHTTP.java:73) ~[?:?]
at org.eclipse.jetty.client.http.HttpChannelOverHTTP.receive(HttpChannelOverHTTP.java:133) ~[?:?]
at org.eclipse.jetty.client.http.HttpConnectionOverHTTP.onFillable(HttpConnectionOverHTTP.java:154) ~[?:?]
at org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(AbstractConnection.java:311) ~[?:?]
at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:103) ~[?:?]
at org.eclipse.jetty.io.ChannelEndPoint$2.run(ChannelEndPoint.java:117) ~[?:?]
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.runTask(EatWhatYouKill.java:336) ~[?:?]
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.doProduce(EatWhatYouKill.java:313) ~[?:?]
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.tryProduce(EatWhatYouKill.java:171) ~[?:?]
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.run(EatWhatYouKill.java:129) ~[?:?]
at org.eclipse.jetty.util.thread.ReservedThreadExecutor$ReservedThread.run(ReservedThreadExecutor.java:367) ~[?:?]
at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:782) ~[?:?]
at org.eclipse.jetty.util.thread.QueuedThreadPool$Runner.run(QueuedThreadPool.java:918) ~[?:?]
... 1 more
I've read there is i fixed buffer limit of 2MB within java which might cause this. I believe jetty is invoked by the discovery service to query the CCU3 for its devices but the response is too big to fit the buffer, so it just crashes.
If i only add the CCU to my things file and nothing else, it works just fine.
Is there anything that can be done to this? I found some hints for jetty on setting a larger buffer size, but i don't know how this can be done with openhab.
Best regards
Andreas
and proposed solution here:
java, jetty, jetty-9
Alexander