felix-on-android | felix-on-android osgi android | Android library
kandi X-RAY | felix-on-android Summary
kandi X-RAY | felix-on-android Summary
优点: * 在有限情况下,实现静黙升级; * 快速分发,升级; * 动态加载(扩展)应用功能(需要定义良好的框架); * 向第三方开放接口,我们成为平台;. 缺点: * 更加复杂的升级方案(apk升级,bundle升级); * 更加复杂的后台? * 对传统android开发人员的挑战(引入额外的开发模型,工具的支持(ant, adt, gradle?),osgi 相关知识); * native支持 NOTE. how to buidl felix?.
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
- Create the grid layout
- Adds a bitmap drawable to the layout
- Adds a drawable drawable to the layout
- Load and print a bitmap
- Initializes the status bar
- Build the default intent for the activity
- Initializes the shadow card
- Creates and returns a set of AnimatorSet based on the provided items
- Handle activity result
- Reads the input stream without closing the stream
- Called when a draw frame is drawn
- Create icicle
- Called when the draw frame is drawn
- Start an animation
- Process an AccessibilityEvent
- Layout the children
- Initializes the View
- Called when the view is clicked
- Initializes the activity
- Initializes the card
- Create the sms message
- Initialize the activity
- Called when a surface is created
- Set up the keystore
- Creates a dialog
- Handle drag event
felix-on-android Key Features
felix-on-android Examples and Code Snippets
Community Discussions
Trending Discussions on felix-on-android
QUESTION
I have an android project developed with AndroidStudio and Gradle which embeds and starts a small OSGi project based on felix. To debug I use emulator for Nexus 5X with Android 8.0, API 26. I use declarative service and therefore my project bases on felix.main, felix.scr and felix.configadmin. All bundles are dexified. Installing the bundles works fine, but if I start the bundles by bundle.start() I get the following error message for felix.scr and felix.configadmin (felix.main and my own bundles work fine -> states are active):
...ANSWER
Answered 2017-Aug-09 at 09:50Your biggest issue is that you cannot know the original exception due to a bug of Apache Felix: https://issues.apache.org/jira/browse/FELIX-5643
If there is an exception during Android based class loading
- the exception is swallowed
- Felix falls back to normal JDK class loading mechanism that throws the exception you see
We could solve the issue temporarily in two ways:
We did set a breakpoint to the beginning of BundleContextImpl.getDexFileClass(...) function in Android Studio and after it stopped, we did set Android dev studio to catch all exceptions. By doing that, we were able to find the original cause.
The first solution made us tired as we had to switch on and off the stop-at-exception feature. With many bundles where one is failing, it is hard to find the right one during debugging. Therefore, we simply copied out the content of BundleWiringImpl class into Android developer studio and changed it to log out the swallowed exception. By doing that, we were able to see the original exception in the log.
Btw.: The most annoying problem was the following. We dexified the jars as the tutorials said. However, the aapt command is that ugly, that if you specify the classes.dex file with an absolute URL, the entry of the ZIP will have the same name (including drive letter if you use windows). E.g.: The entry name of classes.dex in the zip is c:\classes.dex and no ZIP editor show the _c:_ part of its name. Therefore we listed the entry names of the ZIP/JAR in Java and to find out the real entry name.
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install felix-on-android
You can use felix-on-android like any standard Java library. Please include the the jar files in your classpath. You can also use any IDE and you can run and debug the felix-on-android component as you would do with any other Java program. Best practice is to use a build tool that supports dependency management such as Maven or Gradle. For Maven installation, please refer maven.apache.org. For Gradle installation, please refer gradle.org .
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page