Skip to content

Storage queue migration#25078

Closed
sarangan12 wants to merge 15 commits intoAzure:mainfrom
sarangan12:StorageQueueMigration
Closed

Storage queue migration#25078
sarangan12 wants to merge 15 commits intoAzure:mainfrom
sarangan12:StorageQueueMigration

Conversation

@sarangan12
Copy link
Copy Markdown
Contributor

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 repository and link it here)
  • Added a changelog (if necessary)

@ghost ghost added the Storage Storage Service (Queues, Blobs, Files) label Mar 3, 2023
@sarangan12
Copy link
Copy Markdown
Contributor Author

/azp run js - storage-queue - tests

@azure-pipelines
Copy link
Copy Markdown

Azure Pipelines successfully started running 1 pipeline(s).

@azure-sdk
Copy link
Copy Markdown
Collaborator

API change check

APIView has identified API level changes in this PR and created following API reviews.

azure-storage-queue

@sarangan12
Copy link
Copy Markdown
Contributor Author

/azp run js - storage-queue - tests

@azure-pipelines
Copy link
Copy Markdown

Azure Pipelines failed to run 1 pipeline(s).

"@azure/logger": "^1.0.0",
"tslib": "^2.2.0"
"tslib": "^2.2.0",
"@azure/storage-blob": "^12.20.0"
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

storage-queue is a much smaller package so I'd prefer not depending on storage-blob. @azure/storage-common approach would be better. Before that could we keep the copy of code?

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

file-datalake is different in that it actually uses blob client underneath for some operations.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

@jeremymeng is the idea that we put the common files here and then reference them out of the tree? https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/storage/storage-common/src

I wonder if it might also be worth converting storage-common to being a full package like we have done for keyvault-common recently. This would make it much easier to share code between storage libraries in the future. @EmmaZhu thoughts?

Copy link
Copy Markdown
Member

@jeremymeng jeremymeng Mar 6, 2023

Choose a reason for hiding this comment

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

is the idea that we put the common files here and then reference them out of the tree?

no the full published common package is what I meant

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

For now I think we can have a copy in storage-queue.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Hm yeah seems like storage-file-share is in the same boat (no direct dep on storage-blob) so having a better story here seems important.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Having a storage-common package would have some benefit for the duplicated policies, it may also bring a long dependency chain and cause a bit higher dependency complexity in customer environment. I'll need to think it through more clearly. I don't expect it as a blocking for migration. If so, maybe we can do the change later to make the change more clean and easy to understand.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

@EmmaZhu I know we have done the shared source code in the past, but the approach has its own problems and we believe common package approach is better for sharing. That's why we are now moving to use published common package instead (for example, keyvault-common, communication-common, identity is moving to use identity-common).

Yes I agree that separate PRs for migration and moving to common package are better for separate topics and make review easier

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

@jeremymeng , I agree that common package approach would bring more benefits. Let's have another PR for storage-common and maybe we should test some minor case like: customer is using storage-blob and storage-queue which references to different dependencies. Currently storage-blob and storage-queue already have some same dependencies, this should not bring any new potential issue, just we'd need to test the behavior.

parsedHeaders: MessageIdDeleteHeaders;
};
};
export type MessageIdDeleteResponse = MessageIdDeleteHeaders;
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

should these be WithResponse<> similar to what's in storage-blob

* Storage server's default timeout policy will be used.
*
* @see https://docs.microsoft.com/en-us/rest/api/storageservices/setting-timeouts-for-queue-service-operations
* @see https://docs.microsoft.com/en-us/rest/api/storageservices/setting-timeouts-for-blob-service-operations
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

The option is used by multiple services, but comments only mentioned blob.

/**
* AnonymousCredential provides a {@link CredentialPolicyCreator} member used to create
* {@link AnonymousCredentialPolicy} objects. {@link AnonymousCredentialPolicy} is used with
* AnonymousCredential provides a credentialPolicyCreator member used to create
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Why remove the link here?

retryPolicyType: StorageRetryPolicyType.EXPONENTIAL,
secondaryHost: "",
tryTimeoutInMs: 30 * 1000, // https://docs.microsoft.com/en-us/rest/api/storageservices/setting-timeouts-for-queue-service-operations
tryTimeoutInMs: undefined, // Use server side default timeout strategy
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Technically, it's a behavior change. Please keep the origin behavior.

@@ -1,158 +0,0 @@
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT license.
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Why remove this test suite?

@github-actions
Copy link
Copy Markdown

github-actions bot commented Jun 2, 2023

Hi @sarangan12. Thank you for your interest in helping to improve the Azure SDK experience and for your contribution. We've noticed that there hasn't been recent engagement on this pull request. If this is still an active work stream, please let us know by pushing some changes or leaving a comment. Otherwise, we'll close this out in 7 days.

@github-actions github-actions bot added the no-recent-activity There has been no recent activity on this issue. label Jun 2, 2023
@github-actions
Copy link
Copy Markdown

github-actions bot commented Jun 9, 2023

Hi @sarangan12. Thank you for your contribution. Since there hasn't been recent engagement, we're going to close this out. Feel free to respond with a comment containing /reopen if you'd like to continue working on these changes. Please be sure to use the command to reopen or remove the no-recent-activity label; otherwise, this is likely to be closed again with the next cleanup pass.

@github-actions github-actions bot closed this Jun 9, 2023
@jeremymeng jeremymeng reopened this Jun 9, 2023
@github-actions github-actions bot removed the no-recent-activity There has been no recent activity on this issue. label Jun 9, 2023
@xirzec
Copy link
Copy Markdown
Member

xirzec commented Jun 14, 2023

Superseded by #26207

@xirzec xirzec closed this Jun 14, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Storage Storage Service (Queues, Blobs, Files)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants