{"record":{"id":"d0dff76eda96442a","repo":"apache/beam","slug":"setting-the-triggering-frequency-is-only-applicable-to-an","errorCode":null,"errorMessage":"Setting the triggering frequency is only applicable to an unbounded PCollection.","messagePattern":"Setting the triggering frequency is only applicable to an unbounded PCollection\\.","errorType":"console","errorClass":null,"httpStatus":null,"severity":"warning","filePath":"sdks/java/io/google-cloud-platform/src/main/java/org/apache/beam/sdk/io/gcp/bigquery/BigQueryIO.java","lineNumber":3907,"sourceCode":"            LOG.warn(\n                \"The setting of auto-sharding is ignored. It is only supported when writing an\"\n                    + \" unbounded PCollection via FILE_LOADS, STREAMING_INSERTS or\"\n                    + \" STORAGE_WRITE_API, but the method was {}.\",\n                method);\n          }\n        }\n      } else { // PCollection is bounded\n        checkArgument(\n            getTriggeringFrequency() == null,\n            \"Triggering frequency is only applicable to an unbounded PCollection.\");\n        checkArgument(\n            !getAutoSharding(), \"Auto-sharding is only applicable to an unbounded PCollection.\");\n        checkArgument(\n            getNumFileShards() == 0,\n            \"Number of file shards is only applicable to an unbounded PCollection.\");\n\n        if (getStorageApiTriggeringFrequency(bqOptions) != null) {\n          LOG.warn(\n              \"Setting the triggering frequency is only applicable to an unbounded PCollection.\");\n        }\n        if (getStorageApiNumStreams(bqOptions) != 0) {\n          LOG.warn(\n              \"Setting the number of Storage API streams is only applicable to an unbounded PCollection.\");\n        }\n      }\n\n      if (method == Method.STORAGE_API_AT_LEAST_ONCE && getStorageApiNumStreams(bqOptions) != 0) {\n        LOG.warn(\n            \"Setting a number of Storage API streams is only supported when using STORAGE_WRITE_API\");\n      }\n\n      if (method != Method.STORAGE_WRITE_API && method != Method.STORAGE_API_AT_LEAST_ONCE) {\n        checkArgument(\n            !getAutoSchemaUpdate(),\n            \"withAutoSchemaUpdate only supported when using STORAGE_WRITE_API or STORAGE_API_AT_LEAST_ONCE.\");\n        checkArgument(","sourceCodeStart":3889,"sourceCodeEnd":3925,"githubUrl":"https://github.com/apache/beam/blob/12126d8942aaf848030c478b4c6a28c6af861c66/sdks/java/io/google-cloud-platform/src/main/java/org/apache/beam/sdk/io/gcp/bigquery/BigQueryIO.java#L3889-L3925","documentation":"Storage API triggering frequency paces flushes of a streaming (unbounded) write. When the input PCollection is bounded, there is no ongoing stream to pace, so a configured triggering frequency cannot apply and the sink logs this warning instead of failing.","triggerScenarios":"Calling withTriggeringFrequency(...) (so getStorageApiTriggeringFrequency != null) on a BigQueryIO write whose input PCollection is bounded.","commonSituations":"Batch pipelines that copied a streaming sink builder, or a pipeline whose input changed from unbounded (Pub/Sub) to bounded (batch source) without removing the frequency setting.","solutions":["Remove withTriggeringFrequency(...) for the bounded write","Verify the input PCollection is actually intended to be unbounded; if so, ensure its coder/isBounded is unbounded","Switch to STORAGE_WRITE_API with a truly unbounded source if periodic flushes are required"],"exampleFix":"// before\nBigQueryIO.writeTableRows().to(table).withMethod(Method.STORAGE_WRITE_API).withTriggeringFrequency(Duration.standardMinutes(1)) // bounded input\n// after\nBigQueryIO.writeTableRows().to(table).withMethod(Method.STORAGE_WRITE_API) // triggering frequency removed","handlingStrategy":"validation","validationCode":"if (input.isBounded() == PCollection.IsBounded.BOUNDED && triggeringFrequency != null) { /* remove triggering frequency */ }","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Gate withTriggeringFrequency behind an isBounded()==UNBOUNDED check","Re-audit sink options when swapping batch/streaming sources","Keep streaming-only options in streaming pipeline templates only"],"tags":["java","apache-beam","bigquery","bounded-input"],"backgroundTag":"invalid-config-value","analyzedSha":"12126d8942aaf848030c478b4c6a28c6af861c66","analyzedAt":"2026-09-13T01:50:10.254Z","contentChangedAt":"2026-09-13T01:50:10.254Z","schemaVersion":2},"datasetVersion":"2026-09-20T03:17:13.778Z"}