Event Hub blob partition lease conflict
- Dominant language
- TypeScript
- Stars
- 2.3k
- Forks
- 393
- Avg merge
- 1d 20h
- Merged PRs (30d)
- 36
Description
This webjob works fine running on Windows with the Windows Storage Emulator.
### Which service(blob, file, queue, table) does this issue concern?
blob
### Which version of the Azurite was used?
v2
### Where do you get Azurite? (npm, DockerHub, NuGet, Visual Studio Code Extension)
DockerHub
### What's the Node.js version?
`6.11.2`
### What problem was encountered?
```
Microsoft.Azure.WebJobs.Host.Listeners.FunctionListenerException: The listener for function 'RouterHost.Route' was unable to start. ---> Microsoft.Azure.EventHubs.Processor.EventProcessorRuntimeException: Out of retries creating lease for partition ---> Microsoft.Window
sAzure.Storage.StorageException: Conflict
at Microsoft.WindowsAzure.Storage.Core.Executor.Executor.ExecuteAsyncInternal[T](RESTCommand`1 cmd, IRetryPolicy policy, OperationContext operationContext, CancellationToken token)
at Microsoft.WindowsAzure.Storage.Blob.CloudBlockBlob.UploadFromStreamAsyncHelper(Stream source, Nullable`1 length, AccessCondition accessCondition, BlobRequestOptions options, OperationContext operationContext, IProgress`1 progressHandler, CancellationToken cancella
tionToken)
at Microsoft.Azure.EventHubs.Processor.AzureStorageCheckpointLeaseManager.CreateLeaseIfNotExistsAsync(String partitionId)
at Microsoft.Azure.EventHubs.Processor.AzureStorageCheckpointLeaseManager.CreateLeaseIfNotExistsAsync(String partitionId)
at Microsoft.Azure.EventHubs.Processor.PartitionManager.RetryAsync(Func`1 lambda, String partitionId, String retryMessage, String finalFailureMessage, String action, Int32 maxRetries)
--- End of inner exception stack trace ---
at Microsoft.Azure.EventHubs.Processor.PartitionManager.RetryAsync(Func`1 lambda, String partitionId, String retryMessage, String finalFailureMessage, String action, Int32 maxRetries)
at Microsoft.Azure.EventHubs.Processor.PartitionManager.InitializeStoresAsync()
at Microsoft.Azure.EventHubs.Processor.PartitionManager.StartAsync()
at Microsoft.Azure.EventHubs.Processor.EventProcessorHost.RegisterEventProcessorFactoryAsync(IEventProcessorFactory factory, EventProcessorOptions processorOptions)
at Medumo.WebJobs.Extensions.EventHub.Binding.EventHubListener.StartAsync(CancellationToken cancellationToken)
at Microsoft.Azure.WebJobs.Host.Listeners.FunctionListener.StartAsync(CancellationToken cancellationToken, Boolean allowRetry) in C:\projects\azure-webjobs-sdk-rqm4t\src\Microsoft.Azure.WebJobs.Host\Listeners\FunctionListener.cs:line 69
```
### Steps to reproduce the issue?
- Use macOS
- `docker run -d -t -p 10000:10000 -p 10001:10001 -p 10002:10002 -v /Users/myuser/azurite:/opt/azurite/folder arafato/azurite`
- Create .NET Core 2.2 class library
- Setup `HostBuilder` to search for `EventHubTriggerAttribute`
- Set up a `EventHubTrigger` class/function (see [here](https://docs.microsoft.com/en-us/azure/azure-functions/functions-bindings-event-hubs))
- Run WebJob with `dotnet run --project MyWebJobProject`
### Have you found a mitigation/solution?
No
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.