{"action":"created","issue":{"url":"https://api.github.com/repos/Ostico/PhpOrient/issues/55","labels_url":"https://api.github.com/repos/Ostico/PhpOrient/issues/55/labels{/name}","comments_url":"https://api.github.com/repos/Ostico/PhpOrient/issues/55/comments","events_url":"https://api.github.com/repos/Ostico/PhpOrient/issues/55/events","html_url":"https://github.com/Ostico/PhpOrient/issues/55","id":115480281,"number":55,"title":"High memory allocation with 2.1.5","user":{"login":"ncreea","id":5518670,"avatar_url":"https://avatars.githubusercontent.com/u/5518670?v=3","gravatar_id":"","url":"https://api.github.com/users/ncreea","html_url":"https://github.com/ncreea","followers_url":"https://api.github.com/users/ncreea/followers","following_url":"https://api.github.com/users/ncreea/following{/other_user}","gists_url":"https://api.github.com/users/ncreea/gists{/gist_id}","starred_url":"https://api.github.com/users/ncreea/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ncreea/subscriptions","organizations_url":"https://api.github.com/users/ncreea/orgs","repos_url":"https://api.github.com/users/ncreea/repos","events_url":"https://api.github.com/users/ncreea/events{/privacy}","received_events_url":"https://api.github.com/users/ncreea/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":12,"created_at":"2015-11-06T10:40:07Z","updated_at":"2015-11-06T16:09:33Z","closed_at":null,"body":"Hi Guys,\r\n\r\nI recently upgraded our dev environment from 2.1.3 to 2.1.5 and experiencing random high memory allocations. \r\n\r\n`Eg: Allowed memory size of 134217728 bytes exhausted (tried to allocate 335544421 bytes) in /var/www/html/release/1.1.3/.../vendor/ostico/phporient/src/PhpOrient/Protocols/Binary/OrientSocket.php`\r\n\r\nI did some debugging and looks like randomly the read for size is returning gigantic values (eg.~ 320Mb, sometimes even higher). Also identified that all this values originate from `/PhpOrient/Protocols/Binary/Abstracts/Operation.php`,  `_readInt` function called by `_readString`.\r\n\r\nAnalyzing the binary data obtained by the 4 byte read I see this gigantic values. \r\n\r\nI've also logged the $_data variable content into a file and the final result of the read is only 1.1K and contains all the results.\r\n\r\nIs this a bug in the OrientDB 2.1.5 binary protocol or can be caused by some protocol changes that aren't yet fully implemented by this library?\r\n\r\nThanks,\r\nCsaba\r\n"},"comment":{"url":"https://api.github.com/repos/Ostico/PhpOrient/issues/comments/154451348","html_url":"https://github.com/Ostico/PhpOrient/issues/55#issuecomment-154451348","issue_url":"https://api.github.com/repos/Ostico/PhpOrient/issues/55","id":154451348,"user":{"login":"andreyvk","id":1415506,"avatar_url":"https://avatars.githubusercontent.com/u/1415506?v=3","gravatar_id":"","url":"https://api.github.com/users/andreyvk","html_url":"https://github.com/andreyvk","followers_url":"https://api.github.com/users/andreyvk/followers","following_url":"https://api.github.com/users/andreyvk/following{/other_user}","gists_url":"https://api.github.com/users/andreyvk/gists{/gist_id}","starred_url":"https://api.github.com/users/andreyvk/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/andreyvk/subscriptions","organizations_url":"https://api.github.com/users/andreyvk/orgs","repos_url":"https://api.github.com/users/andreyvk/repos","events_url":"https://api.github.com/users/andreyvk/events{/privacy}","received_events_url":"https://api.github.com/users/andreyvk/received_events","type":"User","site_admin":false},"created_at":"2015-11-06T16:09:33Z","updated_at":"2015-11-06T16:09:33Z","body":"PS - if this is a demo DB and you dont mind disclosing info to only him, then just ZIP the whole folder from `$ORIENTDB_DIR/databases/` and send it to him in a private email, because export-import fails sometimes on Orient :)) (bugs!)"}}