From 57ed60b27b378827a8cb67851149d9080b4e32a3 Mon Sep 17 00:00:00 2001 From: dhairya05 Date: Thu, 12 Nov 2026 15:57:25 +0530 Subject: [PATCH 1/3] camel-influxdb2: deprecate retentionPolicy, which has no effect The retentionPolicy endpoint option and the camelInfluxDB.RetentionPolicy header are both declared and documented, and nothing reads either of them. A retention policy is an InfluxDB 1.x concept: its write API takes one per write, and camel-influxdb does pass it, from the same header name. The InfluxDB 2.x API this component calls has no such parameter - retention belongs to the bucket - so InfluxDb2Producer never asks for either value. The header even kept the 1.x spelling, camelInfluxDB.RetentionPolicy, while every other header of this component is CamelInfluxDB2..., which is what gives the copy away. Deprecate both with a note, as camel-aws2-s3vectors' unused headers and camel-tensorflow-serving's target header are deprecated, and say in the description that they are never read. The catalog metadata, the endpoint DSL builder and the 4.24 upgrade guide follow. --- .../org/apache/camel/catalog/components/influxdb2.json | 4 ++-- .../apache/camel/component/influxdb2/influxdb2.json | 4 ++-- .../camel/component/influxdb2/InfluxDb2Constants.java | 7 +++++-- .../camel/component/influxdb2/InfluxDb2Endpoint.java | 6 +++++- .../ROOT/pages/camel-4x-upgrade-guide-4_24.adoc | 10 ++++++++++ .../endpoint/dsl/InfluxDb2EndpointBuilderFactory.java | 6 +++++- 6 files changed, 29 insertions(+), 8 deletions(-) diff --git a/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/influxdb2.json b/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/influxdb2.json index 4de5da9966165..51303849d3829 100644 --- a/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/influxdb2.json +++ b/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/influxdb2.json @@ -30,7 +30,7 @@ }, "headers": { "CamelInfluxDB2MeasurementName": { "index": 0, "kind": "header", "displayName": "", "group": "producer", "label": "", "required": false, "javaType": "String", "deprecated": false, "autowired": false, "secret": false, "description": "The name of measurement", "constantName": "org.apache.camel.component.influxdb2.InfluxDb2Constants#MEASUREMENT" }, - "camelInfluxDB.RetentionPolicy": { "index": 1, "kind": "header", "displayName": "", "group": "producer", "label": "", "required": false, "javaType": "String", "deprecated": false, "autowired": false, "secret": false, "description": "The string that defines the retention policy to the data created by the endpoint", "constantName": "org.apache.camel.component.influxdb2.InfluxDb2Constants#RETENTION_POLICY" }, + "camelInfluxDB.RetentionPolicy": { "index": 1, "kind": "header", "displayName": "", "group": "producer", "label": "", "required": false, "javaType": "String", "deprecated": true, "deprecationNote": "Never read by the component: the InfluxDB 2.x write API has no retention policy, retention is a property of the bucket", "autowired": false, "secret": false, "description": "(deprecated) Never read: InfluxDB 2.x has no per-write retention policy. Deprecation note: Never read by the component: the InfluxDB 2.x write API has no retention policy, retention is a property of the bucket", "constantName": "org.apache.camel.component.influxdb2.InfluxDb2Constants#RETENTION_POLICY" }, "CamelInfluxDB2WritePrecision": { "index": 2, "kind": "header", "displayName": "", "group": "producer", "label": "", "required": false, "javaType": "com.influxdb.client.domain.WritePrecision", "enum": [ "ms", "s", "us", "ns" ], "deprecated": false, "autowired": false, "secret": false, "description": "InfluxDb Write precision.", "constantName": "org.apache.camel.component.influxdb2.InfluxDb2Constants#WRITE_PRECISION" } }, "bodyTypes": { @@ -44,7 +44,7 @@ "bucket": { "index": 3, "kind": "parameter", "displayName": "Bucket", "group": "producer", "label": "", "required": true, "type": "string", "javaType": "java.lang.String", "deprecated": false, "autowired": false, "secret": false, "description": "The name of the bucket where the time series will be stored." }, "operation": { "index": 4, "kind": "parameter", "displayName": "Operation", "group": "producer", "label": "", "required": false, "type": "enum", "javaType": "org.apache.camel.component.influxdb2.enums.Operation", "enum": [ "INSERT", "PING" ], "deprecated": false, "autowired": false, "secret": false, "defaultValue": "INSERT", "description": "Define if this operation is an insert or a ping." }, "org": { "index": 5, "kind": "parameter", "displayName": "Org", "group": "producer", "label": "", "required": true, "type": "string", "javaType": "java.lang.String", "deprecated": false, "autowired": false, "secret": false, "description": "The name of the organization where the time series will be stored." }, - "retentionPolicy": { "index": 6, "kind": "parameter", "displayName": "Retention Policy", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "autowired": false, "secret": false, "defaultValue": "default", "description": "Define the retention policy to the data created by the endpoint." }, + "retentionPolicy": { "index": 6, "kind": "parameter", "displayName": "Retention Policy", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": true, "deprecationNote": "Never read by the component: the InfluxDB 2.x write API has no retention policy, retention is a property of the bucket", "autowired": false, "secret": false, "defaultValue": "default", "description": "(deprecated) Never read: InfluxDB 2.x has no per-write retention policy. Deprecation note: Never read by the component: the InfluxDB 2.x write API has no retention policy, retention is a property of the bucket" }, "writePrecision": { "index": 7, "kind": "parameter", "displayName": "Write Precision", "group": "producer", "label": "", "required": false, "type": "enum", "javaType": "com.influxdb.client.domain.WritePrecision", "enum": [ "ms", "s", "us", "ns" ], "deprecated": false, "autowired": false, "secret": false, "defaultValue": "ms", "description": "The format or precision of time series timestamps." }, "lazyStartProducer": { "index": 8, "kind": "parameter", "displayName": "Lazy Start Producer", "group": "producer (advanced)", "label": "producer,advanced", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "autowired": false, "secret": false, "defaultValue": false, "description": "Whether the producer should be started lazy (on the first message). By starting lazy you can use this to allow CamelContext and routes to startup in situations where a producer may otherwise fail during starting and cause the route to fail being started. By deferring this startup to be lazy then the startup failure can be handled during routing messages via Camel's routing error handlers. Beware that when the first message is processed then creating and starting the producer may take a little time and prolong the total processing time of the processing." } } diff --git a/components/camel-influxdb2/src/generated/resources/META-INF/org/apache/camel/component/influxdb2/influxdb2.json b/components/camel-influxdb2/src/generated/resources/META-INF/org/apache/camel/component/influxdb2/influxdb2.json index 4de5da9966165..51303849d3829 100644 --- a/components/camel-influxdb2/src/generated/resources/META-INF/org/apache/camel/component/influxdb2/influxdb2.json +++ b/components/camel-influxdb2/src/generated/resources/META-INF/org/apache/camel/component/influxdb2/influxdb2.json @@ -30,7 +30,7 @@ }, "headers": { "CamelInfluxDB2MeasurementName": { "index": 0, "kind": "header", "displayName": "", "group": "producer", "label": "", "required": false, "javaType": "String", "deprecated": false, "autowired": false, "secret": false, "description": "The name of measurement", "constantName": "org.apache.camel.component.influxdb2.InfluxDb2Constants#MEASUREMENT" }, - "camelInfluxDB.RetentionPolicy": { "index": 1, "kind": "header", "displayName": "", "group": "producer", "label": "", "required": false, "javaType": "String", "deprecated": false, "autowired": false, "secret": false, "description": "The string that defines the retention policy to the data created by the endpoint", "constantName": "org.apache.camel.component.influxdb2.InfluxDb2Constants#RETENTION_POLICY" }, + "camelInfluxDB.RetentionPolicy": { "index": 1, "kind": "header", "displayName": "", "group": "producer", "label": "", "required": false, "javaType": "String", "deprecated": true, "deprecationNote": "Never read by the component: the InfluxDB 2.x write API has no retention policy, retention is a property of the bucket", "autowired": false, "secret": false, "description": "(deprecated) Never read: InfluxDB 2.x has no per-write retention policy. Deprecation note: Never read by the component: the InfluxDB 2.x write API has no retention policy, retention is a property of the bucket", "constantName": "org.apache.camel.component.influxdb2.InfluxDb2Constants#RETENTION_POLICY" }, "CamelInfluxDB2WritePrecision": { "index": 2, "kind": "header", "displayName": "", "group": "producer", "label": "", "required": false, "javaType": "com.influxdb.client.domain.WritePrecision", "enum": [ "ms", "s", "us", "ns" ], "deprecated": false, "autowired": false, "secret": false, "description": "InfluxDb Write precision.", "constantName": "org.apache.camel.component.influxdb2.InfluxDb2Constants#WRITE_PRECISION" } }, "bodyTypes": { @@ -44,7 +44,7 @@ "bucket": { "index": 3, "kind": "parameter", "displayName": "Bucket", "group": "producer", "label": "", "required": true, "type": "string", "javaType": "java.lang.String", "deprecated": false, "autowired": false, "secret": false, "description": "The name of the bucket where the time series will be stored." }, "operation": { "index": 4, "kind": "parameter", "displayName": "Operation", "group": "producer", "label": "", "required": false, "type": "enum", "javaType": "org.apache.camel.component.influxdb2.enums.Operation", "enum": [ "INSERT", "PING" ], "deprecated": false, "autowired": false, "secret": false, "defaultValue": "INSERT", "description": "Define if this operation is an insert or a ping." }, "org": { "index": 5, "kind": "parameter", "displayName": "Org", "group": "producer", "label": "", "required": true, "type": "string", "javaType": "java.lang.String", "deprecated": false, "autowired": false, "secret": false, "description": "The name of the organization where the time series will be stored." }, - "retentionPolicy": { "index": 6, "kind": "parameter", "displayName": "Retention Policy", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": false, "autowired": false, "secret": false, "defaultValue": "default", "description": "Define the retention policy to the data created by the endpoint." }, + "retentionPolicy": { "index": 6, "kind": "parameter", "displayName": "Retention Policy", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": true, "deprecationNote": "Never read by the component: the InfluxDB 2.x write API has no retention policy, retention is a property of the bucket", "autowired": false, "secret": false, "defaultValue": "default", "description": "(deprecated) Never read: InfluxDB 2.x has no per-write retention policy. Deprecation note: Never read by the component: the InfluxDB 2.x write API has no retention policy, retention is a property of the bucket" }, "writePrecision": { "index": 7, "kind": "parameter", "displayName": "Write Precision", "group": "producer", "label": "", "required": false, "type": "enum", "javaType": "com.influxdb.client.domain.WritePrecision", "enum": [ "ms", "s", "us", "ns" ], "deprecated": false, "autowired": false, "secret": false, "defaultValue": "ms", "description": "The format or precision of time series timestamps." }, "lazyStartProducer": { "index": 8, "kind": "parameter", "displayName": "Lazy Start Producer", "group": "producer (advanced)", "label": "producer,advanced", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "autowired": false, "secret": false, "defaultValue": false, "description": "Whether the producer should be started lazy (on the first message). By starting lazy you can use this to allow CamelContext and routes to startup in situations where a producer may otherwise fail during starting and cause the route to fail being started. By deferring this startup to be lazy then the startup failure can be handled during routing messages via Camel's routing error handlers. Beware that when the first message is processed then creating and starting the producer may take a little time and prolong the total processing time of the processing." } } diff --git a/components/camel-influxdb2/src/main/java/org/apache/camel/component/influxdb2/InfluxDb2Constants.java b/components/camel-influxdb2/src/main/java/org/apache/camel/component/influxdb2/InfluxDb2Constants.java index 10cd39aac4e1a..a1333c02c4434 100644 --- a/components/camel-influxdb2/src/main/java/org/apache/camel/component/influxdb2/InfluxDb2Constants.java +++ b/components/camel-influxdb2/src/main/java/org/apache/camel/component/influxdb2/InfluxDb2Constants.java @@ -21,8 +21,11 @@ public final class InfluxDb2Constants { @Metadata(description = "The name of measurement", javaType = "String") public static final String MEASUREMENT = "CamelInfluxDB2MeasurementName"; - @Metadata(description = "The string that defines the retention policy to the data created by the endpoint", - javaType = "String") + @Metadata(description = "(deprecated) Never read: InfluxDB 2.x has no per-write retention policy", + javaType = "String", + deprecationNote = "Never read by the component: the InfluxDB 2.x write API has no retention policy," + + " retention is a property of the bucket") + @Deprecated public static final String RETENTION_POLICY = "camelInfluxDB.RetentionPolicy"; public static final String ORG = "CamelInfluxDB2Org"; public static final String BUCKET = "CamelInfluxDB2Bucket"; diff --git a/components/camel-influxdb2/src/main/java/org/apache/camel/component/influxdb2/InfluxDb2Endpoint.java b/components/camel-influxdb2/src/main/java/org/apache/camel/component/influxdb2/InfluxDb2Endpoint.java index 47898bdd55efd..6e6e8268858f5 100644 --- a/components/camel-influxdb2/src/main/java/org/apache/camel/component/influxdb2/InfluxDb2Endpoint.java +++ b/components/camel-influxdb2/src/main/java/org/apache/camel/component/influxdb2/InfluxDb2Endpoint.java @@ -79,7 +79,11 @@ public class InfluxDb2Endpoint extends DefaultEndpoint { @UriParam @Metadata(required = true, description = "The name of the bucket where the time series will be stored.") private String bucket; - @UriParam(defaultValue = "default", description = "Define the retention policy to the data created by the endpoint.") + @UriParam(defaultValue = "default", description = "(deprecated) Never read: InfluxDB 2.x has no per-write" + + " retention policy.") + @Metadata(deprecationNote = "Never read by the component: the InfluxDB 2.x write API has no retention policy," + + " retention is a property of the bucket") + @Deprecated private String retentionPolicy = "default"; @UriParam(defaultValue = "INSERT", description = "Define if this operation is an insert or a ping.") diff --git a/docs/user-manual/modules/ROOT/pages/camel-4x-upgrade-guide-4_24.adoc b/docs/user-manual/modules/ROOT/pages/camel-4x-upgrade-guide-4_24.adoc index d072b4110be32..cc8ab4c8acf12 100644 --- a/docs/user-manual/modules/ROOT/pages/camel-4x-upgrade-guide-4_24.adoc +++ b/docs/user-manual/modules/ROOT/pages/camel-4x-upgrade-guide-4_24.adoc @@ -8211,3 +8211,13 @@ not pass a language on; a language header alone turns OCR on, unless the endpoin The language itself is passed to docling untouched, in both forms: it is docling's own identifier (language codes such as `en,de`, BCP-47 tags such as `iso:zh-Hant`, or `script/Latin`), and docling validates it. +=== camel-influxdb2 - the retentionPolicy option and the camelInfluxDB.RetentionPolicy header are deprecated + +Neither has ever had any effect. A retention policy is an InfluxDB 1.x concept: its write API takes one per write, and +`camel-influxdb` passes it there. The InfluxDB 2.x write API that this component calls does not -- retention is a +property of the bucket -- so `InfluxDb2Producer` never reads the option or the header, and both were carried over from +`camel-influxdb` along with the header's 1.x spelling, `camelInfluxDB.RetentionPolicy`. + +Both are now deprecated with a note that says so. Remove `retentionPolicy` from the endpoint URI and stop setting the +header: they are silently ignored. To control how long the data is kept, set the retention period on the bucket the +endpoint writes to. diff --git a/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/InfluxDb2EndpointBuilderFactory.java b/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/InfluxDb2EndpointBuilderFactory.java index 3bd7ab725626b..27b4b944110b7 100644 --- a/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/InfluxDb2EndpointBuilderFactory.java +++ b/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/InfluxDb2EndpointBuilderFactory.java @@ -171,7 +171,10 @@ default InfluxDb2EndpointBuilder org(String org) { return this; } /** - * Define the retention policy to the data created by the endpoint. + * (deprecated) Never read: InfluxDB 2.x has no per-write retention + * policy. Deprecation note: Never read by the component: the InfluxDB + * 2.x write API has no retention policy, retention is a property of the + * bucket. * * The option is a: java.lang.String type. * @@ -181,6 +184,7 @@ default InfluxDb2EndpointBuilder org(String org) { * @param retentionPolicy the value to set * @return the dsl builder */ + @Deprecated default InfluxDb2EndpointBuilder retentionPolicy(String retentionPolicy) { doSetProperty("retentionPolicy", retentionPolicy); return this; From e32e257c9eb2b60b736465e1fd701b85a435fef9 Mon Sep 17 00:00:00 2001 From: Guillaume Nodet Date: Thu, 12 Nov 2026 11:46:25 +0000 Subject: [PATCH 2/3] Regen --- .../camel/component/influxdb2/InfluxDb2Endpoint.java | 2 +- .../endpoint/dsl/InfluxDb2EndpointBuilderFactory.java | 7 +++++-- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/components/camel-influxdb2/src/main/java/org/apache/camel/component/influxdb2/InfluxDb2Endpoint.java b/components/camel-influxdb2/src/main/java/org/apache/camel/component/influxdb2/InfluxDb2Endpoint.java index 6e6e8268858f5..6e54aa9d79680 100644 --- a/components/camel-influxdb2/src/main/java/org/apache/camel/component/influxdb2/InfluxDb2Endpoint.java +++ b/components/camel-influxdb2/src/main/java/org/apache/camel/component/influxdb2/InfluxDb2Endpoint.java @@ -80,7 +80,7 @@ public class InfluxDb2Endpoint extends DefaultEndpoint { @Metadata(required = true, description = "The name of the bucket where the time series will be stored.") private String bucket; @UriParam(defaultValue = "default", description = "(deprecated) Never read: InfluxDB 2.x has no per-write" - + " retention policy.") + + " retention policy.") @Metadata(deprecationNote = "Never read by the component: the InfluxDB 2.x write API has no retention policy," + " retention is a property of the bucket") @Deprecated diff --git a/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/InfluxDb2EndpointBuilderFactory.java b/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/InfluxDb2EndpointBuilderFactory.java index 27b4b944110b7..c21782e57b25c 100644 --- a/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/InfluxDb2EndpointBuilderFactory.java +++ b/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/InfluxDb2EndpointBuilderFactory.java @@ -362,8 +362,10 @@ public String influxDB2MeasurementName() { return "CamelInfluxDB2MeasurementName"; } /** - * The string that defines the retention policy to the data created by - * the endpoint. + * (deprecated) Never read: InfluxDB 2.x has no per-write retention + * policy. Deprecation note: Never read by the component: the InfluxDB + * 2.x write API has no retention policy, retention is a property of the + * bucket. * * The option is a: {@code String} type. * @@ -371,6 +373,7 @@ public String influxDB2MeasurementName() { * * @return the name of the header {@code InfluxDB.RetentionPolicy}. */ + @Deprecated public String influxdbRetentionpolicy() { return "camelInfluxDB.RetentionPolicy"; } From 922728f301710b95ff239590a49e30316f27a2e1 Mon Sep 17 00:00:00 2001 From: dhairya05 Date: Thu, 12 Nov 2026 19:10:51 +0530 Subject: [PATCH 3/3] camel-influxdb2: deprecate the accessors and stop repeating the note Review follow-up on #29709. @Deprecated on the private field does not reach getRetentionPolicy and setRetentionPolicy, so a caller using the endpoint API directly got no compiler warning. Both now carry @Deprecated and a @deprecated tag, as DoclingConfiguration's apiKeyHeader does. The descriptions go back to their original text. Replacing them with "(deprecated) Never read: ..." while the deprecationNote also says "Never read by the component: ..." made the generated text say it twice; the docling precedent keeps the description and puts the explanation only in the note, and the catalog already marks both as deprecated. Both JSON copies and the two DSL javadoc blocks follow. --- .../camel/catalog/components/influxdb2.json | 4 ++-- .../camel/component/influxdb2/influxdb2.json | 4 ++-- .../component/influxdb2/InfluxDb2Constants.java | 2 +- .../component/influxdb2/InfluxDb2Endpoint.java | 13 +++++++++++-- .../ROOT/pages/camel-4x-upgrade-guide-4_24.adoc | 1 + .../dsl/InfluxDb2EndpointBuilderFactory.java | 15 +++++++-------- 6 files changed, 24 insertions(+), 15 deletions(-) diff --git a/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/influxdb2.json b/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/influxdb2.json index 51303849d3829..bb80477b0f952 100644 --- a/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/influxdb2.json +++ b/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/influxdb2.json @@ -30,7 +30,7 @@ }, "headers": { "CamelInfluxDB2MeasurementName": { "index": 0, "kind": "header", "displayName": "", "group": "producer", "label": "", "required": false, "javaType": "String", "deprecated": false, "autowired": false, "secret": false, "description": "The name of measurement", "constantName": "org.apache.camel.component.influxdb2.InfluxDb2Constants#MEASUREMENT" }, - "camelInfluxDB.RetentionPolicy": { "index": 1, "kind": "header", "displayName": "", "group": "producer", "label": "", "required": false, "javaType": "String", "deprecated": true, "deprecationNote": "Never read by the component: the InfluxDB 2.x write API has no retention policy, retention is a property of the bucket", "autowired": false, "secret": false, "description": "(deprecated) Never read: InfluxDB 2.x has no per-write retention policy. Deprecation note: Never read by the component: the InfluxDB 2.x write API has no retention policy, retention is a property of the bucket", "constantName": "org.apache.camel.component.influxdb2.InfluxDb2Constants#RETENTION_POLICY" }, + "camelInfluxDB.RetentionPolicy": { "index": 1, "kind": "header", "displayName": "", "group": "producer", "label": "", "required": false, "javaType": "String", "deprecated": true, "deprecationNote": "Never read by the component: the InfluxDB 2.x write API has no retention policy, retention is a property of the bucket", "autowired": false, "secret": false, "description": "The string that defines the retention policy to the data created by the endpoint. Deprecation note: Never read by the component: the InfluxDB 2.x write API has no retention policy, retention is a property of the bucket", "constantName": "org.apache.camel.component.influxdb2.InfluxDb2Constants#RETENTION_POLICY" }, "CamelInfluxDB2WritePrecision": { "index": 2, "kind": "header", "displayName": "", "group": "producer", "label": "", "required": false, "javaType": "com.influxdb.client.domain.WritePrecision", "enum": [ "ms", "s", "us", "ns" ], "deprecated": false, "autowired": false, "secret": false, "description": "InfluxDb Write precision.", "constantName": "org.apache.camel.component.influxdb2.InfluxDb2Constants#WRITE_PRECISION" } }, "bodyTypes": { @@ -44,7 +44,7 @@ "bucket": { "index": 3, "kind": "parameter", "displayName": "Bucket", "group": "producer", "label": "", "required": true, "type": "string", "javaType": "java.lang.String", "deprecated": false, "autowired": false, "secret": false, "description": "The name of the bucket where the time series will be stored." }, "operation": { "index": 4, "kind": "parameter", "displayName": "Operation", "group": "producer", "label": "", "required": false, "type": "enum", "javaType": "org.apache.camel.component.influxdb2.enums.Operation", "enum": [ "INSERT", "PING" ], "deprecated": false, "autowired": false, "secret": false, "defaultValue": "INSERT", "description": "Define if this operation is an insert or a ping." }, "org": { "index": 5, "kind": "parameter", "displayName": "Org", "group": "producer", "label": "", "required": true, "type": "string", "javaType": "java.lang.String", "deprecated": false, "autowired": false, "secret": false, "description": "The name of the organization where the time series will be stored." }, - "retentionPolicy": { "index": 6, "kind": "parameter", "displayName": "Retention Policy", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": true, "deprecationNote": "Never read by the component: the InfluxDB 2.x write API has no retention policy, retention is a property of the bucket", "autowired": false, "secret": false, "defaultValue": "default", "description": "(deprecated) Never read: InfluxDB 2.x has no per-write retention policy. Deprecation note: Never read by the component: the InfluxDB 2.x write API has no retention policy, retention is a property of the bucket" }, + "retentionPolicy": { "index": 6, "kind": "parameter", "displayName": "Retention Policy", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": true, "deprecationNote": "Never read by the component: the InfluxDB 2.x write API has no retention policy, retention is a property of the bucket", "autowired": false, "secret": false, "defaultValue": "default", "description": "Define the retention policy to the data created by the endpoint. Deprecation note: Never read by the component: the InfluxDB 2.x write API has no retention policy, retention is a property of the bucket" }, "writePrecision": { "index": 7, "kind": "parameter", "displayName": "Write Precision", "group": "producer", "label": "", "required": false, "type": "enum", "javaType": "com.influxdb.client.domain.WritePrecision", "enum": [ "ms", "s", "us", "ns" ], "deprecated": false, "autowired": false, "secret": false, "defaultValue": "ms", "description": "The format or precision of time series timestamps." }, "lazyStartProducer": { "index": 8, "kind": "parameter", "displayName": "Lazy Start Producer", "group": "producer (advanced)", "label": "producer,advanced", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "autowired": false, "secret": false, "defaultValue": false, "description": "Whether the producer should be started lazy (on the first message). By starting lazy you can use this to allow CamelContext and routes to startup in situations where a producer may otherwise fail during starting and cause the route to fail being started. By deferring this startup to be lazy then the startup failure can be handled during routing messages via Camel's routing error handlers. Beware that when the first message is processed then creating and starting the producer may take a little time and prolong the total processing time of the processing." } } diff --git a/components/camel-influxdb2/src/generated/resources/META-INF/org/apache/camel/component/influxdb2/influxdb2.json b/components/camel-influxdb2/src/generated/resources/META-INF/org/apache/camel/component/influxdb2/influxdb2.json index 51303849d3829..bb80477b0f952 100644 --- a/components/camel-influxdb2/src/generated/resources/META-INF/org/apache/camel/component/influxdb2/influxdb2.json +++ b/components/camel-influxdb2/src/generated/resources/META-INF/org/apache/camel/component/influxdb2/influxdb2.json @@ -30,7 +30,7 @@ }, "headers": { "CamelInfluxDB2MeasurementName": { "index": 0, "kind": "header", "displayName": "", "group": "producer", "label": "", "required": false, "javaType": "String", "deprecated": false, "autowired": false, "secret": false, "description": "The name of measurement", "constantName": "org.apache.camel.component.influxdb2.InfluxDb2Constants#MEASUREMENT" }, - "camelInfluxDB.RetentionPolicy": { "index": 1, "kind": "header", "displayName": "", "group": "producer", "label": "", "required": false, "javaType": "String", "deprecated": true, "deprecationNote": "Never read by the component: the InfluxDB 2.x write API has no retention policy, retention is a property of the bucket", "autowired": false, "secret": false, "description": "(deprecated) Never read: InfluxDB 2.x has no per-write retention policy. Deprecation note: Never read by the component: the InfluxDB 2.x write API has no retention policy, retention is a property of the bucket", "constantName": "org.apache.camel.component.influxdb2.InfluxDb2Constants#RETENTION_POLICY" }, + "camelInfluxDB.RetentionPolicy": { "index": 1, "kind": "header", "displayName": "", "group": "producer", "label": "", "required": false, "javaType": "String", "deprecated": true, "deprecationNote": "Never read by the component: the InfluxDB 2.x write API has no retention policy, retention is a property of the bucket", "autowired": false, "secret": false, "description": "The string that defines the retention policy to the data created by the endpoint. Deprecation note: Never read by the component: the InfluxDB 2.x write API has no retention policy, retention is a property of the bucket", "constantName": "org.apache.camel.component.influxdb2.InfluxDb2Constants#RETENTION_POLICY" }, "CamelInfluxDB2WritePrecision": { "index": 2, "kind": "header", "displayName": "", "group": "producer", "label": "", "required": false, "javaType": "com.influxdb.client.domain.WritePrecision", "enum": [ "ms", "s", "us", "ns" ], "deprecated": false, "autowired": false, "secret": false, "description": "InfluxDb Write precision.", "constantName": "org.apache.camel.component.influxdb2.InfluxDb2Constants#WRITE_PRECISION" } }, "bodyTypes": { @@ -44,7 +44,7 @@ "bucket": { "index": 3, "kind": "parameter", "displayName": "Bucket", "group": "producer", "label": "", "required": true, "type": "string", "javaType": "java.lang.String", "deprecated": false, "autowired": false, "secret": false, "description": "The name of the bucket where the time series will be stored." }, "operation": { "index": 4, "kind": "parameter", "displayName": "Operation", "group": "producer", "label": "", "required": false, "type": "enum", "javaType": "org.apache.camel.component.influxdb2.enums.Operation", "enum": [ "INSERT", "PING" ], "deprecated": false, "autowired": false, "secret": false, "defaultValue": "INSERT", "description": "Define if this operation is an insert or a ping." }, "org": { "index": 5, "kind": "parameter", "displayName": "Org", "group": "producer", "label": "", "required": true, "type": "string", "javaType": "java.lang.String", "deprecated": false, "autowired": false, "secret": false, "description": "The name of the organization where the time series will be stored." }, - "retentionPolicy": { "index": 6, "kind": "parameter", "displayName": "Retention Policy", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": true, "deprecationNote": "Never read by the component: the InfluxDB 2.x write API has no retention policy, retention is a property of the bucket", "autowired": false, "secret": false, "defaultValue": "default", "description": "(deprecated) Never read: InfluxDB 2.x has no per-write retention policy. Deprecation note: Never read by the component: the InfluxDB 2.x write API has no retention policy, retention is a property of the bucket" }, + "retentionPolicy": { "index": 6, "kind": "parameter", "displayName": "Retention Policy", "group": "producer", "label": "", "required": false, "type": "string", "javaType": "java.lang.String", "deprecated": true, "deprecationNote": "Never read by the component: the InfluxDB 2.x write API has no retention policy, retention is a property of the bucket", "autowired": false, "secret": false, "defaultValue": "default", "description": "Define the retention policy to the data created by the endpoint. Deprecation note: Never read by the component: the InfluxDB 2.x write API has no retention policy, retention is a property of the bucket" }, "writePrecision": { "index": 7, "kind": "parameter", "displayName": "Write Precision", "group": "producer", "label": "", "required": false, "type": "enum", "javaType": "com.influxdb.client.domain.WritePrecision", "enum": [ "ms", "s", "us", "ns" ], "deprecated": false, "autowired": false, "secret": false, "defaultValue": "ms", "description": "The format or precision of time series timestamps." }, "lazyStartProducer": { "index": 8, "kind": "parameter", "displayName": "Lazy Start Producer", "group": "producer (advanced)", "label": "producer,advanced", "required": false, "type": "boolean", "javaType": "boolean", "deprecated": false, "autowired": false, "secret": false, "defaultValue": false, "description": "Whether the producer should be started lazy (on the first message). By starting lazy you can use this to allow CamelContext and routes to startup in situations where a producer may otherwise fail during starting and cause the route to fail being started. By deferring this startup to be lazy then the startup failure can be handled during routing messages via Camel's routing error handlers. Beware that when the first message is processed then creating and starting the producer may take a little time and prolong the total processing time of the processing." } } diff --git a/components/camel-influxdb2/src/main/java/org/apache/camel/component/influxdb2/InfluxDb2Constants.java b/components/camel-influxdb2/src/main/java/org/apache/camel/component/influxdb2/InfluxDb2Constants.java index a1333c02c4434..858dc4fc2508c 100644 --- a/components/camel-influxdb2/src/main/java/org/apache/camel/component/influxdb2/InfluxDb2Constants.java +++ b/components/camel-influxdb2/src/main/java/org/apache/camel/component/influxdb2/InfluxDb2Constants.java @@ -21,7 +21,7 @@ public final class InfluxDb2Constants { @Metadata(description = "The name of measurement", javaType = "String") public static final String MEASUREMENT = "CamelInfluxDB2MeasurementName"; - @Metadata(description = "(deprecated) Never read: InfluxDB 2.x has no per-write retention policy", + @Metadata(description = "The string that defines the retention policy to the data created by the endpoint", javaType = "String", deprecationNote = "Never read by the component: the InfluxDB 2.x write API has no retention policy," + " retention is a property of the bucket") diff --git a/components/camel-influxdb2/src/main/java/org/apache/camel/component/influxdb2/InfluxDb2Endpoint.java b/components/camel-influxdb2/src/main/java/org/apache/camel/component/influxdb2/InfluxDb2Endpoint.java index 6e54aa9d79680..e98bd5e2fd47c 100644 --- a/components/camel-influxdb2/src/main/java/org/apache/camel/component/influxdb2/InfluxDb2Endpoint.java +++ b/components/camel-influxdb2/src/main/java/org/apache/camel/component/influxdb2/InfluxDb2Endpoint.java @@ -79,8 +79,7 @@ public class InfluxDb2Endpoint extends DefaultEndpoint { @UriParam @Metadata(required = true, description = "The name of the bucket where the time series will be stored.") private String bucket; - @UriParam(defaultValue = "default", description = "(deprecated) Never read: InfluxDB 2.x has no per-write" - + " retention policy.") + @UriParam(defaultValue = "default", description = "Define the retention policy to the data created by the endpoint.") @Metadata(deprecationNote = "Never read by the component: the InfluxDB 2.x write API has no retention policy," + " retention is a property of the bucket") @Deprecated @@ -138,10 +137,20 @@ public void setBucket(String bucket) { this.bucket = bucket; } + /** + * @deprecated Never read by the component: the InfluxDB 2.x write API has no retention policy, retention is a + * property of the bucket + */ + @Deprecated public String getRetentionPolicy() { return retentionPolicy; } + /** + * @deprecated Never read by the component: the InfluxDB 2.x write API has no retention policy, retention is a + * property of the bucket + */ + @Deprecated public void setRetentionPolicy(String retentionPolicy) { this.retentionPolicy = retentionPolicy; } diff --git a/docs/user-manual/modules/ROOT/pages/camel-4x-upgrade-guide-4_24.adoc b/docs/user-manual/modules/ROOT/pages/camel-4x-upgrade-guide-4_24.adoc index cc8ab4c8acf12..d959d2cb758d6 100644 --- a/docs/user-manual/modules/ROOT/pages/camel-4x-upgrade-guide-4_24.adoc +++ b/docs/user-manual/modules/ROOT/pages/camel-4x-upgrade-guide-4_24.adoc @@ -8211,6 +8211,7 @@ not pass a language on; a language header alone turns OCR on, unless the endpoin The language itself is passed to docling untouched, in both forms: it is docling's own identifier (language codes such as `en,de`, BCP-47 tags such as `iso:zh-Hant`, or `script/Latin`), and docling validates it. + === camel-influxdb2 - the retentionPolicy option and the camelInfluxDB.RetentionPolicy header are deprecated Neither has ever had any effect. A retention policy is an InfluxDB 1.x concept: its write API takes one per write, and diff --git a/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/InfluxDb2EndpointBuilderFactory.java b/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/InfluxDb2EndpointBuilderFactory.java index c21782e57b25c..8ed6012687144 100644 --- a/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/InfluxDb2EndpointBuilderFactory.java +++ b/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/InfluxDb2EndpointBuilderFactory.java @@ -171,10 +171,9 @@ default InfluxDb2EndpointBuilder org(String org) { return this; } /** - * (deprecated) Never read: InfluxDB 2.x has no per-write retention - * policy. Deprecation note: Never read by the component: the InfluxDB - * 2.x write API has no retention policy, retention is a property of the - * bucket. + * Define the retention policy to the data created by the endpoint. + * Deprecation note: Never read by the component: the InfluxDB 2.x write + * API has no retention policy, retention is a property of the bucket. * * The option is a: java.lang.String type. * @@ -362,10 +361,10 @@ public String influxDB2MeasurementName() { return "CamelInfluxDB2MeasurementName"; } /** - * (deprecated) Never read: InfluxDB 2.x has no per-write retention - * policy. Deprecation note: Never read by the component: the InfluxDB - * 2.x write API has no retention policy, retention is a property of the - * bucket. + * The string that defines the retention policy to the data created by + * the endpoint. Deprecation note: Never read by the component: the + * InfluxDB 2.x write API has no retention policy, retention is a + * property of the bucket. * * The option is a: {@code String} type. *