ProGuard的后parse.com不工作 [英] parse.com not working after proguard

查看:147
本文介绍了ProGuard的后parse.com不工作的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用Parse.com功能在我的应用程序,一切的伟大工程在调试模式。 当我生成在释放模式已签名的apk,我有时杀人最多等待10秒打开我的应用程序的开始。 最有可能是因为Parse.com试图初始化和它的服务器,这显然是不成功的联系

I'm using Parse.com features in my app, everything works great on debugging mode. As soon as I generate a signed apk in release mode, I have a killing wait sometimes up to 10 seconds at the beginning of opening my app. most probably it's because of Parse.com trying to initialize and contact its servers, which apparently is not successful.

和也,parse.com停止工作,我知道是这样,因为没有数据将被上传到我的帐户。

And also, parse.com stops working I know so, since no data would be uploaded into my account.

应该有与Proguard的一个问题,当然,因为调试和释放模式的唯一区别,是使ProGuard的,在我的情况。

There should be a problem with Proguard of course since the only difference between debug and release mode, is enabling proguard, in my case.

我也triend保持com.parse与以下code在我ProGuard的规则:

I have also triend to keep com.parse with following code in my proguard rules:

 #keep parse classes
-keepattributes Annotation,SourceFile,LineNumberTable
-dontwarn com.parse.**
-keep class com.parse.* { *; }
-keep class com.parse.** { *; }

任何帮助将是AP preciated!

any help would be appreciated!

编辑:

我发现了一个巨大的内存泄漏是发生在Parse.initialize()Proguard的后...还是不知道为什么,但! 当然,这种内存泄漏是不是present而ProGuard的关

I found out that a huge memory leak is happening at the Parse.initialize() after the Proguard ... still have no idea why though! Of course this memory leak is not present while proguard is off

推荐答案

请尝试以下,如果你有Apache的 HTTP核 HTTP-MIME 以及解析库:

Try the following if you have Apache http-core and http-mime along with Parse library:

-keep class org.apache.** { *; }
-keep class com.parse.** { *; }

-dontwarn com.parse.**
-dontwarn org.apache.**
-dontwarn com.squareup.**

这篇关于ProGuard的后parse.com不工作的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