I am trying to establish a toolchain for writing Java ESF/OSGI plugins. I have carefully followed the instructions given in the Eurotech ESF documentation (Development Environment Setup, Hello World Application, Deploy and Debug Applications).
Having completed my trivial Hello_Osgi project, I right-click ESF Emulator_Linux.launch in org.eclipse.jura.emulator project. I then choose Run As and then 1 ESF_Emulator_Linux.
In the Eclipse Console I do not see any output from my Hello_Osgi project being run. The first line of output is this (copied by eye):
<terminated>ESF Emulator Linux[OSGI Framework]/home/john/.p2/pool/plugins/org.eclipse.justj.openjdk.hotspot.jre.full.linux.x86_64_15.0.2.v20210201-0955/jre/bin/java (26 May 2021, 10:32:28 - 10.32.51)
I then get pages of errors, followed by output from other projects. It appears that the ESF Emulator is crashing - but then how come the other projects run OK?
Can anyone please suggest what I am doing wrong?
The components installed are:
- esf-user_workspace_archive_6.2.0.zip Java openJDK 1.8.0_292 (for Hello_Osgi project) mtoolkit-neon.s3-website-us-east-1.amazonws.com
- Eclipse JEE-2021-03 Java OpenJDK 15.0.2 (came with Eclipse EE install) Ubuntu Desktop 20.04
First few lines of Eclipse Console Output:
2021-05-26T10:32:32,348 [main] INFO c.e.f.s.m.AdvancedCryptoServiceImpl - Activating... b0307191400
2021-05-26T10:32:32,977 [Start Level: Equinox Container: 78b7db4a-28f6-4896-8167-2c7fe00192eb] INFO c.f.h.HelloWorld - Bundle com.fuelactive.hello_osgi has started OK
2021-05-26T10:32:32,978 [Start Level: Equinox Container: 78b7db4a-28f6-4896-8167-2c7fe00192eb] INFO c.f.h.HelloWorld - Bundle com.fuelactive.hello_osgi has started OK
2021-05-26T10:32:32,978 [Start Level: Equinox Container: 78b7db4a-28f6-4896-8167-2c7fe00192eb] INFO c.f.h.HelloWorld - Bundle com.fuelactive.hello_osgi has started OK
osgi> 2021-05-26T10:32:34,519 [Start Level: Equinox Container: 78b7db4a-28f6-4896-8167-2c7fe00192eb] INFO o.e.j.u.log - Logging initialized @5901ms to org.eclipse.jetty.util.log.Slf4jLog
2021-05-26T10:32:34,702 [Start Level: Equinox Container: 78b7db4a-28f6-4896-8167-2c7fe00192eb] INFO o.e.j.s.Server - jetty-9.4.19.v20190610; built: 2019-06-10T16:30:51.723Z; git: afcf563148970e98786327af5e07c261fda175d3; jvm 15.0.2+7-27
2021-05-26T10:32:34,743 [Start Level: Equinox Container: 78b7db4a-28f6-4896-8167-2c7fe00192eb] INFO o.e.j.s.session - DefaultSessionIdManager workerName=node0
2021-05-26T10:32:34,743 [Start Level: Equinox Container: 78b7db4a-28f6-4896-8167-2c7fe00192eb] INFO o.e.j.s.session - No SessionScavenger set, using defaults
2021-05-26T10:32:34,745 [Start Level: Equinox Container: 78b7db4a-28f6-4896-8167-2c7fe00192eb] INFO o.e.j.s.session - node0 Scavenging every 660000ms
2021-05-26T10:32:34,783 [Start Level: Equinox Container: 78b7db4a-28f6-4896-8167-2c7fe00192eb] INFO o.e.j.s.h.ContextHandler - Started o.e.j.s.ServletContextHandler@71939acc{/,null,AVAILABLE}
2021-05-26T10:32:34,797 [Start Level: Equinox Container: 78b7db4a-28f6-4896-8167-2c7fe00192eb] INFO o.e.j.s.AbstractConnector - Started ServerConnector@747f84f3{HTTP/1.1,[http/1.1]}{0.0.0.0:8080}
2021-05-26T10:32:34,797 [Start Level: Equinox Container: 78b7db4a-28f6-4896-8167-2c7fe00192eb] INFO o.e.j.s.Server - Started @6181ms
Framework is running in emulation mode
I received a response from technical support. They tell me that the ESF 6.2.0 emulator is a problem and to deploy direct to hardware instead.
This means that the "Getting Started" documentation is useless, since it requires the reader to use the emulator.