You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@felix.apache.org by Albert38 <am...@orange-ftgroup.com> on 2009/04/08 10:39:09 UTC

Felix SCR on Android issue

Hello,
I'm very interested into the felix on android porting thing, which I heard
from the luminis' blog website. I then followed the tutorial on the apache
felix website and everything went well, but then I didn't manage to make my
personal bundles work, because the felix scr bundle doesn't seem to work
right. Did someone tried service component runtime successfully on android?

In fact I get this error stack trace:
ERROR: com.acse.systerminal.JainFacadeImpl (20): [JainSip Facade] Cannot
register Component
java.lang.VerifyError: org.apache.felix.scr.impl.ImmediateComponentManager
at
org.apache.felix.scr.impl.ManagerFactory.createManager(ManagerFactory.java:38)
        at
org.apache.felix.scr.impl.BundleComponentActivator.initialize(BundleComponentActivator.java:181)
        at
org.apache.felix.scr.impl.BundleComponentActivator.(BundleComponentActivator.java:110)
        at
org.apache.felix.scr.impl.Activator.loadComponents(Activator.java:227)
        at
org.apache.felix.scr.impl.Activator.bundleChanged(Activator.java:173)
        at
org.apache.felix.framework.util.EventDispatcher.invokeBundleListenerCallback(EventDispatcher.java:690)
        at
org.apache.felix.framework.util.EventDispatcher.fireEventImmediately(EventDispatcher.java:619)
        at
org.apache.felix.framework.util.EventDispatcher.fireBundleEvent(EventDispatcher.java:532)
        at org.apache.felix.framework.Felix.fireBundleEvent(Felix.java:3555)
        at org.apache.felix.framework.Felix._startBundle(Felix.java:1660)
        at org.apache.felix.framework.Felix.startBundle(Felix.java:1578)
        at
org.apache.felix.framework.Felix.setFrameworkStartLevel(Felix.java:1172)
        at
org.apache.felix.framework.StartLevelImpl.run(StartLevelImpl.java:265)
        at java.lang.Thread.run(Thread.java:935) 

The other problematic thing is that when I'm "dexing" my
org.apache.felix.scr.jar I get some warnings of that kind:

warning: Ignoring InnerClasses attribute for an anonymous inner class that
doesn't come with an associated EnclosingMethod attribute. (This class was
probably produced by a broken compiler.)


Could anyone help?

thx

Albert.



-- 
View this message in context: http://www.nabble.com/Felix-SCR-on-Android-issue-tp22945697p22945697.html
Sent from the Apache Felix - Users mailing list archive at Nabble.com.

Re: Felix SCR on Android issue

Posted by Clement Escoffier <cl...@gmail.com>.
On 24.04.2009, at 10:57, Albert38 wrote:

>
> Hi,
> I quickly patched the jain sip stack to use the native android logger,
> and that gave me a few clues concerning my bug... apparently related  
> to a
> UDP port opening error.
> Jean Deruelle finally gave me the trick, I had forgotten to add the
> android.permission.INTERNET permission in my AndroidManifest.xml file.

He he, I had the same issue once !

>
>
> I had a last question regarding your ipojo on android tutorial: How  
> is the
> ViewFactory's package exported
> to be accessible by the SpellCheckGui? I'm developping maven based  
> OSGI
> bundles, so I have no artifact dependency to get the ViewFactory  
> class,
> because it is defined in the android application.
> How did you manage that?

In fact, Felix run as an embedded framework. My host launches Felix  
and deploys bundles. When I start Felix, I add the following OSGi  
property:
org.osgi.framework.system.packages.extra

This property tells that Felix System Bundle exports the specified  
packages. So, the packages are available for the host and for any  
bundle importing it (very useful, when then need to interact...).

Regards,

Clement


>
>
> Thanks for the help,
>
> Albert.
>
>
> clement escoffier wrote:
>>
>> Hi,
>>
>> On 21.04.2009, at 20:38, Albert38 wrote:
>>
>>>
>>> Hello Clement,
>>> Thanks to your iPojo on Android tutorial I managed to get an Android
>>> app
>>> running an embedded felix
>>> with a default configuration loading and starting a few base  
>>> bundles :
>>> ipojo, log4j and jain-sip-api / jain-sip-ri.
>>> My problem is that I can't manage to configure log4j properly, even
>>> if I add
>>> log4j properties in the m_ConfigMap (cf. your tutorial). Any idea?
>>> Is the
>>> configuration map still valid when dynamically installing bundles
>>> located in
>>> /data/felix/bundles ?
>>
>> Sounds a log4j issue that can't load its log4j.properties file. I'm
>> not an expert in log4j, but maybe somebody else can help you.
>>
>>>
>>> I also wondered if there is a way to embed a log4j.properties file
>>> in the
>>> app?
>>>
>>>
>>> In fact I need logging capabilities because my Jain sip stack can't
>>> initialize properly, and I really don't know why. The weirdest thing
>>> is that
>>> I don't have any problems when running felix from the adb shell, as
>>> explained in the apache felix on android tutorial.
>>
>> I will greatly recommend using the Android logger. To use it, your
>> host can provide it as a service. The advantage: your message are
>> logged in the ADB log, can be filtered from Eclipse, and the log is
>> stored on the device (so, if something wrong happen, you just plug  
>> the
>> device and get your log).
>>
>> If you're interested by this, I can provide you some hints.
>>
>> Regards,
>>
>> Clement
>>
>>
>>
>>>
>>> I anybody here has experience to share in JainSip on felix+Android I
>>> would
>>> greatly appreciate.
>>>
>>> Regards
>>>
>>> Albert
>>>
>>>
>>> Albert38 wrote:
>>>>
>>>> Hi,
>>>> I made a quick port from SCR to iPOJO for a few of my bundles, and
>>>> indeed
>>>> it worked!
>>>> Thanks for the tip, but anyway, if someone ever gets felix scr
>>>> working on
>>>> android, I'd be glad to know.
>>>>
>>>> Regards
>>>>
>>>> Albert
>>>>
>>>>
>>>> clement escoffier wrote:
>>>>>
>>>>> Hi,
>>>>>
>>>>>
>>>>> On 08.04.2009, at 10:39, Albert38 wrote:
>>>>>
>>>>>>
>>>>>> Hello,
>>>>>> I'm very interested into the felix on android porting thing,
>>>>>> which I
>>>>>> heard
>>>>>> from the luminis' blog website. I then followed the tutorial on  
>>>>>> the
>>>>>> apache
>>>>>> felix website and everything went well, but then I didn't  
>>>>>> manage to
>>>>>> make my
>>>>>> personal bundles work, because the felix scr bundle doesn't  
>>>>>> seem to
>>>>>> work
>>>>>> right. Did someone tried service component runtime successfully  
>>>>>> on
>>>>>> android?
>>>>>
>>>>> Not SCR, but it should work. At least iPOJO works on Android :-)
>>>>> http://ipojo-dark-side.blogspot.com/2008/10/ipojo-on-android.html
>>>>>
>>>>>
>>>>>>
>>>>>>
>>>>>> In fact I get this error stack trace:
>>>>>> ERROR: com.acse.systerminal.JainFacadeImpl (20): [JainSip Facade]
>>>>>> Cannot
>>>>>> register Component
>>>>>> java.lang.VerifyError:
>>>>>> org.apache.felix.scr.impl.ImmediateComponentManager
>>>>>> at
>>>>>> org
>>>>>> .apache
>>>>>> .felix.scr.impl.ManagerFactory.createManager(ManagerFactory.java:
>>>>>> 38)
>>>>>>      at
>>>>>> org
>>>>>> .apache
>>>>>> .felix
>>>>>> .scr
>>>>>> .impl
>>>>>> .BundleComponentActivator 
>>>>>> .initialize(BundleComponentActivator.java:
>>>>>> 181)
>>>>>>      at
>>>>>> org.apache.felix.scr.impl.BundleComponentActivator.
>>>>>> (BundleComponentActivator.java:110)
>>>>>>      at
>>>>>> org 
>>>>>> .apache.felix.scr.impl.Activator.loadComponents(Activator.java:
>>>>>> 227)
>>>>>>      at
>>>>>> org.apache.felix.scr.impl.Activator.bundleChanged(Activator.java:
>>>>>> 173)
>>>>>>      at
>>>>>> org
>>>>>> .apache
>>>>>> .felix
>>>>>> .framework
>>>>>> .util
>>>>>> .EventDispatcher 
>>>>>> .invokeBundleListenerCallback(EventDispatcher.java:
>>>>>> 690)
>>>>>>      at
>>>>>> org
>>>>>> .apache
>>>>>> .felix
>>>>>> .framework
>>>>>> .util.EventDispatcher.fireEventImmediately(EventDispatcher.java:
>>>>>> 619)
>>>>>>      at
>>>>>> org
>>>>>> .apache
>>>>>> .felix
>>>>>> .framework
>>>>>> .util.EventDispatcher.fireBundleEvent(EventDispatcher.java:
>>>>>> 532)
>>>>>>      at
>>>>>> org.apache.felix.framework.Felix.fireBundleEvent(Felix.java:3555)
>>>>>>      at org.apache.felix.framework.Felix._startBundle(Felix.java:
>>>>>> 1660)
>>>>>>      at org.apache.felix.framework.Felix.startBundle(Felix.java:
>>>>>> 1578)
>>>>>>      at
>>>>>> org 
>>>>>> .apache.felix.framework.Felix.setFrameworkStartLevel(Felix.java:
>>>>>> 1172)
>>>>>>      at
>>>>>> org 
>>>>>> .apache.felix.framework.StartLevelImpl.run(StartLevelImpl.java:
>>>>>> 265)
>>>>>>      at java.lang.Thread.run(Thread.java:935)
>>>>>>
>>>>>
>>>>> That's bad. Maybe this class is using a not supported
>>>>> "construction".
>>>>> However, I'm not aware of such limitation in Dalvik.
>>>>>
>>>>>
>>>>>
>>>>>> The other problematic thing is that when I'm "dexing" my
>>>>>> org.apache.felix.scr.jar I get some warnings of that kind:
>>>>>>
>>>>>> warning: Ignoring InnerClasses attribute for an anonymous inner
>>>>>> class that
>>>>>> doesn't come with an associated EnclosingMethod attribute. (This
>>>>>> class was
>>>>>> probably produced by a broken compiler.)
>>>>>
>>>>> That's "normal" (I never really found the reason). I also get  
>>>>> those
>>>>> issues. But, despite those warnings, it should work.
>>>>>
>>>>>
>>>>> Regards,
>>>>>
>>>>> Clement
>>>>>
>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>> Could anyone help?
>>>>>>
>>>>>> thx
>>>>>>
>>>>>> Albert.
>>>>>>
>>>>>>
>>>>>>
>>>>>> -- 
>>>>>> View this message in context:
>>>>>> http://www.nabble.com/Felix-SCR-on-Android-issue-tp22945697p22945697.html
>>>>>> Sent from the Apache Felix - Users mailing list archive at
>>>>>> Nabble.com.
>>>>>
>>>>>
>>>>> ---------------------------------------------------------------------
>>>>> To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
>>>>> For additional commands, e-mail: users-help@felix.apache.org
>>>>>
>>>>>
>>>>>
>>>>
>>>>
>>>
>>> -- 
>>> View this message in context:
>>> http://www.nabble.com/Felix-SCR-on-Android-issue-tp22945697p23162251.html
>>> Sent from the Apache Felix - Users mailing list archive at  
>>> Nabble.com.
>>>
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
>>> For additional commands, e-mail: users-help@felix.apache.org
>>>
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
>> For additional commands, e-mail: users-help@felix.apache.org
>>
>>
>>
>
> -- 
> View this message in context: http://www.nabble.com/Felix-SCR-on-Android-issue-tp22945697p23212505.html
> Sent from the Apache Felix - Users mailing list archive at Nabble.com.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
> For additional commands, e-mail: users-help@felix.apache.org
>


