Android的 - 工作灯混合应用程序无法连接到服务器仿真器 [英] Android - Worklight Hybrid application fails to connect to server in the emulator
问题描述
我创建了一个工作灯的应用程序。我试图运行在Android模拟器,应用程序和我收到以下错误。
I created a worklight application. I tried running that application on android emulator and i am getting the following error.
[http://localhost:8080/apps/services/api/MyFirstApp/android/query] Host is not responsive.
Try to manually access the URL through the android emulator browser to verify connectivity
于是,我在模拟器浏览器中输入相同的URL,我得到了下面的文字:
So i tried to enter the same url in the emulator browser, i got the following text:
/*-secure-
{"WL-Authentication-Failure": {"wl_remoteDisableRealm":{"reason":"Login Failed}}} */
有人可以帮助我?
Can someone help me with this?
我使用的Android操作系统版本:4.2.2,API等级:17
I am using Android OS version: 4.2.2, API level: 17
我并没有改变任何应用程序设置自己..
我试图去一个基本的登录页面的URL https://jazz.net/jazz/auth / j_security_check
I haven't changed any application settings myself.. I am trying to go to a basic login page with the url "https://jazz.net/jazz/auth/j_security_check"
这是我的适配器XML:
This is my adapter XML:
<wl:adapter xmlns:wl="worklight.com/integration"; xmlns:http="worklight.com/integration/http"; xmlns:xsi="w3.org/2001/XMLSchema-instance"; name="RQMAdapter">
<displayName>RQMAdapter</displayName>
<description>HTTP type Worklight Adapter for jazz server</description>
<connectivity>
<connectionPolicy xsi:type="http:HTTPConnectionPolicyType">
<protocol>https</protocol>
<domain>jazz.net</domain>
</connectionPolicy>
<loadConstraints maxConcurrentConnectionsPerNode="2" />
</connectivity>
<procedure name="loginToRQM" />
</wl:adapter>
这是我的情况:
我有,我需要了解从jazz.net项目对用户信息的要求。他们都是可用的XML文件中的Jazz服务器上。我需要把它处理到移动设备,使其可以手持设备上......所以,现在有人告诉我,我将不得不下载一些从服务器中的文件,所以我需要有文件IO我的应用程序。我了解到,我们需要使用科尔多瓦plug-in的工作灯来写这一部分。
This is my scenario: I have a requirement where I need to read information about the projects from jazz.net for a user. They are all available on the jazz server within an XML file. I need to process it to a mobile device to make it available on hand held device... So, now I am told that i will have to download some of the files from the server, so i need to have file IO on my app. I learned that we need to write this part using a Cordova plug-in in Worklight.
请让我知道需要什么其他的解决方案...谢谢
please let me know what else is needed for the solution... thank you
推荐答案
请务必将您的服务器计算机的实际IP地址:
Make sure to place the actual IP address of your server machine:
- 文件中更改
worklightServerRootURL
价值
应用descriptor.xml(位于:yourProject \\ APPS \\ yourApp) - 构建和部署
- 右键单击生成的Android项目>>运行方式>>运行应用程序
这篇关于Android的 - 工作灯混合应用程序无法连接到服务器仿真器的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!