eclipse-archived / smarthome

Eclipse SmartHome™ project
https://www.eclipse.org/smarthome/
Eclipse Public License 2.0
862 stars 787 forks source link

[TRANSFORM] use precompiled JavaScript for faster transformation #6793

Closed THKDev closed 5 years ago

THKDev commented 5 years ago

On an ARM machine transformation by JavaScript takes ~15 seconds each time. To speed up this a little bit, each JavaScript file will be pre compiled and cached. This reduces the time of transformation to ~500ms. First call of each JavaScript still takes ~15 seconds. each further call needs then ~500ms. Transformation directory will be observed for file changes and the cache will be refreshed.

This implementation is similar to org.eclipse.smarthome.automation.module.script

maggu2810 commented 5 years ago

@THKDev I realized you missed to add a Signed-off-by footer. Please have a look at the contribution guidelines.

kaikreuzer commented 5 years ago

@THKDev Please ping us once you have addressed the comments, I'd love to merge this!

THKDev commented 5 years ago

@kaikreuzer Last remarks edited.

THKDev commented 5 years ago

@maggu2810 toString() removed.

kaikreuzer commented 5 years ago

@maggu2810 Are all your comments addressed?

maggu2810 commented 5 years ago

The "ECA Validation Tool" tells me that thkdev@protonmail.com is an unknown user.

kaikreuzer commented 5 years ago

@THKDev Please see https://github.com/eclipse/smarthome/blob/master/CONTRIBUTING.md#legal-considerations how to sign the ECA - thanks!

THKDev commented 5 years ago

@kaikreuzer Done.