Re: Felix SCR on Android issue

Posted by Albert38 <am...@orange-ftgroup.com>.
Hi,
I quickly patched the jain sip stack to use the native android logger,
and that gave me a few clues concerning my bug... apparently related to a
UDP port opening error.
Jean Deruelle finally gave me the trick, I had forgotten to add the
android.permission.INTERNET permission in my AndroidManifest.xml file.

I had a last question regarding your ipojo on android tutorial: How is the
ViewFactory's package exported
to be accessible by the SpellCheckGui? I'm developping maven based OSGI
bundles, so I have no artifact dependency to get the ViewFactory class,
because it is defined in the android application.
How did you manage that? 

Thanks for the help,

Albert.


clement escoffier wrote:
> 
> Hi,
> 
> On 21.04.2009, at 20:38, Albert38 wrote:
> 
>>
>> Hello Clement,
>> Thanks to your iPojo on Android tutorial I managed to get an Android  
>> app
>> running an embedded felix
>> with a default configuration loading and starting a few base bundles :
>> ipojo, log4j and jain-sip-api / jain-sip-ri.
>> My problem is that I can't manage to configure log4j properly, even  
>> if I add
>> log4j properties in the m_ConfigMap (cf. your tutorial). Any idea?  
>> Is the
>> configuration map still valid when dynamically installing bundles  
>> located in
>> /data/felix/bundles ?
> 
> Sounds a log4j issue that can't load its log4j.properties file. I'm  
> not an expert in log4j, but maybe somebody else can help you.
> 
>>
>> I also wondered if there is a way to embed a log4j.properties file  
>> in the
>> app?
>>
>>
>> In fact I need logging capabilities because my Jain sip stack can't
>> initialize properly, and I really don't know why. The weirdest thing  
>> is that
>> I don't have any problems when running felix from the adb shell, as
>> explained in the apache felix on android tutorial.
> 
> I will greatly recommend using the Android logger. To use it, your  
> host can provide it as a service. The advantage: your message are  
> logged in the ADB log, can be filtered from Eclipse, and the log is  
> stored on the device (so, if something wrong happen, you just plug the  
> device and get your log).
> 
> If you're interested by this, I can provide you some hints.
> 
> Regards,
> 
> Clement
> 
> 
> 
>>
>> I anybody here has experience to share in JainSip on felix+Android I  
>> would
>> greatly appreciate.
>>
>> Regards
>>
>> Albert
>>
>>
>> Albert38 wrote:
>>>
>>> Hi,
>>> I made a quick port from SCR to iPOJO for a few of my bundles, and  
>>> indeed
>>> it worked!
>>> Thanks for the tip, but anyway, if someone ever gets felix scr  
>>> working on
>>> android, I'd be glad to know.
>>>
>>> Regards
>>>
>>> Albert
>>>
>>>
>>> clement escoffier wrote:
>>>>
>>>> Hi,
>>>>
>>>>
>>>> On 08.04.2009, at 10:39, Albert38 wrote:
>>>>
>>>>>
>>>>> Hello,
>>>>> I'm very interested into the felix on android porting thing,  
>>>>> which I
>>>>> heard
>>>>> from the luminis' blog website. I then followed the tutorial on the
>>>>> apache
>>>>> felix website and everything went well, but then I didn't manage to
>>>>> make my
>>>>> personal bundles work, because the felix scr bundle doesn't seem to
>>>>> work
>>>>> right. Did someone tried service component runtime successfully on
>>>>> android?
>>>>
>>>> Not SCR, but it should work. At least iPOJO works on Android :-)
>>>> http://ipojo-dark-side.blogspot.com/2008/10/ipojo-on-android.html
>>>>
>>>>
>>>>>
>>>>>
>>>>> In fact I get this error stack trace:
>>>>> ERROR: com.acse.systerminal.JainFacadeImpl (20): [JainSip Facade]
>>>>> Cannot
>>>>> register Component
>>>>> java.lang.VerifyError:
>>>>> org.apache.felix.scr.impl.ImmediateComponentManager
>>>>> at
>>>>> org
>>>>> .apache
>>>>> .felix.scr.impl.ManagerFactory.createManager(ManagerFactory.java: 
>>>>> 38)
>>>>>       at
>>>>> org
>>>>> .apache
>>>>> .felix
>>>>> .scr
>>>>> .impl
>>>>> .BundleComponentActivator.initialize(BundleComponentActivator.java:
>>>>> 181)
>>>>>       at
>>>>> org.apache.felix.scr.impl.BundleComponentActivator.
>>>>> (BundleComponentActivator.java:110)
>>>>>       at
>>>>> org.apache.felix.scr.impl.Activator.loadComponents(Activator.java: 
>>>>> 227)
>>>>>       at
>>>>> org.apache.felix.scr.impl.Activator.bundleChanged(Activator.java: 
>>>>> 173)
>>>>>       at
>>>>> org
>>>>> .apache
>>>>> .felix
>>>>> .framework
>>>>> .util
>>>>> .EventDispatcher.invokeBundleListenerCallback(EventDispatcher.java:
>>>>> 690)
>>>>>       at
>>>>> org
>>>>> .apache
>>>>> .felix
>>>>> .framework
>>>>> .util.EventDispatcher.fireEventImmediately(EventDispatcher.java: 
>>>>> 619)
>>>>>       at
>>>>> org
>>>>> .apache
>>>>> .felix
>>>>> .framework 
>>>>> .util.EventDispatcher.fireBundleEvent(EventDispatcher.java:
>>>>> 532)
>>>>>       at
>>>>> org.apache.felix.framework.Felix.fireBundleEvent(Felix.java:3555)
>>>>>       at org.apache.felix.framework.Felix._startBundle(Felix.java:
>>>>> 1660)
>>>>>       at org.apache.felix.framework.Felix.startBundle(Felix.java:
>>>>> 1578)
>>>>>       at
>>>>> org.apache.felix.framework.Felix.setFrameworkStartLevel(Felix.java:
>>>>> 1172)
>>>>>       at
>>>>> org.apache.felix.framework.StartLevelImpl.run(StartLevelImpl.java: 
>>>>> 265)
>>>>>       at java.lang.Thread.run(Thread.java:935)
>>>>>
>>>>
>>>> That's bad. Maybe this class is using a not supported  
>>>> "construction".
>>>> However, I'm not aware of such limitation in Dalvik.
>>>>
>>>>
>>>>
>>>>> The other problematic thing is that when I'm "dexing" my
>>>>> org.apache.felix.scr.jar I get some warnings of that kind:
>>>>>
>>>>> warning: Ignoring InnerClasses attribute for an anonymous inner
>>>>> class that
>>>>> doesn't come with an associated EnclosingMethod attribute. (This
>>>>> class was
>>>>> probably produced by a broken compiler.)
>>>>
>>>> That's "normal" (I never really found the reason). I also get those
>>>> issues. But, despite those warnings, it should work.
>>>>
>>>>
>>>> Regards,
>>>>
>>>> Clement
>>>>
>>>>
>>>>>
>>>>>
>>>>>
>>>>> Could anyone help?
>>>>>
>>>>> thx
>>>>>
>>>>> Albert.
>>>>>
>>>>>
>>>>>
>>>>> -- 
>>>>> View this message in context:
>>>>> http://www.nabble.com/Felix-SCR-on-Android-issue-tp22945697p22945697.html
>>>>> Sent from the Apache Felix - Users mailing list archive at  
>>>>> Nabble.com.
>>>>
>>>>
>>>> ---------------------------------------------------------------------
>>>> To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
>>>> For additional commands, e-mail: users-help@felix.apache.org
>>>>
>>>>
>>>>
>>>
>>>
>>
>> -- 
>> View this message in context:
>> http://www.nabble.com/Felix-SCR-on-Android-issue-tp22945697p23162251.html
>> Sent from the Apache Felix - Users mailing list archive at Nabble.com.
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
>> For additional commands, e-mail: users-help@felix.apache.org
>>
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
> For additional commands, e-mail: users-help@felix.apache.org
> 
> 
> 

-- 
View this message in context: http://www.nabble.com/Felix-SCR-on-Android-issue-tp22945697p23212505.html
Sent from the Apache Felix - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
For additional commands, e-mail: users-help@felix.apache.org


Re: Felix SCR on Android issue

Posted by Clement Escoffier <cl...@gmail.com>.
Hi,

On 21.04.2009, at 20:38, Albert38 wrote:

>
> Hello Clement,
> Thanks to your iPojo on Android tutorial I managed to get an Android  
> app
> running an embedded felix
> with a default configuration loading and starting a few base bundles :
> ipojo, log4j and jain-sip-api / jain-sip-ri.
> My problem is that I can't manage to configure log4j properly, even  
> if I add
> log4j properties in the m_ConfigMap (cf. your tutorial). Any idea?  
> Is the
> configuration map still valid when dynamically installing bundles  
> located in
> /data/felix/bundles ?

Sounds a log4j issue that can't load its log4j.properties file. I'm  
not an expert in log4j, but maybe somebody else can help you.

>
> I also wondered if there is a way to embed a log4j.properties file  
> in the
> app?
>
>
> In fact I need logging capabilities because my Jain sip stack can't
> initialize properly, and I really don't know why. The weirdest thing  
> is that
> I don't have any problems when running felix from the adb shell, as
> explained in the apache felix on android tutorial.

I will greatly recommend using the Android logger. To use it, your  
host can provide it as a service. The advantage: your message are  
logged in the ADB log, can be filtered from Eclipse, and the log is  
stored on the device (so, if something wrong happen, you just plug the  
device and get your log).

If you're interested by this, I can provide you some hints.

Regards,

Clement



>
> I anybody here has experience to share in JainSip on felix+Android I  
> would
> greatly appreciate.
>
> Regards
>
> Albert
>
>
> Albert38 wrote:
>>
>> Hi,
>> I made a quick port from SCR to iPOJO for a few of my bundles, and  
>> indeed
>> it worked!
>> Thanks for the tip, but anyway, if someone ever gets felix scr  
>> working on
>> android, I'd be glad to know.
>>
>> Regards
>>
>> Albert
>>
>>
>> clement escoffier wrote:
>>>
>>> Hi,
>>>
>>>
>>> On 08.04.2009, at 10:39, Albert38 wrote:
>>>
>>>>
>>>> Hello,
>>>> I'm very interested into the felix on android porting thing,  
>>>> which I
>>>> heard
>>>> from the luminis' blog website. I then followed the tutorial on the
>>>> apache
>>>> felix website and everything went well, but then I didn't manage to
>>>> make my
>>>> personal bundles work, because the felix scr bundle doesn't seem to
>>>> work
>>>> right. Did someone tried service component runtime successfully on
>>>> android?
>>>
>>> Not SCR, but it should work. At least iPOJO works on Android :-)
>>> http://ipojo-dark-side.blogspot.com/2008/10/ipojo-on-android.html
>>>
>>>
>>>>
>>>>
>>>> In fact I get this error stack trace:
>>>> ERROR: com.acse.systerminal.JainFacadeImpl (20): [JainSip Facade]
>>>> Cannot
>>>> register Component
>>>> java.lang.VerifyError:
>>>> org.apache.felix.scr.impl.ImmediateComponentManager
>>>> at
>>>> org
>>>> .apache
>>>> .felix.scr.impl.ManagerFactory.createManager(ManagerFactory.java: 
>>>> 38)
>>>>       at
>>>> org
>>>> .apache
>>>> .felix
>>>> .scr
>>>> .impl
>>>> .BundleComponentActivator.initialize(BundleComponentActivator.java:
>>>> 181)
>>>>       at
>>>> org.apache.felix.scr.impl.BundleComponentActivator.
>>>> (BundleComponentActivator.java:110)
>>>>       at
>>>> org.apache.felix.scr.impl.Activator.loadComponents(Activator.java: 
>>>> 227)
>>>>       at
>>>> org.apache.felix.scr.impl.Activator.bundleChanged(Activator.java: 
>>>> 173)
>>>>       at
>>>> org
>>>> .apache
>>>> .felix
>>>> .framework
>>>> .util
>>>> .EventDispatcher.invokeBundleListenerCallback(EventDispatcher.java:
>>>> 690)
>>>>       at
>>>> org
>>>> .apache
>>>> .felix
>>>> .framework
>>>> .util.EventDispatcher.fireEventImmediately(EventDispatcher.java: 
>>>> 619)
>>>>       at
>>>> org
>>>> .apache
>>>> .felix
>>>> .framework 
>>>> .util.EventDispatcher.fireBundleEvent(EventDispatcher.java:
>>>> 532)
>>>>       at
>>>> org.apache.felix.framework.Felix.fireBundleEvent(Felix.java:3555)
>>>>       at org.apache.felix.framework.Felix._startBundle(Felix.java:
>>>> 1660)
>>>>       at org.apache.felix.framework.Felix.startBundle(Felix.java:
>>>> 1578)
>>>>       at
>>>> org.apache.felix.framework.Felix.setFrameworkStartLevel(Felix.java:
>>>> 1172)
>>>>       at
>>>> org.apache.felix.framework.StartLevelImpl.run(StartLevelImpl.java: 
>>>> 265)
>>>>       at java.lang.Thread.run(Thread.java:935)
>>>>
>>>
>>> That's bad. Maybe this class is using a not supported  
>>> "construction".
>>> However, I'm not aware of such limitation in Dalvik.
>>>
>>>
>>>
>>>> The other problematic thing is that when I'm "dexing" my
>>>> org.apache.felix.scr.jar I get some warnings of that kind:
>>>>
>>>> warning: Ignoring InnerClasses attribute for an anonymous inner
>>>> class that
>>>> doesn't come with an associated EnclosingMethod attribute. (This
>>>> class was
>>>> probably produced by a broken compiler.)
>>>
>>> That's "normal" (I never really found the reason). I also get those
>>> issues. But, despite those warnings, it should work.
>>>
>>>
>>> Regards,
>>>
>>> Clement
>>>
>>>
>>>>
>>>>
>>>>
>>>> Could anyone help?
>>>>
>>>> thx
>>>>
>>>> Albert.
>>>>
>>>>
>>>>
>>>> -- 
>>>> View this message in context:
>>>> http://www.nabble.com/Felix-SCR-on-Android-issue-tp22945697p22945697.html
>>>> Sent from the Apache Felix - Users mailing list archive at  
>>>> Nabble.com.
>>>
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
>>> For additional commands, e-mail: users-help@felix.apache.org
>>>
>>>
>>>
>>
>>
>
> -- 
> View this message in context: http://www.nabble.com/Felix-SCR-on-Android-issue-tp22945697p23162251.html
> Sent from the Apache Felix - Users mailing list archive at Nabble.com.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
> For additional commands, e-mail: users-help@felix.apache.org
>


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
For additional commands, e-mail: users-help@felix.apache.org


