As far as is I know you can also use POST with form param mode=replace to delete all triples before adding new triples.
Have a look a the java doc of org.apache.clerezza.rdf.web.core.WebAccess for more details. On Feb 4, 2010, at 8:33 PM, Reto Bachmann-Gmuer wrote: > Hi Oli > > Just for completeness, after getting and modifying the content.graph > you should do a PUT do the same address you got the graph from. > > For example, if you did > > curl -u admin:admin -H "Accept: application/rdf+xml" > http://localhost:8080/graph?name=http://tpf.localhost/content.graph > > sysgraph > > to GET the graph, you would do > > curl -u admin:admin -H "Content-Type: application/rdf+xml" -T > sysgraph http://localhost:8080/graph?name=http://tpf.localhost/content.graph > > to PUT it back. > > The procedure described by Tsuy uses POST to add triples to the system > graph, this works as by default there's no defaultBaseUri to modify an > existing default base use you have to use GET and PUT analogously to > the method descibred abobe for the content-graph. > > NOTE: The current ontology usage in the system graph is bogus, the > property defaultBaseUri should not be on > http://clerezza.org/2009/08/platform#Instance but on an instance of > platform:Instance. Once this is fixed (I will post an issue) the > subject of the defaultBaseUri statement will probably be a bnode this > will render the post method impossible. > > Cheers, > reto > > On Thu, Feb 4, 2010 at 6:38 PM, Tsuyoshi Ito <[email protected]> wrote: >> Hi Oli >> >> All UriRefs of the mediatypes' icons are hardcoded in the contentgraph: You >> can change these UriRefs (and also the UriRefs of existing images incl. >> thumbnails) by get the contentgraph via GET >> (http://localhost:8080/graph?name=http://tpf.localhost/content.graph) and >> change this UriRefs and than post it to your instance (you can also use the >> backup service) >> >> Probably there is an easier way to do that? What to you think Manuel? >> >> The DefaultBaseUri of the instance can be changed by posting the following >> triple to the system.graph of your instance. >> >> <rdf:RDF >> xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"> >> <rdf:Description rdf:about="http://clerezza.org/2009/08/platform#Instance"> >> <defaultBaseUri xmlns="http://clerezza.org/2009/08/platform#" >> rdf:resource="http://YOUR_INSTANCE.org/"/> >> </rdf:Description> >> </rdf:RDF> >> >> You can put it via curl >> >> curl -u admin:admin -F "graph=@/PATH_TO_RDF.rdf;type=application/rdf+xml" -F >> "name=http://tpf.localhost/system.graph" -F "mode=append" >> http://YOUR_INSTANCE.org/graph >> >> On Feb 4, 2010, at 5:30 PM, Oliver Strässer wrote: >> >>> Today is installed all new bundles / launcher on the buffy.bluegecko.net >>> >>> All is working very well . The only Problem is, that i can't see the >>> uploaded image (no thumbnails, ... ) >>> If want to create a thumbnail i got the following error message: >>> >>> Any Ideas ? >>> >>> >>> at >>> org.apache.clerezza.platform.content.representations.core.ThumbnailService.getThumbnailUri(ThumbnailService.java:125) >>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) >>> at >>> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) >>> at >>> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) >>> at java.lang.reflect.Method.invoke(Method.java:616) >>> at >>> org.apache.clerezza.triaxrs.RootResourceExecutorImpl.handleWithMethod(RootResourceExecutorImpl.java:450) >>> at >>> org.apache.clerezza.triaxrs.RootResourceExecutorImpl.execute(RootResourceExecutorImpl.java:119) >>> at >>> org.apache.clerezza.triaxrs.JaxRsHandler.handle(JaxRsHandler.java:468) >>> at >>> org.wymiwyg.wrhapi.util.pathmappings.PathMappingHandler$RegisteredHandler.handle(PathMappingHandler.java:127) >>> at >>> org.wymiwyg.wrhapi.util.pathmappings.PathMappingHandler.handle(PathMappingHandler.java:102) >>> at >>> org.apache.clerezza.platform.security.auth.AuthenticatingFilter$1.run(AuthenticatingFilter.java:97) >>> at java.security.AccessController.doPrivileged(Native Method) >>> at javax.security.auth.Subject.doAsPrivileged(Subject.java:537) >>> at >>> org.apache.clerezza.platform.security.auth.AuthenticatingFilter.handle(AuthenticatingFilter.java:93) >>> at >>> org.wymiwyg.wrhapi.filter.impl.FilterRunner.handle(FilterRunner.java:56) >>> at >>> org.apache.clerezza.platform.xhtml2html.Xhtml2HtmlFilter.handle(Xhtml2HtmlFilter.java:52) >>> at >>> org.wymiwyg.wrhapi.filter.impl.FilterRunner.handle(FilterRunner.java:56) >>> at >>> org.wymiwyg.wrhapi.osgi.OsgiWebServerFactory$1.service(OsgiWebServerFactory.java:76) >>> at javax.servlet.http.HttpServlet.service(HttpServlet.java:820) >>> at >>> org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:502) >>> at >>> org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:389) >>> at >>> org.ops4j.pax.web.service.jetty.internal.HttpServiceServletHandler.handle(HttpServiceServletHandler.java:64) >>> at >>> org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:181) >>> at >>> org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:765) >>> at >>> org.ops4j.pax.web.service.jetty.internal.HttpServiceContext.handle(HttpServiceContext.java:111) >>> at >>> org.ops4j.pax.web.service.jetty.internal.JettyServerHandlerCollection.handle(JettyServerHandlerCollection.java:64) >>> at >>> org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:152) >>> at org.mortbay.jetty.Server.handle(Server.java:326) >>> at >>> org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:534) >>> at >>> org.mortbay.jetty.HttpConnection$RequestHandler.headerComplete(HttpConnection.java:864) >>> at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:539) >>> at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:212) >>> at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:404) >>> at >>> org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:409) >>> at >>> org.mortbay.thread.QueuedThreadPool$PoolThread.run(QueuedThreadPool.java:520) >>> >> >> Cheers >> Tsuy >> >>
