Hi Petre, Thanks for the work on the generic Java binding. I know of some people being interested in using IoTivity in an OCGi environment on some embedded devices. Running full OpenJDK on some embedded devices is sometimes not possible because it consumes too much memory. We have used JamVM with Gnu classpath for example which consumes much less memory. This restricts the available features to Java SE 5.0, but makes it possible to run it on devices with low memory. I do not think these bindings should depends on OSGi it should just be possible to create an OSGi binding later on.
When a recent Oracle Java version is used, the Java SE Embedded 8 Compact Profiles are better supported on smaller devices than the normal SE. Hauke -----Original Message----- From: iotivity-dev-bounces at lists.iotivity.org [mailto:[email protected]] On Behalf Of Eftime, Petre P Sent: Friday, April 22, 2016 4:26 PM To: iotivity-dev at lists.iotivity.org; lanka.madan at samsung.com Subject: Re: [dev] Generic Java Bindings Feature Hi, Thanks for the branch. I have uploaded the code. There currently are some build issues related to Oracle's JDK7 jni.h, which Jenkins is using to build the API. The API for AttachCurrentThread changed between versions 1.6 and 1.7 but there is no JNI_VERSION_1_7 defined. Android is using the old API for AttachCurrentThread. I am using OpenJDK 1.8 to build the code and checking for JNI_VERSION_1_8 to differentiate between Android's jni.h and OpenJDK's. I will try to find an alternative method to determine which function must be used. The alternative would be to have Java 8 available when building the generic bindings. The code can be reviewed here: https://gerrit.iotivity.org/gerrit/#/c/7895/. I have also created a JIRA issue: https://jira.iotivity.org/browse/IOT-1089. Thanks, Petre On Thu, 2016-04-21 at 11:05 +0000, Madan Kanth Lanka wrote: Hi Petre, Nice to see this and you can upload your work to the following branch. Branch Name : generic-java https://gerrit.iotivity.org/gerrit/gitweb?p=iotivity.git;a=shortlog;h=refs/heads/generic-java I have created this using the following commit hash. Commit hash : 8d9849e95ed4dc0f38f952dfa8ee9467c914bf3a Thanks, Madan ------- Original Message ------- Sender : Eftime, Petre P<petre.p.eftime at intel.com> Date : Apr 21, 2016 16:29 (GMT+05:30) Title : [dev] Generic Java Bindings Feature Hi all, I have been working on getting IoTivity Java bindings to function outside of Android and I have a working SimpleClient example. I made some substantial changes to how the Java bindings are built. I removed the android folder and made a single folder named java with the following structure: java/ ??? build.gradle ??? common/ # contains base classes ??? examples-android/ # examples for android ??? examples-java/ # examples for generic java ??? gradle ??? gradle.properties ??? gradlew ??? gradlew.bat ??? iotivity-android/ # contains ca classes for android ??? iotivity-linux/ # contains ca classes for linux ??? jni/ # native bindings, builds with scons ??? SConscript ??? settings.gradle I am requesting a branch to upload my work to (java-generic?) and get someone to review my work to make sure that I can include this in the following IoTivity release. I will add the ticket for the feature on JIRA as soon as I can get an account (if someone can tell me who to mail about this it would be great). Thanks, Petre Eftime _______________________________________________ iotivity-dev mailing list iotivity-dev at lists.iotivity.org https://lists.iotivity.org/mailman/listinfo/iotivity-dev [cid:1461335144.2814.30.camel at intel.com]
