webCoRE built-in on Hubitat - Do I need to transition and how?

As many have heard announcement, Hubitat is building webCoRE into their image.

  • I will use this wiki to update folks on integration status and options they have.

  • Current update: January 3, 2023


What does this mean?

For new installs, installing from the built in version is much easier. (If installing a new instance this is recommended)

  • you select HE Console -> apps -> "Add Built-in App" and scroll down to webCoRE

  • the app will automatically update as Hubibat releases new images and you install them.

  • when moving from SmartThings to HE, note 2 of this thread has information on piston backup and import steps.


FAQ:


Can I have both user installed webCoRE and built-in install webCoRE on the same hub at the same time?

  • YES

Are there code differences between the two versions?

  • in general no (if you regularly update your HE firmware or HPM update webCoRE). It is possible the user installed will get new updates first for testing, but they will regularly go into the HE image

What about existing installs?

  • First you don't have to do anything. You continue to HPM update the code, everything keeps working.

    • In the near term this may be easiest for you

If I wanted to convert, what are the pros/cons?
  • At this time (December 2022)

    • the pro would be the automatic updates

    • the cons would be:

      • you have to move all your pistons from the user installed webCoRE instance to the built-in install webCoRE.

        • this would be the backup/restore or import piston methods you may have used when you initially deployed webCoRE on you HE hub.

        • this will also mean

          • resetting up graphs, and LTS if you use them

          • recreating webCoRE global variables

        • we are discussing ways to make this conversion easier, but I do not have a timeline or details at this time

      • Another issue is during this conversion, you are likely to have the account identifier changed (built-in webCoRE defaults to HE hash account identifier)

        • The nasty part here is your existing online (non file) backups would be inaccessible. (you can still backup to a local file via webCoRE IDE, and restore from the local file).

        • This also affects piston references (between pistons, and other apps or API access to pistons)


Will there be easier ways to convert from user app to built-in app?

  • these are being discussed but I don't have a timeline to share at this time

Are there downsides to having both user-app and built-in app installed at the same time?

  • at a high level no issues.

    • but in details there are things to keep in mind

      • you now have two webCoRE instances to use when working in the IDE

      • there are two copies of code consuming HE memory

      • Likely these two instances have different account identifiers, which can complicate backup access and having the single IDE reference both instances.


If I do not deploy the built-in app, is it consuming memory? or CPU?

  • NO, and NO

    • if you do not create an instance of the built-in app, it will not be consume memory

      • HE loads applications if they are used (ie they exist under HE console -> apps)

What about the webCoRE servers (dashboard.webcore.co, staging.webcore.co)?

  • updates continue to be incorporated into them

  • these are being discussed for transition

  • in the near term no changes are occuring


So what is recommended:

  • New installs should use the built-in deployment method

  • Existing installs can stay the way they are now

    • you can convert yourself if you want

    • we are likely to have an easier way sometime in the future

30 Likes

So How to Backup all your pistons to a backup file (via the webCoRE IDE)

THIS IS NOT TRYING TO ENCOURAGE YOU to transition from user install webCoRE on HE to built-in install at this time.

  • We still want to provide a more seamless experience than below...

If you are moving from SmartThings to HE, this is likely the procedure you should use.


Using dashboard or staging IDE site, connect to the instance you want to backup:

Select Backup Piston(s)

Screenshot 2023-01-02 at 6.03.40 PM


Select the pistons you want to include in the backup file:


Enter password to protect the backup file (can leave it blank if you like)


Restore workflow

This is not a one-click import, by any means. webCoRE code is organized in a way that requires certain actions to occur on certain screens. I don’t think that is a bad thing for a big operation like restoring all of your pistons, but you will need to review imported pistons.

Here is the basic workflow:

  1. Upload backup file (it doesn’t actually upload anywhere, this is all in-browser)
  2. Unlock the backup file with the password used to create it (not account password)
  3. webCoRE shows a list of all pistons in the file, sorted by “safest” to import
  4. Click Import to add a single piston
  5. webCoRE creates the piston and redirects to the editor
  6. Editor shows the piston code with any Execute Piston actions mapped to the new imported piston IDs
    • Pistons that use Execute Piston should always appear last in the “safest” sort order; the mapping will not work if the callee piston has not yet been imported
  7. Review and save the piston
  8. Adjust piston name and category if necessary
  9. Resume piston now or later (all imported pistons are automatically paused to prevent mid-import mayhem)
  10. Click “continue import” in the banner on the piston page
  11. Import list appears again, piston you just imported is moved to the bottom of the list
  12. Repeat steps 4-11 as necessary
  13. Click X to ignore pistons that you don’t want to import (just removes them from the local import data)
  14. Click New Import to reset all of the import data (not the imported pistons, just the local data from the import file)

