You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@stanbol.apache.org by Mihai Radulescu <mi...@salzburgresearch.at> on 2012/05/15 12:38:03 UTC

eHeath Use-case

Dear All,

First of all I will like to congratulate all of you on Stanbol, this is 
a very promising tool (or set of tools).

My name is Mihai Radulescu and I am a software developer at Salzbur 
Research (colleague of Rupert)
My current area or interest is eHealth and for the moment I work in 
eHealth research project named iMedication 
(http://www.salzburgresearch.at/projekt/imedication/ only in German).
One of the challenges in this project is usage of controlled 
terminologies like SNOMED-CT.
According with the last IKS web-log entry 
(http://blog.iks-project.eu/semantic-management-of-health-related-data-with-apache-stanbol/) 
some of you guys already index SNOMED-CT terminologies and use this 
information together with the entity hub.
I am interested to use the SNOMED-CT indexed information in the 
iMedication for better and faster searching, the searching is based on 
LDPath.
My question are :

  * Can I use the index SNOMED-CT terminologies ? If yes how I can
  * Do I need to proceed for a certain lincence (as far as SNOMED-CT
    requires one) ?
  * If I need support how do i need to call >

Thanks in advance,
Mihai

Re: eHeath Use-case

Posted by Suat Gonul <su...@gmail.com>.
Hi Mihai,

On 05/15/2012 01:38 PM, Mihai Radulescu wrote:
> Dear All,
>
> First of all I will like to congratulate all of you on Stanbol, this
> is a very promising tool (or set of tools).
>
> My name is Mihai Radulescu and I am a software developer at Salzbur
> Research (colleague of Rupert)
> My current area or interest is eHealth and for the moment I work in
> eHealth research project named iMedication
> (http://www.salzburgresearch.at/projekt/imedication/ only in German).
> One of the challenges in this project is usage of controlled
> terminologies like SNOMED-CT.
> According with the last IKS web-log entry
> (http://blog.iks-project.eu/semantic-management-of-health-related-data-with-apache-stanbol/)
> some of you guys already index SNOMED-CT terminologies and use this
> information together with the entity hub.
> I am interested to use the SNOMED-CT indexed information in the
> iMedication for better and faster searching, the searching is based on
> LDPath.
> My question are :
>
>  * Can I use the index SNOMED-CT terminologies ? If yes how I can

We can upload the Solr index including the SNOMED/CT to
dev.iks-project.eu. As you said, that index can be loaded into the
Stanbol and you can use LDPath endpoints of various features of
Entityhub to query over the index.

>  * Do I need to proceed for a certain lincence (as far as SNOMED-CT
>    requires one) ?

We have already applied for the license for this terminology to be used
in the scope of IKS project, however we are still waiting the answer.
According to [1] in section "Qualifying Research Project", free license
can be obtained for research projects satisfying some certain conditions.

>  * If I need support how do i need to call >

I would be glad to help if you have any questions.

Best,
Suat

>
> Thanks in advance,
> Mihai
>

[1] http://www.ihtsdo.org/join-us/affiliate/affiliatefees/


Re: Entityhub - Query

Posted by Rupert Westenthaler <ru...@gmail.com>.
Hi Sebastian

I tries the query with

    curl -X POST -H "Content-Type:application/json" --data
"@query.txt" http://dev.iks-project.eu:8080/entityhub/site/dbpedia/query

on

* dev.iks-project.eu:8080 (about 3 month old 0.9.0-incubating-SNAPSHOT)
* /dev.iks-project.eu:8081 (0.9.0-incubationg RC4)
* default config of the 0.10.0-incubating-SNAPSHOT

and it worked on all instances as expected. However this is not a big
surprise as exactly this query is also used within the
integration-tests to validate the ranged query implementation.

Because of that I guess that the problem is related to the data sent
in the request.

best
Rupert





---------- Forwarded message ----------
From: Sebastian Germesin <se...@dfki.de>
Date: Fri, May 18, 2012 at 3:45 PM
Subject: Entityhub - Query
To: stanbol-dev@incubator.apache.org


Dear all,

I am currently implementing the query endpoint of the entityhub
(addresses VIE issue #64 (https://github.com/bergie/VIE/issues/64))

http://dev.iks-project.eu:8080/entityhub/query

Using the folling query from the documentation:

            {
            "selected": [
                         "http://www.w3.org/2000/01/rdf-schema#label",
                         "http://dbpedia.org/ontology/birthDate",
                         "http://dbpedia.org/ontology/deathDate"],
                     "offset": "0",
                     "limit": "3",
                     "constraints": [{
                         "type": "range",
                         "field": "http://dbpedia.org/ontology/birthDate",
                         "lowerBound": "1946-01-01T00:00:00.000Z",
                         "upperBound": "1946-12-31T23:59:59.999Z",
                         "inclusive": true,
                         "datatype": "xsd:dateTime"
                     },{
                         "type": "reference",
                         "field":
"http://www.w3.org/1999/02/22-rdf-syntax-ns#type",
                         "value": "http://dbpedia.org/ontology/Person",
                     }]
                 }

The expected results should include entities: Bill Clinton, George W.
Bush and Donald Trump. However, no results are returned. Is something
wrong with the query?

Thanks a lot in advance,

Sebastian


-- 
| Rupert Westenthaler             rupert.westenthaler@gmail.com
| Bodenlehenstraße 11                             ++43-699-11108907
| A-5500 Bischofshofen

Entityhub - Query

Posted by Sebastian Germesin <se...@dfki.de>.
Dear all,

I am currently implementing the query endpoint of the entityhub (addresses VIE issue #64 (https://github.com/bergie/VIE/issues/64))

http://dev.iks-project.eu:8080/entityhub/query

Using the folling query from the documentation:

             {
             "selected": [
                          "http://www.w3.org/2000/01/rdf-schema#label",
                          "http://dbpedia.org/ontology/birthDate",
                          "http://dbpedia.org/ontology/deathDate"],
                      "offset": "0",
                      "limit": "3",
                      "constraints": [{ 
                          "type": "range", 
                          "field": "http://dbpedia.org/ontology/birthDate", 
                          "lowerBound": "1946-01-01T00:00:00.000Z",
                          "upperBound": "1946-12-31T23:59:59.999Z",
                          "inclusive": true,
                          "datatype": "xsd:dateTime"
                      },{ 
                          "type": "reference", 
                          "field": "http://www.w3.org/1999/02/22-rdf-syntax-ns#type", 
                          "value": "http://dbpedia.org/ontology/Person", 
                      }]
                  }

The expected results should include entities: Bill Clinton, George W. Bush and Donald Trump. However, no results are returned. Is something wrong with the query?

Thanks a lot in advance,

Sebastian

Re: Apache StanbolService implementation in VIE (ContentHub)

Posted by Suat Gonul <su...@gmail.com>.
Added an item to FAQ list.

Best,
Suat

On 05/18/2012 01:03 PM, Rupert Westenthaler wrote:
> Hi Suat
>
> Can you add a this to the Stanbol Documentation at a prominent
> position as I think this is rather important to a lot of Stanbol
> users. Best incl. a screenshot of the configuration dialog of the
> JerseyEndpoint.
>
> best
> Rupert
>
> On Fri, May 18, 2012 at 9:56 AM, Sebastian Germesin
> <se...@dfki.de> wrote:
>> Dear Suat,
>>
>> thank you, we will try it these days and let you know if that worked.
>>
>> Best regards,
>>
>> Sebastian
>> On 18.05.2012, at 09:49, Suat Gonul wrote:
>>
>>> Hi Sebastian,
>>>
>>> I committed the code exposing the Location header in
>>> "Access-Control-Expose-Headers" header . If you need other headers, they
>>> should be added to the CORS Access-Control-Expose-Headers configuration
>>> of JerseyEndpoint of Stanbol. I hope this would be a solution for you.
>>>
>>> Best,
>>> Suat
>>>
>>> On 05/17/2012 03:16 PM, Suat Gonul wrote:
>>>> Hi Sebastian,
>>>>
>>>> I managed to obtain the Location header in javascript. It seems server
>>>> should expose the header in the Access-Control-Expose-Headers so that
>>>> clients can access. However, I managed this with only Google Chrome.
>>>> Firefox 12 still returns the empty results. I read in some articles that
>>>> some browsers have buggy implementations regarding the
>>>> XMLHttpRequest.getRequestHeader method, e.g [1].
>>>>
>>>> Anyway, I will add the necessary code exposing the headers.
>>>>
>>>> Best,
>>>> Suat
>>>>
>>>> [1] http://www.html5rocks.com/en/tutorials/cors/
>>>>
>>>> On 05/16/2012 04:39 PM, Sebastian Germesin wrote:
>>>>> Hi Suat,
>>>>>
>>>>> thanks for checking and for the link. That is bad... How do you think can we ship around this?
>>>>>
>>>>> From my point of view, duplicating the location (the URI) in the content of the response does not
>>>>> hurt the specs and helps me on the client side.
>>>>>
>>>>> Would that be a proper solution?
>>>>>
>>>>> Best regards,
>>>>>
>>>>> Sebastian
>>>>>
>>>>> On 16.05.2012, at 15:26, Suat Gonul wrote:
>>>>>
>>>>>> Hi Sebastian,
>>>>>>
>>>>>> I have tried a number of cases for the header specifications while
>>>>>> sending the query to Contenthub, but I could not read the Location
>>>>>> header with jQuery at all, even any other headers. However, the details
>>>>>> of the response seems like as follows through the Live HTTP Headers
>>>>>> plugin in Firefox:
>>>>>>
>>>>>> HTTP/1.1 201 Created
>>>>>> Access-Control-Allow-Origin: *
>>>>>> Location:
>>>>>> http://localhost:8080/contenthub/contenthub/store/content/urn:content-item-sha1-358dbe75624b135aa72c1ad6cc34f325bf7fdf50
>>>>>>
>>>>>> Content-Length: 0
>>>>>> Server: Jetty(6.1.x)
>>>>>>
>>>>>> Then, I ran across the following note in [1]:
>>>>>> "The Cross-Origin Resource Sharing specification filters the headers
>>>>>> that are exposed by |getAllResponseHeaders()
>>>>>> <http://dvcs.w3.org/hg/xhr/raw-file/tip/Overview.html#dom-xmlhttprequest-getallresponseheaders>|
>>>>>> for non same-origin
>>>>>> <http://www.whatwg.org/specs/web-apps/current-work/multipage/origin-0.html#same-origin>
>>>>>> requests."
>>>>>>
>>>>>> I think this may be the reason. I'm not sure though.
>>>>>>
>>>>>> [1]
>>>>>> http://dvcs.w3.org/hg/xhr/raw-file/tip/Overview.html#dom-xmlhttprequest-getallresponseheaders
>>>>>>
>>>>>> Best,
>>>>>> Suat
>>>>>>
>>>>>>
>>>>>> On 05/15/2012 07:19 PM, Sebastian Germesin wrote:
>>>>>>> Dear all,
>>>>>>>
>>>>>>> we are currently working on extending the VIE.StanbolService and currently face a problem with the content hub of Apache Stanbol.
>>>>>>>
>>>>>>> From the REST API, it seems that a simple HTTP-POST request is enough to create a resource and in fact it works and the result is a HTTP response (201 - Created).
>>>>>>>
>>>>>>> However, using jQuery, we are currently not able to retrieve the location of the created resource, to be more precise, the "Location" header field is not readable from jQuery.
>>>>>>>
>>>>>>> I've created a jsbin example for you to test the code:
>>>>>>>
>>>>>>> http://jsbin.com/unekoh/edit#javascript,html,live
>>>>>>>
>>>>>>> Could you please be so kind to have a look at it and check why jQuery is not able to parse the header?
>>>>>>>
>>>>>>> Is it maybe possible to also send the location as response text?
>>>>>>>
>>>>>>>
>>>>>>> Thanks a lot in advance,
>>>>>>>
>>>>>>> Sebastian
>>>>> --
>>>>> M.Sc. Sebastian Germesin
>>>>>
>>>>> DFKI GmbH
>>>>> Campus D3 2
>>>>> Stuhlsatzenhausweg 3
>>>>> D-66123 Saarbruecken, Germany
>>>>>
>>>>> phone:      +49 (681) 85775 - 5079
>>>>> fax:        +49 (681) 85775 - 5021
>>>>> mail:       sebastian.germesin@dfki.de
>>>>> http:       www.dfki.de/~germesin
>>>>> skype:      neogermi1337
>>>>> twitter:    germesin
>>>>>
>> --
>> M.Sc. Sebastian Germesin
>>
>> DFKI GmbH
>> Campus D3 2
>> Stuhlsatzenhausweg 3
>> D-66123 Saarbruecken, Germany
>>
>> phone:  +49 (681) 85775 - 5079
>> fax:    +49 (681) 85775 - 5021
>> mail:   sebastian.germesin@dfki.de
>> http:   www.dfki.de/~germesin
>> skype:  neogermi1337
>> twitter:    germesin
>>
>> --
>> Deutsches Forschungszentrum fuer Kuenstliche Intelligenz (DFKI) GmbH
>> Firmensitz: Trippstadter Strasse 122, D-67663 Kaiserslautern; Amtsgericht Kaiserslautern, HRB 2313
>> Geschaeftsfuehrung: Prof. Dr. Dr. h.c. mult. Wolfgang Wahlster (Vorsitzender), Dr. Walter Olthoff
>> Vorsitzender des Aufsichtsrats: Prof. Dr. h.c. Hans A. Aukes
>>
>
>


Re: Apache StanbolService implementation in VIE (ContentHub)

Posted by Fabian Christ <ch...@googlemail.com>.
Hi,

IMO the Apache CMS that is used by Apache Stanbol to create its
website is not that difficult to use. It is just simple Markdown text
files. The website's sources are available via SVN from

http://svn.apache.org/repos/asf/incubator/stanbol/site/

So improving the documentation for non-committers is a matter of
creating a JIRA issue and submitting a patch to the site sources.

A Wiki may be easier to use at a first glance but I like the idea to
have all docs in a single system at one place. What do others think?

Best,
 - Fabian

2012/5/18 seralf <se...@gmail.com>:
> is it possibile to create a sort of collaborative wiki? i think the entire
> community could contribute writing materials (even on the lesser obvious
> use-case) that could be edited by the project manager in order to make a
> revised documentation.
> Alfredo
>
> 2012/5/18 Rupert Westenthaler <ru...@gmail.com>
>
>> Hi Suat
>>
>> Can you add a this to the Stanbol Documentation at a prominent
>> position as I think this is rather important to a lot of Stanbol
>> users. Best incl. a screenshot of the configuration dialog of the
>> JerseyEndpoint.
>>
>> best
>> Rupert
>>
>> On Fri, May 18, 2012 at 9:56 AM, Sebastian Germesin
>> <se...@dfki.de> wrote:
>> > Dear Suat,
>> >
>> > thank you, we will try it these days and let you know if that worked.
>> >
>> > Best regards,
>> >
>> > Sebastian
>> > On 18.05.2012, at 09:49, Suat Gonul wrote:
>> >
>> >> Hi Sebastian,
>> >>
>> >> I committed the code exposing the Location header in
>> >> "Access-Control-Expose-Headers" header . If you need other headers, they
>> >> should be added to the CORS Access-Control-Expose-Headers configuration
>> >> of JerseyEndpoint of Stanbol. I hope this would be a solution for you.
>> >>
>> >> Best,
>> >> Suat
>> >>
>> >> On 05/17/2012 03:16 PM, Suat Gonul wrote:
>> >>> Hi Sebastian,
>> >>>
>> >>> I managed to obtain the Location header in javascript. It seems server
>> >>> should expose the header in the Access-Control-Expose-Headers so that
>> >>> clients can access. However, I managed this with only Google Chrome.
>> >>> Firefox 12 still returns the empty results. I read in some articles
>> that
>> >>> some browsers have buggy implementations regarding the
>> >>> XMLHttpRequest.getRequestHeader method, e.g [1].
>> >>>
>> >>> Anyway, I will add the necessary code exposing the headers.
>> >>>
>> >>> Best,
>> >>> Suat
>> >>>
>> >>> [1] http://www.html5rocks.com/en/tutorials/cors/
>> >>>
>> >>> On 05/16/2012 04:39 PM, Sebastian Germesin wrote:
>> >>>> Hi Suat,
>> >>>>
>> >>>> thanks for checking and for the link. That is bad... How do you think
>> can we ship around this?
>> >>>>
>> >>>> From my point of view, duplicating the location (the URI) in the
>> content of the response does not
>> >>>> hurt the specs and helps me on the client side.
>> >>>>
>> >>>> Would that be a proper solution?
>> >>>>
>> >>>> Best regards,
>> >>>>
>> >>>> Sebastian
>> >>>>
>> >>>> On 16.05.2012, at 15:26, Suat Gonul wrote:
>> >>>>
>> >>>>> Hi Sebastian,
>> >>>>>
>> >>>>> I have tried a number of cases for the header specifications while
>> >>>>> sending the query to Contenthub, but I could not read the Location
>> >>>>> header with jQuery at all, even any other headers. However, the
>> details
>> >>>>> of the response seems like as follows through the Live HTTP Headers
>> >>>>> plugin in Firefox:
>> >>>>>
>> >>>>> HTTP/1.1 201 Created
>> >>>>> Access-Control-Allow-Origin: *
>> >>>>> Location:
>> >>>>>
>> http://localhost:8080/contenthub/contenthub/store/content/urn:content-item-sha1-358dbe75624b135aa72c1ad6cc34f325bf7fdf50
>> >>>>>
>> >>>>> Content-Length: 0
>> >>>>> Server: Jetty(6.1.x)
>> >>>>>
>> >>>>> Then, I ran across the following note in [1]:
>> >>>>> "The Cross-Origin Resource Sharing specification filters the headers
>> >>>>> that are exposed by |getAllResponseHeaders()
>> >>>>> <
>> http://dvcs.w3.org/hg/xhr/raw-file/tip/Overview.html#dom-xmlhttprequest-getallresponseheaders
>> >|
>> >>>>> for non same-origin
>> >>>>> <
>> http://www.whatwg.org/specs/web-apps/current-work/multipage/origin-0.html#same-origin
>> >
>> >>>>> requests."
>> >>>>>
>> >>>>> I think this may be the reason. I'm not sure though.
>> >>>>>
>> >>>>> [1]
>> >>>>>
>> http://dvcs.w3.org/hg/xhr/raw-file/tip/Overview.html#dom-xmlhttprequest-getallresponseheaders
>> >>>>>
>> >>>>> Best,
>> >>>>> Suat
>> >>>>>
>> >>>>>
>> >>>>> On 05/15/2012 07:19 PM, Sebastian Germesin wrote:
>> >>>>>> Dear all,
>> >>>>>>
>> >>>>>> we are currently working on extending the VIE.StanbolService and
>> currently face a problem with the content hub of Apache Stanbol.
>> >>>>>>
>> >>>>>> From the REST API, it seems that a simple HTTP-POST request is
>> enough to create a resource and in fact it works and the result is a HTTP
>> response (201 - Created).
>> >>>>>>
>> >>>>>> However, using jQuery, we are currently not able to retrieve the
>> location of the created resource, to be more precise, the "Location" header
>> field is not readable from jQuery.
>> >>>>>>
>> >>>>>> I've created a jsbin example for you to test the code:
>> >>>>>>
>> >>>>>> http://jsbin.com/unekoh/edit#javascript,html,live
>> >>>>>>
>> >>>>>> Could you please be so kind to have a look at it and check why
>> jQuery is not able to parse the header?
>> >>>>>>
>> >>>>>> Is it maybe possible to also send the location as response text?
>> >>>>>>
>> >>>>>>
>> >>>>>> Thanks a lot in advance,
>> >>>>>>
>> >>>>>> Sebastian
>> >>>> --
>> >>>> M.Sc. Sebastian Germesin
>> >>>>
>> >>>> DFKI GmbH
>> >>>> Campus D3 2
>> >>>> Stuhlsatzenhausweg 3
>> >>>> D-66123 Saarbruecken, Germany
>> >>>>
>> >>>> phone:      +49 (681) 85775 - 5079
>> >>>> fax:        +49 (681) 85775 - 5021
>> >>>> mail:       sebastian.germesin@dfki.de
>> >>>> http:       www.dfki.de/~germesin
>> >>>> skype:      neogermi1337
>> >>>> twitter:    germesin
>> >>>>
>> >>
>> >
>> > --
>> > M.Sc. Sebastian Germesin
>> >
>> > DFKI GmbH
>> > Campus D3 2
>> > Stuhlsatzenhausweg 3
>> > D-66123 Saarbruecken, Germany
>> >
>> > phone:  +49 (681) 85775 - 5079
>> > fax:    +49 (681) 85775 - 5021
>> > mail:   sebastian.germesin@dfki.de
>> > http:   www.dfki.de/~germesin
>> > skype:  neogermi1337
>> > twitter:    germesin
>> >
>> > --
>> > Deutsches Forschungszentrum fuer Kuenstliche Intelligenz (DFKI) GmbH
>> > Firmensitz: Trippstadter Strasse 122, D-67663 Kaiserslautern;
>> Amtsgericht Kaiserslautern, HRB 2313
>> > Geschaeftsfuehrung: Prof. Dr. Dr. h.c. mult. Wolfgang Wahlster
>> (Vorsitzender), Dr. Walter Olthoff
>> > Vorsitzender des Aufsichtsrats: Prof. Dr. h.c. Hans A. Aukes
>> >
>>
>>
>>
>> --
>> | Rupert Westenthaler             rupert.westenthaler@gmail.com
>> | Bodenlehenstraße 11                             ++43-699-11108907
>> | A-5500 Bischofshofen
>>



-- 
Fabian
http://twitter.com/fctwitt

Re: Apache StanbolService implementation in VIE (ContentHub)

Posted by seralf <se...@gmail.com>.
is it possibile to create a sort of collaborative wiki? i think the entire
community could contribute writing materials (even on the lesser obvious
use-case) that could be edited by the project manager in order to make a
revised documentation.
Alfredo

2012/5/18 Rupert Westenthaler <ru...@gmail.com>

> Hi Suat
>
> Can you add a this to the Stanbol Documentation at a prominent
> position as I think this is rather important to a lot of Stanbol
> users. Best incl. a screenshot of the configuration dialog of the
> JerseyEndpoint.
>
> best
> Rupert
>
> On Fri, May 18, 2012 at 9:56 AM, Sebastian Germesin
> <se...@dfki.de> wrote:
> > Dear Suat,
> >
> > thank you, we will try it these days and let you know if that worked.
> >
> > Best regards,
> >
> > Sebastian
> > On 18.05.2012, at 09:49, Suat Gonul wrote:
> >
> >> Hi Sebastian,
> >>
> >> I committed the code exposing the Location header in
> >> "Access-Control-Expose-Headers" header . If you need other headers, they
> >> should be added to the CORS Access-Control-Expose-Headers configuration
> >> of JerseyEndpoint of Stanbol. I hope this would be a solution for you.
> >>
> >> Best,
> >> Suat
> >>
> >> On 05/17/2012 03:16 PM, Suat Gonul wrote:
> >>> Hi Sebastian,
> >>>
> >>> I managed to obtain the Location header in javascript. It seems server
> >>> should expose the header in the Access-Control-Expose-Headers so that
> >>> clients can access. However, I managed this with only Google Chrome.
> >>> Firefox 12 still returns the empty results. I read in some articles
> that
> >>> some browsers have buggy implementations regarding the
> >>> XMLHttpRequest.getRequestHeader method, e.g [1].
> >>>
> >>> Anyway, I will add the necessary code exposing the headers.
> >>>
> >>> Best,
> >>> Suat
> >>>
> >>> [1] http://www.html5rocks.com/en/tutorials/cors/
> >>>
> >>> On 05/16/2012 04:39 PM, Sebastian Germesin wrote:
> >>>> Hi Suat,
> >>>>
> >>>> thanks for checking and for the link. That is bad... How do you think
> can we ship around this?
> >>>>
> >>>> From my point of view, duplicating the location (the URI) in the
> content of the response does not
> >>>> hurt the specs and helps me on the client side.
> >>>>
> >>>> Would that be a proper solution?
> >>>>
> >>>> Best regards,
> >>>>
> >>>> Sebastian
> >>>>
> >>>> On 16.05.2012, at 15:26, Suat Gonul wrote:
> >>>>
> >>>>> Hi Sebastian,
> >>>>>
> >>>>> I have tried a number of cases for the header specifications while
> >>>>> sending the query to Contenthub, but I could not read the Location
> >>>>> header with jQuery at all, even any other headers. However, the
> details
> >>>>> of the response seems like as follows through the Live HTTP Headers
> >>>>> plugin in Firefox:
> >>>>>
> >>>>> HTTP/1.1 201 Created
> >>>>> Access-Control-Allow-Origin: *
> >>>>> Location:
> >>>>>
> http://localhost:8080/contenthub/contenthub/store/content/urn:content-item-sha1-358dbe75624b135aa72c1ad6cc34f325bf7fdf50
> >>>>>
> >>>>> Content-Length: 0
> >>>>> Server: Jetty(6.1.x)
> >>>>>
> >>>>> Then, I ran across the following note in [1]:
> >>>>> "The Cross-Origin Resource Sharing specification filters the headers
> >>>>> that are exposed by |getAllResponseHeaders()
> >>>>> <
> http://dvcs.w3.org/hg/xhr/raw-file/tip/Overview.html#dom-xmlhttprequest-getallresponseheaders
> >|
> >>>>> for non same-origin
> >>>>> <
> http://www.whatwg.org/specs/web-apps/current-work/multipage/origin-0.html#same-origin
> >
> >>>>> requests."
> >>>>>
> >>>>> I think this may be the reason. I'm not sure though.
> >>>>>
> >>>>> [1]
> >>>>>
> http://dvcs.w3.org/hg/xhr/raw-file/tip/Overview.html#dom-xmlhttprequest-getallresponseheaders
> >>>>>
> >>>>> Best,
> >>>>> Suat
> >>>>>
> >>>>>
> >>>>> On 05/15/2012 07:19 PM, Sebastian Germesin wrote:
> >>>>>> Dear all,
> >>>>>>
> >>>>>> we are currently working on extending the VIE.StanbolService and
> currently face a problem with the content hub of Apache Stanbol.
> >>>>>>
> >>>>>> From the REST API, it seems that a simple HTTP-POST request is
> enough to create a resource and in fact it works and the result is a HTTP
> response (201 - Created).
> >>>>>>
> >>>>>> However, using jQuery, we are currently not able to retrieve the
> location of the created resource, to be more precise, the "Location" header
> field is not readable from jQuery.
> >>>>>>
> >>>>>> I've created a jsbin example for you to test the code:
> >>>>>>
> >>>>>> http://jsbin.com/unekoh/edit#javascript,html,live
> >>>>>>
> >>>>>> Could you please be so kind to have a look at it and check why
> jQuery is not able to parse the header?
> >>>>>>
> >>>>>> Is it maybe possible to also send the location as response text?
> >>>>>>
> >>>>>>
> >>>>>> Thanks a lot in advance,
> >>>>>>
> >>>>>> Sebastian
> >>>> --
> >>>> M.Sc. Sebastian Germesin
> >>>>
> >>>> DFKI GmbH
> >>>> Campus D3 2
> >>>> Stuhlsatzenhausweg 3
> >>>> D-66123 Saarbruecken, Germany
> >>>>
> >>>> phone:      +49 (681) 85775 - 5079
> >>>> fax:        +49 (681) 85775 - 5021
> >>>> mail:       sebastian.germesin@dfki.de
> >>>> http:       www.dfki.de/~germesin
> >>>> skype:      neogermi1337
> >>>> twitter:    germesin
> >>>>
> >>
> >
> > --
> > M.Sc. Sebastian Germesin
> >
> > DFKI GmbH
> > Campus D3 2
> > Stuhlsatzenhausweg 3
> > D-66123 Saarbruecken, Germany
> >
> > phone:  +49 (681) 85775 - 5079
> > fax:    +49 (681) 85775 - 5021
> > mail:   sebastian.germesin@dfki.de
> > http:   www.dfki.de/~germesin
> > skype:  neogermi1337
> > twitter:    germesin
> >
> > --
> > Deutsches Forschungszentrum fuer Kuenstliche Intelligenz (DFKI) GmbH
> > Firmensitz: Trippstadter Strasse 122, D-67663 Kaiserslautern;
> Amtsgericht Kaiserslautern, HRB 2313
> > Geschaeftsfuehrung: Prof. Dr. Dr. h.c. mult. Wolfgang Wahlster
> (Vorsitzender), Dr. Walter Olthoff
> > Vorsitzender des Aufsichtsrats: Prof. Dr. h.c. Hans A. Aukes
> >
>
>
>
> --
> | Rupert Westenthaler             rupert.westenthaler@gmail.com
> | Bodenlehenstraße 11                             ++43-699-11108907
> | A-5500 Bischofshofen
>

Re: Apache StanbolService implementation in VIE (ContentHub)

Posted by Rupert Westenthaler <ru...@gmail.com>.
Hi Suat

Can you add a this to the Stanbol Documentation at a prominent
position as I think this is rather important to a lot of Stanbol
users. Best incl. a screenshot of the configuration dialog of the
JerseyEndpoint.

best
Rupert

On Fri, May 18, 2012 at 9:56 AM, Sebastian Germesin
<se...@dfki.de> wrote:
> Dear Suat,
>
> thank you, we will try it these days and let you know if that worked.
>
> Best regards,
>
> Sebastian
> On 18.05.2012, at 09:49, Suat Gonul wrote:
>
>> Hi Sebastian,
>>
>> I committed the code exposing the Location header in
>> "Access-Control-Expose-Headers" header . If you need other headers, they
>> should be added to the CORS Access-Control-Expose-Headers configuration
>> of JerseyEndpoint of Stanbol. I hope this would be a solution for you.
>>
>> Best,
>> Suat
>>
>> On 05/17/2012 03:16 PM, Suat Gonul wrote:
>>> Hi Sebastian,
>>>
>>> I managed to obtain the Location header in javascript. It seems server
>>> should expose the header in the Access-Control-Expose-Headers so that
>>> clients can access. However, I managed this with only Google Chrome.
>>> Firefox 12 still returns the empty results. I read in some articles that
>>> some browsers have buggy implementations regarding the
>>> XMLHttpRequest.getRequestHeader method, e.g [1].
>>>
>>> Anyway, I will add the necessary code exposing the headers.
>>>
>>> Best,
>>> Suat
>>>
>>> [1] http://www.html5rocks.com/en/tutorials/cors/
>>>
>>> On 05/16/2012 04:39 PM, Sebastian Germesin wrote:
>>>> Hi Suat,
>>>>
>>>> thanks for checking and for the link. That is bad... How do you think can we ship around this?
>>>>
>>>> From my point of view, duplicating the location (the URI) in the content of the response does not
>>>> hurt the specs and helps me on the client side.
>>>>
>>>> Would that be a proper solution?
>>>>
>>>> Best regards,
>>>>
>>>> Sebastian
>>>>
>>>> On 16.05.2012, at 15:26, Suat Gonul wrote:
>>>>
>>>>> Hi Sebastian,
>>>>>
>>>>> I have tried a number of cases for the header specifications while
>>>>> sending the query to Contenthub, but I could not read the Location
>>>>> header with jQuery at all, even any other headers. However, the details
>>>>> of the response seems like as follows through the Live HTTP Headers
>>>>> plugin in Firefox:
>>>>>
>>>>> HTTP/1.1 201 Created
>>>>> Access-Control-Allow-Origin: *
>>>>> Location:
>>>>> http://localhost:8080/contenthub/contenthub/store/content/urn:content-item-sha1-358dbe75624b135aa72c1ad6cc34f325bf7fdf50
>>>>>
>>>>> Content-Length: 0
>>>>> Server: Jetty(6.1.x)
>>>>>
>>>>> Then, I ran across the following note in [1]:
>>>>> "The Cross-Origin Resource Sharing specification filters the headers
>>>>> that are exposed by |getAllResponseHeaders()
>>>>> <http://dvcs.w3.org/hg/xhr/raw-file/tip/Overview.html#dom-xmlhttprequest-getallresponseheaders>|
>>>>> for non same-origin
>>>>> <http://www.whatwg.org/specs/web-apps/current-work/multipage/origin-0.html#same-origin>
>>>>> requests."
>>>>>
>>>>> I think this may be the reason. I'm not sure though.
>>>>>
>>>>> [1]
>>>>> http://dvcs.w3.org/hg/xhr/raw-file/tip/Overview.html#dom-xmlhttprequest-getallresponseheaders
>>>>>
>>>>> Best,
>>>>> Suat
>>>>>
>>>>>
>>>>> On 05/15/2012 07:19 PM, Sebastian Germesin wrote:
>>>>>> Dear all,
>>>>>>
>>>>>> we are currently working on extending the VIE.StanbolService and currently face a problem with the content hub of Apache Stanbol.
>>>>>>
>>>>>> From the REST API, it seems that a simple HTTP-POST request is enough to create a resource and in fact it works and the result is a HTTP response (201 - Created).
>>>>>>
>>>>>> However, using jQuery, we are currently not able to retrieve the location of the created resource, to be more precise, the "Location" header field is not readable from jQuery.
>>>>>>
>>>>>> I've created a jsbin example for you to test the code:
>>>>>>
>>>>>> http://jsbin.com/unekoh/edit#javascript,html,live
>>>>>>
>>>>>> Could you please be so kind to have a look at it and check why jQuery is not able to parse the header?
>>>>>>
>>>>>> Is it maybe possible to also send the location as response text?
>>>>>>
>>>>>>
>>>>>> Thanks a lot in advance,
>>>>>>
>>>>>> Sebastian
>>>> --
>>>> M.Sc. Sebastian Germesin
>>>>
>>>> DFKI GmbH
>>>> Campus D3 2
>>>> Stuhlsatzenhausweg 3
>>>> D-66123 Saarbruecken, Germany
>>>>
>>>> phone:      +49 (681) 85775 - 5079
>>>> fax:        +49 (681) 85775 - 5021
>>>> mail:       sebastian.germesin@dfki.de
>>>> http:       www.dfki.de/~germesin
>>>> skype:      neogermi1337
>>>> twitter:    germesin
>>>>
>>
>
> --
> M.Sc. Sebastian Germesin
>
> DFKI GmbH
> Campus D3 2
> Stuhlsatzenhausweg 3
> D-66123 Saarbruecken, Germany
>
> phone:  +49 (681) 85775 - 5079
> fax:    +49 (681) 85775 - 5021
> mail:   sebastian.germesin@dfki.de
> http:   www.dfki.de/~germesin
> skype:  neogermi1337
> twitter:    germesin
>
> --
> Deutsches Forschungszentrum fuer Kuenstliche Intelligenz (DFKI) GmbH
> Firmensitz: Trippstadter Strasse 122, D-67663 Kaiserslautern; Amtsgericht Kaiserslautern, HRB 2313
> Geschaeftsfuehrung: Prof. Dr. Dr. h.c. mult. Wolfgang Wahlster (Vorsitzender), Dr. Walter Olthoff
> Vorsitzender des Aufsichtsrats: Prof. Dr. h.c. Hans A. Aukes
>



-- 
| Rupert Westenthaler             rupert.westenthaler@gmail.com
| Bodenlehenstraße 11                             ++43-699-11108907
| A-5500 Bischofshofen

Re: Apache StanbolService implementation in VIE (ContentHub)

Posted by Sebastian Germesin <se...@dfki.de>.
Dear Suat,

thank you, we will try it these days and let you know if that worked.

Best regards,

Sebastian
On 18.05.2012, at 09:49, Suat Gonul wrote:

> Hi Sebastian,
> 
> I committed the code exposing the Location header in
> "Access-Control-Expose-Headers" header . If you need other headers, they
> should be added to the CORS Access-Control-Expose-Headers configuration
> of JerseyEndpoint of Stanbol. I hope this would be a solution for you.
> 
> Best,
> Suat
> 
> On 05/17/2012 03:16 PM, Suat Gonul wrote:
>> Hi Sebastian,
>> 
>> I managed to obtain the Location header in javascript. It seems server
>> should expose the header in the Access-Control-Expose-Headers so that
>> clients can access. However, I managed this with only Google Chrome.
>> Firefox 12 still returns the empty results. I read in some articles that
>> some browsers have buggy implementations regarding the
>> XMLHttpRequest.getRequestHeader method, e.g [1].
>> 
>> Anyway, I will add the necessary code exposing the headers.
>> 
>> Best,
>> Suat
>> 
>> [1] http://www.html5rocks.com/en/tutorials/cors/
>> 
>> On 05/16/2012 04:39 PM, Sebastian Germesin wrote:
>>> Hi Suat,
>>> 
>>> thanks for checking and for the link. That is bad... How do you think can we ship around this?
>>> 
>>> From my point of view, duplicating the location (the URI) in the content of the response does not
>>> hurt the specs and helps me on the client side.
>>> 
>>> Would that be a proper solution?
>>> 
>>> Best regards,
>>> 
>>> Sebastian
>>> 
>>> On 16.05.2012, at 15:26, Suat Gonul wrote:
>>> 
>>>> Hi Sebastian,
>>>> 
>>>> I have tried a number of cases for the header specifications while
>>>> sending the query to Contenthub, but I could not read the Location
>>>> header with jQuery at all, even any other headers. However, the details
>>>> of the response seems like as follows through the Live HTTP Headers
>>>> plugin in Firefox:
>>>> 
>>>> HTTP/1.1 201 Created
>>>> Access-Control-Allow-Origin: *
>>>> Location:
>>>> http://localhost:8080/contenthub/contenthub/store/content/urn:content-item-sha1-358dbe75624b135aa72c1ad6cc34f325bf7fdf50
>>>> 
>>>> Content-Length: 0
>>>> Server: Jetty(6.1.x)
>>>> 
>>>> Then, I ran across the following note in [1]:
>>>> "The Cross-Origin Resource Sharing specification filters the headers
>>>> that are exposed by |getAllResponseHeaders()
>>>> <http://dvcs.w3.org/hg/xhr/raw-file/tip/Overview.html#dom-xmlhttprequest-getallresponseheaders>|
>>>> for non same-origin
>>>> <http://www.whatwg.org/specs/web-apps/current-work/multipage/origin-0.html#same-origin>
>>>> requests."
>>>> 
>>>> I think this may be the reason. I'm not sure though.
>>>> 
>>>> [1]
>>>> http://dvcs.w3.org/hg/xhr/raw-file/tip/Overview.html#dom-xmlhttprequest-getallresponseheaders
>>>> 
>>>> Best,
>>>> Suat
>>>> 
>>>> 
>>>> On 05/15/2012 07:19 PM, Sebastian Germesin wrote:
>>>>> Dear all,
>>>>> 
>>>>> we are currently working on extending the VIE.StanbolService and currently face a problem with the content hub of Apache Stanbol.
>>>>> 
>>>>> From the REST API, it seems that a simple HTTP-POST request is enough to create a resource and in fact it works and the result is a HTTP response (201 - Created).
>>>>> 
>>>>> However, using jQuery, we are currently not able to retrieve the location of the created resource, to be more precise, the "Location" header field is not readable from jQuery.
>>>>> 
>>>>> I've created a jsbin example for you to test the code:
>>>>> 
>>>>> http://jsbin.com/unekoh/edit#javascript,html,live
>>>>> 
>>>>> Could you please be so kind to have a look at it and check why jQuery is not able to parse the header?
>>>>> 
>>>>> Is it maybe possible to also send the location as response text?
>>>>> 
>>>>> 
>>>>> Thanks a lot in advance,
>>>>> 
>>>>> Sebastian
>>> --
>>> M.Sc. Sebastian Germesin
>>> 
>>> DFKI GmbH
>>> Campus D3 2
>>> Stuhlsatzenhausweg 3                 
>>> D-66123 Saarbruecken, Germany   
>>> 
>>> phone: 	+49 (681) 85775 - 5079 
>>> fax:   	+49 (681) 85775 - 5021
>>> mail: 	sebastian.germesin@dfki.de
>>> http: 	www.dfki.de/~germesin
>>> skype: 	neogermi1337
>>> twitter:    germesin
>>> 
> 

--
M.Sc. Sebastian Germesin

DFKI GmbH
Campus D3 2
Stuhlsatzenhausweg 3                 
D-66123 Saarbruecken, Germany   

phone: 	+49 (681) 85775 - 5079 
fax:   	+49 (681) 85775 - 5021
mail: 	sebastian.germesin@dfki.de
http: 	www.dfki.de/~germesin
skype: 	neogermi1337
twitter:    germesin

-- 
Deutsches Forschungszentrum fuer Kuenstliche Intelligenz (DFKI) GmbH 
Firmensitz: Trippstadter Strasse 122, D-67663 Kaiserslautern; Amtsgericht Kaiserslautern, HRB 2313
Geschaeftsfuehrung: Prof. Dr. Dr. h.c. mult. Wolfgang Wahlster (Vorsitzender), Dr. Walter Olthoff
Vorsitzender des Aufsichtsrats: Prof. Dr. h.c. Hans A. Aukes


Re: Apache StanbolService implementation in VIE (ContentHub)

Posted by Suat Gonul <su...@gmail.com>.
Hi Sebastian,

I committed the code exposing the Location header in
"Access-Control-Expose-Headers" header . If you need other headers, they
should be added to the CORS Access-Control-Expose-Headers configuration
of JerseyEndpoint of Stanbol. I hope this would be a solution for you.

Best,
Suat

On 05/17/2012 03:16 PM, Suat Gonul wrote:
> Hi Sebastian,
>
> I managed to obtain the Location header in javascript. It seems server
> should expose the header in the Access-Control-Expose-Headers so that
> clients can access. However, I managed this with only Google Chrome.
> Firefox 12 still returns the empty results. I read in some articles that
> some browsers have buggy implementations regarding the
> XMLHttpRequest.getRequestHeader method, e.g [1].
>
> Anyway, I will add the necessary code exposing the headers.
>
> Best,
> Suat
>
> [1] http://www.html5rocks.com/en/tutorials/cors/
>
> On 05/16/2012 04:39 PM, Sebastian Germesin wrote:
>> Hi Suat,
>>
>> thanks for checking and for the link. That is bad... How do you think can we ship around this?
>>
>> From my point of view, duplicating the location (the URI) in the content of the response does not
>> hurt the specs and helps me on the client side.
>>
>> Would that be a proper solution?
>>
>> Best regards,
>>
>> Sebastian
>>
>> On 16.05.2012, at 15:26, Suat Gonul wrote:
>>
>>> Hi Sebastian,
>>>
>>> I have tried a number of cases for the header specifications while
>>> sending the query to Contenthub, but I could not read the Location
>>> header with jQuery at all, even any other headers. However, the details
>>> of the response seems like as follows through the Live HTTP Headers
>>> plugin in Firefox:
>>>
>>> HTTP/1.1 201 Created
>>> Access-Control-Allow-Origin: *
>>> Location:
>>> http://localhost:8080/contenthub/contenthub/store/content/urn:content-item-sha1-358dbe75624b135aa72c1ad6cc34f325bf7fdf50
>>>
>>> Content-Length: 0
>>> Server: Jetty(6.1.x)
>>>
>>> Then, I ran across the following note in [1]:
>>> "The Cross-Origin Resource Sharing specification filters the headers
>>> that are exposed by |getAllResponseHeaders()
>>> <http://dvcs.w3.org/hg/xhr/raw-file/tip/Overview.html#dom-xmlhttprequest-getallresponseheaders>|
>>> for non same-origin
>>> <http://www.whatwg.org/specs/web-apps/current-work/multipage/origin-0.html#same-origin>
>>> requests."
>>>
>>> I think this may be the reason. I'm not sure though.
>>>
>>> [1]
>>> http://dvcs.w3.org/hg/xhr/raw-file/tip/Overview.html#dom-xmlhttprequest-getallresponseheaders
>>>
>>> Best,
>>> Suat
>>>
>>>
>>> On 05/15/2012 07:19 PM, Sebastian Germesin wrote:
>>>> Dear all,
>>>>
>>>> we are currently working on extending the VIE.StanbolService and currently face a problem with the content hub of Apache Stanbol.
>>>>
>>>> From the REST API, it seems that a simple HTTP-POST request is enough to create a resource and in fact it works and the result is a HTTP response (201 - Created).
>>>>
>>>> However, using jQuery, we are currently not able to retrieve the location of the created resource, to be more precise, the "Location" header field is not readable from jQuery.
>>>>
>>>> I've created a jsbin example for you to test the code:
>>>>
>>>> http://jsbin.com/unekoh/edit#javascript,html,live
>>>>
>>>> Could you please be so kind to have a look at it and check why jQuery is not able to parse the header?
>>>>
>>>> Is it maybe possible to also send the location as response text?
>>>>
>>>>
>>>> Thanks a lot in advance,
>>>>
>>>> Sebastian
>> --
>> M.Sc. Sebastian Germesin
>>
>> DFKI GmbH
>> Campus D3 2
>> Stuhlsatzenhausweg 3                 
>> D-66123 Saarbruecken, Germany   
>>
>> phone: 	+49 (681) 85775 - 5079 
>> fax:   	+49 (681) 85775 - 5021
>> mail: 	sebastian.germesin@dfki.de
>> http: 	www.dfki.de/~germesin
>> skype: 	neogermi1337
>> twitter:    germesin
>>


Re: Apache StanbolService implementation in VIE (ContentHub)

Posted by Suat Gonul <su...@gmail.com>.
Hi Sebastian,

I managed to obtain the Location header in javascript. It seems server
should expose the header in the Access-Control-Expose-Headers so that
clients can access. However, I managed this with only Google Chrome.
Firefox 12 still returns the empty results. I read in some articles that
some browsers have buggy implementations regarding the
XMLHttpRequest.getRequestHeader method, e.g [1].

Anyway, I will add the necessary code exposing the headers.

Best,
Suat

[1] http://www.html5rocks.com/en/tutorials/cors/

On 05/16/2012 04:39 PM, Sebastian Germesin wrote:
> Hi Suat,
>
> thanks for checking and for the link. That is bad... How do you think can we ship around this?
>
> From my point of view, duplicating the location (the URI) in the content of the response does not
> hurt the specs and helps me on the client side.
>
> Would that be a proper solution?
>
> Best regards,
>
> Sebastian
>
> On 16.05.2012, at 15:26, Suat Gonul wrote:
>
>> Hi Sebastian,
>>
>> I have tried a number of cases for the header specifications while
>> sending the query to Contenthub, but I could not read the Location
>> header with jQuery at all, even any other headers. However, the details
>> of the response seems like as follows through the Live HTTP Headers
>> plugin in Firefox:
>>
>> HTTP/1.1 201 Created
>> Access-Control-Allow-Origin: *
>> Location:
>> http://localhost:8080/contenthub/contenthub/store/content/urn:content-item-sha1-358dbe75624b135aa72c1ad6cc34f325bf7fdf50
>>
>> Content-Length: 0
>> Server: Jetty(6.1.x)
>>
>> Then, I ran across the following note in [1]:
>> "The Cross-Origin Resource Sharing specification filters the headers
>> that are exposed by |getAllResponseHeaders()
>> <http://dvcs.w3.org/hg/xhr/raw-file/tip/Overview.html#dom-xmlhttprequest-getallresponseheaders>|
>> for non same-origin
>> <http://www.whatwg.org/specs/web-apps/current-work/multipage/origin-0.html#same-origin>
>> requests."
>>
>> I think this may be the reason. I'm not sure though.
>>
>> [1]
>> http://dvcs.w3.org/hg/xhr/raw-file/tip/Overview.html#dom-xmlhttprequest-getallresponseheaders
>>
>> Best,
>> Suat
>>
>>
>> On 05/15/2012 07:19 PM, Sebastian Germesin wrote:
>>> Dear all,
>>>
>>> we are currently working on extending the VIE.StanbolService and currently face a problem with the content hub of Apache Stanbol.
>>>
>>> From the REST API, it seems that a simple HTTP-POST request is enough to create a resource and in fact it works and the result is a HTTP response (201 - Created).
>>>
>>> However, using jQuery, we are currently not able to retrieve the location of the created resource, to be more precise, the "Location" header field is not readable from jQuery.
>>>
>>> I've created a jsbin example for you to test the code:
>>>
>>> http://jsbin.com/unekoh/edit#javascript,html,live
>>>
>>> Could you please be so kind to have a look at it and check why jQuery is not able to parse the header?
>>>
>>> Is it maybe possible to also send the location as response text?
>>>
>>>
>>> Thanks a lot in advance,
>>>
>>> Sebastian
> --
> M.Sc. Sebastian Germesin
>
> DFKI GmbH
> Campus D3 2
> Stuhlsatzenhausweg 3                 
> D-66123 Saarbruecken, Germany   
>
> phone: 	+49 (681) 85775 - 5079 
> fax:   	+49 (681) 85775 - 5021
> mail: 	sebastian.germesin@dfki.de
> http: 	www.dfki.de/~germesin
> skype: 	neogermi1337
> twitter:    germesin
>


Re: Apache StanbolService implementation in VIE (ContentHub)

Posted by Sebastian Germesin <se...@dfki.de>.
Hi Suat,

thanks for checking and for the link. That is bad... How do you think can we ship around this?

From my point of view, duplicating the location (the URI) in the content of the response does not
hurt the specs and helps me on the client side.

Would that be a proper solution?

Best regards,

Sebastian

On 16.05.2012, at 15:26, Suat Gonul wrote:

> Hi Sebastian,
> 
> I have tried a number of cases for the header specifications while
> sending the query to Contenthub, but I could not read the Location
> header with jQuery at all, even any other headers. However, the details
> of the response seems like as follows through the Live HTTP Headers
> plugin in Firefox:
> 
> HTTP/1.1 201 Created
> Access-Control-Allow-Origin: *
> Location:
> http://localhost:8080/contenthub/contenthub/store/content/urn:content-item-sha1-358dbe75624b135aa72c1ad6cc34f325bf7fdf50
> 
> Content-Length: 0
> Server: Jetty(6.1.x)
> 
> Then, I ran across the following note in [1]:
> "The Cross-Origin Resource Sharing specification filters the headers
> that are exposed by |getAllResponseHeaders()
> <http://dvcs.w3.org/hg/xhr/raw-file/tip/Overview.html#dom-xmlhttprequest-getallresponseheaders>|
> for non same-origin
> <http://www.whatwg.org/specs/web-apps/current-work/multipage/origin-0.html#same-origin>
> requests."
> 
> I think this may be the reason. I'm not sure though.
> 
> [1]
> http://dvcs.w3.org/hg/xhr/raw-file/tip/Overview.html#dom-xmlhttprequest-getallresponseheaders
> 
> Best,
> Suat
> 
> 
> On 05/15/2012 07:19 PM, Sebastian Germesin wrote:
>> Dear all,
>> 
>> we are currently working on extending the VIE.StanbolService and currently face a problem with the content hub of Apache Stanbol.
>> 
>> From the REST API, it seems that a simple HTTP-POST request is enough to create a resource and in fact it works and the result is a HTTP response (201 - Created).
>> 
>> However, using jQuery, we are currently not able to retrieve the location of the created resource, to be more precise, the "Location" header field is not readable from jQuery.
>> 
>> I've created a jsbin example for you to test the code:
>> 
>> http://jsbin.com/unekoh/edit#javascript,html,live
>> 
>> Could you please be so kind to have a look at it and check why jQuery is not able to parse the header?
>> 
>> Is it maybe possible to also send the location as response text?
>> 
>> 
>> Thanks a lot in advance,
>> 
>> Sebastian
> 

--
M.Sc. Sebastian Germesin

DFKI GmbH
Campus D3 2
Stuhlsatzenhausweg 3                 
D-66123 Saarbruecken, Germany   

phone: 	+49 (681) 85775 - 5079 
fax:   	+49 (681) 85775 - 5021
mail: 	sebastian.germesin@dfki.de
http: 	www.dfki.de/~germesin
skype: 	neogermi1337
twitter:    germesin

-- 
Deutsches Forschungszentrum fuer Kuenstliche Intelligenz (DFKI) GmbH 
Firmensitz: Trippstadter Strasse 122, D-67663 Kaiserslautern; Amtsgericht Kaiserslautern, HRB 2313
Geschaeftsfuehrung: Prof. Dr. Dr. h.c. mult. Wolfgang Wahlster (Vorsitzender), Dr. Walter Olthoff
Vorsitzender des Aufsichtsrats: Prof. Dr. h.c. Hans A. Aukes


Re: Apache StanbolService implementation in VIE (ContentHub)

Posted by Suat Gonul <su...@gmail.com>.
Hi Sebastian,

I have tried a number of cases for the header specifications while
sending the query to Contenthub, but I could not read the Location
header with jQuery at all, even any other headers. However, the details
of the response seems like as follows through the Live HTTP Headers
plugin in Firefox:

HTTP/1.1 201 Created
Access-Control-Allow-Origin: *
Location:
http://localhost:8080/contenthub/contenthub/store/content/urn:content-item-sha1-358dbe75624b135aa72c1ad6cc34f325bf7fdf50

Content-Length: 0
Server: Jetty(6.1.x)

Then, I ran across the following note in [1]:
"The Cross-Origin Resource Sharing specification filters the headers
that are exposed by |getAllResponseHeaders()
<http://dvcs.w3.org/hg/xhr/raw-file/tip/Overview.html#dom-xmlhttprequest-getallresponseheaders>|
for non same-origin
<http://www.whatwg.org/specs/web-apps/current-work/multipage/origin-0.html#same-origin>
requests."

I think this may be the reason. I'm not sure though.

[1]
http://dvcs.w3.org/hg/xhr/raw-file/tip/Overview.html#dom-xmlhttprequest-getallresponseheaders

Best,
Suat


On 05/15/2012 07:19 PM, Sebastian Germesin wrote:
> Dear all,
>
> we are currently working on extending the VIE.StanbolService and currently face a problem with the content hub of Apache Stanbol.
>
> From the REST API, it seems that a simple HTTP-POST request is enough to create a resource and in fact it works and the result is a HTTP response (201 - Created).
>
> However, using jQuery, we are currently not able to retrieve the location of the created resource, to be more precise, the "Location" header field is not readable from jQuery.
>
> I've created a jsbin example for you to test the code:
>
> http://jsbin.com/unekoh/edit#javascript,html,live
>
> Could you please be so kind to have a look at it and check why jQuery is not able to parse the header?
>
> Is it maybe possible to also send the location as response text?
>
>
> Thanks a lot in advance,
>
> Sebastian


Apache StanbolService implementation in VIE (ContentHub)

Posted by Sebastian Germesin <se...@dfki.de>.
Dear all,

we are currently working on extending the VIE.StanbolService and currently face a problem with the content hub of Apache Stanbol.

From the REST API, it seems that a simple HTTP-POST request is enough to create a resource and in fact it works and the result is a HTTP response (201 - Created).

However, using jQuery, we are currently not able to retrieve the location of the created resource, to be more precise, the "Location" header field is not readable from jQuery.

I've created a jsbin example for you to test the code:

http://jsbin.com/unekoh/edit#javascript,html,live

Could you please be so kind to have a look at it and check why jQuery is not able to parse the header?

Is it maybe possible to also send the location as response text?


Thanks a lot in advance,

Sebastian