Re: Felix SCR on Android issue

Posted by Albert38 <am...@orange-ftgroup.com>.
Hello Clement,
Thanks to your iPojo on Android tutorial I managed to get an Android app
running an embedded felix
with a default configuration loading and starting a few base bundles :
ipojo, log4j and jain-sip-api / jain-sip-ri.
My problem is that I can't manage to configure log4j properly, even if I add
log4j properties in the m_ConfigMap (cf. your tutorial). Any idea? Is the
configuration map still valid when dynamically installing bundles located in
/data/felix/bundles ?
I also wondered if there is a way to embed a log4j.properties file in the
app?


In fact I need logging capabilities because my Jain sip stack can't
initialize properly, and I really don't know why. The weirdest thing is that
I don't have any problems when running felix from the adb shell, as
explained in the apache felix on android tutorial.
I anybody here has experience to share in JainSip on felix+Android I would
greatly appreciate.

Regards

Albert 


Albert38 wrote:
> 
> Hi,
> I made a quick port from SCR to iPOJO for a few of my bundles, and indeed
> it worked!
> Thanks for the tip, but anyway, if someone ever gets felix scr working on
> android, I'd be glad to know.
> 
> Regards
> 
> Albert
> 
> 
> clement escoffier wrote:
>> 
>> Hi,
>> 
>> 
>> On 08.04.2009, at 10:39, Albert38 wrote:
>> 
>>>
>>> Hello,
>>> I'm very interested into the felix on android porting thing, which I  
>>> heard
>>> from the luminis' blog website. I then followed the tutorial on the  
>>> apache
>>> felix website and everything went well, but then I didn't manage to  
>>> make my
>>> personal bundles work, because the felix scr bundle doesn't seem to  
>>> work
>>> right. Did someone tried service component runtime successfully on  
>>> android?
>> 
>> Not SCR, but it should work. At least iPOJO works on Android :-)
>> http://ipojo-dark-side.blogspot.com/2008/10/ipojo-on-android.html
>> 
>> 
>>>
>>>
>>> In fact I get this error stack trace:
>>> ERROR: com.acse.systerminal.JainFacadeImpl (20): [JainSip Facade]  
>>> Cannot
>>> register Component
>>> java.lang.VerifyError:  
>>> org.apache.felix.scr.impl.ImmediateComponentManager
>>> at
>>> org 
>>> .apache 
>>> .felix.scr.impl.ManagerFactory.createManager(ManagerFactory.java:38)
>>>        at
>>> org 
>>> .apache 
>>> .felix 
>>> .scr 
>>> .impl 
>>> .BundleComponentActivator.initialize(BundleComponentActivator.java: 
>>> 181)
>>>        at
>>> org.apache.felix.scr.impl.BundleComponentActivator. 
>>> (BundleComponentActivator.java:110)
>>>        at
>>> org.apache.felix.scr.impl.Activator.loadComponents(Activator.java:227)
>>>        at
>>> org.apache.felix.scr.impl.Activator.bundleChanged(Activator.java:173)
>>>        at
>>> org 
>>> .apache 
>>> .felix 
>>> .framework 
>>> .util 
>>> .EventDispatcher.invokeBundleListenerCallback(EventDispatcher.java: 
>>> 690)
>>>        at
>>> org 
>>> .apache 
>>> .felix 
>>> .framework 
>>> .util.EventDispatcher.fireEventImmediately(EventDispatcher.java:619)
>>>        at
>>> org 
>>> .apache 
>>> .felix 
>>> .framework.util.EventDispatcher.fireBundleEvent(EventDispatcher.java: 
>>> 532)
>>>        at  
>>> org.apache.felix.framework.Felix.fireBundleEvent(Felix.java:3555)
>>>        at org.apache.felix.framework.Felix._startBundle(Felix.java: 
>>> 1660)
>>>        at org.apache.felix.framework.Felix.startBundle(Felix.java: 
>>> 1578)
>>>        at
>>> org.apache.felix.framework.Felix.setFrameworkStartLevel(Felix.java: 
>>> 1172)
>>>        at
>>> org.apache.felix.framework.StartLevelImpl.run(StartLevelImpl.java:265)
>>>        at java.lang.Thread.run(Thread.java:935)
>>>
>> 
>> That's bad. Maybe this class is using a not supported "construction".  
>> However, I'm not aware of such limitation in Dalvik.
>> 
>> 
>> 
>>> The other problematic thing is that when I'm "dexing" my
>>> org.apache.felix.scr.jar I get some warnings of that kind:
>>>
>>> warning: Ignoring InnerClasses attribute for an anonymous inner  
>>> class that
>>> doesn't come with an associated EnclosingMethod attribute. (This  
>>> class was
>>> probably produced by a broken compiler.)
>> 
>> That's "normal" (I never really found the reason). I also get those  
>> issues. But, despite those warnings, it should work.
>> 
>> 
>> Regards,
>> 
>> Clement
>> 
>> 
>>>
>>>
>>>
>>> Could anyone help?
>>>
>>> thx
>>>
>>> Albert.
>>>
>>>
>>>
>>> -- 
>>> View this message in context:
>>> http://www.nabble.com/Felix-SCR-on-Android-issue-tp22945697p22945697.html
>>> Sent from the Apache Felix - Users mailing list archive at Nabble.com.
>> 
>> 
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
>> For additional commands, e-mail: users-help@felix.apache.org
>> 
>> 
>> 
> 
> 

-- 
View this message in context: http://www.nabble.com/Felix-SCR-on-Android-issue-tp22945697p23162251.html
Sent from the Apache Felix - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
For additional commands, e-mail: users-help@felix.apache.org


Re: Felix SCR on Android issue

Posted by Albert38 <am...@orange-ftgroup.com>.
Hi,
I made a quick port from SCR to iPOJO for a few of my bundles, and indeed it
worked!
Thanks for the tip, but anyway, if someone ever gets felix scr working on
android, I'd be glad to know.

Regards

Albert


clement escoffier wrote:
> 
> Hi,
> 
> 
> On 08.04.2009, at 10:39, Albert38 wrote:
> 
>>
>> Hello,
>> I'm very interested into the felix on android porting thing, which I  
>> heard
>> from the luminis' blog website. I then followed the tutorial on the  
>> apache
>> felix website and everything went well, but then I didn't manage to  
>> make my
>> personal bundles work, because the felix scr bundle doesn't seem to  
>> work
>> right. Did someone tried service component runtime successfully on  
>> android?
> 
> Not SCR, but it should work. At least iPOJO works on Android :-)
> http://ipojo-dark-side.blogspot.com/2008/10/ipojo-on-android.html
> 
> 
>>
>>
>> In fact I get this error stack trace:
>> ERROR: com.acse.systerminal.JainFacadeImpl (20): [JainSip Facade]  
>> Cannot
>> register Component
>> java.lang.VerifyError:  
>> org.apache.felix.scr.impl.ImmediateComponentManager
>> at
>> org 
>> .apache 
>> .felix.scr.impl.ManagerFactory.createManager(ManagerFactory.java:38)
>>        at
>> org 
>> .apache 
>> .felix 
>> .scr 
>> .impl 
>> .BundleComponentActivator.initialize(BundleComponentActivator.java: 
>> 181)
>>        at
>> org.apache.felix.scr.impl.BundleComponentActivator. 
>> (BundleComponentActivator.java:110)
>>        at
>> org.apache.felix.scr.impl.Activator.loadComponents(Activator.java:227)
>>        at
>> org.apache.felix.scr.impl.Activator.bundleChanged(Activator.java:173)
>>        at
>> org 
>> .apache 
>> .felix 
>> .framework 
>> .util 
>> .EventDispatcher.invokeBundleListenerCallback(EventDispatcher.java: 
>> 690)
>>        at
>> org 
>> .apache 
>> .felix 
>> .framework 
>> .util.EventDispatcher.fireEventImmediately(EventDispatcher.java:619)
>>        at
>> org 
>> .apache 
>> .felix 
>> .framework.util.EventDispatcher.fireBundleEvent(EventDispatcher.java: 
>> 532)
>>        at  
>> org.apache.felix.framework.Felix.fireBundleEvent(Felix.java:3555)
>>        at org.apache.felix.framework.Felix._startBundle(Felix.java: 
>> 1660)
>>        at org.apache.felix.framework.Felix.startBundle(Felix.java: 
>> 1578)
>>        at
>> org.apache.felix.framework.Felix.setFrameworkStartLevel(Felix.java: 
>> 1172)
>>        at
>> org.apache.felix.framework.StartLevelImpl.run(StartLevelImpl.java:265)
>>        at java.lang.Thread.run(Thread.java:935)
>>
> 
> That's bad. Maybe this class is using a not supported "construction".  
> However, I'm not aware of such limitation in Dalvik.
> 
> 
> 
>> The other problematic thing is that when I'm "dexing" my
>> org.apache.felix.scr.jar I get some warnings of that kind:
>>
>> warning: Ignoring InnerClasses attribute for an anonymous inner  
>> class that
>> doesn't come with an associated EnclosingMethod attribute. (This  
>> class was
>> probably produced by a broken compiler.)
> 
> That's "normal" (I never really found the reason). I also get those  
> issues. But, despite those warnings, it should work.
> 
> 
> Regards,
> 
> Clement
> 
> 
>>
>>
>>
>> Could anyone help?
>>
>> thx
>>
>> Albert.
>>
>>
>>
>> -- 
>> View this message in context:
>> http://www.nabble.com/Felix-SCR-on-Android-issue-tp22945697p22945697.html
>> Sent from the Apache Felix - Users mailing list archive at Nabble.com.
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
> For additional commands, e-mail: users-help@felix.apache.org
> 
> 
> 

-- 
View this message in context: http://www.nabble.com/Felix-SCR-on-Android-issue-tp22945697p22974213.html
Sent from the Apache Felix - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
For additional commands, e-mail: users-help@felix.apache.org


Re: Felix SCR on Android issue

Posted by Clement Escoffier <cl...@gmail.com>.
Hi,


On 08.04.2009, at 10:39, Albert38 wrote:

>
> Hello,
> I'm very interested into the felix on android porting thing, which I  
> heard
> from the luminis' blog website. I then followed the tutorial on the  
> apache
> felix website and everything went well, but then I didn't manage to  
> make my
> personal bundles work, because the felix scr bundle doesn't seem to  
> work
> right. Did someone tried service component runtime successfully on  
> android?

Not SCR, but it should work. At least iPOJO works on Android :-)
http://ipojo-dark-side.blogspot.com/2008/10/ipojo-on-android.html


>
>
> In fact I get this error stack trace:
> ERROR: com.acse.systerminal.JainFacadeImpl (20): [JainSip Facade]  
> Cannot
> register Component
> java.lang.VerifyError:  
> org.apache.felix.scr.impl.ImmediateComponentManager
> at
> org 
> .apache 
> .felix.scr.impl.ManagerFactory.createManager(ManagerFactory.java:38)
>        at
> org 
> .apache 
> .felix 
> .scr 
> .impl 
> .BundleComponentActivator.initialize(BundleComponentActivator.java: 
> 181)
>        at
> org.apache.felix.scr.impl.BundleComponentActivator. 
> (BundleComponentActivator.java:110)
>        at
> org.apache.felix.scr.impl.Activator.loadComponents(Activator.java:227)
>        at
> org.apache.felix.scr.impl.Activator.bundleChanged(Activator.java:173)
>        at
> org 
> .apache 
> .felix 
> .framework 
> .util 
> .EventDispatcher.invokeBundleListenerCallback(EventDispatcher.java: 
> 690)
>        at
> org 
> .apache 
> .felix 
> .framework 
> .util.EventDispatcher.fireEventImmediately(EventDispatcher.java:619)
>        at
> org 
> .apache 
> .felix 
> .framework.util.EventDispatcher.fireBundleEvent(EventDispatcher.java: 
> 532)
>        at  
> org.apache.felix.framework.Felix.fireBundleEvent(Felix.java:3555)
>        at org.apache.felix.framework.Felix._startBundle(Felix.java: 
> 1660)
>        at org.apache.felix.framework.Felix.startBundle(Felix.java: 
> 1578)
>        at
> org.apache.felix.framework.Felix.setFrameworkStartLevel(Felix.java: 
> 1172)
>        at
> org.apache.felix.framework.StartLevelImpl.run(StartLevelImpl.java:265)
>        at java.lang.Thread.run(Thread.java:935)
>

That's bad. Maybe this class is using a not supported "construction".  
However, I'm not aware of such limitation in Dalvik.



> The other problematic thing is that when I'm "dexing" my
> org.apache.felix.scr.jar I get some warnings of that kind:
>
> warning: Ignoring InnerClasses attribute for an anonymous inner  
> class that
> doesn't come with an associated EnclosingMethod attribute. (This  
> class was
> probably produced by a broken compiler.)

That's "normal" (I never really found the reason). I also get those  
issues. But, despite those warnings, it should work.


Regards,

Clement


>
>
>
> Could anyone help?
>
> thx
>
> Albert.
>
>
>
> -- 
> View this message in context: http://www.nabble.com/Felix-SCR-on-Android-issue-tp22945697p22945697.html
> Sent from the Apache Felix - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
For additional commands, e-mail: users-help@felix.apache.org