[ 
https://issues.apache.org/jira/browse/LUCENE-2688?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12917952#action_12917952
 ] 

Robert Muir commented on LUCENE-2688:
-------------------------------------

bq. I'd only like to understand how is it that java.lang.management does not 
exist on Android, because that might indicate other classes don't exist as 
well, and thus fixing NativeFSLockFactory won't solve the real problem of 
running Lucene 3.x on Android.

exactly my point!

android doesn't have all the java apis (only a subset: 
http://developer.android.com/reference/packages.html)
its not actually java...

either we want lucene to fully work on it (which means we intentionally limit 
ourselves to the intersection of the 
java apis and the android apis, install a simulator on hudson, ensure ant test 
passes, etc), or we don't.

but i don't think we should degrade anything for it, in other words we 
shouldn't limit ourselves to its subset
if the damn thing isn't going to work anyway.

> NativeFSLockFactory throws an exception on Android 2.2 platform as 
> java.lang.management package is not available on android.
> ----------------------------------------------------------------------------------------------------------------------------
>
>                 Key: LUCENE-2688
>                 URL: https://issues.apache.org/jira/browse/LUCENE-2688
>             Project: Lucene - Java
>          Issue Type: Bug
>          Components: Store
>    Affects Versions: 3.0, 3.0.1, 3.0.2
>         Environment: Android 2.2 Froyo Nexus One
>            Reporter: Surinder Pal Singh Bindra
>             Fix For: 2.9.4, 3.0.3, 3.1, 4.0
>
>
> NativeFSLockFactory throws an exception on Android 2.2 platform as 
> java.lang.management package is not available on android.
>    Looks like FSDirectory defaults to NativeFSLockFactory, and this class 
> refers to java.lang.management package to generate a unique lock. 
> java.lang.management is not available in Android 2.2 and hence a runtime 
> exception is raised. The workaround is to use another custom LockFactory or 
> SimpleFSLockFactory, but Fixing NativeFSLockFactroy will help.
> Thanks,
> Surinder

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org
For additional commands, e-mail: dev-h...@lucene.apache.org

Reply via email to