{"record":{"id":"390aba0ed1ef72f4","repo":"influxdata/influxdb","slug":"shouldn-t-have-request-path-trigger-for-scheduled-plugin","errorCode":null,"errorMessage":"shouldn't have request path trigger for scheduled plugin","messagePattern":"shouldn't have request path trigger for scheduled plugin","errorType":"validation","errorClass":"PluginError","httpStatus":null,"severity":"error","filePath":"influxdb3_processing_engine/src/plugins.rs","lineNumber":175,"sourceCode":"}\n\nstruct ScheduleTriggerRunner {\n    schedule: Schedule,\n    next_trigger_time: Option<DateTime<Utc>>,\n}\n\nimpl ScheduleTriggerRunner {\n    fn try_new(\n        trigger_spec: &TriggerSpecificationDefinition,\n        time_provider: Arc<dyn TimeProvider>,\n    ) -> Result<Self, PluginError> {\n        match trigger_spec {\n            TriggerSpecificationDefinition::AllTablesWalWrite\n            | TriggerSpecificationDefinition::SingleTableWalWrite { .. } => {\n                Err(anyhow!(\"shouldn't have table trigger for scheduled plugin\").into())\n            }\n            TriggerSpecificationDefinition::RequestPath { .. } => {\n                Err(anyhow!(\"shouldn't have request path trigger for scheduled plugin\").into())\n            }\n            TriggerSpecificationDefinition::Schedule { schedule } => {\n                let schedule = CronSchedule::from_str(schedule.as_str())\n                    .context(\"cron schedule should be parsable\")?;\n                Ok(Self::new_cron(schedule, time_provider))\n            }\n            TriggerSpecificationDefinition::Every { duration } => {\n                // check that duration isn't longer than a year, so we avoid overflows.\n                if *duration > parse_duration(\"1 year\").unwrap() {\n                    return Err(anyhow!(\"schedule duration cannot be greater than 1 year\").into());\n                }\n                Ok(Self::new_every(\n                    Duration::from_std(*duration)\n                        .context(\"should be able to convert durations. \")?,\n                    time_provider,\n                ))\n            }\n        }","sourceCodeStart":157,"sourceCodeEnd":193,"githubUrl":"https://github.com/influxdata/influxdb/blob/06200ef96ba82c5f6727e5038a83af8e722c6875/influxdb3_processing_engine/src/plugins.rs#L157-L193","documentation":"Raised by ScheduleRunner::try_new when a scheduled plugin is constructed with a RequestPath trigger specification. Scheduled plugins cannot be invoked via HTTP request-path triggers; only request-path-capable plugins may use that spec.","triggerScenarios":"Calling try_new with TriggerSpecificationDefinition::RequestPath for a scheduled plugin.","commonSituations":"Admin creates a trigger binding a scheduled plugin to an API endpoint path; confusion between request-trigger plugins and cron plugins.","solutions":["Use a Schedule trigger spec with a cron expression for this plugin.","If HTTP invocation is needed, register the plugin as a request-path plugin instead.","Correct the CREATE TRIGGER statement to drop the request-path spec."],"exampleFix":"// before\nCREATE TRIGGER \"t\" AT GET /write  // for a scheduled plugin\n// after\nCREATE TRIGGER \"t\" ... SCHEDULE '0 * * * *'","handlingStrategy":"validation","validationCode":"fn request_path_allowed(spec: &TriggerSpecificationDefinition, plugin_kind: PluginKind) -> bool {\n    !matches!(spec, TriggerSpecificationDefinition::RequestPath { .. }) || plugin_kind == PluginKind::Request\n}","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Reserve RequestPath specs for request-capable plugins.","Use SCHEDULE specs for cron-driven plugins.","Add CLI/UI validation preventing mismatched trigger-plugin combinations."],"tags":["trigger","http","invalid-argument"],"backgroundTag":"conflicting-config-options","analyzedSha":"06200ef96ba82c5f6727e5038a83af8e722c6875","analyzedAt":"2026-09-19T12:55:30.003Z","contentChangedAt":"2026-09-19T12:55:30.003Z","schemaVersion":2},"datasetVersion":"2026-09-23T08:17:48.524Z"}