Skip to content
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

[Search] Add a work around to fix CreateAzureBlobIndexer test #39117

Merged
merged 1 commit into from
Oct 6, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion sdk/search/Azure.Search.Documents/assets.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,5 @@
"AssetsRepo": "Azure/azure-sdk-assets",
"AssetsRepoPrefixPath": "net",
"TagPrefix": "net/search/Azure.Search.Documents",
"Tag": "net/search/Azure.Search.Documents_53888408bf"
"Tag": "net/search/Azure.Search.Documents_547641209a"
}
Original file line number Diff line number Diff line change
Expand Up @@ -85,17 +85,21 @@ public async Task CreateAzureBlobIndexer()
dataSource.Name,
resources.IndexName);

SearchIndexer actualIndexer = await serviceClient.CreateIndexerAsync(
indexer);
await serviceClient.CreateIndexerAsync(indexer);

// Wait till the indexer is done.
await WaitForIndexingAsync(serviceClient, indexer.Name);

// Remove this workaround once the service issue is fixed: https://github.com/Azure/azure-sdk-for-net/issues/39104#issuecomment-1749469582
// Tracking issue: https://msdata.visualstudio.com/Azure%20Search/_workitems/edit/2737454
SearchIndexer actualIndexer = await serviceClient.GetIndexerAsync(indexer.Name);

// Update the indexer.
actualIndexer.Description = "Updated description";
await serviceClient.CreateOrUpdateIndexerAsync(
actualIndexer,
onlyIfUnchanged: true);

await WaitForIndexingAsync(serviceClient, actualIndexer.Name);

// Run the indexer.
await serviceClient.RunIndexerAsync(
indexer.Name);
Expand Down