Return-Path: X-Original-To: apmail-clerezza-dev-archive@www.apache.org Delivered-To: apmail-clerezza-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 00385FB16 for ; Tue, 26 Mar 2013 16:39:26 +0000 (UTC) Received: (qmail 37085 invoked by uid 500); 26 Mar 2013 16:39:20 -0000 Delivered-To: apmail-clerezza-dev-archive@clerezza.apache.org Received: (qmail 36678 invoked by uid 500); 26 Mar 2013 16:39:20 -0000 Mailing-List: contact dev-help@clerezza.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@clerezza.apache.org Delivered-To: mailing list dev@clerezza.apache.org Received: (qmail 36443 invoked by uid 500); 26 Mar 2013 16:39:19 -0000 Delivered-To: apmail-incubator-clerezza-dev@incubator.apache.org Received: (qmail 36403 invoked by uid 99); 26 Mar 2013 16:39:19 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 26 Mar 2013 16:39:19 +0000 X-ASF-Spam-Status: No, hits=2.2 required=5.0 tests=HTML_MESSAGE,RCVD_IN_DNSWL_LOW,SPF_NEUTRAL X-Spam-Check-By: apache.org Received-SPF: neutral (nike.apache.org: local policy) Received: from [209.85.215.45] (HELO mail-la0-f45.google.com) (209.85.215.45) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 26 Mar 2013 16:39:12 +0000 Received: by mail-la0-f45.google.com with SMTP id er20so14078686lab.32 for ; Tue, 26 Mar 2013 09:38:52 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=mime-version:x-received:sender:x-originating-ip:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type :x-gm-message-state; bh=SFftyuXyiZ3l/5L536xHYeUrop3+q3gqHlmv0Gx+6kg=; b=AbGzSyLwJCEvnhstYLpuxpOshI4Gh1cpDUmksQi0fBNhCmreGejAhPnZy5PhEmaAWF V4NFpLSag20i5swBT3oifN6+ZVTU52AZcb9Bc6Fo1DP6f3GIxCLZuwlKYT7r3qLeaGko 38ZBeuCUhjZWx6B8zrm3yLfr5Ec2Fth/AWDXdY5Xgpt43rSlVon6nRpMfJcJ+iJ6lwis vlpZ1wVAtc+Vsnu06CxgSM1W4DRDLeH59uhh7Xs2am2PDmd9q5HDQ4njnx2HirQvJcH0 5iNcESup04QGobM0qYNwiz3I+QtkdDUS85iwJAoogGRlhkqSIy4///SD4hRzRARq13LN gG3g== MIME-Version: 1.0 X-Received: by 10.152.135.205 with SMTP id pu13mr8529146lab.48.1364315931878; Tue, 26 Mar 2013 09:38:51 -0700 (PDT) Sender: me@farewellutopia.com Received: by 10.152.8.138 with HTTP; Tue, 26 Mar 2013 09:38:51 -0700 (PDT) X-Originating-IP: [95.128.94.82] Date: Tue, 26 Mar 2013 17:38:51 +0100 X-Google-Sender-Auth: O2Uw2GIvpo_8LIDpS7I8alPa5II Message-ID: Subject: Wink issue affecting clerezza From: =?ISO-8859-1?Q?Reto_Bachmann=2DGm=FCr?= To: clerezza-dev@incubator.apache.org Cc: wink-dev@incubator.apache.org Content-Type: multipart/alternative; boundary=f46d044284f87b4b0b04d8d68ec3 X-Gm-Message-State: ALoCoQmLPE+sVSt85TN6HeG/Oybh0VHi7KTTtsXP5pUsSPJ8n7jqOwyUyIBvhZ8+QdbELZr4IgHA X-Virus-Checked: Checked by ClamAV on apache.org --f46d044284f87b4b0b04d8d68ec3 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable The issue WINK-379 is I think the major blocker preventing us to release clerezza platform with wink. For example the sparql endpoint isn't working because of this issue. The sparql endoint jaxrs resource method returns an object that can be a graph, a resultset or a Boolean. Currently it only works when the client sets the accept header to prefer the right format, i.e. for a construct query one has to prefer rdf over xml and for a select query xml over rdf. If they prefer application/rdf+xml over application/xml and the query results in a ResultSet this will results in the following error. The system could not find a javax.ws.rs.ext.MessageBodyWriter or a DataSourceProvider class for the javax.xml.transform.dom.DOMSource type and application/rdf+xml mediaType. Ensure that a javax.ws.rs.ext.MessageBodyWriter exists in the JAX-RS application for the type and media type specified. Currently because of this some clerezza modules are working better in Stanbol than in clerezza. Stanbol is using jersey. The part of clerezza tied to wink is TypeRendering however with jax-rs 2.0 typerendering can be implemented in a portable way thanks to http://java.net/jira/browse/JAX_RS_SPEC-23 being resolved. Jax-rs 2.0 is currently implemented in jersey 2 release candidate and in a RestEasy 3 beta. I haven't tried any of them. WDYT? Reto ---------- Forwarded message ---------- From: Reto Bachmann-Gm=FCr Date: Sun, Mar 17, 2013 at 6:41 PM Subject: Re: 500 - Response and Error unless restricting accept header To: user@wink.apache.org Cc: wink-user@incubator.apache.org Hi Luciano The error occurs when the resource method has no @Produces (or @Produces(*/*) ) and there is no MessageBodyWriter for the first preference in the Accept header. Cheers, Reto On Sun, Mar 17, 2013 at 6:18 PM, Luciano Resende wrot= e: > On Sun, Jan 13, 2013 at 10:34 AM, Reto Bachmann-Gm=FCr > wrote: > > Hello > > > > When the accept header is set to > > > > Accept: text/html,application/xhtml+xml,application/xml;q=3D0.9,*/*;q= =3D0.8 > > > > I get a 500 reponse and the following errr is logged. > > > > 2013-01-13 19:27:25,639 [931211918@qtp-341460182-40] ERROR > > 931211918@qtp-341460182-40 > > org.apache.wink.server.internal.handlers.FlushResultHandler - The syste= m > > could not find a javax.ws.rs.ext.MessageBodyWriter or a > DataSourceProvider > > class for the > org.apache.clerezza.rdf.core.impl.util.PrivilegedGraphWrapper > > type and text/html mediaType. Ensure that a > > javax.ws.rs.ext.MessageBodyWriter exists in the JAX-RS application for > the > > type and media type specified. > > > > When I restrict the accept header to a format for which there is a > > MessageBodyWriter things works correctly. > > > > Is this a known problem or should I investigate further and create an > issue? > > > > Cheers, > > Reto > > I was trying to reproduce the error with the trunk code, I created a > simple resource that @produces application/xml and then used a browser > rest client to submit a request passing the accept header you > mentioned and it worked ok. Could you double check with trunk code and > maybe provide more details on how I could reproduce the issue. > > -- > Luciano Resende > http://people.apache.org/~lresende > http://twitter.com/lresende1975 > http://lresende.blogspot.com/ > --f46d044284f87b4b0b04d8d68ec3--