HEADS-project / training

Training material to get started with the HEADS technologies
10 stars 16 forks source link

Kevoree HelloWord example not working in JS #12

Closed brice-morin closed 9 years ago

brice-morin commented 9 years ago

I think I went through all the steps (using CLI) until the grunt kevoree, and it crashed...

$ grunt kevoree
Running "kevoree" task
>> Platform node name: node0
>> Bootstrap script: kevs\main.kevs
kevoree-nodejs-runtime@5.1.1 node_modules\grunt-kevoree\node_modules\kevoree-nodejs-runtime
├── pseudoclass@1.0.2
├── kevoree-core@6.1.2 (async@0.9.0)
└── optimist@0.6.1 (wordwrap@0.0.2, minimist@0.0.10)
>> Starting runtime: v5.1.1
09:35:13  INFO   KevoreeCore      Platform node name: node0
kevoree-node-javascript@3.0.4 .deploy_units\node0\node_modules\kevoree-node-javascript
├── kevoree-kotlin@1.0.2
├── async@0.9.0
├── pseudoclass@1.0.2
├── kevoree-library@5.0.4
├── kevoree-commons@2.1.0 (chalk@0.4.0)
└── kevoree-entities@5.2.0 (kevoree-kevscript@2.1.4)
09:35:19  ALL    KevoreeLogger    Set logLevel= debug
09:35:19  INFO   KevoreeCore      node0 : JavascriptNode/3.0.4 successfully started
09:35:19  ERROR  KevoreeCore      Deployment failed.
Error: no DeployUnit found for 'sync: WSGroup/5.2.2' that matches the 'javascript' platform
    at Class.processTrace (c:\Users\bmori\dev\heads\tmp\kevTuto\.deploy_units\node0\node_modules\kevoree-node-javasc
\lib\AdaptationEngine.js:140:43)
    at Class.processTraces (c:\Users\bmori\dev\heads\tmp\kevTuto\.deploy_units\node0\node_modules\kevoree-node-javas
t\lib\AdaptationEngine.js:86:25)
    at Class.AbstractNode.extend.processTraces (c:\Users\bmori\dev\heads\tmp\kevTuto\.deploy_units\node0\node_module
voree-node-javascript\lib\JavascriptNode.js:136:38)
    at c:\Users\bmori\dev\heads\tmp\kevTuto\node_modules\grunt-kevoree\node_modules\kevoree-nodejs-runtime\node_modu
kevoree-core\kevoree-core.js:138:65
    at Class.<anonymous> (c:\Users\bmori\dev\heads\tmp\kevTuto\node_modules\grunt-kevoree\node_modules\kevoree-nodej
ntime\node_modules\kevoree-core\kevoree-core.js:332:25)
    at Class.<anonymous> (c:\Users\bmori\dev\heads\tmp\kevTuto\.deploy_units\node0\node_modules\kevoree-node-javascr
lib\JavascriptNode.js:77:13)
    at Class.start [as _super] (c:\Users\bmori\dev\heads\tmp\kevTuto\.deploy_units\node0\node_modules\kevoree-node-j
cript\node_modules\kevoree-entities\lib\KevoreeEntity.js:57:9)
    at Class.AbstractNode.extend.start (c:\Users\bmori\dev\heads\tmp\kevTuto\.deploy_units\node0\node_modules\kevore
de-javascript\lib\JavascriptNode.js:51:14)
    at Class.PseudoClass_setStaticSuper [as start] (c:\Users\bmori\dev\heads\tmp\kevTuto\.deploy_units\node0\node_mo
s\kevoree-node-javascript\node_modules\pseudoclass\source\Class.js:126:19)
    at Class.<anonymous> (c:\Users\bmori\dev\heads\tmp\kevTuto\node_modules\grunt-kevoree\node_modules\kevoree-nodej
ntime\node_modules\kevoree-core\kevoree-core.js:327:35)

Fatal error: "grunt-kevoree" unable to bootstrap platform. Shutting down.
brice-morin commented 9 years ago

Works with the following kevs:

// This file is a default Kevoree Kevscript auto-generated by Yo generator-kevoree package
// Feel free to (and you really should) mess with this script =)
// KevScript documentation http://kevoree.org/doc/#kevoree-script-aka-kevscript
add node0 : JavascriptNode
add sync : WSGroup/5.2.1
add node0.myComp : my.package.HelloWorld

attach node0 sync

set sync.port/node0 = "9000"
maxleiko commented 9 years ago

Yes, that's because the versions of certain libraries in JavaScript aren't matching the versions in Java. I'll update this asap and close the issue.

But, if you force the versions of the incriminated DeployUnits, you'll bypass the error. And yes, 5.2.1 is the latest cross-platform version. 5.2.2 is only for Java

maxleiko commented 9 years ago

Shoud be fixed: no need to specify versions anymore