incubator-clerezza-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Reto Bachmann-Gmür (JIRA) <j...@apache.org>
Subject [jira] Commented: (CLEREZZA-321) stresstest: requests an ssp page containing an rdflist makes the list corrupt
Date Tue, 19 Oct 2010 14:09:29 GMT

    [ https://issues.apache.org/jira/browse/CLEREZZA-321?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12922562#action_12922562
] 

Reto Bachmann-Gmür commented on CLEREZZA-321:
---------------------------------------------

I didn't manage to reproduce the erorr yet, but got another exception (100 threads, no delay
between requests)

ava.lang.RuntimeException: Cannot compare users!
    at org.apache.clerezza.platform.usermanager.UserComparator.compare(UserComparator.java:39)
    at org.apache.clerezza.platform.usermanager.UserComparator.compare(UserComparator.java:28)
    at java.util.TreeMap.put(TreeMap.java:547)
    at java.util.TreeSet.add(TreeSet.java:255)
    at org.apache.clerezza.platform.usermanager.webinterface.UserManagerWeb.listUsers(UserManagerWeb.java:222)
    at sun.reflect.GeneratedMethodAccessor9.invoke(Unknown Source)
    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:471)
    at org.apache.clerezza.triaxrs.RootResourceExecutorImpl.execute(RootResourceExecutorImpl.java:121)
    at org.apache.clerezza.triaxrs.JaxRsHandler.handle(JaxRsHandler.java:503)
    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:94)
    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:90)
    at org.wymiwyg.wrhapi.filter.impl.FilterRunner.handle(FilterRunner.java:56)
    at org.apache.clerezza.platform.xhtml2html.Xhtml2HtmlFilter.handle(Xhtml2HtmlFilter.java:73)
    at org.wymiwyg.wrhapi.filter.impl.FilterRunner.handle(FilterRunner.java:56)
    at org.wymiwyg.wrhapi.osgi.OsgiWebServerFactory$1.service(OsgiWebServerFactory.java:78)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
    at org.eclipse.equinox.http.servlet.internal.ServletRegistration.handleRequest(ServletRegistration.java:90)
    at org.eclipse.equinox.http.servlet.internal.ProxyServlet.processAlias(ProxyServlet.java:109)
    at org.eclipse.equinox.http.servlet.internal.ProxyServlet.service(ProxyServlet.java:75)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
    at org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:527)
    at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:423)
    at org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:223)
    at org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:930)
    at org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:358)
    at org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:183)
    at org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:866)
    at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:117)
    at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:113)
    at org.eclipse.jetty.server.Server.handle(Server.java:337)
    at org.eclipse.jetty.server.HttpConnection.handleRequest(HttpConnection.java:595)
    at org.eclipse.jetty.server.HttpConnection$RequestHandler.headerComplete(HttpConnection.java:1038)
    at org.eclipse.jetty.http.HttpParser.parseNext(HttpParser.java:549)
    at org.eclipse.jetty.http.HttpParser.parseAvailable(HttpParser.java:211)
    at org.eclipse.jetty.server.HttpConnection.handle(HttpConnection.java:424)
    at org.eclipse.jetty.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:489)
    at org.eclipse.jetty.util.thread.QueuedThreadPool$2.run(QueuedThreadPool.java:436)
    at java.lang.Thread.run(Thread.java:636)

In the system graph there's onlyone user:

<rdf:RDF
    xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
    xmlns:j.0="http://clerezza.org/2008/10/permission#"
    xmlns:j.1="http://xmlns.com/foaf/0.1/"
    xmlns:dc="http://purl.org/dc/elements/1.1/"
    xmlns:j.2="http://clerezza.org/2009/08/platform#"
    xmlns:j.3="http://rdfs.org/sioc/ns#"
    xmlns:rdfs="http://www.w3.org/2000/01/rdf-schema#" > 
  <rdf:Description rdf:nodeID="A0">
    <rdf:rest rdf:nodeID="A1"/>
    <rdf:first rdf:resource="http://clerezza.org/2009/09/hierarchy#Collection"/>
  </rdf:Description>
  <rdf:Description rdf:nodeID="A2">
    <j.0:javaPermissionEntry>(org.apache.clerezza.rdf.core.access.security.TcPermission
"http://tpf.localhost/documentation.graph" "read")</j.0:javaPermissionEntry>
  </rdf:Description>
  <rdf:Description rdf:nodeID="A3">

    <j.0:javaPermissionEntry>(org.apache.clerezza.rdf.core.access.security.TcPermission
"http://tpf.localhost/config.graph" "read")</j.0:javaPermissionEntry>
  </rdf:Description>
  <rdf:Description rdf:nodeID="A4">
    <j.0:javaPermissionEntry>(org.apache.clerezza.platform.accountcontrolpanel.ChangePasswordPermission
"{username}" "")</j.0:javaPermissionEntry>
  </rdf:Description>
  <rdf:Description rdf:nodeID="A5">
    <rdf:type rdf:resource="http://clerezza.org/2008/10/permission#Role"/>
    <rdf:type rdf:resource="http://clerezza.org/2008/10/permission#BaseRole"/>

    <dc:title>BasePermissionsRole</dc:title>
    <rdfs:comment>Every user implicitely has this role as this is a perm:BaseRole</rdfs:comment>
    <j.0:hasPermission rdf:nodeID="A6"/>
    <j.0:hasPermission rdf:nodeID="A7"/>
    <j.0:hasPermission rdf:nodeID="A8"/>
    <j.0:hasPermission rdf:nodeID="A2"/>
    <j.0:hasPermission rdf:nodeID="A3"/>
  </rdf:Description>

  <rdf:Description rdf:nodeID="A8">
    <j.0:javaPermissionEntry>(org.apache.clerezza.rdf.core.access.security.TcPermission
"http://tpf.localhost/content.graph" "read")</j.0:javaPermissionEntry>
  </rdf:Description>
  <rdf:Description rdf:nodeID="A7">
    <j.0:javaPermissionEntry>(org.osgi.framework.AdminPermission "*" "resource")</j.0:javaPermissionEntry>
  </rdf:Description>
  <rdf:Description rdf:about="http://tpf.localhost/typePriorityList">
    <rdf:rest rdf:nodeID="A9"/>

    <rdf:rest rdf:nodeID="A10"/>
    <rdf:first rdf:resource="http://clerezza.org/2009/07/script#ScriptGeneratedResource"/>
  </rdf:Description>
  <rdf:Description rdf:nodeID="A11">
    <rdf:type rdf:resource="http://clerezza.org/2008/10/permission#Role"/>
    <dc:title>CommunityUser</dc:title>
    <j.0:hasPermission rdf:nodeID="A12"/>
    <j.0:hasPermission rdf:nodeID="A13"/>

  </rdf:Description>
  <rdf:Description rdf:nodeID="A14">
    <rdf:type rdf:resource="http://clerezza.org/2009/08/platform#Instance"/>
    <j.2:languages rdf:nodeID="A15"/>
  </rdf:Description>
  <rdf:Description rdf:nodeID="A1">
    <rdf:rest rdf:resource="http://www.w3.org/1999/02/22-rdf-syntax-ns#nil"/>
    <rdf:first rdf:resource="http://www.w3.org/2000/01/rdf-schema#Resource"/>
  </rdf:Description>

  <rdf:Description rdf:nodeID="A16">
    <j.0:javaPermissionEntry>(org.apache.clerezza.platform.accountcontrolpanel.AccountControlPanelAppPermission
"{username}" "")</j.0:javaPermissionEntry>
  </rdf:Description>
  <rdf:Description rdf:nodeID="A9">
    <rdf:rest rdf:nodeID="A17"/>
    <rdf:first rdf:resource="http://clerezza.org/2009/07/script#ScriptGeneratedResource"/>
  </rdf:Description>
  <rdf:Description rdf:nodeID="A6">

    <j.0:javaPermissionEntry>(java.util.PropertyPermission "*" "read")</j.0:javaPermissionEntry>
  </rdf:Description>
  <rdf:Description rdf:nodeID="A10">
    <rdf:rest rdf:nodeID="A0"/>
    <rdf:first rdf:resource="http://clerezza.org/2009/09/hierarchy#Collection"/>
  </rdf:Description>
  <rdf:Description rdf:nodeID="A12">
    <j.0:javaPermissionEntry>(org.apache.clerezza.platform.accountcontrolpanel.UserBundlePermission
"{username}" "")</j.0:javaPermissionEntry>

  </rdf:Description>
  <rdf:Description rdf:nodeID="A15">
    <rdf:rest rdf:resource="http://www.w3.org/1999/02/22-rdf-syntax-ns#nil"/>
    <rdf:first rdf:resource="http://www.lingvoj.org/lang/en"/>
  </rdf:Description>
  <rdf:Description rdf:nodeID="A18">
    <j.0:javaPermissionEntry>(java.security.AllPermission "" "")</j.0:javaPermissionEntry>
  </rdf:Description>

  <rdf:Description rdf:nodeID="A19">
    <rdf:rest rdf:resource="http://www.w3.org/1999/02/22-rdf-syntax-ns#nil"/>
    <rdf:first rdf:resource="http://www.w3.org/2000/01/rdf-schema#Resource"/>
  </rdf:Description>
  <rdf:Description rdf:nodeID="A20">
    <rdf:type rdf:resource="http://clerezza.org/2008/10/permission#Role"/>
    <dc:title>DefaultRole</dc:title>
    <rdfs:comment>A role regular users typically have</rdfs:comment>

    <j.0:hasPermission rdf:nodeID="A4"/>
    <j.0:hasPermission rdf:nodeID="A16"/>
  </rdf:Description>
  <rdf:Description rdf:nodeID="A13">
    <j.0:javaPermissionEntry>(org.apache.clerezza.rdf.core.access.security.TcPermission
"http://tpf.localhost/user/{username}/*" "readwrite")</j.0:javaPermissionEntry>
  </rdf:Description>
  <rdf:Description rdf:nodeID="A21">
    <rdf:type rdf:resource="http://xmlns.com/foaf/0.1/Agent"/>

    <j.0:hasPermission rdf:nodeID="A18"/>
    <j.2:userName>admin</j.2:userName>
    <j.1:mbox rdf:resource="mailto:noreply@clerezza.org"/>
    <j.0:passwordSha1>d033e22ae348aeb5660fc2140aec35850c4da997</j.0:passwordSha1>
  </rdf:Description>
  <rdf:Description rdf:nodeID="A17">
    <rdf:rest rdf:nodeID="A19"/>
    <rdf:first rdf:resource="http://clerezza.org/2009/07/script#ScriptGeneratedResource"/>

  </rdf:Description>
  <rdf:Description rdf:nodeID="A22">
  </rdf:Description>
</rdf:RDF>



import org.apache.clerezza.rdf.core._
import org.apache.clerezza.rdf.core.impl._
import org.apache.clerezza.rdf.utils._
import org.apache.clerezza.rdf.ontologies._
val graphName =new UriRef("http://tpf.localhost/system.graph")
val graph = tcManager.getMGraph(graphName)
val iter = graph.filter(null, RDF.`type`, FOAF.Agent)
var result = ""
while (iter.hasNext) {
val agentStmt = iter.next
val iter2 = graph.filter(agentStmt.getSubject, null, null)
while (iter2.hasNext) {
val stmt = iter2.next
result = result + "-> "+stmt.toString+ "\n"
}
result = result + agentStmt.toString+ "\n"
}
<pre>{result}</pre>.toString


yields to:
org.apache.clerezza.rdf.core.BNode@100c657 <http://www.w3.org/1999/02/22-rdf-syntax-ns#type>
<http://xmlns.com/foaf/0.1/Agent>.
-> org.apache.clerezza.rdf.core.BNode@15492d3 <http://www.w3.org/1999/02/22-rdf-syntax-ns#type>
<http://xmlns.com/foaf/0.1/Agent>.
-> org.apache.clerezza.rdf.core.BNode@15492d3 <http://clerezza.org/2008/10/permission#hasPermission>
org.apache.clerezza.rdf.core.BNode@1d9462f.
-> org.apache.clerezza.rdf.core.BNode@15492d3 <http://clerezza.org/2009/08/platform#userName>
"admin".
-> org.apache.clerezza.rdf.core.BNode@15492d3 <http://xmlns.com/foaf/0.1/mbox> <mailto:noreply@clerezza.org>.
-> org.apache.clerezza.rdf.core.BNode@15492d3 <http://clerezza.org/2008/10/permission#passwordSha1>
"d033e22ae348aeb5660fc2140aec35850c4da997".
org.apache.clerezza.rdf.core.BNode@15492d3 <http://www.w3.org/1999/02/22-rdf-syntax-ns#type>
<http://xmlns.com/foaf/0.1/Agent>.


consistently
PREFIX rdf:<http://www.w3.org/1999/02/22-rdf-syntax-ns#>
PREFIX foaf:<http://xmlns.com/foaf/0.1/>
PREFIX platform:<http://clerezza.org/2009/08/platform#>
SELECT ?U ?A {?A rdf:type foaf:Agent.
OPTIONAL {?A platform:userName ?U}}
to:
<sparql>
−
<head>
<variable name="U"/>
<variable name="A"/>
</head>
−
<results>
−
<result>
−
<binding name="A">
<bnode>org.apache.clerezza.rdf.core.BNode@15cd718</bnode>
</binding>
</result>
−
<result>
−
<binding name="U">
<literal>admin</literal>
</binding>
−
<binding name="A">
<bnode>org.apache.clerezza.rdf.core.BNode@2d739d</bnode>
</binding>
</result>
</results>
</sparql>

restarting scb core: no change

restart scb jena tdb storage provider, user anonymous resurrected:
<sparql>
−
<head>
<variable name="U"/>
<variable name="A"/>
</head>
−
<results>
−
<result>
−
<binding name="U">
<literal>anonymous</literal>
</binding>
−
<binding name="A">
<bnode>org.apache.clerezza.rdf.core.BNode@1d147a8</bnode>
</binding>
</result>
−
<result>
−
<binding name="U">
<literal>admin</literal>
</binding>
−
<binding name="A">
<bnode>org.apache.clerezza.rdf.core.BNode@b776e9</bnode>
</binding>
</result>
</results>
</sparql>

> stresstest: requests an ssp page containing an rdflist makes the list corrupt
> -----------------------------------------------------------------------------
>
>                 Key: CLEREZZA-321
>                 URL: https://issues.apache.org/jira/browse/CLEREZZA-321
>             Project: Clerezza
>          Issue Type: Bug
>            Reporter: Tsuyoshi Ito
>            Assignee: Reto Bachmann-Gmür
>            Priority: Critical
>
> After a while the following error occured on the page:
> java.lang.RuntimeException: java.lang.RuntimeException: broken list org.apache.clerezza.rdf.core.BNode@3bebc3b5
	at org.apache.clerezza.rdf.utils.RdfList.getFirstEntry(RdfList.java:270) 	at org.apache.clerezza.rdf.utils.RdfList.expandTill(RdfList.java:155)
	at org.apache.clerezza.rdf.utils.RdfList.size(RdfList.java:170) 	at java.util.AbstractList$Itr.hasNext(AbstractList.java:339)
	at scala.collection.JavaConversions$JIteratorWrapper.hasNext(JavaConversions.scala:475) 
at scala.collection.Iterator$class.foreach(Iterator.scala:631) 	at scala.collection.JavaConversions$JIteratorWrapper.foreach(JavaConversions.scala:474)
	at scala.collection.IterableLike$class.foreach(IterableLike.scala:79) 	at scala.collection.JavaConversions$JListWrapper.foreach(JavaConversions.scala:521)
	at scala.collection.TraversableLike$class.map(TraversableLike.scala:206) 	at scala.collection.JavaConversions$JListWrapper.map(JavaConversions.scala:521)
	at org.apache.clerezza.rdf.scala.utils.RichGraphNode.$bang$bang(RichGraphNode.scala:46) 
at CompiledScript5.topMenu$1(&lt;script&gt;:76) 	at CompiledScript5.run(&lt;script&gt;:188)
	at sun.reflect.GeneratedMethodAccessor19.invoke(Unknown Source) 	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
	at java.lang.reflect.Method.invoke(Method.java:597) 	at org.apache.clerezza.scala.scripting.ScriptEngineFactory$MyScriptEngine$$anon$4$$anon$5.eval(ScriptEngineFactory.scala:270)
	at javax.script.CompiledScript.eval(CompiledScript.java:75) 	at org.apache.clerezza.platform.typerendering.scalaserverpages.ScalaServerPagesRenderlet$1.run(ScalaServerPagesRenderlet.java:231)
	at java.security.AccessController.doPrivileged(Native Method) 	at org.apache.clerezza.platform.typerendering.scalaserverpages.ScalaServerPagesRenderlet.exec(ScalaServerPagesRenderlet.java:227)
	at org.apache.clerezza.platform.typerendering.scalaserverpages.ScalaServerPagesRenderlet.render(ScalaServerPagesRenderlet.java:132)
	at org.apache.clerezza.platform.typerendering.RendererImpl.render(RendererImpl.java:95) 
