I think the Luca's update query will be able to use my index, where this 
one even though it looks cleaner will probably not.

It's no long hanging, but i do have a connection that did not make it back 
to the thread pool.  It's stuck in the graph.shutdown().

dw-57 - PUT 
/api/asset-manager/assets/fc3a7566-5ae2-4cda-b323-cc612f3ad87b/check-in 
id=57 state=TIMED_WAITING
    - waiting on <0x1c563d7a> (a 
java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject)
    - locked <0x1c563d7a> (a 
java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject)
    at sun.misc.Unsafe.park(Native Method)
    at 
java.util.concurrent.locks.LockSupport.parkNanos(LockSupport.java:226)
    at 
java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject.await(AbstractQueuedSynchronizer.java:2176)
    at 
com.orientechnologies.orient.enterprise.channel.binary.OChannelBinaryAsynchClient.beginResponse(OChannelBinaryAsynchClient.java:257)
    at 
com.orientechnologies.orient.enterprise.channel.binary.OChannelBinaryAsynchClient.beginResponse(OChannelBinaryAsynchClient.java:171)
    at 
com.orientechnologies.orient.client.remote.OStorageRemote.beginResponse(OStorageRemote.java:1865)
    at 
com.orientechnologies.orient.client.remote.OStorageRemote.commit(OStorageRemote.java:1129)
    at 
com.orientechnologies.orient.client.remote.OStorageRemoteThread.commit(OStorageRemoteThread.java:445)
    at 
com.orientechnologies.orient.core.tx.OTransactionOptimistic.doCommit(OTransactionOptimistic.java:470)
    at 
com.orientechnologies.orient.core.tx.OTransactionOptimistic.commit(OTransactionOptimistic.java:147)
    at 
com.orientechnologies.orient.core.db.document.ODatabaseDocumentTx.commit(ODatabaseDocumentTx.java:2370)
    at 
com.orientechnologies.orient.core.db.document.ODatabaseDocumentTx.close(ODatabaseDocumentTx.java:1059)
    at 
com.orientechnologies.orient.core.db.OPartitionedDatabasePool$DatabaseDocumentTxPolled.close(OPartitionedDatabasePool.java:135)
    at 
com.tinkerpop.blueprints.impls.orient.OrientBaseGraph.shutdown(OrientBaseGraph.java:1152)
    at 
com.tinkerpop.blueprints.impls.orient.OrientBaseGraph.shutdown(OrientBaseGraph.java:1124)
    at com.netiq.common.graphdao.DalSession.close(DalSession.java:26)
    at 
com.netiq.common.graphdao.AbstractMultiDao.close(AbstractMultiDao.java:27)
    at com.netiq.assets.services.AssetService.close(AssetService.java:109)
    at 
com.netiq.assets.resources.AssetsResource.checkIn(AssetsResource.java:450)
    at sun.reflect.GeneratedMethodAccessor12.invoke(Unknown Source)
    at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:606)
    at 
com.sun.jersey.spi.container.JavaMethodInvokerFactory$1.invoke(JavaMethodInvokerFactory.java:60)
    at 
com.sun.jersey.server.impl.model.method.dispatch.AbstractResourceMethodDispatchProvider$ResponseOutInvoker._dispatch(AbstractResourceMethodDispatchProvider.java:205)
    at 
com.sun.jersey.server.impl.model.method.dispatch.ResourceJavaMethodDispatcher.dispatch(ResourceJavaMethodDispatcher.java:75)
    at 
com.codahale.metrics.jersey.InstrumentedResourceMethodDispatchProvider$TimedRequestDispatcher.dispatch(InstrumentedResourceMethodDispatchProvider.java:30)
    at 
io.dropwizard.jersey.guava.OptionalResourceMethodDispatchAdapter$OptionalRequestDispatcher.dispatch(OptionalResourceMethodDispatchAdapter.java:37)
    at 
com.sun.jersey.server.impl.uri.rules.HttpMethodRule.accept(HttpMethodRule.java:302)
    at 
com.sun.jersey.server.impl.uri.rules.RightHandPathRule.accept(RightHandPathRule.java:147)
    at 
com.sun.jersey.server.impl.uri.rules.ResourceObjectRule.accept(ResourceObjectRule.java:100)
    at 
com.sun.jersey.server.impl.uri.rules.RightHandPathRule.accept(RightHandPathRule.java:147)
    at 
com.sun.jersey.server.impl.uri.rules.RootResourceClassesRule.accept(RootResourceClassesRule.java:84)
    at 
com.sun.jersey.server.impl.application.WebApplicationImpl._handleRequest(WebApplicationImpl.java:1542)
    at 
