Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Optional metadata for rxjs requesters #241

Merged
merged 4 commits into from
Aug 9, 2022

Conversation

viglucci
Copy link
Member

@viglucci viglucci commented Aug 9, 2022

Motivation:

Addressed feedback: #158 (comment)

Modifications:

Allow optional metadata argument in rxjs requesters

Result:

Allows for:

const rsocket = await connector.connect();

let requestResponse = RxRequestersFactory.requestResponse(
  "Hello World",
  stringCodec,
  stringCodec
);

let stringObservable = requestResponse(rsocket);

Where previously passing new Map() would have been required.

let stringObservable = requestResponse(rsocket, new Map());

@viglucci viglucci added the 1.0 Pullrequests & issues related to the Typescript rewrite and 1.0 release label Aug 9, 2022
@viglucci viglucci force-pushed the feature/rxjs-adapter-optional-metadata branch from aa9723e to 0538234 Compare August 9, 2022 03:12
lerna.json Outdated
@@ -11,7 +11,7 @@
},
"version": {
"push": false,
"allowBranch": ["main", "1.0.x-alpha"]
"allowBranch": ["main", "1.0.x-alpha", "feature/rxjs-adapter-optional-metadata"]
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Temp change to allow publishing a prerelease for external testing.

@@ -48,21 +48,23 @@ export function fireAndForget<TData>(
inputCodec: Codec<TData>
): (
rsocket: RSocket,
metadata: Map<string | number | WellKnownMimeType, Buffer>
metadata?: Map<string | number | WellKnownMimeType, Buffer>
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

All requesters updated to consider metadata optional.

Copy link

@lachenmayer lachenmayer left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great, thanks a lot for this!

Signed-off-by: Kevin Viglucci <kviglucci@gmail.com>
Signed-off-by: Kevin Viglucci <kviglucci@gmail.com>
 - rsocket-adapter-rxjs@1.0.0-alpha-rxjs-adapter-optional-metadata.0
 - rsocket-composite-metadata@1.0.0-alpha-rxjs-adapter-optional-metadata.0
 - rsocket-core@1.0.0-alpha-rxjs-adapter-optional-metadata.0
 - rsocket-examples@1.0.0-alpha-rxjs-adapter-optional-metadata.0
 - rsocket-messaging@1.0.0-alpha-rxjs-adapter-optional-metadata.0
 - rsocket-tcp-client@1.0.0-alpha-rxjs-adapter-optional-metadata.0
 - rsocket-tcp-server@1.0.0-alpha-rxjs-adapter-optional-metadata.0
 - rsocket-websocket-client@1.0.0-alpha-rxjs-adapter-optional-metadata.0
 - rsocket-websocket-server@1.0.0-alpha-rxjs-adapter-optional-metadata.0

Signed-off-by: Kevin Viglucci <kviglucci@gmail.com>
Signed-off-by: Kevin Viglucci <kviglucci@gmail.com>
@viglucci viglucci force-pushed the feature/rxjs-adapter-optional-metadata branch from 04c8858 to 862ae2e Compare August 9, 2022 14:29
@viglucci viglucci merged commit f995700 into 1.0.x-alpha Aug 9, 2022
@viglucci viglucci deleted the feature/rxjs-adapter-optional-metadata branch August 9, 2022 14:43
viglucci added a commit that referenced this pull request Sep 4, 2022
* feat: support optional metadata in rxjs adapter requesters

Signed-off-by: Kevin Viglucci <kviglucci@gmail.com>

* chore(release): release

 - rsocket-adapter-rxjs@1.0.0-alpha-rxjs-adapter-optional-metadata.0
 - rsocket-composite-metadata@1.0.0-alpha-rxjs-adapter-optional-metadata.0
 - rsocket-core@1.0.0-alpha-rxjs-adapter-optional-metadata.0
 - rsocket-examples@1.0.0-alpha-rxjs-adapter-optional-metadata.0
 - rsocket-messaging@1.0.0-alpha-rxjs-adapter-optional-metadata.0
 - rsocket-tcp-client@1.0.0-alpha-rxjs-adapter-optional-metadata.0
 - rsocket-tcp-server@1.0.0-alpha-rxjs-adapter-optional-metadata.0
 - rsocket-websocket-client@1.0.0-alpha-rxjs-adapter-optional-metadata.0
 - rsocket-websocket-server@1.0.0-alpha-rxjs-adapter-optional-metadata.0

Signed-off-by: Kevin Viglucci <kviglucci@gmail.com>
viglucci added a commit that referenced this pull request Nov 2, 2022
* feat: support optional metadata in rxjs adapter requesters

Signed-off-by: Kevin Viglucci <kviglucci@gmail.com>

* chore(release): release

 - rsocket-adapter-rxjs@1.0.0-alpha-rxjs-adapter-optional-metadata.0
 - rsocket-composite-metadata@1.0.0-alpha-rxjs-adapter-optional-metadata.0
 - rsocket-core@1.0.0-alpha-rxjs-adapter-optional-metadata.0
 - rsocket-examples@1.0.0-alpha-rxjs-adapter-optional-metadata.0
 - rsocket-messaging@1.0.0-alpha-rxjs-adapter-optional-metadata.0
 - rsocket-tcp-client@1.0.0-alpha-rxjs-adapter-optional-metadata.0
 - rsocket-tcp-server@1.0.0-alpha-rxjs-adapter-optional-metadata.0
 - rsocket-websocket-client@1.0.0-alpha-rxjs-adapter-optional-metadata.0
 - rsocket-websocket-server@1.0.0-alpha-rxjs-adapter-optional-metadata.0

Signed-off-by: Kevin Viglucci <kviglucci@gmail.com>
viglucci added a commit that referenced this pull request Apr 27, 2023
* feat: support optional metadata in rxjs adapter requesters

Signed-off-by: Kevin Viglucci <kviglucci@gmail.com>

* chore(release): release

 - rsocket-adapter-rxjs@1.0.0-alpha-rxjs-adapter-optional-metadata.0
 - rsocket-composite-metadata@1.0.0-alpha-rxjs-adapter-optional-metadata.0
 - rsocket-core@1.0.0-alpha-rxjs-adapter-optional-metadata.0
 - rsocket-examples@1.0.0-alpha-rxjs-adapter-optional-metadata.0
 - rsocket-messaging@1.0.0-alpha-rxjs-adapter-optional-metadata.0
 - rsocket-tcp-client@1.0.0-alpha-rxjs-adapter-optional-metadata.0
 - rsocket-tcp-server@1.0.0-alpha-rxjs-adapter-optional-metadata.0
 - rsocket-websocket-client@1.0.0-alpha-rxjs-adapter-optional-metadata.0
 - rsocket-websocket-server@1.0.0-alpha-rxjs-adapter-optional-metadata.0

Signed-off-by: Kevin Viglucci <kviglucci@gmail.com>
viglucci added a commit that referenced this pull request Apr 27, 2023
* feat: support optional metadata in rxjs adapter requesters

Signed-off-by: Kevin Viglucci <kviglucci@gmail.com>

* chore(release): release

 - rsocket-adapter-rxjs@1.0.0-alpha-rxjs-adapter-optional-metadata.0
 - rsocket-composite-metadata@1.0.0-alpha-rxjs-adapter-optional-metadata.0
 - rsocket-core@1.0.0-alpha-rxjs-adapter-optional-metadata.0
 - rsocket-examples@1.0.0-alpha-rxjs-adapter-optional-metadata.0
 - rsocket-messaging@1.0.0-alpha-rxjs-adapter-optional-metadata.0
 - rsocket-tcp-client@1.0.0-alpha-rxjs-adapter-optional-metadata.0
 - rsocket-tcp-server@1.0.0-alpha-rxjs-adapter-optional-metadata.0
 - rsocket-websocket-client@1.0.0-alpha-rxjs-adapter-optional-metadata.0
 - rsocket-websocket-server@1.0.0-alpha-rxjs-adapter-optional-metadata.0

Signed-off-by: Kevin Viglucci <kviglucci@gmail.com>
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
1.0 Pullrequests & issues related to the Typescript rewrite and 1.0 release
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants