Error 500 - Java Null Pointer Exception


Fairly new user of OH2 here… Trying to use the REST API to query my items and getting an Error 500.

The output of is

“error”: {
“http-code”: 500,
“exception”: {
“class”: “java.lang.NullPointerException”

Running the latest apt-get build (openhab2-offline_2.0.0~20161028034017_all.deb) on Raspberry.

Anyone with any ideas why???

Look in your openhab.log file for errors. There might be more information there.

Do you have any Items defined? I could see OH having problems if there are no Items.

Even without items it should not give you a HTTP 500.
The most recent change about the REST API that came to my mind is this, but I have just tested build #558 and the REST API still seems to work well there.
So @Mark_Webster, in any case an HTTP 500 is a bug, so with a log:exception-display on the openHAB console, you should see the full error - if you do, please enter a bug with that stacktrace at, describing a minimal setup required for reproducing your problem. Thanks!

So, just a complete rebuild, (I’m just at the point of simple experimenting at the moment), including re-install of Raspbian Jessie Lite and managed to get the 500 error to occur. I had installed the following through the PaperUI…

JSONPath Transformation
Map Transformation
MQTT Action
Prowl Action
JDBC Persistence MySQL
Astro Binding
MQTT Binding
Network Binding
NTP Binding

And created a number of “Things” using the Astro, Network and NTP binding… Once I’d done this I could see all my items from my items files fine through the PaperUI, including those associated with Things created from these bindings.

I then installed the Samsung TV Binding and ever since that installed and discovered my TV, I’ve been getting the 500 error. I’ve now uninstalled the Samsung TV Binding and deleted all “Things” associated with the binding but I’m still getting the error 500.

I tried doing log:exception-display in the karaf console and then triggering the error but I don’t see any output in karaf… Where should I be looking for that??