I have configured a couple of transforms in the past and now looking at the log I am getting these lines:
2024-05-21 12:47:30.664 [WARN ] [t.generic.ChannelStateTransformation] - Executing the JSONPATH-transformation failed: An error occurred while transforming JSON expression.
2024-05-21 12:47:30.665 [WARN ] [t.generic.ChannelStateTransformation] - Executing the JSONPATH-transformation failed: An error occurred while transforming JSON expression.
2024-05-21 12:47:30.665 [WARN ] [t.generic.ChannelStateTransformation] - Executing the JSONPATH-transformation failed: An error occurred while transforming JSON expression.
2024-05-21 12:47:30.665 [WARN ] [t.generic.ChannelStateTransformation] - Executing the JSONPATH-transformation failed: An error occurred while transforming JSON expression.
But I have no idea what the problem is. How can I enable a debug log option in Karaf (or similar) where I can see which channel this is on? Or what value is the problem happening on?
Any help is much appreciated.
A couple of transformations I have in some things:
Based on the timing of the warnings I would conclude the following…
It’s coming from a single MQTT Thing. MQTT because I think that’s the only place where generic would be in the package name. Single because you have four warnings within a millisecond which implies all four are coming from a single JSON message being processed by four different Channels with four different JSONPATHs.
If that’s not enough to narrow it down, I recommend putting the MQTT binding into DEBUG level logging and see which message received happens almost immediately before the warnings. That should help you narrow down to the specific Thing and tell you what’s up with the JSON to make it not work with those JSONPATHs.
You can change the logging level of the MQTT binding under Settings → Add-on Settnigs → MQTT Binding (you might need to click “show all”).
The additional logging is merged. But the reporter is on 3.4.4.
Unless you can create a JAR that is 3.4.4 compatible, i guess @ralfonat needs to update to 4.2 snapshot to check.
Please remove the .txt extension - it’s there just so I can upload the file. Place this file in your addons folder, and disable the other addon that has the same name.
To do this, go to karaf console, and type
list -s | grep mqtt.generic
You’ll see a list of bundles, note the bundle id number.
stop the original bundle and make sure the snapshot bundle is started.
Sorry for a non-information post, but I just want to express my sincere thanks for these quick, extremely helpful replies @jimtng@rlkoshak@lsiepel . I am really blown away. THANKS!
I will try and replace the addons and test it out and post the results.