As we removed core-http and Fetch api is being added into NodeJS,
node-fetch is no longer relevant. Now it is only used in perf tests.
This PR removes node-fetch dependency and its perf tests.
while at it I also removed stale references to core-http.
ESlint plugins are resolved relative to the config file. In our repo
that means ESLint would try resolving plugins from `sdk` folder or
individual package folder if it contains a config file. The plugins
needed are actually installed under
`common/tools/eslint-plugin-azure-sdk`. Linting works when running cli
because `NODE_PATH` is set to contain a bunch of directories, including
`common/temp/node_modules/.pnpm/node_modules`, and ESLint is able to
find plugins.
When the `dataplane.code-workspace` is opened in VS Code, ESLint in
`vscode-eslint` extension attempts to load plugins but couldn't because
there's no `NODE_PATH` or equivalent. As a result, the extension
crashes.
This PR provides a workaround utilizing the
`eslint.options.resolvePluginsRelativeTo` setting and a empty rush
project whose sole purpose is to provide symlinks to eslint dependencies
so that ESLint from the VS Code extension can loads them.
Bonus change includes some fixes done by the `vscode-eslint` extension
UI.
After `rush update`, build `eslint-plugin-azure-sdk` project first then
open/re-open `dataplane.code-workspace`
### Packages impacted by this PR
Deprecating `@azure/maps-search` in favor of `@azure-rest/maps-search`
### 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)
* Update maps dependency in pnpm-lock.yaml
* Fix sample metadata errors
* Fix linting errors
* Fix linting errors
* Fix run time error
* Update package.json in samples folder
* Fix linting errors
* Fix linting errors
* Add changelog for maps-common
* Update recording files for maps-search
* Add test.yml for maps-search
* Add tests.yml for render and route
* Update tests.yml
* Update test-resources.json for maps
* Fix tests.yml format error
* Update env vars and remove unused export var
* Remove unused code
* Fix lock file
* Remove route & render
* Replace `beginGet*Batch` with `resume*Batch`
We provide a `beginGet*Batch` method to resume the previous
request previously. This is not ideal because it need to get a
`batchId` which is store in the internal state of the LRO. Once
the LRO brings changes, our code will be broken.
We can achieve the same thing by using serialized state.
This change aims to leverage this approach and create convenience
methods `resume*Batch` for users
* Update recording
* Make the endpoint of `MapsSearchClient` configurable
* Change LatLon from an interface to a tuple
Also remove the `toLatLon` function since creating a tuple
is quite easy.
* Make the props `coordinates` and `countryCodeFilter` optional
Specifying `coordinates` and `countryCodeFilter` can narrow the results
of the fuzzy search. But considring the case like searching "Australia",
theese fields may have no use. We decided to make them optional so user
can decides if they want to narrow down the results or not.
* fixup! Remove route & render
* Adjust CHANGELOGs of maps-search & common
Following the keyvault-common, removing CHANGELOGs
from maps-common since it's not published.
* Update samples
* Add batchRequest sample
* Add a new sample searchAddressResult
* Update search.ts and its examples
* enhance code example in README.md
* comment unused import
* Update recording for maps-search
* remove redundant recording files
* Add maps-search
* Rename LatLong to LatLon
* Fix constructor Readme doc
* Update readme to new signature
* Add tests partially
* Change LatLon/BoundingBox to interfaces
* Reduce the number of constructor overloading
* Rename SearchClient as MapsSearchClient
* Add options mapper tests
* Add result type mapper tests (in progress)
* rename clientId to mapsAccountClientId
* listPolygons -> getPolygons
* getPointOfInterestCategoryTree -> getPointOfInterestCategories
* Expose missing model
* Add alternative input file for quick experiment
* Regenerate code and make changes accordingly
* Reduce number of overloads of fuzzy searches
* Add geojson types
* Adopting new geojson definitions
* Change test specs to align with new method names
* clean up models and tsconfig
* Expose Known* models
* Remove batch sync methods
* Add public tests (non-batch)
* move model
* Add docstrings
* Start polling in begin* method
* Refactor BatchPoller for retrieving batchId
* Finalize batch pollers
* Readd batch methods
* Update generated code
* Finalize batch signature
* Rebuild samples & clean up
* Add AAD tests
* Clean up Swagger readme
* Fix spelling
* Add initial files for @azure/maps-route module
* maps-search: change comments and perform formatting
* Methods options and testing skeleton for maps-route
* maps-search: refactor options
* Improve convenience layer for non-LRO methods
* Change variable names
* Complete batch methods
* update maps-search Readme
* Update maps-route Readme
* Add generated samples for maps-route
* Update samples for maps-search
* Delete backup file
* Add maps-common module
* Update maps-route/maps-search to use maps-common
* maps-render: first draft
* Use LatLon/BoundingBox from maps-common
* Complete maps-render with tests
* Expose required types from maps-route
* Expose required types from maps-search
* Complete unit tests for maps-render
* Update maps-render README
* Update samples
* Fix comment/strings
* Fix comment/strings
* Update Route comment/interface
* Regenerate code
* Update files
* Define required fields and fix code
* Remove non-poller batch methods
* Fix playback test failure
* Rename parts of model names
* Rename remaining parts of models according to review feedback
* Remove TODO comments
* Update Reamdme transform to reflect latest swagger
* Change key policy name
* Simplify batch item error model
* Add brower tests
* Turn maps-common into internal module
* Rearrange Readme
* Rewrite Readme for common
* Remove batch-sync methods
* Route required fields: part 1
* Route required fields: part 2
* Add AAD back
* Route model fixes#1
* Route model fixes#2 + geojson named tuples
* Refine geojson types
* Aliased a few method options
* maps-render required fields part 1
* Do not validate budget parameters
* Revert "Do not validate budget parameters"
This reverts commit 4ec3f5fd18a21466745ad23fe3e79c043ace9546.
* Rename MapTileset to TileJson
* Render: model rename & type improvement
* Explicitly transform image range
* Fix route record tests
* Update map account creation commands in Readme
* Update Readme/docstrings/samples for Search/Route/Render
* Remove rollup and use dev-tool instead
* Remove some empty tests
* Add AAD test case and make file name shorter
* Update test cases
* Update cspell rules
* Update recording files
* Simplify test cases
* Sync cspell.json from upstream
* Use test-recorder 2.0 and update unit test cases
* Push wrong browsers recording files
* Update settings to support recording
* Fix dependency errors
* Upgrade api-recorder and fix errors
* Code refinement
* Update maps search recording files
* Update karma.conf.js format
* Update recording files and settings
* Fix broken links
* Update maps dependency in pnpm-lock.yaml
* Fix sample metadata errors
* Fix linting errors
* Fix linting errors
* Fix run time error
* Update package.json in samples folder
* Fix linting errors
* Fix linting errors
* Add changelog for maps-common
* Update recording files for maps-search
* Add test.yml for maps-search
* Add tests.yml for render and route
* Update tests.yml
* Update test-resources.json for maps
* Fix tests.yml format error
* Update env vars and remove unused export var
* Remove unused code
* Fix lock file
* Remove maps-render
* fixup! Change LatLon from an interface to a tuple
* Comment the future doc link
* Update doc & fix type issue
* fix lint issues
* Regenerate API View
* Comment the whole [apiref] since the original syntax cannot pass the Analyze/Link verification
* Fix issue related to the change of maps-common
- Replace beginGet*Result with resume* methods
- Turn LatLon to a tuple
- Add mapper to transform the string to Date because resume* method will
return a serialized Date
* Update test recording
* Remove maps-common from the Artifacts
* remove unused dependencies
* Add impression in README so we can track the page views
* Remove `AZURE_LOG_LEVEL` in test.yml
* Update samples
- Move the option parameter to the right place
- Add comments & "break" for handling the type of the search result to make it clear for the user
* Patch {} to properties for GeoJsonPolygon
* rename maxDetourTime to maxDetourTimeInSeconds
* Update recordings
* Remove any
* Rename to detourTimeInSeconds to align the convention
* Change the test.yml EnvVar
See more explanation here:
- https://github.com/Azure/azure-sdk-for-js/pull/23039#discussion_r973292952
- https://github.com/Azure/azure-sdk-for-js/pull/23039#discussion_r972413976
* Rename numResults to numberResults
* Add document comment
* Add endpoint options to MapsRouteClient
* Remove unused dependencies in maps-route
* fixup! Change the test.yml EnvVar
* Update interfaces & documents
* Update changelog
* Merge getRouteDirection with the additional parameter one
* Update samples
* Make the `maps-common to a published package
* Update the import of `maps-common` in `maps-search`
* Fix CI Issue
* Add documents for geojson
* Update the samples & readme
* Leverage maps-common package in mpas-route
* chore update
- Remove the unnecessary rule setting of eslint
- Update the legacy type path
* Remove unnecessary eslint config
* WIP: Remove LRO generation
* WIP: refactor mapsRouteClient
* WIP: first generation
* Format the generated code
* Support AAD
* Transform the model name
* Add helper functions
* Add a sample - route.ts
* Add samples for lro
* Add test
* Generate samples
* Add api view
* Update the generation
* WIP: ReadMe
* Rename "computeBestOrder" to "computeBestWaypointOrder"
* Refine README
* Rename model
* Add test createRouteDirectionsBatchRequest
* Fix lint issue
* Add missing metadata
* Remove maps-route/
* Update CI issue
* Fix merged issue
* Update version rule for maps-common
* Update CI name
* Remove extra lint config
* Use `require` in the README for consistency
* Regenerate the samples
* Remove redundant recording files
* Remove unused parameters in test-resources.json
* Refine readme snippet
* Log something specific for the result
* Update samples
* Split the route.ts into 3
* Remove model rename
* Use default export for RLC factory function
Co-authored-by: Charlie Chen <charlie.chen@microsoft.com>
Co-authored-by: Charlie Chen <yuchungchen@microsoft.com>
Co-authored-by: --global <alankashiwa@gmail.com>
* Remove @azure/core-asynciterator-polyfill usage
* Remove @azure/core-asynciterator-polyfill usage
* Remove from workspace too
* Remove from core artifacts list
* Make eslint happy
* Fix more eslint errors
Co-authored-by: Jeremy Meng <yumeng@microsoft.com>
Thanks to #19530 we have a new HttpClient that uses Fetch. Currently, we can't make it the default because of recorded tests. However, we'd like folks to be able to try it out, which this PR makes possible.
The solution here is for tests that are dependent on XHR to pass in a custom HttpClient to allow the previous recordings to be used until we can migrate those packages to the new recorder.
Reported in #18033.
Basically did a bulk find+replace everywhere. Things _seem_ to be working OK, but wouldn't be surprised if there's something somewhere I've missed, or somewhere where I've replaced something I shouldn't.
I've split the rename of PerfStress -> Perf and runAsync -> run into two commits for ease of review :)
This greatly improved my first open experience on my laptop. The only tradeoff is `node_modules` folders won't appear in the file tree of VS Code, but I think this is a pretty uncommon place to browse into manually.
New rest client for Confidential Ledger @azure-rest/confidential-ledger.
Changes in @azure/core-auth:
* Added new CertificateCredential for client cert authentication
Changes in @azure/core-rest-pipeline:
* Expose Agent Secure Context options to set CA, Cert, and Key in an Agent
Changes in @azure-res/core-client:
* Expose the pipeline as part of the client to allow pipeline customization
This PR introduces 2 new packages
- `@azure-rest/core-client` - which contains shared types and functions that will be reused across generated Rest Level Clients
- `@azure-rest/ai-document-translator` - which is an auto generated rest level client that consumes `@azure-rest/core-client`. for the most part this package is composed of types.
A couple of changes included in this PR
- Updated dev-tool so that samples work with the new `@azure-rest` namespace
- Allow alternate versions for `prettier` and `api-extractor` to support newer TS features used in the Rest Level Clients such as Template Literal Types
- Talked to @deyaaeldeen and there doesn't seem to be any constraint for upgrading Prettier for the whole repo. To keep this PR scoped down to the Rest Level Client work I'll address the upgrade in a separate PR
TODO:
- [x] @azure-rest/core-client
- [x] Functionality
- [x] Readme
- [x] Tests
- [x] @azure-rest/ai-document-translator
- [x] Functionality
- [x] Samples
- [x] Readme
- [x] Tests
* Add files missing from the initial project
A couple of files are missing from the previous PR #14016 of adding the initial
project structure.
* Add ACR swagger version 2019-08-15-preview
* Update swagger to Anne's version (re-formatted)
* Re-generate with the updated swagger
* Add RepositoryClient and some of its method stubs
- Add a .vscode launch.json
- Add a credential and a policy for basic auth
* Updated to Anne's latest version (re-formatted)
* Rename properties with x-ms-client-name then re-generate
* Flatten two attributes properties
* Adjust api surface
* Address CR feedback
* Return DeletedRepositoryResult from deleteRepository()
* acr/v1 manifest endpoints only take digests
* Remove TagAttributes.signed as service is deprecating it
* Fix v1 manifests path issue
It takes a digest.
To avoid having to export random helpers from `@azure/core-rest-pipeline`, this new package is being created to house them instead. This will also allow us to share utilities between HTTP and AMQP stacks.
See #14049 for some of the motivation.
This change adds an authentication library for Mixed Reality services, which all currently utilize a custom STS for authentication. Upcoming Mixed Reality client libraries will depend on this library to perform authentication using identities from Azure.Identity. See the added `README.md` for more information about the library.
[ApiView link](https://apiview.dev/Assemblies/Review/4917626415bc448c8e2534e00c6f3a17)
karma-remap-istanbul is an undesirable dependency we've been trying to remove from the tree. This PR does the same dance we've performed in other libraries to make it unnecessary.
This PR removes our dependency on the unmaintained package "karma-remap-istanbul" and replaces it with a smaller karma plugin ("karma-sourcemap-loader") that allows karma-coverage to load source maps from the disk correctly.
I tested and confirmed that the generated coverage data has the correct source TS files.
* [WIP] prototype: multi-service-version test support
* Move multi-version test support into its own package
* Add some unit tests
* Add README
* Fix missing rollup error in CI build
* Disable browser test bundling
* Remove option to specify custom string comparison function
Now it's required to have a sorted list of API version strings
supported by the service from the oldest to the latest. This list is
used to compare version strings.
Add missing `skip` method to the chain object.
Add unit tests
* Fix README analysis issue
* Move `forEach()` and `onVersions()` into `versionsToTest()`
* Ignore README verification errors
* Fix rollup error
* Undo file moves
* Minor README tweak
* Fix build error in pipeline
* Add `DISABLE_MULTI_VERSION_TESTING` env var
This change updates the Event Grid client to follow the new Azure SDK Design guidelines. In addition, it exposes support for sending and processing events in the Cloud Events format, which the previous SDK did not support.