My manually patched system has been running the new jar for 47 hours. Everything seems to be fine, no log errors or obvious memory leaks. A big thank you to the community for solving the issue.
In case it helps another user, I’ll share my installation instructions.
I’m running openHAB 2.4.0 (build #1412) on a RaspberryPi. It was using a manually installed amazonechocontrol_2.5.0.Beta_07_Preview_1 jar binding at the time of the Web Socket incident. That is to say, long ago the default binding had been unistalled from PaperUI and I installed the “preview” version in the addons folder.
My instructions are intended for other users with a similar OpenHab 2.4 installation that do NOT use the extra features found in the “Beta” Preview release (an updated beta release is not available at this time). Do not use these instructions on OpenHab 2.5 (hint: perform a system upgrade instead).
IMPORTANT: Create a image backup of your system BEFORE making any changes.
1. Stop the OpenHAB2 service (be patient, takes a couple minutes):
sudo systemctl stop openhab2.service
2. Copy the new echo control binding into the /usr/share/openhab2/addons folder
Use the latest amazonechocontrol-2.5.6-SNAPSHOT jar file:
https://openhab.jfrog.io/openhab/libs-pullrequest-local/org/openhab/addons/bundles/org.openhab.binding.amazonechocontrol/2.5.6-SNAPSHOT/
NOTE: I highly recommend renaming the jar file to match the old file name. This prevents duplicate bindings from running.
3. Clear OpenHAB2's cache:
sudo openhab-cli clean-cache
4. Restart OpenHAB2
sudo systemctl restart openhab2.service
5. Start OpenHAB2's Console CLI:
openhab-cli console
6. Install the updated Gson 2.8.5 library jar file:
bundle:install https://repo1.maven.org/maven2/com/google/code/gson/gson/2.8.5/gson-2.8.5.jar
7. Wait a couple minutes for the new Gson to refresh the echo devices.
8. Use the list command to confirm that the new Gson is listed as "Installed" or "Resolved".
list | grep -i gson
You will still see the old Gson as active. This appears to be normal, so don't worry.
It will report something similar to this:
21 x Active x 80 x 2.7.0.v20170129-0911 x Gson: Google Json Library for Java
234 x Resolved x 80 x 2.8.5 x Gson
9. Go to OpenHAB's amazonechocontrol account web page (replace <> parameters with your details):
http://<IPADDRESS>:8080/amazonechocontrol/<ACCOUNT_NAME>
Confirm the echo devices are online.
10. Test the system and confirm echo control features are operational. Done.
-Thomas
EDIT: Updated link to jar file.
EDIT: Added comment regarding OpenHab 2.5.