Skip to Content
0
Former Member
Oct 06, 2017 at 02:21 PM

SAPUI5 [ODataMetadata] initial loading of metadata failed while using OData service

10626 Views Last edit Oct 06, 2017 at 07:56 AM 4 rev

Hi!

I have problem while using OData service with sapui
In manifest.json dataSource contiains:

"adminsRemote": {
  "uri": "/odata.svc/",
  "type": "OData"
}

/odata.svc/$metadata
results:

<?xml version="1.0" encoding="UTF-8" standalone="yes"?><edmx:Edmx Version="1.0" xmlns:edmx="http://schemas.microsoft.com/ado/2007/06/edmx"> <edmx:DataServices xmlns:m="http://schemas.microsoft.com/ado/2007/08/dataservices/metadata" m:DataServiceVersion="1.0" xmlns:edmx="http://schemas.microsoft.com/ado/2007/06/edmx">  <Schema Namespace="Data" xmlns:d="http://schemas.microsoft.com/ado/2007/08/dataservices" xmlns:m="http://schemas.microsoft.com/ado/2007/08/dataservices/metadata" xmlns="http://schemas.microsoft.com/ado/2007/05/edm">   <EntityType Name="Admin">    <Key>     <PropertyRef Name="id"/>    </Key>    <Property Name="id" Type="Edm.Int64" Nullable="false"/>    <Property Name="username" Type="Edm.String" Nullable="true"/>    <Property Name="email" Type="Edm.String" Nullable="true"/>   </EntityType>   <EntityContainer Name="Data" m:IsDefaultEntityContainer="true">    <EntitySet Name="Admins" EntityType="Data.Admin"/>   </EntityContainer>  </Schema> </edmx:DataServices></edmx:Edmx>

But the same error appeared:
[ODataMetadata] initial loading of metadata faile

In browser network panel I see, that metadata loaded correct, like sample above.

What's wrong?