<!-- mobian-agent-page publisher="dailydev" canonical="https://daily.dev/posts/why-did-our-gcs-pipeline-trigger-when-no-file-was-uploaded--oltmbffun" -->

---
title: Why Did Our GCS Pipeline Trigger When No File Was Uploaded?
description: A GCS-to-Pub/Sub-to-Cloud-Function pipeline was firing without any file upload. The culprit was zero-byte objects representing folder-like paths in Google...
canonical: https://daily.dev/posts/why-did-our-gcs-pipeline-trigger-when-no-file-was-uploaded--oltmbffun
twitter:card: summary_large_image
twitter:site: @dailydotdev
og:type: website
og:site_name: daily.dev
og:title: Why Did Our GCS Pipeline Trigger When No File Was Uploaded? | daily.dev
og:description: A GCS-to-Pub/Sub-to-Cloud-Function pipeline was firing without any file upload. The culprit was zero-byte objects representing folder-like paths in Google...
og:url: https://daily.dev/posts/why-did-our-gcs-pipeline-trigger-when-no-file-was-uploaded--oltmbffun
og:image: https://api.daily.dev/og/posts/OLtmBffuN.png
og:image:alt: Why Did Our GCS Pipeline Trigger When No File Was Uploaded?
og:image:width: 1200
og:image:height: 630
og:locale: en
---

> ## Documentation Index
> Fetch the complete documentation index at: https://daily.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# Why Did Our GCS Pipeline Trigger When No File Was Uploaded?

