Skip to content

How to add batchsize in blob triggered Azure Function #10624

Closed
@anime-shed

Description

@anime-shed

To prevent race conditions and exceed the 1.5 GB memory limit, I would like the BlobTrigger to process only 1 file at a time.

host.json

{
  "version": "2.0",
  "concurrency": {
    "dynamicConcurrencyEnabled": true,
    "snapshotPersistenceEnabled": true
  },
  "logging": {
    "logLevel": {
      "default": "Error"
    }
  },
  "extensions": {
    "blobs": {
      "maxDegreeOfParallelism": 2,
      "poisonBlobThreshold": 1
    },
    "queues": {
            "maxPollingInterval": "00:00:02",
            "visibilityTimeout" : "00:00:30",
            "batchSize": 1,
            "maxDequeueCount": 5,
            "newBatchThreshold": 8
        }
  },
  "extensionBundle": {
    "id": "Microsoft.Azure.Functions.ExtensionBundle",
    "version": "[4.*, 5.0.0)"
  }
}

The deployment for the above is in AKS.

I tried "How to ensure only one Azure Function BlobTrigger runs at a time?", but that also does not seem to be working.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions