[REQUIRED] Environment info
firebase-tools: 15.21.0 (bundled Data Connect emulator toolkit 3.4.11)
Platform: macOS (Darwin 25.4). Not platform-specific — the missing dispatch is inside the emulator, so it reproduces on any host.
Other relevant versions: firebase-functions 7.0.0, firebase-admin 13.6.0, Cloud Functions runtime Node 24. The Functions region matches the Data Connect service location (us-east4), as the triggers docs require for events to fire when deployed.
[REQUIRED] Test case
A Data Connect service with one connector (main) exposing a simple mutation, plus a Cloud Function that subscribes to it via onMutationExecuted:
# dataconnect/main/example.gql
mutation CreateThing($name: String!) @auth(level: PUBLIC) {
thing_insert(data: { name: $name })
}
// functions/src/index.ts (built to lib/ before starting the emulator)
import { onMutationExecuted } from "firebase-functions/dataconnect";
import * as logger from "firebase-functions/logger";
export const onThingCreated = onMutationExecuted(
{ service: "example-service", connector: "main", operation: "CreateThing", region: "us-east4" },
(event) => {
logger.info("onThingCreated FIRED", { vars: event.data.payload.variables });
},
);
[REQUIRED] Steps to reproduce
- Build functions (
npm run build) so lib/ is current.
- Start the suite:
firebase emulators:start --only auth,dataconnect,functions.
- Execute the mutation against the Data Connect emulator by any client path — the VS Code extension's Run (local), the generated SDK pointed at the emulator, or:
firebase dataconnect:execute --emulator main CreateThing '{"name":"hello"}'
- Watch the Functions emulator logs.
[REQUIRED] Expected behavior
The emulator dispatches the onMutationExecuted event to the local Functions runtime and onThingCreated runs — the onThingCreated FIRED line appears — the same as when the function is deployed to a live project.
[REQUIRED] Actual behavior
The mutation succeeds and writes the row, but the Cloud Function is never invoked under the emulator: no onThingCreated FIRED log, no error, nothing is dispatched. The same function fires as expected once deployed to a live project (this is the documented production behavior — our deployed onImageFileCreated thumbnail trigger, also an onMutationExecuted trigger, fires normally), so the handler and its filter are correct — the emulator simply doesn't deliver Data Connect mutation events to Functions.
The only way we've found to exercise such a handler locally is to import the built handler and call .run(syntheticEvent) directly against a live emulator (with DATA_CONNECT_EMULATOR_HOST set) — i.e. manually simulate the dispatch the emulator never performs. This affects every onMutationExecuted trigger, not one specific operation.
Notes / related:
[REQUIRED] Environment info
firebase-tools: 15.21.0 (bundled Data Connect emulator toolkit 3.4.11)
Platform: macOS (Darwin 25.4). Not platform-specific — the missing dispatch is inside the emulator, so it reproduces on any host.
Other relevant versions:
firebase-functions7.0.0,firebase-admin13.6.0, Cloud Functions runtime Node 24. The Functions region matches the Data Connect service location (us-east4), as the triggers docs require for events to fire when deployed.[REQUIRED] Test case
A Data Connect service with one connector (
main) exposing a simple mutation, plus a Cloud Function that subscribes to it viaonMutationExecuted:[REQUIRED] Steps to reproduce
npm run build) solib/is current.firebase emulators:start --only auth,dataconnect,functions.firebase dataconnect:execute --emulator main CreateThing '{"name":"hello"}'[REQUIRED] Expected behavior
The emulator dispatches the
onMutationExecutedevent to the local Functions runtime andonThingCreatedruns — theonThingCreated FIREDline appears — the same as when the function is deployed to a live project.[REQUIRED] Actual behavior
The mutation succeeds and writes the row, but the Cloud Function is never invoked under the emulator: no
onThingCreated FIREDlog, no error, nothing is dispatched. The same function fires as expected once deployed to a live project (this is the documented production behavior — our deployedonImageFileCreatedthumbnail trigger, also anonMutationExecutedtrigger, fires normally), so the handler and its filter are correct — the emulator simply doesn't deliver Data Connect mutation events to Functions.The only way we've found to exercise such a handler locally is to import the built handler and call
.run(syntheticEvent)directly against a live emulator (withDATA_CONNECT_EMULATOR_HOSTset) — i.e. manually simulate the dispatch the emulator never performs. This affects everyonMutationExecutedtrigger, not one specific operation.Notes / related:
Data Connectlocally usingCloud Functionsin emulator #8379 (Cloud Functions couldn't query Data Connect in the emulator) and Allow @refresh(onMutationExecuted:) to fire across connectors within the same Data Connect service #10553 (@refresh(onMutationExecuted:)not firing across connectors).