New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Android Samsung devices crash on init #33
Comments
There is a test with android before each release now, to prevent this. Are you sure you have added the cache2k-api and cache2k-core jar to your application? |
I run the same exact build on my emulators and Nexus 5X and it works with no problem. However our crashlytics reports shows a spike for crashes with this stacktrace. Samsung Galaxy S6 running Android 5.0.1/2 are problematic so far |
oh, and yes, i have both: |
I tracked down a possible source of the problem. Please try to do:
Before doing anything with the cache. Here is some background on this: My apologies for the bad experience! Please report back whether this solves the problem. I will do a fix for the next release, so this is not needed any more. |
seems like it has been fixed with this, thanks for a quick response. It's Samsung, they always causing fragmentation issues, sorry. |
Perfect, you are welcome! Keeping the issue open, to remind me to do a change in the next release, so this workaround is not needed. |
👍 |
Fixed in 0.23 |
On Android 5.0 (so far) 100% samsung.
Crash happens every time I try to init Cache like so:
CacheBuilder.newCache(Long.class, BasePresenter.class)
.maxSize(maxSize)
.expiryDuration(expirationValue, expirationUnit)
.build();
01-22 11:33:28.474: E/AndroidRuntime(11647): java.lang.LinkageError: Error instantiating org.cache2k.spi.Cache2kCoreProvider, got java.io.IOException: Class resource file not found: org/cache2k/services/org.cache2k.spi.Cache2kCoreProvider
01-22 11:33:28.474: E/AndroidRuntime(11647): at org.cache2k.spi.SingleProviderResolver.loadProvider(SingleProviderResolver.java:101)
01-22 11:33:28.474: E/AndroidRuntime(11647): at org.cache2k.spi.SingleProviderResolver.resolve(SingleProviderResolver.java:86)
01-22 11:33:28.474: E/AndroidRuntime(11647): at org.cache2k.CacheBuilder.(CacheBuilder.java:41)
01-22 11:33:28.474: E/AndroidRuntime(11647): at com.remind101.PresenterManager.(PresenterManager.java:24)
01-22 11:33:28.474: E/AndroidRuntime(11647): at com.remind101.PresenterManager.getInstance(PresenterManager.java:32)
01-22 11:33:28.474: E/AndroidRuntime(11647): at com.remind101.ui.fragments.BaseMvpFragment.onSaveInstanceState(BaseMvpFragment.java:48)
01-22 11:33:28.474: E/AndroidRuntime(11647): at android.support.v4.app.Fragment.performSaveInstanceState(Fragment.java:2109)
01-22 11:33:28.474: E/AndroidRuntime(11647): at android.support.v4.app.FragmentManagerImpl.saveFragmentBasicState(FragmentManager.java:1767)
01-22 11:33:28.474: E/AndroidRuntime(11647): at android.support.v4.app.FragmentManagerImpl.saveAllState(FragmentManager.java:1835)
01-22 11:33:28.474: E/AndroidRuntime(11647): at android.support.v4.app.FragmentController.saveAllState(FragmentController.java:125)
01-22 11:33:28.474: E/AndroidRuntime(11647): at android.support.v4.app.FragmentActivity.onSaveInstanceState(FragmentActivity.java:523)
01-22 11:33:28.474: E/AndroidRuntime(11647): at com.remind101.ui.activities.ClassFeedActivity.onSaveInstanceState(ClassFeedActivity.java:304)
01-22 11:33:28.474: E/AndroidRuntime(11647): at android.app.Activity.performSaveInstanceState(Activity.java:1383)
01-22 11:33:28.474: E/AndroidRuntime(11647): at android.app.Instrumentation.callActivityOnSaveInstanceState(Instrumentation.java:1286)
01-22 11:33:28.474: E/AndroidRuntime(11647): at android.app.ActivityThread.callCallActivityOnSaveInstanceState(ActivityThread.java:4475)
01-22 11:33:28.474: E/AndroidRuntime(11647): at android.app.ActivityThread.performStopActivityInner(ActivityThread.java:3847)
01-22 11:33:28.474: E/AndroidRuntime(11647): at android.app.ActivityThread.handleStopActivity(ActivityThread.java:3910)
01-22 11:33:28.474: E/AndroidRuntime(11647): at android.app.ActivityThread.access$1200(ActivityThread.java:178)
01-22 11:33:28.474: E/AndroidRuntime(11647): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1473)
01-22 11:33:28.474: E/AndroidRuntime(11647): at android.os.Handler.dispatchMessage(Handler.java:102)
01-22 11:33:28.474: E/AndroidRuntime(11647): at android.os.Looper.loop(Looper.java:145)
01-22 11:33:28.474: E/AndroidRuntime(11647): at android.app.ActivityThread.main(ActivityThread.java:5944)
01-22 11:33:28.474: E/AndroidRuntime(11647): at java.lang.reflect.Method.invoke(Native Method)
01-22 11:33:28.474: E/AndroidRuntime(11647): at java.lang.reflect.Method.invoke(Method.java:372)
01-22 11:33:28.474: E/AndroidRuntime(11647): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1399)
01-22 11:33:28.474: E/AndroidRuntime(11647): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1194)
The text was updated successfully, but these errors were encountered: