[ 
https://issues.apache.org/jira/browse/STANBOL-426?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13205572#comment-13205572
 ] 

Alessandro Adamou commented on STANBOL-426:
-------------------------------------------

Actually it should be possible to have multiple identifiers for the same 
graphs, or better, equal graphs which share the same triples.

I performed a code check: you get two TripleCollection's because whan you call 
addOntology() on ontology collectors (spaces or sessions), they always try to 
create a MGraph named after the ontology itself (if it has a name, otherwise it 
uses a timestamp - I hope your ontonet:: graph ID looks like that because your 
ontology did not have an OWL name, did it?). 

Then it performs addAll() from the originally stored graph.

I would expect this to be equivalent to having a single graph with two names 
and *no* double memory usage, since they share the same TcProvider (the unique 
TcManager).

You could get yourself a single identifier by using a new SimpleTcProvider() 
for the GraphContentInputSource, I guess that *would* cause twice the memory 
usage, at least until the input source is garbage-collected.

If you wish, I can implement a check that "deletes" the triple collection 
org.apache.stanbol.ontologymanager.ontonet.api.io.GraphContentInputSource-1328882620149
 . According to the Clerezza API specification, the triples should survive the 
deletion, because they still belong to 
ontonet::http://stanbol.apache.org/1328882278969
                
> Ability to manage identifiers of ontologies added to spaces
> -----------------------------------------------------------
>
>                 Key: STANBOL-426
>                 URL: https://issues.apache.org/jira/browse/STANBOL-426
>             Project: Stanbol
>          Issue Type: Story
>          Components: Ontology Manager
>            Reporter: Stephen Bayliss
>            Priority: Minor
>
> We have a use case which involves synchronising ontologies stored in a KReS 
> custom space with content from an external system, which itself identifies 
> units of content (ie the ontology being added to KReS) using URIs.
> When adding an ontology using an OntologyInputSource there doesn't seem to be 
> any way of reconciling the identity of the ontology in the custom space with 
> the content identifier URI from the external system.
> This means that when content in the external system is modified or deleted, 
> there is no easy way to determine which ontology in the custom space should 
> be updated/deleted.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Reply via email to