**[DevOps & Platform Engineering Hub](https://daily.dev/sources/sanjay)** · [@divyansh30](https://daily.dev/divyansh30) · 1 min read · 0 upvotes · 0 comments

## Summary

A GCS-to-Pub/Sub-to-Cloud-Function pipeline was firing without any file upload. The culprit was zero-byte objects representing folder-like paths in Google Cloud Storage, which can also emit notifications. The fix was to filter these placeholder events out inside the Cloud Function before forwarding requests to the backend. The post ends by asking other teams how they handle unexpected pipeline triggers and where they prefer to filter such events.

## Content

We had a simple event-driven setup:

**GCS → Pub/Sub → Cloud Function → Backend**

The idea was straightforward: upload a file, trigger the function, and process it.

Then we started seeing backend requests when **no actual file had been uploaded**.

The reason turned out to be something easy to miss: in Google Cloud Storage, folder-like paths can be represented by **zero-byte objects** with names ending in `/`. Those objects can also generate notifications.

So a zero-byte folder-like object was generating an event that our pipeline wasn't expecting.

The fix was to filter these events in the Cloud Function before sending anything to the backend.

Curious how other DevOps and platform teams handle this:

- Have you ever had unexpected events trigger a cloud pipeline?
- Where do you prefer to filter unwanted events?
- Do you filter at the event layer or inside the application?
- Have you run into similar object-storage quirks?

I came across this practical write-up while looking into the issue:

[https://www.kubeblogs.com/google-cloud-storage-and-the-problem-with-zero-byte-folders/](https://www.kubeblogs.com/google-cloud-storage-and-the-problem-with-zero-byte-folders/)

**What's the strangest “unexpected event” you've had to debug in a production pipeline?**

#DevOps #PlatformEngineering #GoogleCloud #GCP #CloudEngineering #Serverless

## Similar posts on daily.dev

- [Unordered mode for GCS ClickPipes is now available](https://daily.dev/posts/unordered-mode-for-gcs-clickpipes-is-now-available-zd8hdjikm) · ClickHouse · 1 upvotes · 0 comments
- [When a file is uploaded, run the job on Neon](https://daily.dev/posts/when-a-file-is-uploaded-run-the-job-on-neon-r0fjcimoy) · Neon · 12 upvotes · 1 comments
- [When Notifications Became Data Trucks: A Real-World Crash Story from Firebase FCM](https://daily.dev/posts/when-notifications-became-data-trucks-a-real-world-crash-story-from-firebase-fcm-nh9ixqylv) · ProAndroidDev · 1 upvotes · 0 comments
- [Your bucket is already a message queue](https://daily.dev/posts/your-bucket-is-already-a-message-queue-1szqzwfrk) · Tigris · 3 upvotes · 0 comments
- [Reimagining how you structure workflows in Bitbucket Pipelines](https://daily.dev/posts/reimagining-how-you-structure-workflows-in-bitbucket-pipelines-ogkly4u8w) · Atlassian · 2 upvotes · 0 comments

---

Tags: [#architecture](https://daily.dev/tags/architecture), [#gcp](https://daily.dev/tags/gcp), [#serverless](https://daily.dev/tags/serverless)

[View this post on daily.dev](https://daily.dev/posts/why-did-our-gcs-pipeline-trigger-when-no-file-was-uploaded--oltmbffun)

```json
{"@context":"https://schema.org","@graph":[{"@type":"Organization","@id":"https://daily.dev/#organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180},"sameAs":["https://twitter.com/dailydotdev","https://github.com/dailydotdev","https://www.linkedin.com/company/daily-dev-ltd"]},{"@type":"WebSite","@id":"https://daily.dev/#website","url":"https://daily.dev","name":"daily.dev","publisher":{"@id":"https://daily.dev/#organization"},"potentialAction":{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https://daily.dev/search?q={search_term_string}"},"query-input":"required name=search_term_string"}}]}
{"@context":"https://schema.org","@type":"DiscussionForumPosting","mainEntityOfPage":"https://daily.dev/posts/why-did-our-gcs-pipeline-trigger-when-no-file-was-uploaded--oltmbffun","headline":"Why Did Our GCS Pipeline Trigger When No File Was Uploaded?","text":"A GCS-to-Pub/Sub-to-Cloud-Function pipeline was firing without any file upload. The culprit was zero-byte objects representing folder-like paths in Google Cloud Storage, which can also emit notifications. The fix was to filter these placeholder events out inside the Cloud Function before forwarding requests to the backend. The post ends by asking other teams how they handle unexpected pipeline triggers and where they prefer to filter such events.","url":"https://daily.dev/posts/why-did-our-gcs-pipeline-trigger-when-no-file-was-uploaded--oltmbffun","datePublished":"2026-09-07T05:22:54.850Z","dateModified":"2026-09-07T05:23:10.423Z","author":{"@type":"Person","name":"Divyansh","url":"https://daily.dev/divyansh30","image":"https://media.daily.dev/image/upload/s--f9lbkpFv--/f_auto/v1744873189/avatars/avatar_JMQ4qarKTe7zPurSPRrzM","description":"Aspiring engineer with an interest in AI, tech and DevOps :)","interactionStatistic":{"@type":"InteractionCounter","interactionType":{"@type":"EndorseAction"},"userInteractionCount":1090}},"image":"https://media.daily.dev/image/upload/s--BazeQz7H--/f_auto/v1788758575/posts/OLtmBffuN?_a=BAMAMicg0","interactionStatistic":[{"@type":"InteractionCounter","interactionType":{"@type":"LikeAction"},"userInteractionCount":0},{"@type":"InteractionCounter","interactionType":{"@type":"CommentAction"},"userInteractionCount":0}],"isPartOf":{"@type":"WebPage","url":"https://daily.dev/squads/sanjay","name":"DevOps \u0026 Platform Engineering Hub"}}
{"@context":"https://schema.org","@type":"BreadcrumbList","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https://daily.dev"},{"@type":"ListItem","position":2,"name":"DevOps \u0026 Platform Engineering Hub","item":"https://daily.dev/squads/sanjay"},{"@type":"ListItem","position":3,"name":"Why Did Our GCS Pipeline Trigger When No File Was Uploaded?"}]}
```

