简体   繁体   English

将apk资源上传到appcenter期间发生异常

[英]Exception during resource upload of apk to appcenter

I've been trying to upload an Android application .apk file to an Worklight application center running on Power System Linux RHEL v6.5 and Worklight Foundation Server version 6.2.0.1. 我一直试图将Android应用程序.apk文件上传到在Power System Linux RHEL v6.5和Worklight Foundation Server版本6.2.0.1上运行的Worklight应用程序中心。 The AppCenter Database is DB2 V 10.5. AppCenter数据库是DB2 V 10.5。 I get the following error in the console.log for the appcenter server: 我在appcenter服务器的console.log中收到以下错误:

[err] dataBaseFromDataSource=true
[err] dataBaseUrl=jdbc:db2://localhost:50000/APPCNTR
[err] dataBaseDriver=IBM Data Server Driver for JDBC and SQLJ
[err] dataBaseDriverVersion=4.17
[err] dataBaseProduct=DB2/LINUXPPC64
[err] dataBaseVersion=SQL10053
[err] dataBaseUser=dasusr1
[err] 370  appcenterdb-db2  INFO   [Default Executor-thread-4] openjpa.Runtime - Starting OpenJPA      1.2.2
[err] 882  appcenterdb-db2  INFO   [Default Executor-thread-4] openjpa.jdbc.JDBC - Using dictionary class "org.apache.openjpa.jdbc.sql.DB2Dictionary" (DB2/LINUXPPC64 SQL10053 ,IBM Data Server Driver for JDBC and SQLJ 4.17.29).
[err] java.io.IOException: Expected chunk of type 0x11c0200, read 0x1200200.
[err]   at com.ibm.puremeap.util.android.ReadUtil.readCheckType(ReadUtil.java:32)
[err]   at com.ibm.puremeap.util.android.AndroidResourceParser.readPackage(AndroidResourceParser.java:80)
[err]   at com.ibm.puremeap.util.android.AndroidResourceParser.read(AndroidResourceParser.java:62)
[err]   at com.ibm.puremeap.util.android.AndroidAPKResolver.resolve(AndroidAPKResolver.java:138)
[err]   at com.ibm.puremeap.util.android.AAPT.getMetadata(AAPT.java:362)
[err]   at com.ibm.puremeap.services.UploadService.fileUploaded(UploadService.java:153)
[err]   at com.ibm.puremeap.services.UploadService.__fileUploadedJSON__(UploadService.java:106)
[err]   at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
[err]   at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:88)
[err]   at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:55)
[err]   at java.lang.reflect.Method.invoke(Method.java:618)
...
....
...

[ERROR   ] Exception during resource upload. null
[ERROR   ] {
        "id": "8a3f6944-8ce5-4323-9fa2-ac5d72483b31",
        "message": "FWLAC0000E: A server error was detected.",
        "productVersion": "6.2.0.01-20141013-1735"

I have successfully deployed the IBM AppCenter Installer but have yet to successfully upload an android application .apk file. 我已经成功部署了IBM AppCenter安装程序,但尚未成功上传android应用程序.apk文件。 I've manually installed the .apk on an android phone and the application installs and works just fine. 我已经在Android手机上手动安装了.apk,并且该应用程序已安装并正常运行。

I've tried to generate the .apk file a couple of different ways, but the result is always the same. 我尝试了几种不同的方式来生成.apk文件,但结果始终是相同的。 I've used the androidproject->run as->android application, exporting the application, as well as just copying the .apk file to a directory used for uploads. 我使用了androidproject-> run as-> android应用程序,导出了该应用程序,以及仅将.apk文件复制到用于上传的目录中。

My environment includes: 我的环境包括:

Android Development Toolkit Version: 23.0.4.1468518 Android开发工具包版本:23.0.4.1468518

Eclipse Version: Kepler Service Release 2 Build id: 20140224-062 Eclipse版本:Kepler Service Release 2内部版本号:20140224-062

您必须按照以下文档中的说明启用AAPT: http ://www-01.ibm.com/support/knowledgecenter/SSZH4A_6.1.0/com.ibm.worklight.installconfig.doc/admin/t_configuring_websphere_application_server_for_appcenter_manually.html?lang=en

The issue my environment had was the configured android build tools revisions installed. 我的环境存在的问题是安装了已配置的android构建工具修订版。 This can be viewed in the SDK Manager. 可以在SDK Manager中查看。

My target android sdk build defined in the project is 19. The installed android build tools, as viewed from the SDK Manager, included revisions 21, and 19.1. 我在项目中定义的目标android sdk构建为19。从SDK Manager查看,已安装的android构建工具包括版本21和19.1。 I had to remove revision 21 from the configuration and add revision 19. 我必须从配置中删除修订版21并添加修订版19。

The lessen learned from this exercise is to make sure your minSDK and target SDK builds are installed as shown in the Android SDK Manager. 从本练习中学到的教训是,确保按照Android SDK Manager中的说明安装minSDK和目标SDK版本。

With these changes, I can now successfully deploy mny androidapp.apk to a stand-alone Power System Linux server running the Worklight Server Application Center. 通过这些更改,我现在可以成功地将mny androidapp.apk部署到运行Worklight Server Application Center的独立Power System Linux服务器。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 MobileFirst Platform AppCenter apk上传失败 - MobileFirst Platform AppCenter apk upload fails Microsoft Appcenter并上传APK,而无需在Ionic 3应用程序上集成其SDK - Microsoft appcenter and upload APK without integrating their SDK on Ionic 3 app IBM Appcenter控制台apk无法上传-找不到android.aapt.dir - IBM Appcenter console apk fails to upload - Could not find android.aapt.dir APK上载期间Google Play错误 - Google play error during apk upload Appcenter找不到APK文件 - Appcenter can't find APK file 将新APK上传到Google Play商店进行生产期间发生错误 - error during Upload new APK to google play store for Production 使用口味使用 MS AppCenter 构建 Flutter android APK 的问题 - Issue building Flutter android APK with MS AppCenter using flavors IBM Worklight - IBM appcenter 客户端 (apk) 的推送通知未交付 - IBM Worklight - Push Notification for IBM appcenter client (apk) Not delivering Gradle 将 AppCenter 连接到 GitHub 时构建无法生成 .apk 文件 - Gradle build failed to produce an .apk file while connecting AppCenter to GitHub 渲染问题渲染期间引发的异常:无法找到布局资源 - Rendering Problems Exception raised during rendering: Could not find layout resource
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM