Note that there are some explanatory texts on larger screens.

plurals
  1. POAndroid - can't retrieve $metadata from WCF Data Service
    text
    copied!<p>I'am using Restlet-Framework 2.1.2, from my Android app, I try retrieve data from WCF Data Service and recieve LogCat error messages:</p> <pre> Starting the HTTP client Get the metadata for http://Server.domain.local:82/northdata.svc/ at http:// Server.domain.local:82/northdata.svc/$metadata GC_CONCURRENT freed 1154K, 56% free 2966K/6727K, external 1625K/2137K, paused 4ms+6ms Can't get the metadata for http://Server.domain.local:82/northdata.svc/ java.io.IOException: Unable to create customized SAX source ... </pre> <p>My steps: I allow INTERNET permission in Manifest file:</p> <pre><code>uses-permission android:name="android.permission.INTERNET" uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" </code></pre> <p>I replace HTTP client:</p> <pre><code>Engine.getInstance().getRegisteredClients().clear(); Engine.getInstance().getRegisteredClients().add(new HttpClientHelper(null)); </code></pre> <p>and use StrictMode:</p> <pre><code>StrictMode.ThreadPolicy policy = new StrictMode.ThreadPolicy.Builder().permitAll().build(); StrictMode.setThreadPolicy(policy); </code></pre> <p>I use AsyncTask, my code:</p> <pre><code>protected String doInBackground(Object... params) { { try { NorthdataService service = new NorthdataService(); Query&lt;Customers&gt; queryCustomers = service .createCustomersQuery("/Customers"); } } catch (Exception e) { // return e; } return customers; } </code></pre> <p>What could it be? How I check \ get data from $metadata?</p> <p>P.S. I open my Data Service links in Android internal browser, it opened.</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload