Skip to content

Commit

Permalink
Removes artificial loop usleep for better performance
Browse files Browse the repository at this point in the history
  • Loading branch information
hollodotme committed Nov 18, 2017
1 parent f657930 commit 5c2add6
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
8 changes: 7 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,13 @@ This project adheres to [Semantic Versioning](http://semver.org/) and [Keep a CH

## [1.4.1] - 2017-11-19

* Fixes PHP warning when trying to get ready request IDs - [#14]
### Fixes

* PHP warning when trying to get ready request IDs - [#14]

### Improves

* Loop performance

## [1.4.0] - 2017-09-28

Expand Down
6 changes: 0 additions & 6 deletions src/Client.php
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,6 @@
*/
class Client
{
const LOOP_TICK_USEC = 2000;

/** @var ConfiguresSocketConnection */
private $connection;

Expand Down Expand Up @@ -160,8 +158,6 @@ public function waitForResponse( int $requestId, $timeoutMs = null )
$this->fetchResponseAndNotifyCallback( $socket, $timeoutMs );
break;
}

usleep( self::LOOP_TICK_USEC );
}
}

Expand All @@ -184,8 +180,6 @@ public function waitForResponses( $timeoutMs = null )
{
$this->fetchResponseAndNotifyCallback( $socket, $timeoutMs );
}

usleep( self::LOOP_TICK_USEC );
}
}

Expand Down

0 comments on commit 5c2add6

Please sign in to comment.