com.sun.jersey.server.impl.application.WebApplicationImpl._handleRequest(WebApplicationImpl.java:1473)
    at 
com.sun.jersey.server.impl.application.WebApplicationImpl.handleRequest(WebApplicationImpl.java:1419)
    at 
com.sun.jersey.server.impl.application.WebApplicationImpl.handleRequest(WebApplicationImpl.java:1409)
    at 
com.sun.jersey.spi.container.servlet.WebComponent.service(WebComponent.java:409)
    at 
com.sun.jersey.spi.container.servlet.ServletContainer.service(ServletContainer.java:540)
    at 
com.sun.jersey.spi.container.servlet.ServletContainer.service(ServletContainer.java:715)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:848)
    at 
io.dropwizard.jetty.NonblockingServletHolder.handle(NonblockingServletHolder.java:49)
    at 
org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1515)
    at 
org.eclipse.jetty.servlets.UserAgentFilter.doFilter(UserAgentFilter.java:83)
    at org.eclipse.jetty.servlets.GzipFilter.doFilter(GzipFilter.java:295)
    at io.dropwizard.jetty.BiDiGzipFilter.doFilter(BiDiGzipFilter.java:127)
    at 
org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1486)
    at 
io.dropwizard.servlets.ThreadNameFilter.doFilter(ThreadNameFilter.java:29)
    at 
org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1486)
    at 
io.dropwizard.jersey.filter.AllowedMethodsFilter.handle(AllowedMethodsFilter.java:44)
    at 
io.dropwizard.jersey.filter.AllowedMethodsFilter.doFilter(AllowedMethodsFilter.java:39)
    at 
org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1486)
    at 
org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:519)
    at 
org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:1097)
    at 
org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:448)
    at 
org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1031)
    at 
org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:136)
    at 
org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:97)
    at 
com.codahale.metrics.jetty9.InstrumentedHandler.handle(InstrumentedHandler.java:175)
    at io.dropwizard.jetty.RoutingHandler.handle(RoutingHandler.java:51)
    at 
org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:97)
    at 
org.eclipse.jetty.server.handler.RequestLogHandler.handle(RequestLogHandler.java:92)
    at 
org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:97)
    at 
org.eclipse.jetty.server.handler.StatisticsHandler.handle(StatisticsHandler.java:162)
    at 
org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:97)
    at org.eclipse.jetty.server.Server.handle(Server.java:446)
    at org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:271)
    at 
org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.java:246)
    at 
org.eclipse.jetty.io.AbstractConnection$ReadCallback.run(AbstractConnection.java:358)
    at 
org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:601)
    at 
org.eclipse.jetty.util.thread.QueuedThreadPool$3.run(QueuedThreadPool.java:532)
    at java.lang.Thread.run(Thread.java:745)




On Friday, February 6, 2015 at 10:49:41 AM UTC-6, syshex wrote:
>
> Yes, you can, but that way you need to know the rid of the records , you 
> cant  ( that I know of ) put a subquery on the update , like you want (
> http://www.orientechnologies.com/docs/last/orientdb.wiki/SQL-Update.html)
>
> You can however address the problem you have at hand, which is : selecting 
> something by "guid" is taking too long . Why is that ? Are there too many 
> "asset"s and guid is not indexed ?
>
> What I belive you are looking for is something along the lines of :
>
> update Agent 
> set lastCommunicationTime=date() 
> where 
>     out("Manages").guid  contains '19da4856-57c0-4b39-8f4b-53fc47f86dcf'
>
> which will probably give you problems still, dur to the fact that you are 
> performing a lookup with guid, which seems to take too long.
>
>
>
> On Friday, February 6, 2015 at 4:40:57 PM UTC, alexander anguiano wrote:
>>
>> I didn't realize you can do this.
>>
>> The real query that i need is 
>>
>>
>> update (select in('Manages') from asset where guid = 
>> '817ea932-4a4a-49a4-8454-37c5098703a2') set lastCommunicationTime=date()
>>
>> but it isn't working, it get this
>>
>>  java.lang.IllegalArgumentException: Cluster segment #-2 does not exist 
>> in database 'assets'
>>
>> any clue and how to for this query?
>>
>>
>> On Friday, February 6, 2015 at 10:07:47 AM UTC-6, Emanuele wrote:
>>>
>>> Have you thought to do change in this way: 
>>>
>>> update  #13:3 set lastCommunicationTime=date() 
>>>
>>> bye 
>>>
>>> Emanuel 
>>>
>>> On 06/02/15 15:59, syshex wrote: 
>>> > update Agent set lastCommunicationTime=date() where @rid = #13:3 
>>> > 
>>>
>>>

-- 

--- 
You received this message because you are subscribed to the Google Groups 
"OrientDB" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to orient-database+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to