No. You can do it before or after. That doesn’t really matter. They won’t work in 3.4.4 with that mime time and they won’t work in 4.0 until they have that mime type.
Note that the name you used implies you are looking at the marketplace version of the add-on. Be sure you install the official version.
And what has not been mentioned here yet is if you are using the JS Transformation, you should remove it before upgrading. And if you are using the JS Transformtion, the easiest thing to do will be to install both JS Scripting add-ons.
and one more regarding JS Transformation. You mentioned that I should remove it before upgrade to ver 4.0.0.
So, e.g. for all my outgoing JS transformations in my channel configs, for example JS:setLightState.js
I can keep the code, but rename the transformation script to setLightState.nashornjs and then change the channel configuration to NASHORNJS:setLightState.nashornjs. Is this correct?
That’s one option.
Or you can keep the file names and channel configs and just install the GraalVM JS Scripting add-in in addition to the Nashorn JS Scripting add-on. Nashorn JS Transforms are compatible with GraalVM JS Scripting so they will run just fine on the newer version unchanged.
Thanks Rich, I’m now slowly getting an overview of what needs to be done to make the migration to Openhab 4.0.0 as easy as possible.
Also, hopefully your useful marketplace extensions like the Debounce rule will work afterwards as well.
You stated here:
- A Debounce Group created
- All the “raw” Items added to the Debounce Group
- All the “raw” Items have valid “debounce” Item metadata
It feels like there is more to-do’s than former migration from Openhab 2.0 to 3.x.
You should upgrade to the 4.0 version. However that will require the GraalVM add-on to be installed as well as the openhab_rules_tools library to be installed (from the $OH_CONF/automation/js folder run
npm install openhab_rules_tools which is discussed in the readme for the 4.0+ version of the rule template.
All but one of my rule templates have been rewritten for GraalJS.
To upgrade, once you are on OH 4, remove the Debounce rule template, refresh the page (I don’t know if that is for sure required but it wouldn’t hurt) and then add it back. It should only show the 4.0+ version of the template after refreshing the page.
It is not super well tested, but I did go to some effort to make those older versions of the rule template work with both Nashorn and GraalJS. Consequently, as long as you have the JS Scripting add-on installed, the 3.x version of the template should work.
But the rewrite version for 4.0+ is a much better implementation with way better error checking and reporting and takes advantage of all the new stuff in GraalJS which makes the code way simpler and easier to maintain.
Not in my experience. 2->3 had tons and tons of breaking changes and way more of them were user facing. YMMV. But a major version upgrade is always going to be way more work than a minor version update because major breaking changes are only allowed for major version updates.