-
Notifications
You must be signed in to change notification settings - Fork 957
[Migrate-Check] sdk/resourcemanager/marketplace/armmarketplace #25906
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
API Change CheckAPIView identified API level changes in this PR and created the following API reviews |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
This pull request migrates the Azure Marketplace SDK from AutoRest code generation to the new Go Code Generator (TypeSpec-based), updating from API version 2021-12-01 to 2025-01-01 and bumping the major version from v1 to v2.
Changes:
- Migration from AutoRest to TypeSpec-based Go Code Generator
- API version update from 2021-12-01 to 2025-01-01
- Module version bump to v2 with updated import paths
- New operations and response types added
- Method signature changes (some optional parameters moved to required)
Reviewed changes
Copilot reviewed 33 out of 34 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| version.go | New file defining module name and version v2.0.0 |
| tsp-location.yaml | New TypeSpec configuration file for SDK generation |
| testdata/_metadata.json | New test metadata with API version 2025-01-01 |
| time_rfc3339.go | Removed (functionality likely moved to generated code) |
| responses.go | Updated response types with new operations and improved comments |
| go.mod | Updated module path to v2 and dependency versions |
| go.sum | Updated dependency checksums |
| *_client.go | Updated with API version changes, signature changes, and new methods |
| *_example_test.go | Updated examples with new import path and API patterns |
| options.go | Updated with new optional parameter structures |
| build.go | Removed (no longer needed for TypeSpec generation) |
| fake/*.go | Updated fake server implementations |
| - New struct `CollectionOffersByContext` | ||
| - New struct `CollectionOffersByContextList` | ||
| - New struct `CollectionOffersByContextOffers` | ||
| - New struct `CollectionsToSubscriptionsMappingResponseProperties` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Feature Migration Added:
- New struct
CollectionsToSubscriptionsMappingResponseProperties - New enum type
CreatedByTypewith valuesCreatedByTypeApplication,CreatedByTypeKey,CreatedByTypeManagedIdentity,CreatedByTypeUser -
- New function
NewClient(credential azcore.TokenCredential, options *arm.ClientOptions) (*Client, error)
- New function
- New function
*Client.NewOperationsClient() *OperationsClient - New function
*Client.NewPrivateStoreClient() *PrivateStoreClient - New function
*Client.NewPrivateStoreCollectionClient() *PrivateStoreCollectionClient - New function
*Client.NewPrivateStoreCollectionOfferClient() *PrivateStoreCollectionOfferClient - New function
*Client.QueryRules(ctx context.Context, privateStoreID string, collectionID string, options *ClientQueryRulesOptions) (ClientQueryRulesResponse, error) - New function
*Client.QueryUserRules(ctx context.Context, privateStoreID string, options *ClientQueryUserRulesOptions) (ClientQueryUserRulesResponse, error) - New function
*Client.SetCollectionRules(ctx context.Context, privateStoreID string, collectionID string, options *ClientSetCollectionRulesOptions) (ClientSetCollectionRulesResponse, error) - New function
*ClientFactory.NewClient() *Client
Feature Migration removed:
- New function
*ClientFactory.NewRPServiceClient() *RPServiceClient - New function
NewRPServiceClient(credential azcore.TokenCredential, options *arm.ClientOptions) (*RPServiceClient, error) - New function
*RPServiceClient.QueryRules(ctx context.Context, privateStoreID string, collectionID string, options *RPServiceClientQueryRulesOptions) (RPServiceClientQueryRulesResponse, error) - New function
*RPServiceClient.QueryUserRules(ctx context.Context, privateStoreID string, options *RPServiceClientQueryUserRulesOptions) (RPServiceClientQueryUserRulesResponse, error) - New function
*RPServiceClient.SetCollectionRules(ctx context.Context, privateStoreID string, collectionID string, options *RPServiceClientSetCollectionRulesOptions) (RPServiceClientSetCollectionRulesResponse, error)
| - Field `Payload` of struct `PrivateStoreClientUpdateAdminRequestApprovalOptions` has been removed | ||
| - Field `Payload` of struct `PrivateStoreCollectionClientCreateOrUpdateOptions` has been removed | ||
| - Field `Payload` of struct `PrivateStoreCollectionOfferClientCreateOrUpdateOptions` has been removed | ||
|
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Migration Breaking Changed added:
- Function
*PrivateStoreClient.CreateApprovalRequestparameter(s) have been changed from(ctx context.Context, privateStoreID string, requestApprovalID string, options *PrivateStoreClientCreateApprovalRequestOptions)to(ctx context.Context, privateStoreID string, requestApprovalID string, payload RequestApprovalResource, options *PrivateStoreClientCreateApprovalRequestOptions) - Function
*PrivateStoreClient.CreateOrUpdateparameter(s) have been changed from(ctx context.Context, privateStoreID string, options *PrivateStoreClientCreateOrUpdateOptions)to(ctx context.Context, privateStoreID string, payload PrivateStore, options *PrivateStoreClientCreateOrUpdateOptions) - Function
*PrivateStoreClient.UpdateAdminRequestApprovalparameter(s) have been changed from(ctx context.Context, privateStoreID string, adminRequestApprovalID string, options *PrivateStoreClientUpdateAdminRequestApprovalOptions)to(ctx context.Context, privateStoreID string, adminRequestApprovalID string, payload AdminRequestApprovalsResource, options *PrivateStoreClientUpdateAdminRequestApprovalOptions) - Type of
CollectionsToSubscriptionsMappingResponse.Detailshas been changed frommap[string]*CollectionsSubscriptionsMappingDetailsto*CollectionsToSubscriptionsMappingResponseProperties - Type of
PlanDetails.RequestDatehas been changed fromanyto*time.Time - Type of
SystemData.CreatedByTypehas been changed from*IdentityTypeto*CreatedByType - Type of
SystemData.LastModifiedByTypehas been changed from*IdentityTypeto*CreatedByType - Enum
IdentityTypehas been removed - Operation
*OperationsClient.Listhas supported pagination, use*OperationsClient.NewListPagerinstead. - Operation
*PrivateStoreClient.AdminRequestApprovalsListhas supported pagination, use*PrivateStoreClient.NewAdminRequestApprovalsListPagerinstead. - Operation
*PrivateStoreClient.GetApprovalRequestsListhas supported pagination, use*PrivateStoreClient.NewGetApprovalRequestsListPagerinstead. - Operation
*PrivateStoreCollectionClient.Listhas supported pagination, use*PrivateStoreCollectionClient.NewListPagerinstead. - Struct
ErrorResponsehas been removed - Struct
ErrorResponseErrorhas been removed - Struct
Resourcehas been removed - Field
Payloadof structPrivateStoreClientCreateApprovalRequestOptionshas been removed - Field
Payloadof structPrivateStoreClientCreateOrUpdateOptionshas been removed - Field
Payloadof structPrivateStoreClientUpdateAdminRequestApprovalOptionshas been removed - Field
Payloadof structPrivateStoreCollectionClientCreateOrUpdateOptionshas been removed - Field
Payloadof structPrivateStoreCollectionOfferClientCreateOrUpdateOptionshas been removed
modifiled breaking changes:
before:
- Function
*PrivateStoreCollectionOfferClient.CreateOrUpdateparameter(s) have been changed from(ctx context.Context, privateStoreID string, offerID string, collectionID string, options *PrivateStoreCollectionOfferClientCreateOrUpdateOptions)to(ctx context.Context, privateStoreID string, collectionID string, offerID string, options *PrivateStoreCollectionOfferClientCreateOrUpdateOptions)
after:
- Function
*PrivateStoreCollectionOfferClient.CreateOrUpdateparameter(s) have been changed from(ctx context.Context, privateStoreID string, offerID string, collectionID string, options *PrivateStoreCollectionOfferClientCreateOrUpdateOptions)to(ctx context.Context, privateStoreID string, collectionID string, offerID string, payload Offer, options *PrivateStoreCollectionOfferClientCreateOrUpdateOptions)
generation base on spec branch migration/marketplace