Skip to content

Commit

Permalink
v0.2.0 release
Browse files Browse the repository at this point in the history
  • Loading branch information
edefimov committed Jul 25, 2015
1 parent e94ce38 commit 4bba6be
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 3 deletions.
11 changes: 11 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,16 @@
# Changelog

0.2.0 (Jul 25, 2015)
--------------------
Changes:
- Removed support of synchronous I/O
- Server socket support
- Support all transports returned by `stream_get_transports`
- Distinguish frame boundaries
- Determine datagram size for udp sockets
- Improved working with TLS sockets


0.2.0-alpha (Jul 1, 2015)
--------------------
New features:
Expand Down
11 changes: 8 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ Async sockets library
[![Scrutinizer](https://img.shields.io/scrutinizer/g/edefimov/async-sockets.svg?style=flat)](https://scrutinizer-ci.com/g/edefimov/async-sockets/)
[![GitHub release](https://img.shields.io/github/release/edefimov/async-sockets.svg?style=flat)](https://github.com/edefimov/async-sockets/releases/latest)
[![Dependency Status](https://www.versioneye.com/user/projects/55525b5706c318305500014b/badge.png?style=flat)](https://www.versioneye.com/user/projects/55525b5706c318305500014b)
[![Downloads](https://img.shields.io/packagist/dt/edefimov/async-sockets.svg)](https://packagist.org/packages/edefimov/async-sockets)
[![Minimum PHP Version](https://img.shields.io/badge/php-%3E%3D%205.4-777bb4.svg?style=flat)](https://php.net/)

Async sockets is event-based library for asynchronous work with sockets built on php streams.
Expand All @@ -20,7 +21,7 @@ Async sockets is event-based library for asynchronous work with sockets built on
- all transports returned by stream_get_transports are supported
- compatible with symfony event dispatcher component
- full control over timeouts
- dynamically adding new request during working process
- dynamically adding new request during execution process
- separate timeout values for each socket
- custom sockets setup by php stream contexts
- custom user context for each socket
Expand All @@ -40,7 +41,7 @@ The recommended way to install async sockets library is through composer

stable version:
```
$ composer require edefimov/async-sockets:~0.1.0 --prefer-dist|--prefer-source
$ composer require edefimov/async-sockets:~0.2.0 --prefer-dist|--prefer-source
```

actual version:
Expand Down Expand Up @@ -123,7 +124,7 @@ $server = $factory->createSocket(AsyncSocketFactory::SOCKET_SERVER);
```

### RequestExecutor
RequestExecutor is the engine, which hides all I/O operations and provides event system for client code.
RequestExecutor is an engine, which hides all I/O operations and provides event system for client code.
Creating RequestExecutor is as simple as creating sockets:
```php
$executor = $factory->createRequestExecutor();
Expand Down Expand Up @@ -177,6 +178,10 @@ To deal with sockets you need to subscribe to events you are interested in. Ther
- EventType::TIMEOUT - socket failed to connect/read/write data during set up period of time
- EventType::EXCEPTION - some `NetworkSocketException` occurred, detailed information can be retrieved from `SocketExceptionEvent`

Each event type has `Event` object (or one of its children) as the callback argument. If you have installed symfony event
dispatcher component, library's `Event` object will be inherited from symfony `Event` object.


### Adding sockets
To add socket to RequestExecutor use `SocketBagInterface` returned by `socketBag` method of `RequestExecutor`
```php
Expand Down

0 comments on commit 4bba6be

Please sign in to comment.