You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@marmotta.apache.org by "Matteo Busanelli (GMail)" <ma...@gmail.com> on 2013/05/27 19:32:57 UTC

Problem with Prefixes Admin Interface

Hi all,
     I'm trying Marmotta 3.0 incubator and I'm facing some problem in using prefixes admin interface 
(http://localhost:8080/marmotta/core/admin/prefixes.html)
It seems that from the Admin interface I can't really add any new prefixes because when I click on the Add prefix button nothing happens.
Also if I refresh the page or I reboot the server I can't find the prefix that I added.

I looked at the Marmotta Jira but I found only a fixed issue on the front-end implemetation (https://issues.apache.org/jira/browse/MARMOTTA-44)

Thanx in advance for your support.

Matteo.

Re: Problem with Prefixes Admin Interface

Posted by "Matteo Busanelli (GMail)" <ma...@gmail.com>.
The same error occurs if I use "_" (es. "test_a" as prefix).

Matteo.

Il 28/05/2013 11:08, Matteo Busanelli (GMail) ha scritto:
> Ciao Sergio,
>     I have checked all the things you told to me and I think Ifound the problem.
>
> The http://s.apache.org/marmotta-commit-cbce17677236c400d780459eafa126d5453c5a63 is ok.
>
> I made a different test using "Inspect Element " of Chrome for looking at some js console error.
>
> I found that there is an ajax call error when I use a prefix like "my-pref" because of the "-" char that give problems in the API URL call.
> This is the massage in the console:
>
>  1. POST http://busa:8080/marmotta/prefix/test-test?uri=http://www.test.org/test2 404 (Not Found) jquery.min.js:2
>     <http://busa:8080/marmotta/webjars/jquery/1.8.2/jquery.min.js>
>     1.
>         sendjquery.min.js:2 <http://busa:8080/marmotta/webjars/jquery/1.8.2/jquery.min.js>
>     2.
>         p.extend.ajaxjquery.min.js:2 <http://busa:8080/marmotta/webjars/jquery/1.8.2/jquery.min.js>
>     3.
>         (anonymous function)prefixes.html:338 <http://busa:8080/marmotta/core/admin/prefixes.html>
>     4.
>         p.event.dispatchjquery.min.js:2 <http://busa:8080/marmotta/webjars/jquery/1.8.2/jquery.min.js>
>     5.
>         g.handle.h
>
>
> If I use a prefix without the "-" everything is ok and I can find my new prefix in the list (is there any delete prefix interface?).
>
> Now I know that I can't use "-" in my prefixes with Marmotta (that I used to use in many ontologies) but I guess that is a bug that should be 
> fixed in some way becouse the XML standard (and thus RDF/OWL in any kind of serialization) allows this kind of prefixes.
>
> Looking forward for any news about this issue.
>
> Thanx for your good and fast support.;-)
>
> Matteo.
>
>
>
> Il 27/05/2013 20:15, Sergio Fernández ha scritto:
>> Ciao Matteo,
>>
>> On 27/05/13 19:32, Matteo Busanelli (GMail) wrote:
>>>      I'm trying Marmotta 3.0 incubator and I'm facing some problem in
>>> using prefixes admin interface
>>> (http://localhost:8080/marmotta/core/admin/prefixes.html)
>>> It seems that from the Admin interface I can't really add any new
>>> prefixes because when I click on the Add prefix button nothing happens.
>>> Also if I refresh the page or I reboot the server I can't find the
>>> prefix that I added.
>>>
>>> I looked at the Marmotta Jira but I found only a fixed issue on the
>>> front-end implemetation (https://issues.apache.org/jira/browse/MARMOTTA-44)
>>
>> This commit may be also relevant:
>>
>> http://s.apache.org/marmotta-commit-cbce17677236c400d780459eafa126d5453c5a63
>>
>> But both were fixed before 3.0.0-incubating release, so no idea how this issue appears again...
>>
>> Could you please provide us more details about the error? Two things you could check for helping us:
>>
>> - check for javascript errors in your browser (it you are not familiar with such environment, I can provide you some help)
>>
>> - Check in the file $MARMOTTA_HOME/system-config.properties if you have the line:
>>
>>   prefix.yourprefix = http://example.org/yourns#
>>
>> Thanks for the report.
>>
>> Cheers,
>>
>


Re: Problem with Prefixes Admin Interface

Posted by Sergio Fernández <wi...@apache.org>.
Ciao Matteo,

On 28/05/13 11:08, Matteo Busanelli (GMail) wrote:
> I have checked all the things you told to me and I think I found the problem.
>
> I found that there is an ajax call error when I use a prefix like
> "my-pref" because of the "-" char that give problems in the API URL call.

OK, finally we got it...

I registered MARMOTTA-248 to address this issue:

https://issues.apache.org/jira/browse/MARMOTTA-248

Hopefully I'd manage to solve it during this week.

> If I use a prefix without the "-" everything is ok and I can find my new
> prefix in the list (is there any delete prefix interface?).

Not possible now, but we could try to provide such feature for the next 
version, see MARMOTTA-249 for further details:

https://issues.apache.org/jira/browse/MARMOTTA-249

> Thanx for your good and fast support.;-)

Thanks for the error reporting :-)

Cheers,

-- 
Sergio Fernández

Problem with context deleting from admin interface

Posted by "Matteo Busanelli (GMail)" <ma...@gmail.com>.
Hi all,
     another problem:

1. I import an OWL in a new context called "http://localhost:8080/marmotta/context/abilab/proc <http://busa:8080/marmotta/context/abilab/proc>" => OK
2. If I try to delete the context from the interface (link "delete" in the http://localhost:8080/marmotta/core/admin/contexts.html 
<http://busa:8080/marmotta/core/admin/contexts.html>page)I get the following js console error:

 1. DELETE http://localhost:8080/marmotta/context/abilabproc <http://busa:8080/marmotta/context/abilabproc> 405 (Method Not Allowed) jquery.min.js:2
    <http://busa:8080/marmotta/webjars/jquery/1.8.2/jquery.min.js>
     1.
        sendjquery.min.js:2 <http://busa:8080/marmotta/webjars/jquery/1.8.2/jquery.min.js>
     2.
        p.extend.ajaxjquery.min.js:2 <http://busa:8080/marmotta/webjars/jquery/1.8.2/jquery.min.js>
     3.
        deleteContextcontexts.html:324 <http://busa:8080/marmotta/core/admin/contexts.html>
     4.
        (anonymous function)contexts.html:344 <http://busa:8080/marmotta/core/admin/contexts.html>
     5.
        p.event.dispatchjquery.min.js:2 <http://busa:8080/marmotta/webjars/jquery/1.8.2/jquery.min.js>
     6.
        g.handle.h


3. The only way to delete is using cURL from command line calling the API in this way:

     curl -X DELETE http://localhost:8080/marmotta/context?graph=http://busa:8080/marmotta/context/abilabproc

May be the link in the admin interface page context.html call the API in a wrong way (http://localhost:8080/marmotta/context/abilabproc 
<http://busa:8080/marmotta/context/abilabproc>)?

Hoping to give you some usefull feedback.

Thanx for the support.

Matteo.

Re: Problem with context deleting from admin interface

Posted by "Matteo Busanelli (GMail)" <ma...@gmail.com>.
Ok I'll register on this issue too.

Thanx again Sergio.

Il 03/06/2013 10:46, Sergio Fernández ha scritto:
> Hi Matteo,
>
> On 28/05/13 14:49, Matteo Busanelli (GMail) wrote:
>> Ok I have changed the profile in "standard" and logged in as "admin "but
>> nothing change.
>> When I try to delete the context
>> http://busa:8080/marmotta/context/abiprocfrom the Admin interface I
>> always get this error:
>>
>> 1. DELETE http://busa:8080/marmotta/context/abiproc 405 (Method Not
>> Allowed) jquery.min.js:2
>>
>> Now (in standard profile) also the curl doesn't work.
>> I made the test! If I change back to "simple" profile at least the curl
>> DELETE works fine (both direct and indirect).
>
> So definitely this looks a bug in the js-side in the admin ui. I already identified another one (MARMOTTA-253) related with the usage non-local 
> context uris. Please, register also this in jira, and I'd try to check all related issues during the week.
>
> Cheers,
>


Re: Problem with context deleting from admin interface

Posted by Sergio Fernández <wi...@apache.org>.
Hi Matteo,

On 28/05/13 14:49, Matteo Busanelli (GMail) wrote:
> Ok I have changed the profile in "standard" and logged in as "admin "but
> nothing change.
> When I try to delete the context
> http://busa:8080/marmotta/context/abiprocfrom the Admin interface I
> always get this error:
>
> 1. DELETE http://busa:8080/marmotta/context/abiproc 405 (Method Not
> Allowed) jquery.min.js:2
>
> Now (in standard profile) also the curl doesn't work.
> I made the test! If I change back to "simple" profile at least the curl
> DELETE works fine (both direct and indirect).

So definitely this looks a bug in the js-side in the admin ui. I already 
identified another one (MARMOTTA-253) related with the usage non-local 
context uris. Please, register also this in jira, and I'd try to check 
all related issues during the week.

Cheers,

-- 
Sergio Fernández

Re: Problem with context deleting from admin interface

Posted by "Matteo Busanelli (GMail)" <ma...@gmail.com>.
In line...
Il 28/05/2013 13:08, Sergio Fernández ha scritto:
> Hi Matteo,
>
> by default the simple security profile allows read access from everywhere and write access only from localhost or other local interface. Therefore 
> you can do it from localhost (as you did it with curl) or switch to the standard profile to be able to login.
>
> Further details at:
>
> http://marmotta.incubator.apache.org/platform/security-module.html
Ok I have changed the profile in "standard" and logged in as "admin "but nothing change.
When I try to delete the context http://busa:8080/marmotta/context/abiprocfrom the Admin interface I always get this error:

 1. DELETE http://busa:8080/marmotta/context/abiproc 405 (Method Not Allowed) jquery.min.js:2
    <http://busa:8080/marmotta/webjars/jquery/1.8.2/jquery.min.js>
     1.
        sendjquery.min.js:2 <http://busa:8080/marmotta/webjars/jquery/1.8.2/jquery.min.js>
     2.
        p.extend.ajaxjquery.min.js:2 <http://busa:8080/marmotta/webjars/jquery/1.8.2/jquery.min.js>
     3.
        deleteContextcontexts.html:324 <http://busa:8080/marmotta/core/admin/contexts.html>
     4.
        (anonymous function)contexts.html:344 <http://busa:8080/marmotta/core/admin/contexts.html>
     5.
        p.event.dispatchjquery.min.js:2 <http://busa:8080/marmotta/webjars/jquery/1.8.2/jquery.min.js>
     6.
        g.handle.h
 2.

(I'm doing all this on localhost (busa is the host name used and preconfigured from marmotta install setup).)

<http://busa:8080/marmotta/context/abiproc>
>
> Context management is implemented by (partially) follow the SPARQL 1.1 Graph Store HTTP Protocol:
>
> http://www.w3.org/TR/sparql11-http-rdf-update/
>
> So both direct (DELETE /context/foo) and indirect (DELETE /context?graph=http://.../context/foo) graph identification may be supported.
Now (in standard profile) also the curl doesn't work.
I made the test! If I change back to "simple" profile at least the curl DELETE works fine (both direct and indirect).

>
> I'd need to check, but maybe we have a bug in that web service: requests to /context/foo would be correctly handled, but maybe /context/foo/bar 
> not. Could you please confirm it?

I also made this last test as you requested. I imported in a new context named "http://busa:8080/marmotta/context/abi/proc".
I'm with profile "simple" from localhost and again the delete from Admin Interface doesn't work:

 1. DELETE http://busa:8080/marmotta/context/abi/proc 405 (Method Not Allowed) jquery.min.js:2
    <http://busa:8080/marmotta/webjars/jquery/1.8.2/jquery.min.js>
     1.
        sendjquery.min.js:2 <http://busa:8080/marmotta/webjars/jquery/1.8.2/jquery.min.js>
     2.
        p.extend.ajaxjquery.min.js:2 <http://busa:8080/marmotta/webjars/jquery/1.8.2/jquery.min.js>
     3.
        deleteContextcontexts.html:324 <http://busa:8080/marmotta/core/admin/contexts.html>
     4.
        (anonymous function)contexts.html:344 <http://busa:8080/marmotta/core/admin/contexts.html>
     5.
        p.event.dispatchjquery.min.js:2 <http://busa:8080/marmotta/webjars/jquery/1.8.2/jquery.min.js>
     6.
        g.handle.h


 From command line woks fine both the direct and the indirect DELETE:

1) curl -X DELETE http://busa:8080/marmotta/context/abi/proc  ==> OK
2) curl -X DELETE http://busa:8080/marmotta/context?graph=http://busa:8080/marmotta/context/abi/proc ==> OK

To summarize:
- curl works in simple but not in the standard profile (both direct and indirect delete call)
- the delete from admin interface (logged in as admin) doesn't wok neither in simple nor in the standard profile

I'm doing something wrong?

Thanx again,
Matteo.



>
> Hope this helps.
>
> Cheers,
>
>
> On 28/05/13 12:47, Matteo (Tim) wrote:
>> Hi all,
>>      another problem:
>>
>> 1. I import an OWL in a new context called
>> "http://localhost:8080/marmotta/context/abilab/proc
>> <http://busa:8080/marmotta/context/abilab/proc>" => OK
>> 2. If I try to delete the context from the interface (link "delete" in
>> the http://localhost:8080/marmotta/core/admin/contexts.html
>> <http://busa:8080/marmotta/core/admin/contexts.html>page)I get the
>> following js console error:
>>
>> 1. DELETE http://localhost:8080/marmotta/context/abilabproc
>> <http://busa:8080/marmotta/context/abilabproc> 405 (Method Not Allowed)
>> jquery.min.js:2
>> <http://busa:8080/marmotta/webjars/jquery/1.8.2/jquery.min.js>
>>      1.
>>         sendjquery.min.js:2
>> <http://busa:8080/marmotta/webjars/jquery/1.8.2/jquery.min.js>
>>      2.
>>         p.extend.ajaxjquery.min.js:2
>> <http://busa:8080/marmotta/webjars/jquery/1.8.2/jquery.min.js>
>>      3.
>>         deleteContextcontexts.html:324
>> <http://busa:8080/marmotta/core/admin/contexts.html>
>>      4.
>>         (anonymous function)contexts.html:344
>> <http://busa:8080/marmotta/core/admin/contexts.html>
>>      5.
>>         p.event.dispatchjquery.min.js:2
>> <http://busa:8080/marmotta/webjars/jquery/1.8.2/jquery.min.js>
>>      6.
>>         g.handle.h
>>
>>
>> 3. The only way to delete is using cURL from command line calling the
>> API in this way:
>>
>>      curl -X DELETE
>> http://localhost:8080/marmotta/context?graph=http://busa:8080/marmotta/context/abilabproc
>>
>>
>> May be the link in the admin interface page context.html call the API in
>> a wrong way (http://localhost:8080/marmotta/context/abilabproc
>> <http://busa:8080/marmotta/context/abilabproc>)?
>>
>> Hoping to give you some usefull feedback.
>>
>> Thanx for the support.
>>
>> Matteo.
>>
>


Re: Problem with context deleting from admin interface

Posted by Sergio Fernández <wi...@apache.org>.
Hi Matteo,

by default the simple security profile allows read access from 
everywhere and write access only from localhost or other local 
interface. Therefore you can do it from localhost (as you did it with 
curl) or switch to the standard profile to be able to login.

Further details at:

http://marmotta.incubator.apache.org/platform/security-module.html

Context management is implemented by (partially) follow the SPARQL 1.1 
Graph Store HTTP Protocol:

http://www.w3.org/TR/sparql11-http-rdf-update/

So both direct (DELETE /context/foo) and indirect (DELETE 
/context?graph=http://.../context/foo) graph identification may be 
supported.

I'd need to check, but maybe we have a bug in that web service: requests 
to /context/foo would be correctly handled, but maybe /context/foo/bar 
not. Could you please confirm it?

Hope this helps.

Cheers,


On 28/05/13 12:47, Matteo (Tim) wrote:
> Hi all,
>      another problem:
>
> 1. I import an OWL in a new context called
> "http://localhost:8080/marmotta/context/abilab/proc
> <http://busa:8080/marmotta/context/abilab/proc>" => OK
> 2. If I try to delete the context from the interface (link "delete" in
> the http://localhost:8080/marmotta/core/admin/contexts.html
> <http://busa:8080/marmotta/core/admin/contexts.html>page)I get the
> following js console error:
>
> 1. DELETE http://localhost:8080/marmotta/context/abilabproc
> <http://busa:8080/marmotta/context/abilabproc> 405 (Method Not Allowed)
> jquery.min.js:2
>     <http://busa:8080/marmotta/webjars/jquery/1.8.2/jquery.min.js>
>      1.
>         sendjquery.min.js:2
> <http://busa:8080/marmotta/webjars/jquery/1.8.2/jquery.min.js>
>      2.
>         p.extend.ajaxjquery.min.js:2
> <http://busa:8080/marmotta/webjars/jquery/1.8.2/jquery.min.js>
>      3.
>         deleteContextcontexts.html:324
> <http://busa:8080/marmotta/core/admin/contexts.html>
>      4.
>         (anonymous function)contexts.html:344
> <http://busa:8080/marmotta/core/admin/contexts.html>
>      5.
>         p.event.dispatchjquery.min.js:2
> <http://busa:8080/marmotta/webjars/jquery/1.8.2/jquery.min.js>
>      6.
>         g.handle.h
>
>
> 3. The only way to delete is using cURL from command line calling the
> API in this way:
>
>      curl -X DELETE
> http://localhost:8080/marmotta/context?graph=http://busa:8080/marmotta/context/abilabproc
>
>
> May be the link in the admin interface page context.html call the API in
> a wrong way (http://localhost:8080/marmotta/context/abilabproc
> <http://busa:8080/marmotta/context/abilabproc>)?
>
> Hoping to give you some usefull feedback.
>
> Thanx for the support.
>
> Matteo.
>

-- 
Sergio Fernández

Re: Problem with Prefixes Admin Interface

Posted by "Matteo Busanelli (GMail)" <ma...@gmail.com>.
Ciao Sergio,
     I have checked all the things you told to me and I think Ifound the problem.

The http://s.apache.org/marmotta-commit-cbce17677236c400d780459eafa126d5453c5a63 is ok.

I made a different test using "Inspect Element " of Chrome for looking at some js console error.

I found that there is an ajax call error when I use a prefix like "my-pref" because of the "-" char that give problems in the API URL call.
This is the massage in the console:

 1. POST http://busa:8080/marmotta/prefix/test-test?uri=http://www.test.org/test2 404 (Not Found) jquery.min.js:2
    <http://busa:8080/marmotta/webjars/jquery/1.8.2/jquery.min.js>
     1.
        sendjquery.min.js:2 <http://busa:8080/marmotta/webjars/jquery/1.8.2/jquery.min.js>
     2.
        p.extend.ajaxjquery.min.js:2 <http://busa:8080/marmotta/webjars/jquery/1.8.2/jquery.min.js>
     3.
        (anonymous function)prefixes.html:338 <http://busa:8080/marmotta/core/admin/prefixes.html>
     4.
        p.event.dispatchjquery.min.js:2 <http://busa:8080/marmotta/webjars/jquery/1.8.2/jquery.min.js>
     5.
        g.handle.h


If I use a prefix without the "-" everything is ok and I can find my new prefix in the list (is there any delete prefix interface?).

Now I know that I can't use "-" in my prefixes with Marmotta (that I used to use in many ontologies) but I guess that is a bug that should be fixed 
in some way becouse the XML standard (and thus RDF/OWL in any kind of serialization) allows this kind of prefixes.

Looking forward for any news about this issue.

Thanx for your good and fast support.;-)

Matteo.



Il 27/05/2013 20:15, Sergio Fernández ha scritto:
> Ciao Matteo,
>
> On 27/05/13 19:32, Matteo Busanelli (GMail) wrote:
>>      I'm trying Marmotta 3.0 incubator and I'm facing some problem in
>> using prefixes admin interface
>> (http://localhost:8080/marmotta/core/admin/prefixes.html)
>> It seems that from the Admin interface I can't really add any new
>> prefixes because when I click on the Add prefix button nothing happens.
>> Also if I refresh the page or I reboot the server I can't find the
>> prefix that I added.
>>
>> I looked at the Marmotta Jira but I found only a fixed issue on the
>> front-end implemetation (https://issues.apache.org/jira/browse/MARMOTTA-44)
>
> This commit may be also relevant:
>
> http://s.apache.org/marmotta-commit-cbce17677236c400d780459eafa126d5453c5a63
>
> But both were fixed before 3.0.0-incubating release, so no idea how this issue appears again...
>
> Could you please provide us more details about the error? Two things you could check for helping us:
>
> - check for javascript errors in your browser (it you are not familiar with such environment, I can provide you some help)
>
> - Check in the file $MARMOTTA_HOME/system-config.properties if you have the line:
>
>   prefix.yourprefix = http://example.org/yourns#
>
> Thanks for the report.
>
> Cheers,
>


Re: Problem with Prefixes Admin Interface

Posted by Sergio Fernández <wi...@apache.org>.
Ciao Matteo,

On 27/05/13 19:32, Matteo Busanelli (GMail) wrote:
>      I'm trying Marmotta 3.0 incubator and I'm facing some problem in
> using prefixes admin interface
> (http://localhost:8080/marmotta/core/admin/prefixes.html)
> It seems that from the Admin interface I can't really add any new
> prefixes because when I click on the Add prefix button nothing happens.
> Also if I refresh the page or I reboot the server I can't find the
> prefix that I added.
>
> I looked at the Marmotta Jira but I found only a fixed issue on the
> front-end implemetation (https://issues.apache.org/jira/browse/MARMOTTA-44)

This commit may be also relevant:

http://s.apache.org/marmotta-commit-cbce17677236c400d780459eafa126d5453c5a63

But both were fixed before 3.0.0-incubating release, so no idea how this 
issue appears again...

Could you please provide us more details about the error? Two things you 
could check for helping us:

- check for javascript errors in your browser (it you are not familiar 
with such environment, I can provide you some help)

- Check in the file $MARMOTTA_HOME/system-config.properties if you have 
the line:

   prefix.yourprefix = http://example.org/yourns#

Thanks for the report.

Cheers,

-- 
Sergio Fernández