Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id 2C2BD200C08 for ; Thu, 26 Jan 2017 11:33:29 +0100 (CET) Received: by cust-asf.ponee.io (Postfix) id 2AC26160B4C; Thu, 26 Jan 2017 10:33:29 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id 73EBD160B40 for ; Thu, 26 Jan 2017 11:33:28 +0100 (CET) Received: (qmail 27910 invoked by uid 500); 26 Jan 2017 10:33:27 -0000 Mailing-List: contact dev-help@olingo.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@olingo.apache.org Delivered-To: mailing list dev@olingo.apache.org Received: (qmail 27899 invoked by uid 99); 26 Jan 2017 10:33:27 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd1-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 26 Jan 2017 10:33:27 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd1-us-west.apache.org (ASF Mail Server at spamd1-us-west.apache.org) with ESMTP id F08FFC16EB for ; Thu, 26 Jan 2017 10:33:26 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd1-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -1.998 X-Spam-Level: X-Spam-Status: No, score=-1.998 tagged_above=-999 required=6.31 tests=[KAM_LAZY_DOMAIN_SECURITY=1, RP_MATCHES_RCVD=-2.999, URIBL_BLOCKED=0.001] autolearn=disabled Received: from mx1-lw-eu.apache.org ([10.40.0.8]) by localhost (spamd1-us-west.apache.org [10.40.0.7]) (amavisd-new, port 10024) with ESMTP id WQ0WJi078qMw for ; Thu, 26 Jan 2017 10:33:26 +0000 (UTC) Received: from mailrelay1-us-west.apache.org (mailrelay1-us-west.apache.org [209.188.14.139]) by mx1-lw-eu.apache.org (ASF Mail Server at mx1-lw-eu.apache.org) with ESMTP id 9AEE55F476 for ; Thu, 26 Jan 2017 10:33:25 +0000 (UTC) Received: from jira-lw-us.apache.org (unknown [207.244.88.139]) by mailrelay1-us-west.apache.org (ASF Mail Server at mailrelay1-us-west.apache.org) with ESMTP id CF782E03A4 for ; Thu, 26 Jan 2017 10:33:24 +0000 (UTC) Received: from jira-lw-us.apache.org (localhost [127.0.0.1]) by jira-lw-us.apache.org (ASF Mail Server at jira-lw-us.apache.org) with ESMTP id 6C08D2528C for ; Thu, 26 Jan 2017 10:33:24 +0000 (UTC) Date: Thu, 26 Jan 2017 10:33:24 +0000 (UTC) From: "Christian Amend (JIRA)" To: dev@olingo.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Resolved] (OLINGO-1025) Issue in Excel with relative context URI MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 archived-at: Thu, 26 Jan 2017 10:33:29 -0000 [ https://issues.apache.org/jira/browse/OLINGO-1025?page=3Dcom.atlassi= an.jira.plugin.system.issuetabpanels:all-tabpanel ] Christian Amend resolved OLINGO-1025. ------------------------------------- Resolution: Fixed Assignee: Christian Amend Fix Version/s: V2 2.0.9 Hi, You can use the "serviceRoot(URI)" method in the builder to get absolute UR= Ls. Best Regards, Christian > Issue in Excel with relative context URI > ---------------------------------------- > > Key: OLINGO-1025 > URL: https://issues.apache.org/jira/browse/OLINGO-1025 > Project: Olingo > Issue Type: Bug > Components: odata4-server > Affects Versions: (Java) V4 4.3.0 > Reporter: Olivier VERMONT > Assignee: Christian Amend > Fix For: V2 2.0.9 > > > Hi Olingo Team, > I'm trying out your library to publish an odata v4 stream to Excel Power = Query. > I started with your tutorial and ran into this first issue :=C2=A0Excel r= equires absolute metadata URL in service document which I solved by creatin= g a custom processor as indicated here : https://issues.apache.org/jira/bro= wse/OLINGO-758 > That enabled me to go one step further but I got stuck again when I reque= sted /Products because of the m:context which also seems to be relative : m= :context=3D"$metadata#Products" > I tried playing with the ContextURL but I only managed to come up with th= is which Excel doesn't like either : m:context=3D"../../../../$metadata#Pro= ducts=20 > Here is the code in the DemoEntityCollectionProcessor.java : > ContextURL contextUrl =3D ContextURL.with().entitySet(edmEntitySet).oData= Path(request.getRawBaseUri()).build(); > EntitySerializerOptions options =3D EntitySerializerOptions.with().contex= tURL(contextUrl).build(); > Here is the message I get in Excel : > DataSource.Error: OData : The top level context URL '$metadata#Products' = should be an absolute Uri. > D=C3=A9tails : > DataSourceKind=3DOData > DataSourcePath=3Dhttp://mydomain.net/Developpement/SettOData.nsf/odat= a.xsp/Products > Could anyone please help me to solve this issue ? > Regards, -- This message was sent by Atlassian JIRA (v6.3.4#6332)