To Restore pistons(s), webCoRE will run you thru a dialog

Select + New Piston (on the left)

  • Select Import a piston from a backup file
  • Choose the file
    • input the password for the file

webCoRE will begin a dialog allow to select which pistons in the file to restore


The default sort encourages you to restore the “safest” pistons first but you can also sort by name, created date, last modified, or category. Unfortunately we don’t have category names in the backup file, just numbers. The screen shows warnings for pistons that:

  • Use global variables, here are HE variable details, because you may want to create global or hub variables before importing those pistons
  • Have tiles, because you probably need to configure a category for any piston that will show tiles
  • Requires IFTTT to be configured
  • Expects arguments, because it is likely to be called by another piston or remotely executed by URL
  • Has devices in expressions like [Hallway Light: switch] , just in case you need to update them
  • Use the Execute Piston command since the dashboard can only update to your new piston IDs if the corresponding piston has already been imported

When a piston is imported it moves to the bottom of the list so that you can always restore the topmost piston. You can view the imported piston from this screen or restore another copy. When the import file is loaded, any pistons with identical name are indicated as imported.

Any Execute Piston actions are automatically updated to the new piston ID if you have already imported the target piston.

This feature is primarily useful for transferring pistons to a new webCoRE instance on the same account (i.e. same platform and devices) as an alternative to private backup bin codes which cannot be accessed on a different instance.


There are desired improvements (that do not exist):

  • The ability to copy over global variables and categories and globally replace devices would be convenient for significant changes

  • the import will save time over manually recreating pistons, but you’ll still have a lot of work to manually update all devices and settings.


Here is a more complicated screen view if a lot of pistons:


Again - we expect to have a simpler migration from user app to built-in app in the future (ie you already are using webCoRE on the HE system).

1 Like

This is the greatest app I've ever used. Thank you.

3 Likes

Yes I'm a HUGE Webcore fan, coming from ST. I've never even installed the Rules Engine because I liked webcore so much.

3 Likes

Thanks for the post it’s very helpful :+1:

1 Like

Doesn't show up on my list.
Any idea why?

Have you updated your hub to the latest version?

I’ve just updated my firmware, the webcore ap was mentioned on the release notes, but I don’t see it in the list if build in apps to install.
I’m hoping for an easy migration option, having just migrated all my pistons from ST, and not too keen to do it again!
A potential downside of the built in app in less ability to debug. I initially had a few issues with WC on HE, and with assistance from the WC gurus, debug options could be enabled to help resolve the issues.

New apps are lazy loaded after the update and may take a few minutes to become available. Give it 15-30 minutes and look again…

2 Likes

I’ve just checked the apps again, and its appeared.

I’m staying with my HPM install at the moment, but will be watching this with interest, This is a great step for HE & WC, and will hopefully increase the number of users of WC.

I've tried - it just sits there uselessly "spinning" doing nothing.

Currently on 2.3.4.117.

Tried on Safari and Firefox.

Just looked - still not there.

Shouldn’t need to, but some folks have reported that they had to reboot to see it…

Update to the latest platform, reboot and it will be there

1 Like

WebCoRE was added in platform version 2.3.4.127 a couple days ago.

2 Likes

This likely means your hub is not connected to Hubitat’s cloud. Did you give your hub a static IP?

1 Like

I think I messed up the transition from my previous version of webcore to this new built in version. I seem to have multiple instances as shown below. How do I get rid of those highlighted?

Thanks.

i would not do anything rash

one of your instances may have all your pistons, the other may have none

1 Like

So, with the Theme of HE being a Local enviroment, and I understand that the pistons run local no matter what, . What if I do not have Internet and I want to edit a piston.

Will there be a local Webserver at any point, or can I perhaps install an app on a PC that can act as my server on a local only connection.

I guess, if Webcore goes belly up (And YES I know that its open source, and there is almost no chance of that happening) but I'd like to know more out of curiosity.

Try here:

1 Like