at org.apache.clerezza.platform.typerendering.CallbackRendererImpl.render(CallbackRendererImpl.java:59)
	at CompiledScript1.render$1(&lt;script&gt;:31) 	at CompiledScript1.run(&lt;script&gt;:150)
	at sun.reflect.GeneratedMethodAccessor23.invoke(Unknown Source) 	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
	at java.lang.reflect.Method.invoke(Method.java:597) 	at org.apache.clerezza.scala.scripting.ScriptEngineFactory$MyScriptEngine$$anon$4$$anon$5.eval(ScriptEngineFactory.scala:270)
	at javax.script.CompiledScript.eval(CompiledScript.java:75) 	at org.apache.clerezza.platform.typerendering.scalaserverpages.ScalaServerPagesRenderlet$1.run(ScalaServerPagesRenderlet.java:231)
	at java.security.AccessController.doPrivileged(Native Method) 	at org.apache.clerezza.platform.typerendering.scalaserverpages.ScalaServerPagesRenderlet.exec(ScalaServerPagesRenderlet.java:227)
	at org.apache.clerezza.platform.typerendering.scalaserverpages.ScalaServerPagesRenderlet.render(ScalaServerPagesRenderlet.java:132)
	at org.apache.clerezza.platform.typerendering.RendererImpl.render(RendererImpl.java:95) 
at org.apache.clerezza.platform.typerendering.GenericGraphNodeMBW.writeTo(GenericGraphNodeMBW.java:159)
	at org.apache.clerezza.platform.typerendering.GenericGraphNodeMBW.writeTo(GenericGraphNodeMBW.java:76)
	at org.apache.clerezza.triaxrs.ResponseProcessor$1.writeTo(ResponseProcessor.java:333) 	at
org.apache.clerezza.triaxrs.ResponseProcessor$1.access$200(ResponseProcessor.java:280) 	at
org.apache.clerezza.triaxrs.ResponseProcessor$1$3.run(ResponseProcessor.java:313) 	at java.security.AccessController.doPrivileged(Native
Method) 	at javax.security.auth.Subject.doAs(Subject.java:396) 	at org.apache.clerezza.triaxrs.ResponseProcessor$1.writeTo(ResponseProcessor.java:309)
	at org.wymiwyg.wrhapi.osgi.OsgiWebServerFactory$1.service(OsgiWebServerFactory.java:112)
	at javax.servlet.http.HttpServlet.service(HttpServlet.java:847) 	at org.eclipse.equinox.http.servlet.internal.ServletRegistration.handleRequest(ServletRegistration.java:90)
	at org.eclipse.equinox.http.servlet.internal.ProxyServlet.processAlias(ProxyServlet.java:109)
	at org.eclipse.equinox.http.servlet.internal.ProxyServlet.service(ProxyServlet.java:75) 
at javax.servlet.http.HttpServlet.service(HttpServlet.java:847) 	at org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:532)
	at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:453) 	at org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:227)
	at org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:965) 	at
org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:388) 	at org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:187)
	at org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:901) 	at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:117)
	at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:113) 	at org.eclipse.jetty.server.Server.handle(Server.java:352)
	at org.eclipse.jetty.server.HttpConnection.handleRequest(HttpConnection.java:596) 	at org.eclipse.jetty.server.HttpConnection$RequestHandler.headerComplete(HttpConnection.java:1048)
	at org.eclipse.jetty.http.HttpParser.parseNext(HttpParser.java:549) 	at org.eclipse.jetty.http.HttpParser.parseAvailable(HttpParser.java:211)
	at org.eclipse.jetty.server.HttpConnection.handle(HttpConnection.java:425) 	at org.eclipse.jetty.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:489)
	at org.eclipse.jetty.util.thread.QueuedThreadPool$2.run(QueuedThreadPool.java:436) 	at java.lang.Thread.run(Thread.java:619)
Caused by: java.lang.RuntimeException: broken list org.apache.clerezza.rdf.core.BNode@3bebc3b5
	at org.apache.clerezza.rdf.utils.RdfList.getFirstEntry(RdfList.java:268) 	... 68 more Caused
by: java.lang.NullPointerException 
> Console log says 
> [qtp1281006702-136] WARN org.apache.clerezza.rdf.utils.RdfList - GraphNode: org.apache.clerezza.rdf.core.BNode@3bebc3b5

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message