{"record":{"id":"44f5a0c14ced8dc3","repo":"apache/seatunnel","slug":"read-failed-44f5a0","errorCode":"READ_FAILED","errorMessage":"Failed to receive Azure Queue Storage messages","messagePattern":"Failed to receive Azure Queue Storage messages","errorType":"error_code","errorClass":"AzureQueueConnectorException","httpStatus":null,"severity":"error","filePath":"seatunnel-connectors-v2/connector-azure-queue-storage/src/main/java/org/apache/seatunnel/connectors/seatunnel/azure/queue/source/AzureQueueStorageSourceReader.java","lineNumber":102,"sourceCode":"    public void pollNext(Collector<SeaTunnelRow> output) {\n        if (!splitAssigned) {\n            return;\n        }\n        checkVisibilityRenewalFailure();\n        int availableCapacity;\n        synchronized (acknowledgementLock) {\n            availableCapacity = config.getMaxInFlightMessages() - leasedMessages.size();\n        }\n        if (availableCapacity <= 0) {\n            sleepBeforeNextPoll();\n            return;\n        }\n\n        List<AzureQueueMessage> messages;\n        try {\n            messages = receiver.receive(Math.min(config.getBatchSize(), availableCapacity));\n        } catch (Exception e) {\n            throw readFailure(\"Failed to receive Azure Queue Storage messages\", e);\n        }\n        if (messages.isEmpty()) {\n            sleepBeforeNextPoll();\n            return;\n        }\n\n        synchronized (acknowledgementLock) {\n            leasedMessages.addAll(messages);\n        }\n        for (int index = 0; index < messages.size(); index++) {\n            AzureQueueMessage message = messages.get(index);\n            try {\n                synchronized (output.getCheckpointLock()) {\n                    deserializationSchema.deserialize(message.getBody(), output);\n                    synchronized (acknowledgementLock) {\n                        unacknowledgedMessages.add(message);\n                    }\n                }","sourceCodeStart":84,"sourceCodeEnd":120,"githubUrl":"https://github.com/apache/seatunnel/blob/cf67b549a7a6c35fa0beb12d83c62892427ea919/seatunnel-connectors-v2/connector-azure-queue-storage/src/main/java/org/apache/seatunnel/connectors/seatunnel/azure/queue/source/AzureQueueStorageSourceReader.java#L84-L120","documentation":"The source reader wraps any exception from receiver.receive(batchSize) into an AzureQueueConnectorException (READ_FAILED) with this message. receiver.receive dequeues up to batchSize messages from the Azure Queue; any client-side or service-side failure during that call aborts the poll loop.","triggerScenarios":"pollNext() calls receiver.receive(...) and the Azure Queue Storage SDK throws — invalid/expired credentials, nonexistent queue, network failure, throttling, or SDK client misconfiguration.","commonSituations":"Wrong connection string or account key; queue name typo or queue deleted; storage account firewall blocking the cluster; receiving before visibility timeout handling with an invalid pop receipt.","solutions":["Check the wrapped cause: validate connection string, account name, and queue name in the source config.","Verify the queue exists and the credentials have read/delete (process) permissions.","Test network/firewall access from the cluster to the storage endpoint (storage account firewall/VNet rules).","Add retry/backoff for transient throttling and restart the job from the last checkpoint."],"exampleFix":"// before: typo in queue name\n\"queue\" = \"myquue\"\n// after\n\"queue\" = \"myqueue\"","handlingStrategy":"retry","validationCode":"// validate config before starting the source\nQueueClient c = new QueueClientBuilder()\n        .connectionString(connStr).queueName(queueName).buildAsyncClient();\nc.getProperties().block(Duration.ofSeconds(10)); // fails fast on bad queue/credentials","typeGuard":null,"tryCatchPattern":"try {\n    reader.pollNext();\n} catch (AzureQueueConnectorException e) {\n    if (e.getCause() instanceof IOException\n            || (e.getCause() instanceof HttpResponseException h && h.getStatusCode() >= 500)) {\n        backoffAndRetry();\n    } else {\n        throw e; // auth/config errors are not retryable\n    }\n}","preventionTips":["Verify connection string, account name, and queue name in config","Grant read+delete (process) permissions to the credential","Open firewall/VNet rules for the cluster's egress IPs","Add retry/backoff for throttling (429) and transient 5xx"],"tags":["azure","queue-storage","source-reader","receive","network"],"backgroundTag":"api-request-failed","analyzedSha":"cf67b549a7a6c35fa0beb12d83c62892427ea919","analyzedAt":"2026-09-10T21:44:55.265Z","contentChangedAt":"2026-09-10T21:44:55.265Z","schemaVersion":2},"datasetVersion":"2026-09-14T11:17:12.474Z"}