-
Notifications
You must be signed in to change notification settings - Fork 54
Connection or reconnection strange behavior in response time #168
Comments
Hi Alessandro. |
that'd be great! it was implemente in this pull request |
You totally right! So I changed my binding initialization that way: $adapter = new Doctrine\OrientDB\Binding\Adapter\CurlClientAdapter(new CurlClient(true)); and it works. No more additional delay. I'm wondering. Is it a issue related to the culr library in PHP 5.5? |
I honestly have no idea, especially because the library is only tested on php 5.3 and 5.4 :) |
@nrk do you have any idea? |
Nope. |
@nrk, thank you in advance. |
Just did a quick test against OrientDB 1.6.2 using PHP 5.4.17 and 5.5.6 under MacOS X 10.9 but I couldn't reproduce the reported issue: reusing or not the underlying cURL handle didn't make much difference, the observed timings were roughly the same (between 1ms and 4ms). @pulciux where is the OrientDB database instance running? Same host of your scripts or a remote host? |
Same host, connected through remote protocol. But that's interesting. Here a comparison with curl handler reusing : OrientDB 1.6.2 2013-12-14T12:28:13+01:00: objects list retrieved OrientDB 1.6.0 2013-12-14T12:33:11+01:00: objects list retrieved |
Ping @lgarulli On Dec 14, 2013 4:08 PM, "pulciux" notifications@github.com wrote:
|
ooops /cc @lvca |
OrientDB 1.6.2 has little enhancements on performance (and the upcoming 1.6.3 a little more), so I'm expecting it could be faster. |
Considering that this issue seems to be specifically related to |
Great! |
Thanks :-) |
OreintDB 1.6.0
orientdb-odm: lastest master branch
PHP: 5.5.6
Linux x86_64 - OpenSuSE 12.3
Hi all.
I using orientdb-odm by few days now, in conjunction with OrientDB 1.6.0, and I've encountered a strange behavior in multiple db calls after a single connection to the server.
I mean, I guess it's a strange behavior but it may be I forgot some step.
After a db connection using
$parameters = new BindingParameters($this->host,$this->port,$this->user,$this->password,$this->dbname);
$this->oobj = new HttpBinding($parameters);
I call a query or a command method and I get a response in 0.004 seconds.
e.g.
$this->oobj->query("select expand(inE('isSysUsersRoleOfClass')) from #21:0");
If I call them a second or more times the response time increase dramatically: about 0.5 seconds per call or more.
But if before calling a query or a command method I rebind it to the server recreating a new HttpBinding object the response time it still closer to the real server performances.
$this->oobj = new HttpBinding($parameters);
$this->oobj->query("select expand(inE('isSysUsersRoleOfClass')) from #21:0");
$this->oobj = new HttpBinding($parameters);
$this->oobj->query("select expand(inE('isSysUsersRoleOfClass')) from #21:1");
...
That it means, every first call it's executed fast but any further more on the same HttpBinding object takes a lot of time.
I was expecting the opposite behavior.
Any advice?
The text was updated successfully, but these errors were encountered: