Azure / Azure/Azurite

Running BlockBlobClient highlevel unit test with t2 Azure Storage SDK has an socket issue

Open
#526 1 comment 0 reactions 0 assignees View on GitHub
stale
Dominant language
TypeScript
Stars
2.3k
Forks
393
Avg merge
1d 20h
Merged PRs (30d)
36

Description

Azurite Version: v3.8.0

Issue Description:
Run BlockBlobClient highlevel unit test with t2 Azure Storage SDK In Azurite, an socket issue is shown in the figure below:
![Annotation 2020-06-17 103855](https://user-images.githubusercontent.com/20970631/88870059-f351f600-d246-11ea-8d1a-eae3f1bdf6c0.png)
Note: If disable keep alive when create blob service client, the socket issue will not happen. The modified code snippet is as following:
```typescript
const serviceClient = new BlobServiceClient(
baseURL,
newPipeline(
new StorageSharedKeyCredential(
EMULATOR_ACCOUNT_NAME,
EMULATOR_ACCOUNT_KEY
),
{
retryOptions: { maxTries: 1 },
// Make sure socket is closed once the operation is done.
keepAliveOptions: { enable: false }
}
)
);
```

Steps to reproduce:
1)Clone the repo from [link](https://github.com/zzhxiaofeng/Azurite.git).
2)Open Azurite folder with VS Code and run command `npm i` to install dependencies packages.
3)Run command `npm run test` to run all unit test.

Note: it does not happen at every time, it happens at some time. Please try more times.

Expected Behavior:
Run highlevel unit test successfully.

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.