### Packages impacted by this PR
@azure/web-pubsub-client
### Issues associated with this PR
### Describe the problem that is addressed by this PR
This PR try to resolve 2 kinds of issues:
1. The original logic returns sequenceAck every second but if there're a
lot of receiving messages, the client may fail to ack in time (service
only buffer 1000 unacked messages).
2. In some cases, the ws may in the half close state (service has closed
the connection but client don't recognize it). The websocket library
doesn't proactively send ping, and results in some cases that the
connection may wait for TCP timeout which is too long.
### What are the possible designs available to address the problem? If
there are more than one possible design, why was the one in this PR
chosen?
1. We quick ack if we have more than 300 messages unacked
2. Add a timer to send something, it can trigger TCP to detect closure
quickly
### Are there test cases added in this PR? _(If not, why?)_
Yes
### Provide a list of related PRs _(if any)_
### Command used to generate this PR:**_(Applicable only to SDK release
request PRs)_
### Checklists
- [ ] Added impacted package name to the issue description
- [ ] Does this PR needs any fixes in the SDK Generator?** _(If so,
create an Issue in the
[Autorest/typescript](https://github.com/Azure/autorest.typescript)
repository and link it here)_
- [ ] Added a changelog (if necessary)
Builds off of Matt's work on moving to tsx in #28801 by removing the
`use-esm-workaround` flag from packages that needed it before we moved to tsx.
There's additional cleanup to be had, but I am trying not to cause a
build storm.
We are at a point where we can delete `esm` globally!
Contributes to #28617 which can be completed with a no-ci change to
remove `esm` globally
****NO_CI****
Looks like Google updated their URLs for chrome for testing downloads,
planning to retire the `hdgedl.me.gvt1.com...` URLs with
`storage.googleapis.com` URLs
It may have been deprecated for quite some time, but looks like as of
last night the old URLs have died, returning 500 instead.
As a result, puppeteer postinstall breaks the build
According to https://github.com/puppeteer/puppeteer/issues/11967
puppeteer 22.2.0 already uses the new URLs which
we can easily upgrade to.
This PR bumps the min-version to 22.2.0 across the board.
- Switch to use esm4mocha loader by default
- Add `--use-esm-workaround=true` to packages that need more work
(mostly due to usage of `__dirname` that is no longer available in ESM)
- Change some usage of `__dirname` to `"."` when possible
- [esm4mocha] only transform modules whose format is changed
- [load-testing-rest] update tsconfig.json to be consistent with other
packages
by running `rush add -m --dev -p puppeteer@^22.0.0`
- adjust core-xml test due puppeteer switched from Chromium to Chrome
- ignore Accept-Language headers for browser playback tests
Resolves https://github.com/Azure/azure-sdk-for-js/issues/25790
This change migrates every package to the latest major version of
identity in order to ensure we can catch any regressions earlier in the
development process.
I chose to upgrade the samples' package.json as well - but happy to
revert that if there are objections.
***NO_CI***
Our tests use the type `Mocha.Context` when they need to pass the test context
to test recorder. However, without a dev dependency on `@types/mocha`
compilation may fail when recorder constructor is changed from taking a
`Mocha.Test` to taking an interface that is compatible.
This change ensures the dev depedency on `@types/mocha` too if there's a dev
dependency on `mocha`.
***NO_CI***
***NO_CI***
Latest versions of prettier now correctly formats `tsconfig.json`, which results
in differences with previous version of 3.1.1 in pnpm-lock.yaml. This is failing
the automated rush update pipeline because `check-format` fails with version
3.2.4.
This includes changes of
- bumping prettier version to ^3.2.4
- running `rush format`
***NO_CI***
- remove dev dependency `prettier` from non-tool packages when possible and
update them to run vendored prettier for `check-format` and `format` scripts
- upgrade rest of packages to prettier v3
- run `rush format` for all rush packages
This is a follow-up to https://github.com/Azure/azure-sdk-for-js/pull/28127 to
move the rest of repo to prettier v3.
### Packages impacted by this PR
@azure/web-pubsub-client
### Describe the problem that is addressed by this PR
Update according to GA API review:
https://apiview.dev/Assemblies/Review/492267bc4ab44b19a558635733047147
### What are the possible designs available to address the problem? If
there are more than one possible design, why was the one in this PR
chosen?
### Are there test cases added in this PR? _(If not, why?)_
### Provide a list of related PRs _(if any)_
### Command used to generate this PR:**_(Applicable only to SDK release
request PRs)_
### Checklists
- [ ] Added impacted package name to the issue description
- [ ] Does this PR needs any fixes in the SDK Generator?** _(If so,
create an Issue in the
[Autorest/typescript](https://github.com/Azure/autorest.typescript)
repository and link it here)_
- [ ] Added a changelog (if necessary)
A couple of README files have different link than most packages' in this
repo, likely due to in-flight PRs when we update the link to point to
github one. These are now broken. This PR replaces them with the one
used in other packages.
***NO_CI***
The combination of `nyc` + `esm` is broken in latest versions of
NodeJS (https://github.com/istanbuljs/nyc/issues/1530#issuecomment-1773403365).
Since `esm` package is no longer actively maintained and its repo is archived,
it's less likely that the issue will be fixed soon.
This change switches to use another code coverage tool `c8` which is not
affected. `c8` respects `.nycrc` config files so those are not renamed.
### Packages impacted by this PR
@azure/web-pubsub-client-protobuf
### Describe the problem that is addressed by this PR
Update Changelog for preparing beta.2
### What are the possible designs available to address the problem? If
there are more than one possible design, why was the one in this PR
chosen?
### Are there test cases added in this PR? _(If not, why?)_
### Provide a list of related PRs _(if any)_
### Command used to generate this PR:**_(Applicable only to SDK release
request PRs)_
### Checklists
- [ ] Added impacted package name to the issue description
- [ ] Does this PR needs any fixes in the SDK Generator?** _(If so,
create an Issue in the
[Autorest/typescript](https://github.com/Azure/autorest.typescript)
repository and link it here)_
- [ ] Added a changelog (if necessary)
### Packages impacted by this PR
@azure/web-pubsub-client
### Issues associated with this PR
### Describe the problem that is addressed by this PR
Change the interface of `parseMessages` and allow protocol implementor
to return a list of messages. It's designed for further possible new
protocols that contains multiple messages in one websocket frame.
### What are the possible designs available to address the problem? If
there are more than one possible design, why was the one in this PR
chosen?
### Are there test cases added in this PR? _(If not, why?)_
yes
### Provide a list of related PRs _(if any)_
### Command used to generate this PR:**_(Applicable only to SDK release
request PRs)_
### Checklists
- [ ] Added impacted package name to the issue description
- [ ] Does this PR needs any fixes in the SDK Generator?** _(If so,
create an Issue in the
[Autorest/typescript](https://github.com/Azure/autorest.typescript)
repository and link it here)_
- [ ] Added a changelog (if necessary)
***NO_CI***
- update engine.node to >=16.0.0 in package.json
- update @types/node version to ^16.0.0
- update dev-tool sample's MIN_SUPPORTED_NODE_VERSION to 16
- update eslint-plugin's rules and tests related to engine.node version
- remove TextEncoder and TextDecoder stubs as they are now on global object
- fix tests compiler error due to better typings in v16
- update some README files to not reference version like 14.x.x
### Packages impacted by this PR
All libraries
### Issues associated with this PR
Fixes https://github.com/Azure/azure-sdk-for-js/issues/26665
### Describe the problem that is addressed by this PR
We need to upgrade Rollup to v3 so our cjs bundles could import ES
modules among other goodness.
### What are the possible designs available to address the problem? If
there are more than one possible design, why was the one in this PR
chosen?
See the linked issue for discussion of the upgrade. Credit to @xirzec
for writing up the sourcemaps plugin in-house replacement!
### Are there test cases added in this PR? _(If not, why?)_
N/A
### Provide a list of related PRs _(if any)_
[N/A](https://github.com/Azure/azure-sdk-for-js/pull/27258)
### Command used to generate this PR:**_(Applicable only to SDK release
request PRs)_
### Checklists
- [x] Added impacted package name to the issue description
- [ ] Does this PR needs any fixes in the SDK Generator?** _(If so,
create an Issue in the
[Autorest/typescript](https://github.com/Azure/autorest.typescript)
repository and link it here)_
- [ ] Added a changelog (if necessary)
### Packages impacted by this PR
@azure/web-pubsub-client
### Issues associated with this PR
https://github.com/Azure/azure-sdk-for-js/issues/26400
### Describe the problem that is addressed by this PR
React native use some different packages from node, I added some package
map to resolve it.
### What are the possible designs available to address the problem? If
there are more than one possible design, why was the one in this PR
chosen?
### Are there test cases added in this PR? _(If not, why?)_
### Provide a list of related PRs _(if any)_
### Command used to generate this PR:**_(Applicable only to SDK release
request PRs)_
### Checklists
- [ ] Added impacted package name to the issue description
- [ ] Does this PR needs any fixes in the SDK Generator?** _(If so,
create an Issue in the
[Autorest/typescript](https://github.com/Azure/autorest.typescript)
repository and link it here)_
- [ ] Added a changelog (if necessary)
- along with it, `@types/mocha` version to `^10.0.0`
- add `esm` dev dependency as they are used, but not explicitly list
- use dev-tool run command for test scripts as much as possible
- fix test issue caused by Mocha behavior change around test name
- move `import "chai/register-should"` to mocha -r command line option for core
http tests
***NO_CI***
### Packages impacted by this PR
@azure/web-pubsub-client-protobuf
### Issues associated with this PR
https://github.com/Azure/azure-sdk-for-js/issues/25703
### Describe the problem that is addressed by this PR
As protobufjs is purely commonjs type but rollup bundle didn't add
commonjs support. So only file in `dist-esm/` works but in `dist`
doesn't.
### Are there test cases added in this PR? _(If not, why?)_
Test already added `cjs()` plugin in bundle, so it works.
It is desirable to centralize our NPM test scripts so that we can change
common options easily. Currently test-proxy is always launched, which
isn't useful for packages (e.g., core) that don't have recorded tests.
This PR adds an opt-in option to not launch test-proxy when running
tests.
### Packages impacted by this PR
`@azure/dev-tool`
***NO_CI***
Most of our packages, if not all, have dev dependency on `ts-node` either
directly (`mocha --require ts-node/register`) or indirectly via dev-tool (`run
test:node-ts-input`). Currently tests are running fine because mocha is able to
resolve ts-node currently. It may fail in other cases though (e.g., after
migrating a package to ESM).
This ensures `ts-node@^10.0.0` and `types/node` are included for our rush
packages.
- update `sinon` version to `^15.0.0`. The breaking changes does not
affect our usages.
- upgrade `@types/sinon` to `^10.0.0`. This reveals test issue where
mocked tokens are not compatible with `AccessToken`. This PR fixes the
tests too.
### Packages impacted by this PR
@azure/web-pubsub-client
### Issues associated with this PR
#24901
### Describe the problem that is addressed by this PR
### What are the possible designs available to address the problem? If there are more than one possible design, why was the one in this PR chosen?
### Are there test cases added in this PR? _(If not, why?)_
### Provide a list of related PRs _(if any)_
### Command used to generate this PR:**_(Applicable only to SDK release request PRs)_
### Checklists
- [ ] Added impacted package name to the issue description
- [ ] Does this PR needs any fixes in the SDK Generator?** _(If so, create an Issue in the [Autorest/typescript](https://github.com/Azure/autorest.typescript) repository and link it here)_
- [ ] Added a changelog (if necessary)
### Packages impacted by this PR
@azure/web-pubsub-express
### Issues associated with this PR
https://github.com/Azure/azure-sdk-for-js/issues/24515
### Describe the problem that is addressed by this PR
The Azure Web PubSub service defines it's protocol sending CloudEvents out as `query`, however in TS we defined it as `queries` in the interface. To resolve the inconsistency between them, add a `query` property to the interface but mark it as obsolete and mean why set the value of `queries` as the value of `query` to make the property work.
### What are the possible designs available to address the problem? If there are more than one possible design, why was the one in this PR chosen?
### Are there test cases added in this PR? _(If not, why?)_
### Provide a list of related PRs _(if any)_
### Command used to generate this PR:**_(Applicable only to SDK release request PRs)_
### Checklists
- [ ] Added impacted package name to the issue description
- [ ] Does this PR needs any fixes in the SDK Generator?** _(If so, create an Issue in the [Autorest/typescript](https://github.com/Azure/autorest.typescript) repository and link it here)_
- [ ] Added a changelog (if necessary)
### Packages impacted by this PR
@azure/web-pubsub-client-protobuf
### Issues associated with this PR
### Describe the problem that is addressed by this PR
Prepare for beta release
### What are the possible designs available to address the problem? If there are more than one possible design, why was the one in this PR chosen?
### Are there test cases added in this PR? _(If not, why?)_
### Provide a list of related PRs _(if any)_
### Command used to generate this PR:**_(Applicable only to SDK release request PRs)_
### Checklists
- [ ] Added impacted package name to the issue description
- [ ] Does this PR needs any fixes in the SDK Generator?** _(If so, create an Issue in the [Autorest/typescript](https://github.com/Azure/autorest.typescript) repository and link it here)_
- [ ] Added a changelog (if necessary)
### Packages impacted by this PR
@azure/web-pubsub-client
### Issues associated with this PR
#24901https://github.com/Azure/azure-sdk-for-js/pull/24902 try to fix this issue but blocked by format.
### Describe the problem that is addressed by this PR
`IsDuplicated` always return true in WebPubSubResult.
### What are the possible designs available to address the problem? If there are more than one possible design, why was the one in this PR chosen?
### Are there test cases added in this PR? _(If not, why?)_
### Provide a list of related PRs _(if any)_
### Command used to generate this PR:**_(Applicable only to SDK release request PRs)_
### Checklists
- [ ] Added impacted package name to the issue description
- [ ] Does this PR needs any fixes in the SDK Generator?** _(If so, create an Issue in the [Autorest/typescript](https://github.com/Azure/autorest.typescript) repository and link it here)_
- [ ] Added a changelog (if necessary)
### Packages impacted by this PR
eb-pubsub-client-protobuf
### Issues associated with this PR
### Describe the problem that is addressed by this PR
Add more tests
### What are the possible designs available to address the problem? If there are more than one possible design, why was the one in this PR chosen?
### Are there test cases added in this PR? _(If not, why?)_
### Provide a list of related PRs _(if any)_
### Command used to generate this PR:**_(Applicable only to SDK release request PRs)_
### Checklists
- [ ] Added impacted package name to the issue description
- [ ] Does this PR needs any fixes in the SDK Generator?** _(If so, create an Issue in the [Autorest/typescript](https://github.com/Azure/autorest.typescript) repository and link it here)_
- [ ] Added a changelog (if necessary)
### Packages impacted by this PR
@azure/web-pubsub-client-protobuf
This is the init pr for @azure/web-pubsub-client-protobuf. Please review the package name, dependencies.
### Checklists
- [ ] Added impacted package name to the issue description
- [ ] Does this PR needs any fixes in the SDK Generator?** _(If so, create an Issue in the [Autorest/typescript](https://github.com/Azure/autorest.typescript) repository and link it here)_
- [ ] Added a changelog (if necessary)
***NO_CI***
- `@rollup/plugin-commonjs` to `^24.0.0`
- `@rollup/plugin-json` to `^6.0.0`
- `@rollup/plugin-multi-entry` to `^6.0.0`
- `rollup-plugin-polyfill-node` to `^0.12.0`
- `@rollup/plugin-inject` to `^5.0.0`
- `@rollup/plugin-replace` to `^5.0.0`
Fix notification-hubs rollup test config: now sourcemaps plugin is complaining
about .ts file. Move typescript plugin before it.
Fix service-bus to include needed rollup dependencies. It was lucky to be able
to re-use on other packages to install them but is failing in some builds.
Organized and edited README so that it's easier to get started with this client library and easier to find further reference docs.
### Packages impacted by this PR
### Issues associated with this PR
### Describe the problem that is addressed by this PR
### What are the possible designs available to address the problem? If there are more than one possible design, why was the one in this PR chosen?
### Are there test cases added in this PR? _(If not, why?)_
### Provide a list of related PRs _(if any)_
### Command used to generate this PR:**_(Applicable only to SDK release request PRs)_
### Checklists
- [ ] Added impacted package name to the issue description
- [ ] Does this PR needs any fixes in the SDK Generator?** _(If so, create an Issue in the [Autorest/typescript](https://github.com/Azure/autorest.typescript) repository and link it here)_
- [ ] Added a changelog (if necessary)
### Packages impacted by this PR
### Issues associated with this PR
### Describe the problem that is addressed by this PR
### What are the possible designs available to address the problem? If there are more than one possible design, why was the one in this PR chosen?
### Are there test cases added in this PR? _(If not, why?)_
### Provide a list of related PRs _(if any)_
### Command used to generate this PR:**_(Applicable only to SDK release request PRs)_
### Checklists
- [ ] Added impacted package name to the issue description
- [ ] Does this PR needs any fixes in the SDK Generator?** _(If so, create an Issue in the [Autorest/typescript](https://github.com/Azure/autorest.typescript) repository and link it here)_
- [ ] Added a changelog (if necessary)
### Packages impacted by this PR
wpb-pubsub-client
### Issues associated with this PR
https://github.com/Azure/azure-webpubsub/issues/477
### Describe the problem that is addressed by this PR
Remove signalr term
### What are the possible designs available to address the problem? If there are more than one possible design, why was the one in this PR chosen?
### Are there test cases added in this PR? _(If not, why?)_
### Provide a list of related PRs _(if any)_
### Command used to generate this PR:**_(Applicable only to SDK release request PRs)_
### Checklists
- [ ] Added impacted package name to the issue description
- [ ] Does this PR needs any fixes in the SDK Generator?** _(If so, create an Issue in the [Autorest/typescript](https://github.com/Azure/autorest.typescript) repository and link it here)_
- [ ] Added a changelog (if necessary)
### Packages impacted by this PR
web-pubsub-client
### Issues associated with this PR
### Describe the problem that is addressed by this PR
### What are the possible designs available to address the problem? If there are more than one possible design, why was the one in this PR chosen?
`autoRejoinGroup` options didn't take effect and some naming are `autoRestoreGroup` which doesn't keep consistent.
### Are there test cases added in this PR? _(If not, why?)_
yes
### Provide a list of related PRs _(if any)_
### Command used to generate this PR:**_(Applicable only to SDK release request PRs)_
### Checklists
- [ ] Added impacted package name to the issue description
- [ ] Does this PR needs any fixes in the SDK Generator?** _(If so, create an Issue in the [Autorest/typescript](https://github.com/Azure/autorest.typescript) repository and link it here)_
- [ ] Added a changelog (if necessary)
### Packages impacted by this PR
web-pubsub-client
### Issues associated with this PR
### Describe the problem that is addressed by this PR
Prepare for beta release
### What are the possible designs available to address the problem? If there are more than one possible design, why was the one in this PR chosen?
### Are there test cases added in this PR? _(If not, why?)_
### Provide a list of related PRs _(if any)_
### Command used to generate this PR:**_(Applicable only to SDK release request PRs)_
### Checklists
- [ ] Added impacted package name to the issue description
- [ ] Does this PR needs any fixes in the SDK Generator?** _(If so, create an Issue in the [Autorest/typescript](https://github.com/Azure/autorest.typescript) repository and link it here)_
- [ ] Added a changelog (if necessary)
### Packages impacted by this PR
web-pubsub-client
### Issues associated with this PR
### Describe the problem that is addressed by this PR
Make ackable operation cancellable
### What are the possible designs available to address the problem? If there are more than one possible design, why was the one in this PR chosen?
### Are there test cases added in this PR? _(If not, why?)_
Yes
### Provide a list of related PRs _(if any)_
### Command used to generate this PR:**_(Applicable only to SDK release request PRs)_
### Checklists
- [ ] Added impacted package name to the issue description
- [ ] Does this PR needs any fixes in the SDK Generator?** _(If so, create an Issue in the [Autorest/typescript](https://github.com/Azure/autorest.typescript) repository and link it here)_
- [ ] Added a changelog (if necessary)
### Packages impacted by this PR
web-pubsub-client
### Issues associated with this PR
### Describe the problem that is addressed by this PR
Update Readme
### What are the possible designs available to address the problem? If there are more than one possible design, why was the one in this PR chosen?
### Are there test cases added in this PR? _(If not, why?)_
### Provide a list of related PRs _(if any)_
### Command used to generate this PR:**_(Applicable only to SDK release request PRs)_
### Checklists
- [ ] Added impacted package name to the issue description
- [ ] Does this PR needs any fixes in the SDK Generator?** _(If so, create an Issue in the [Autorest/typescript](https://github.com/Azure/autorest.typescript) repository and link it here)_
- [ ] Added a changelog (if necessary)
### Packages impacted by this PR
web-pubsub-client
### Issues associated with this PR
### Describe the problem that is addressed by this PR
### What are the possible designs available to address the problem? If there are more than one possible design, why was the one in this PR chosen?
### Are there test cases added in this PR? _(If not, why?)_
Yes. Add more tests.
### Provide a list of related PRs _(if any)_
### Command used to generate this PR:**_(Applicable only to SDK release request PRs)_
### Checklists
- [x] Added impacted package name to the issue description
- [ ] Does this PR needs any fixes in the SDK Generator?** _(If so, create an Issue in the [Autorest/typescript](https://github.com/Azure/autorest.typescript) repository and link it here)_
- [ ] Added a changelog (if necessary)
- fix(web-pubsub-client): fix browser export for ws
- fix(web-pubsub-client): various fixes in samples
<!-- Give your Pull Request a brief description, and answer the following questions. This helps us find the best reviewers for the PR. -->
### Packages impacted by this PR
### Issues associated with this PR
### Describe the problem that is addressed by this PR
### What are the possible designs available to address the problem? If there are more than one possible design, why was the one in this PR chosen?
### Are there test cases added in this PR? _(If not, why?)_
### Provide a list of related PRs _(if any)_
### Command used to generate this PR: _(Applicable only to SDK release request PRs)_
### Checklists
- [ ] Added impacted package name to the issue description.
- [ ] Does this PR need any fixes in the SDK Generator?** _(If so, create an Issue in the [Autorest/typescript](https://github.com/Azure/autorest.typescript) repository and link it here.)_
- [ ] Added a changelog (if necessary).
### Packages impacted by this PR
web-pubsub-client
### Issues associated with this PR
### Describe the problem that is addressed by this PR
### What are the possible designs available to address the problem? If there are more than one possible design, why was the one in this PR chosen?
### Are there test cases added in this PR? _(If not, why?)_
### Provide a list of related PRs _(if any)_
### Command used to generate this PR:**_(Applicable only to SDK release request PRs)_
### Checklists
- [ ] Added impacted package name to the issue description
- [ ] Does this PR needs any fixes in the SDK Generator?** _(If so, create an Issue in the [Autorest/typescript](https://github.com/Azure/autorest.typescript) repository and link it here)_
- [ ] Added a changelog (if necessary)
### Packages impacted by this PR
web-pubsub-client
### Issues associated with this PR
### Describe the problem that is addressed by this PR
This is the init PR for new package web-pubsub-client.
### What are the possible designs available to address the problem? If there are more than one possible design, why was the one in this PR chosen?
### Are there test cases added in this PR? _(If not, why?)_
Yes
### Provide a list of related PRs _(if any)_
### Command used to generate this PR:**_(Applicable only to SDK release request PRs)_
### Checklists
- [x] Added impacted package name to the issue description
- [ ] Does this PR needs any fixes in the SDK Generator?** _(If so, create an Issue in the [Autorest/typescript](https://github.com/Azure/autorest.typescript) repository and link it here)_
- [x] Added a changelog (if necessary)
* upgrade dev dependency `puppeteer` to `^19.2.2`
* update pnpm-lock.yaml
* Fix failing tests
by changing them to verify `error.name`. The error message from parsing an
incomplete JSON string has been improved in recent versions of chromium.
Unfortunately it doesn't match NodeJS version any more.
### Packages impacted by this PR
@azure/web-pubsub
### Issues associated with this PR
N/A
### Describe the problem that is addressed by this P
Support new swagger
1. Support sending with "filter" syntax
2. Support generating access url with initial groups
3. Add new API "removeConnectionFromAllGroups"
### What are the possible designs available to address the problem? If there are more than one possible design, why was the one in this PR chosen?
### Are there test cases added in this PR? _(If not, why?)_
### Provide a list of related PRs _(if any)_
### Command used to generate this PR:**_(Applicable only to SDK release request PRs)_
### Checklists
- [ ] Added impacted package name to the issue description
- [ ] Does this PR needs any fixes in the SDK Generator?** _(If so, create an Issue in the [Autorest/typescript](https://github.com/Azure/autorest.typescript) repository and link it here)_
- [ ] Added a changelog (if necessary)