- Updated minimum version of
rhea
to^1.0.8
. - Added a read only property
id
to theSession
object. The id property is created by concatenating session's local channel, remote channel and the connection id"local-<number>_remote-<number>_<connection-id>"
, thus making it unique for that connection. - Improved log statements by adding the session
id
and the sender, receivername
to help while debugging applications. - Added
options
toLink.close({closeSession: true | false})
, thus the user can specify whether the underlying session should be closed while closing theSender|Receiver
. Default istrue
. - Improved
open
andclose
operations onConnection
,Session
andLink
by creating timer in case the connection gets disconnected. Fixes #41. - The current
Sender
does not have a provision of "awaiting" on sending a message. The user needs to add handlers on theSender
foraccepted
,rejected
,released
,modified
to ensure whether the message was successfully sent. Now, we have added a newAwaitableSender
which adds the handlers internally and provides an awaitablesend()
operation to the customer. Fixes #45. - Exporting new Errors:
InsufficientCreditError
: Defines the error that occurs when the Sender does not have enough credit.SendOperationFailedError
: Defines the error that occurs when the Sender fails to send a message.
- Export rhea types for
Typed
. PR. - Export rhea types for
WebSocketImpl
andWebSocketInstance
. PR. - When opening a connection fails with no error, use standard error message. PR.
- Allow websockets usage on a connection without creating a container first. PR.
- New function
removeAllSessions()
on the connection to clear the internal map in rhea to ensure sessions are not reconnected on the nextconnection.open()
call. PR. - Remove all event listeners on link and session objects when
close()
is called on them. PR
- Throw
OperationTimeoutError
when a Promise to create/close an entity is rejected.
- Fix a minor bug in receiver creation.
- Added checks for some event handler methods to exist before logging information that uses node's event handlers inbuilt functions.
- Improved error checking while creating the receiver.
- Provided an option to add an event handler for "settled" event on the Receiver.
- With the usage of
importHelpers
, the tslib will be needed in package.json for installers using older versions of npm (or using yarn). PR.
- Allow setting drain property on the receiver PR.
- Fixed a bug while populating the connectionId PR.
- property
actionInitiated
is now of typenumber
which is incremented when thecreate
,close
action on an entity is under process and decremented when the action completes (succeeeded or failed).
- Improved log statements for better debugging.
- Any type of
error
event will be emitted with a tick delay. This would give enough time for thecreate()
methods to resolve the promise. - Added a new
boolean
propertyactionInitiated
which indicates whether thecreate
,close
action on an entity is under process.
options
is a required property ofConnection
andContainer
.
- Transform relevant objects in rhea EventContext to rhea-promise objects.
- Ensure that
container.createConnection()
creates a connection on that container and not on the default container.
- TS target to ES2015. This should help us support node.js version 6.x and above.
- Update homepage, repository and bug urls in package.json
- Initial version of rhea-promise.