Skip to content

2.0.0 Beta 4

Pre-release
Pre-release

Choose a tag to compare

@trowski trowski released this 28 Mar 16:42
v2.0.0-beta.4
b1e6ce0
  • Updated interfaces extending ClosableStream (which was renamed to Closable in amphp/byte-stream) to include the onClose method which was added to the interface.

  • SocketAddress has been changed to an interface with two implementations - InternetAddress and UnixAddress. These can be differentiated using SocketAddress::getType(), which returns an enum SocketAddressType with cases Unix and Internet.

  • SocketAddress static constructors have been relocated as functions in the Amp\Socket\SocketAddress namespace.

  • DnsSocketConnector now tries each host returned from a DNS query a single time before failing. Retrying the list is accomplished through a new connector implementation, RetrySocketConnector that can be configured to retry a given number of times with an exponential backoff between attempts.

  • Max attempts has been removed from ConnectContext in favor of a constructor parameter to RetrySocketConnector.

  • Added SocketServerFactory interface for creating SocketServer instances, along with an implementation ResourceSocketServerFactory.

  • EncryptableSocket::getTlsState() now returns an enum TlsState with cases corresponding to the prior constants defined in EncryptableSocket, which have been removed.