{"action":"created","issue":{"url":"https://api.github.com/repos/orientechnologies/orientdb/issues/5286","labels_url":"https://api.github.com/repos/orientechnologies/orientdb/issues/5286/labels{/name}","comments_url":"https://api.github.com/repos/orientechnologies/orientdb/issues/5286/comments","events_url":"https://api.github.com/repos/orientechnologies/orientdb/issues/5286/events","html_url":"https://github.com/orientechnologies/orientdb/issues/5286","id":115487640,"number":5286,"title":"Concurrent reads with LET subquery very slow","user":{"login":"janjilek","id":5908091,"avatar_url":"https://avatars.githubusercontent.com/u/5908091?v=3","gravatar_id":"","url":"https://api.github.com/users/janjilek","html_url":"https://github.com/janjilek","followers_url":"https://api.github.com/users/janjilek/followers","following_url":"https://api.github.com/users/janjilek/following{/other_user}","gists_url":"https://api.github.com/users/janjilek/gists{/gist_id}","starred_url":"https://api.github.com/users/janjilek/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/janjilek/subscriptions","organizations_url":"https://api.github.com/users/janjilek/orgs","repos_url":"https://api.github.com/users/janjilek/repos","events_url":"https://api.github.com/users/janjilek/events{/privacy}","received_events_url":"https://api.github.com/users/janjilek/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/orientechnologies/orientdb/labels/question","name":"question","color":"cc317c"}],"state":"open","locked":false,"assignee":{"login":"luigidellaquila","id":459289,"avatar_url":"https://avatars.githubusercontent.com/u/459289?v=3","gravatar_id":"","url":"https://api.github.com/users/luigidellaquila","html_url":"https://github.com/luigidellaquila","followers_url":"https://api.github.com/users/luigidellaquila/followers","following_url":"https://api.github.com/users/luigidellaquila/following{/other_user}","gists_url":"https://api.github.com/users/luigidellaquila/gists{/gist_id}","starred_url":"https://api.github.com/users/luigidellaquila/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/luigidellaquila/subscriptions","organizations_url":"https://api.github.com/users/luigidellaquila/orgs","repos_url":"https://api.github.com/users/luigidellaquila/repos","events_url":"https://api.github.com/users/luigidellaquila/events{/privacy}","received_events_url":"https://api.github.com/users/luigidellaquila/received_events","type":"User","site_admin":false},"milestone":null,"comments":4,"created_at":"2015-11-06T11:25:39Z","updated_at":"2015-11-06T12:20:30Z","closed_at":null,"body":"Hi, if i try to query 100 times in parallel this select: \r\n\r\n```sql\r\nSELECT *, $product as product FROM Category LET product = (SELECT expand($parent.$current.IN('Belong')[@class = Product]) LIMIT 10) ORDER BY (priority desc)\r\n```\r\n\r\nIt looks like, that queries are executed one by one, because i receive first response in 500ms, second in 1000ms and last in 50s.\r\n\r\nI have index on priority column.\r\n\r\nAny work around for this? \r\n\r\nTested on:\r\nOrientDB 2.1.5\r\n4 cores\r\n15GB of RAM"},"comment":{"url":"https://api.github.com/repos/orientechnologies/orientdb/issues/comments/154396216","html_url":"https://github.com/orientechnologies/orientdb/issues/5286#issuecomment-154396216","issue_url":"https://api.github.com/repos/orientechnologies/orientdb/issues/5286","id":154396216,"user":{"login":"luigidellaquila","id":459289,"avatar_url":"https://avatars.githubusercontent.com/u/459289?v=3","gravatar_id":"","url":"https://api.github.com/users/luigidellaquila","html_url":"https://github.com/luigidellaquila","followers_url":"https://api.github.com/users/luigidellaquila/followers","following_url":"https://api.github.com/users/luigidellaquila/following{/other_user}","gists_url":"https://api.github.com/users/luigidellaquila/gists{/gist_id}","starred_url":"https://api.github.com/users/luigidellaquila/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/luigidellaquila/subscriptions","organizations_url":"https://api.github.com/users/luigidellaquila/orgs","repos_url":"https://api.github.com/users/luigidellaquila/repos","events_url":"https://api.github.com/users/luigidellaquila/events{/privacy}","received_events_url":"https://api.github.com/users/luigidellaquila/received_events","type":"User","site_admin":false},"created_at":"2015-11-06T12:20:30Z","updated_at":"2015-11-06T12:20:30Z","body":"Hi Jan,\r\n\r\nJust to better understand, how many incoming edges to you have on each vertex?\r\nLET operator in some cases is not very efficient, but simple traversal should be\r\n\r\nThanks\r\n\r\nLuigi"}}