Azure / Azure/azure-functions-host

SQL Trigger function breaks Service Bus Trigger bindings

Open
#10,852 2 comments 3 reactions 0 assignees View on GitHub
Needs: Attention :wave: Needs: Triage (Functions)
Dominant language
C#
Stars
2k
Forks
482
Avg merge
2d 10h
Merged PRs (30d)
36

Description

We are getting the following error in Azure Portal on our function app overview:

Image

> The following Application Settings are referenced in Function bindings but not configured in the Function App. This can cause execution errors
> Function: fiz-azure-functions/SendCustomerVerificationEmail, Binding parameter: json, Application setting: ServiceBusConnectionStringV2

Time: 17-02-2025 10:05:29 UTC

This happens for all service bus trigger functions we have in the function app.

The app settings is present in Environment variables > App settings.

Image

It does not matter if it is in Environment variables > App settings or Environment variables > Connection strings.

This happens only under **these two conditions:**

1. We introduce SQL Trigger function
2. We introduce SQL connection string bindings for the trigger.

When we remove either, **service bus bindings work again** and message errors disappear.

This is how SqlTrigger is defined:

```
public async Task Run([SqlTrigger("[dbo].[Customers]", "SqlServerConnectionString")] IReadOnlyList> changes, FunctionContext context)
```

Environment variables > App settings

```
Key: SqlServerConnectionString
Value: Server=tcp:{azuresql},1433;Initial Catalog=fiz;Persist Security Info=False;User ID=fizfunctions;Password={pass};MultipleActiveResultSets=False;Encrypt=True;TrustServerCertificate=False;Connection Timeout=30;
```

We have exactly the same setup in different Azure subscription which works correctly.

The project is using the following packages:

```









```

Contributor guide

Open the contributing guide

Research direction

Start with the SqlTrigger declaration and the listed Worker, ServiceBus, and SQL extension package versions; reproduce the behavior with and without the SQL trigger or connection binding. Done means the SQL trigger remains usable while Service Bus bindings no longer report the configured connection setting as missing.

Written by the indexing model from the issue text.

Assessment

Tech stack
azure, csharp, sql
Domain
backend, cloud, databases
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.