This is an automated email from the ASF dual-hosted git repository.
tsato pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/camel.git
The following commit(s) were added to refs/heads/main by this push:
new 235b9a9fad0 camel-ai - Add torchserve and tensorflow-serving to
catalog (#16892)
235b9a9fad0 is described below
commit 235b9a9fad0a3b2956b062a83f685facfded883c
Author: Tadayoshi Sato <[email protected]>
AuthorDate: Thu Jan 23 15:32:12 2025 +0900
camel-ai - Add torchserve and tensorflow-serving to catalog (#16892)
* camel-ai - Add torchserve and tensorflow-serving to catalog
* Regen
---
.../org/apache/camel/catalog/components.properties | 2 +
.../catalog/components/tensorflow-serving.json | 55 ++
.../camel/catalog/components/torchserve.json | 83 +++
.../org/apache/camel/main/components.properties | 2 +
.../component/ComponentsBuilderFactory.java | 28 +
.../TensorflowServingComponentBuilderFactory.java | 248 ++++++++
.../dsl/TorchserveComponentBuilderFactory.java | 475 ++++++++++++++
.../builder/endpoint/EndpointBuilderFactory.java | 2 +
.../camel/builder/endpoint/EndpointBuilders.java | 2 +
.../builder/endpoint/StaticEndpointBuilders.java | 104 ++++
.../TensorFlowServingEndpointBuilderFactory.java | 387 ++++++++++++
.../dsl/TorchServeEndpointBuilderFactory.java | 683 +++++++++++++++++++++
.../camel-component-known-dependencies.properties | 2 +
.../apache/camel/maven/packaging/MojoHelper.java | 3 +-
14 files changed, 2075 insertions(+), 1 deletion(-)
diff --git
a/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components.properties
b/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components.properties
index 3502089f41a..df0aaa04167 100644
---
a/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components.properties
+++
b/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components.properties
@@ -320,10 +320,12 @@ stub
tahu-edge
tahu-host
telegram
+tensorflow-serving
thrift
thymeleaf
tika
timer
+torchserve
twilio
twitter-directmessage
twitter-search
diff --git
a/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/tensorflow-serving.json
b/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/tensorflow-serving.json
new file mode 100644
index 00000000000..40aada7b3f6
--- /dev/null
+++
b/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/tensorflow-serving.json
@@ -0,0 +1,55 @@
+{
+ "component": {
+ "kind": "component",
+ "name": "tensorflow-serving",
+ "title": "TensorFlow Serving",
+ "description": "Provide access to TensorFlow Serving model servers to run
inference with TensorFlow saved models remotely",
+ "deprecated": false,
+ "firstVersion": "4.10.0",
+ "label": "ai",
+ "javaType":
"org.apache.camel.component.tensorflow.serving.TensorFlowServingComponent",
+ "supportLevel": "Preview",
+ "groupId": "org.apache.camel",
+ "artifactId": "camel-tensorflow-serving",
+ "version": "4.10.0-SNAPSHOT",
+ "scheme": "tensorflow-serving",
+ "extendsScheme": "",
+ "syntax": "tensorflow-serving:api",
+ "async": false,
+ "api": false,
+ "consumerOnly": false,
+ "producerOnly": true,
+ "lenientProperties": false,
+ "browsable": false,
+ "remote": true
+ },
+ "componentProperties": {
+ "configuration": { "index": 0, "kind": "property", "displayName":
"Configuration", "group": "producer", "label": "", "required": false, "type":
"object", "javaType":
"org.apache.camel.component.tensorflow.serving.TensorFlowServingConfiguration",
"deprecated": false, "autowired": false, "secret": false, "description": "The
configuration." },
+ "modelName": { "index": 1, "kind": "property", "displayName": "Model
Name", "group": "common", "label": "common", "required": false, "type":
"string", "javaType": "java.lang.String", "deprecated": false, "autowired":
false, "secret": false, "configurationClass":
"org.apache.camel.component.tensorflow.serving.TensorFlowServingConfiguration",
"configurationField": "configuration", "description": "Required servable name."
},
+ "modelVersion": { "index": 2, "kind": "property", "displayName": "Model
Version", "group": "common", "label": "common", "required": false, "type":
"integer", "javaType": "java.lang.Long", "deprecated": false, "autowired":
false, "secret": false, "configurationClass":
"org.apache.camel.component.tensorflow.serving.TensorFlowServingConfiguration",
"configurationField": "configuration", "description": "Optional choice of which
version of the model to use. Use this specific version number." },
+ "modelVersionLabel": { "index": 3, "kind": "property", "displayName":
"Model Version Label", "group": "common", "label": "common", "required": false,
"type": "string", "javaType": "java.lang.String", "deprecated": false,
"autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.tensorflow.serving.TensorFlowServingConfiguration",
"configurationField": "configuration", "description": "Optional choice of which
version of the model to use. Use the version ass [...]
+ "signatureName": { "index": 4, "kind": "property", "displayName":
"Signature Name", "group": "common", "label": "common", "required": false,
"type": "string", "javaType": "java.lang.String", "deprecated": false,
"autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.tensorflow.serving.TensorFlowServingConfiguration",
"configurationField": "configuration", "description": "A named signature to
evaluate. If unspecified, the default signature will be used." },
+ "target": { "index": 5, "kind": "property", "displayName": "Target",
"group": "common", "label": "common", "required": false, "type": "string",
"javaType": "java.lang.String", "deprecated": false, "autowired": false,
"secret": false, "defaultValue": "localhost:8500", "configurationClass":
"org.apache.camel.component.tensorflow.serving.TensorFlowServingConfiguration",
"configurationField": "configuration", "description": "The target URI of the
client. See: https:\/\/grpc.github.io\/gr [...]
+ "lazyStartProducer": { "index": 6, "kind": "property", "displayName":
"Lazy Start Producer", "group": "producer", "label": "producer", "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 [...]
+ "autowiredEnabled": { "index": 7, "kind": "property", "displayName":
"Autowired Enabled", "group": "advanced", "label": "advanced", "required":
false, "type": "boolean", "javaType": "boolean", "deprecated": false,
"autowired": false, "secret": false, "defaultValue": true, "description":
"Whether autowiring is enabled. This is used for automatic autowiring options
(the option must be marked as autowired) by looking up in the registry to find
if there is a single instance of matching t [...]
+ "credentials": { "index": 8, "kind": "property", "displayName":
"Credentials", "group": "security", "label": "security", "required": false,
"type": "object", "javaType": "io.grpc.ChannelCredentials", "deprecated":
false, "autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.tensorflow.serving.TensorFlowServingConfiguration",
"configurationField": "configuration", "description": "The credentials of the
client." }
+ },
+ "headers": {
+ "CamelTensorFlowServingTarget": { "index": 0, "kind": "header",
"displayName": "", "group": "producer", "label": "", "required": false,
"javaType": "String", "deprecated": false, "deprecationNote": "", "autowired":
false, "secret": false, "description": "The target of the client. See:
https:\/\/grpc.github.io\/grpc-java\/javadoc\/io\/grpc\/Grpc.html#newChannelBuilder%28java.lang.String,io.grpc.ChannelCredentials%29",
"constantName": "org.apache.camel.component.tensorflow.serving.Tens [...]
+ "CamelTensorFlowServingCredentials": { "index": 1, "kind": "header",
"displayName": "", "group": "producer", "label": "", "required": false,
"javaType": "io.grpc.ChannelCredentials", "deprecated": false,
"deprecationNote": "", "autowired": false, "secret": false, "description": "The
credentials of the client.", "constantName":
"org.apache.camel.component.tensorflow.serving.TensorFlowServingConstants#CREDENTIALS"
},
+ "CamelTensorFlowServingModelName": { "index": 2, "kind": "header",
"displayName": "", "group": "producer", "label": "", "required": false,
"javaType": "String", "deprecated": false, "deprecationNote": "", "autowired":
false, "secret": false, "description": "Required servable name.",
"constantName":
"org.apache.camel.component.tensorflow.serving.TensorFlowServingConstants#MODEL_NAME"
},
+ "CamelTensorFlowServingModelVersion": { "index": 3, "kind": "header",
"displayName": "", "group": "producer", "label": "", "required": false,
"javaType": "long", "deprecated": false, "deprecationNote": "", "autowired":
false, "secret": false, "description": "Optional choice of which version of the
model to use. Use this specific version number.", "constantName":
"org.apache.camel.component.tensorflow.serving.TensorFlowServingConstants#MODEL_VERSION"
},
+ "CamelTensorFlowServingModelVersionLabel": { "index": 4, "kind": "header",
"displayName": "", "group": "producer", "label": "", "required": false,
"javaType": "String", "deprecated": false, "deprecationNote": "", "autowired":
false, "secret": false, "description": "Optional choice of which version of the
model to use. Use the version associated with the given label.",
"constantName":
"org.apache.camel.component.tensorflow.serving.TensorFlowServingConstants#MODEL_VERSION_LABEL"
},
+ "CamelTensorFlowServingSignatureName": { "index": 5, "kind": "header",
"displayName": "", "group": "producer", "label": "", "required": false,
"javaType": "String", "deprecated": false, "deprecationNote": "", "autowired":
false, "secret": false, "description": "A named signature to evaluate. If
unspecified, the default signature will be used.", "constantName":
"org.apache.camel.component.tensorflow.serving.TensorFlowServingConstants#SIGNATURE_NAME"
}
+ },
+ "properties": {
+ "api": { "index": 0, "kind": "path", "displayName": "Api", "group":
"producer", "label": "", "required": true, "type": "string", "javaType":
"java.lang.String", "enum": [ "model-status", "model-metadata", "classify",
"regress", "predict" ], "deprecated": false, "deprecationNote": "",
"autowired": false, "secret": false, "description": "The TensorFlow Serving
API" },
+ "modelName": { "index": 1, "kind": "parameter", "displayName": "Model
Name", "group": "common", "label": "common", "required": false, "type":
"string", "javaType": "java.lang.String", "deprecated": false, "autowired":
false, "secret": false, "configurationClass":
"org.apache.camel.component.tensorflow.serving.TensorFlowServingConfiguration",
"configurationField": "configuration", "description": "Required servable name."
},
+ "modelVersion": { "index": 2, "kind": "parameter", "displayName": "Model
Version", "group": "common", "label": "common", "required": false, "type":
"integer", "javaType": "java.lang.Long", "deprecated": false, "autowired":
false, "secret": false, "configurationClass":
"org.apache.camel.component.tensorflow.serving.TensorFlowServingConfiguration",
"configurationField": "configuration", "description": "Optional choice of which
version of the model to use. Use this specific version number." },
+ "modelVersionLabel": { "index": 3, "kind": "parameter", "displayName":
"Model Version Label", "group": "common", "label": "common", "required": false,
"type": "string", "javaType": "java.lang.String", "deprecated": false,
"autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.tensorflow.serving.TensorFlowServingConfiguration",
"configurationField": "configuration", "description": "Optional choice of which
version of the model to use. Use the version as [...]
+ "signatureName": { "index": 4, "kind": "parameter", "displayName":
"Signature Name", "group": "common", "label": "common", "required": false,
"type": "string", "javaType": "java.lang.String", "deprecated": false,
"autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.tensorflow.serving.TensorFlowServingConfiguration",
"configurationField": "configuration", "description": "A named signature to
evaluate. If unspecified, the default signature will be used." },
+ "target": { "index": 5, "kind": "parameter", "displayName": "Target",
"group": "common", "label": "common", "required": false, "type": "string",
"javaType": "java.lang.String", "deprecated": false, "autowired": false,
"secret": false, "defaultValue": "localhost:8500", "configurationClass":
"org.apache.camel.component.tensorflow.serving.TensorFlowServingConfiguration",
"configurationField": "configuration", "description": "The target URI of the
client. See: https:\/\/grpc.github.io\/g [...]
+ "lazyStartProducer": { "index": 6, "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 produc [...]
+ "credentials": { "index": 7, "kind": "parameter", "displayName":
"Credentials", "group": "security", "label": "security", "required": false,
"type": "object", "javaType": "io.grpc.ChannelCredentials", "deprecated":
false, "autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.tensorflow.serving.TensorFlowServingConfiguration",
"configurationField": "configuration", "description": "The credentials of the
client." }
+ }
+}
diff --git
a/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/torchserve.json
b/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/torchserve.json
new file mode 100644
index 00000000000..ff565ade6b2
--- /dev/null
+++
b/catalog/camel-catalog/src/generated/resources/org/apache/camel/catalog/components/torchserve.json
@@ -0,0 +1,83 @@
+{
+ "component": {
+ "kind": "component",
+ "name": "torchserve",
+ "title": "TorchServe",
+ "description": "Provide access to PyTorch TorchServe servers to run
inference with PyTorch models remotely",
+ "deprecated": false,
+ "firstVersion": "4.9.0",
+ "label": "ai",
+ "javaType": "org.apache.camel.component.torchserve.TorchServeComponent",
+ "supportLevel": "Preview",
+ "groupId": "org.apache.camel",
+ "artifactId": "camel-torchserve",
+ "version": "4.10.0-SNAPSHOT",
+ "scheme": "torchserve",
+ "extendsScheme": "",
+ "syntax": "torchserve:api\/operation",
+ "async": false,
+ "api": false,
+ "consumerOnly": false,
+ "producerOnly": true,
+ "lenientProperties": false,
+ "browsable": false,
+ "remote": true
+ },
+ "componentProperties": {
+ "configuration": { "index": 0, "kind": "property", "displayName":
"Configuration", "group": "producer", "label": "", "required": false, "type":
"object", "javaType":
"org.apache.camel.component.torchserve.TorchServeConfiguration", "deprecated":
false, "autowired": false, "secret": false, "description": "The configuration."
},
+ "modelName": { "index": 1, "kind": "property", "displayName": "Model
Name", "group": "common", "label": "common", "required": false, "type":
"string", "javaType": "java.lang.String", "deprecated": false, "autowired":
false, "secret": false, "configurationClass":
"org.apache.camel.component.torchserve.TorchServeConfiguration",
"configurationField": "configuration", "description": "The name of model." },
+ "modelVersion": { "index": 2, "kind": "property", "displayName": "Model
Version", "group": "common", "label": "common", "required": false, "type":
"string", "javaType": "java.lang.String", "deprecated": false, "autowired":
false, "secret": false, "configurationClass":
"org.apache.camel.component.torchserve.TorchServeConfiguration",
"configurationField": "configuration", "description": "The version of model." },
+ "lazyStartProducer": { "index": 3, "kind": "property", "displayName":
"Lazy Start Producer", "group": "producer", "label": "producer", "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 [...]
+ "autowiredEnabled": { "index": 4, "kind": "property", "displayName":
"Autowired Enabled", "group": "advanced", "label": "advanced", "required":
false, "type": "boolean", "javaType": "boolean", "deprecated": false,
"autowired": false, "secret": false, "defaultValue": true, "description":
"Whether autowiring is enabled. This is used for automatic autowiring options
(the option must be marked as autowired) by looking up in the registry to find
if there is a single instance of matching t [...]
+ "healthCheckConsumerEnabled": { "index": 5, "kind": "property",
"displayName": "Health Check Consumer Enabled", "group": "health", "label":
"health", "required": false, "type": "boolean", "javaType": "boolean",
"deprecated": false, "autowired": false, "secret": false, "defaultValue": true,
"description": "Used for enabling or disabling all consumer based health checks
from this component" },
+ "healthCheckProducerEnabled": { "index": 6, "kind": "property",
"displayName": "Health Check Producer Enabled", "group": "health", "label":
"health", "required": false, "type": "boolean", "javaType": "boolean",
"deprecated": false, "autowired": false, "secret": false, "defaultValue": true,
"description": "Used for enabling or disabling all producer based health checks
from this component. Notice: Camel has by default disabled all producer based
health-checks. You can turn on producer [...]
+ "inferenceAddress": { "index": 7, "kind": "property", "displayName":
"Inference Address", "group": "inference", "label": "inference", "required":
false, "type": "string", "javaType": "java.lang.String", "deprecated": false,
"autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.torchserve.TorchServeConfiguration",
"configurationField": "configuration", "description": "The address of the
inference API endpoint." },
+ "inferencePort": { "index": 8, "kind": "property", "displayName":
"Inference Port", "group": "inference", "label": "inference", "required":
false, "type": "integer", "javaType": "int", "deprecated": false, "autowired":
false, "secret": false, "defaultValue": 8080, "configurationClass":
"org.apache.camel.component.torchserve.TorchServeConfiguration",
"configurationField": "configuration", "description": "The port of the
inference API endpoint." },
+ "listLimit": { "index": 9, "kind": "property", "displayName": "List
Limit", "group": "management", "label": "management", "required": false,
"type": "integer", "javaType": "int", "deprecated": false, "autowired": false,
"secret": false, "defaultValue": 100, "configurationClass":
"org.apache.camel.component.torchserve.TorchServeConfiguration",
"configurationField": "configuration", "description": "The maximum number of
items to return for the list operation. When this value is present [...]
+ "listNextPageToken": { "index": 10, "kind": "property", "displayName":
"List Next Page Token", "group": "management", "label": "management",
"required": false, "type": "string", "javaType": "java.lang.String",
"deprecated": false, "autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.torchserve.TorchServeConfiguration",
"configurationField": "configuration", "description": "The token to retrieve
the next set of results for the list operation. TorchSer [...]
+ "managementAddress": { "index": 11, "kind": "property", "displayName":
"Management Address", "group": "management", "label": "management", "required":
false, "type": "string", "javaType": "java.lang.String", "deprecated": false,
"autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.torchserve.TorchServeConfiguration",
"configurationField": "configuration", "description": "The address of the
management API endpoint." },
+ "managementPort": { "index": 12, "kind": "property", "displayName":
"Management Port", "group": "management", "label": "management", "required":
false, "type": "integer", "javaType": "int", "deprecated": false, "autowired":
false, "secret": false, "defaultValue": 8081, "configurationClass":
"org.apache.camel.component.torchserve.TorchServeConfiguration",
"configurationField": "configuration", "description": "The port of the
management API endpoint." },
+ "registerOptions": { "index": 13, "kind": "property", "displayName":
"Register Options", "group": "management", "label": "management", "required":
false, "type": "object", "javaType":
"org.apache.camel.component.torchserve.client.model.RegisterOptions",
"deprecated": false, "autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.torchserve.TorchServeConfiguration",
"configurationField": "configuration", "description": "Additional options for
the registe [...]
+ "scaleWorkerOptions": { "index": 14, "kind": "property", "displayName":
"Scale Worker Options", "group": "management", "label": "management",
"required": false, "type": "object", "javaType":
"org.apache.camel.component.torchserve.client.model.ScaleWorkerOptions",
"deprecated": false, "autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.torchserve.TorchServeConfiguration",
"configurationField": "configuration", "description": "Additional options for t
[...]
+ "unregisterOptions": { "index": 15, "kind": "property", "displayName":
"Unregister Options", "group": "management", "label": "management", "required":
false, "type": "object", "javaType":
"org.apache.camel.component.torchserve.client.model.UnregisterOptions",
"deprecated": false, "autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.torchserve.TorchServeConfiguration",
"configurationField": "configuration", "description": "Additional options for
the u [...]
+ "url": { "index": 16, "kind": "property", "displayName": "Url", "group":
"management", "label": "management", "required": false, "type": "string",
"javaType": "java.lang.String", "deprecated": false, "autowired": false,
"secret": false, "configurationClass":
"org.apache.camel.component.torchserve.TorchServeConfiguration",
"configurationField": "configuration", "description": "Model archive download
url, support local file or HTTP(s) protocol. For S3, consider using pre-signed
url." },
+ "metricsAddress": { "index": 17, "kind": "property", "displayName":
"Metrics Address", "group": "metrics", "label": "metrics", "required": false,
"type": "string", "javaType": "java.lang.String", "deprecated": false,
"autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.torchserve.TorchServeConfiguration",
"configurationField": "configuration", "description": "The address of the
metrics API endpoint." },
+ "metricsName": { "index": 18, "kind": "property", "displayName": "Metrics
Name", "group": "metrics", "label": "metrics", "required": false, "type":
"string", "javaType": "java.lang.String", "deprecated": false, "autowired":
false, "secret": false, "configurationClass":
"org.apache.camel.component.torchserve.TorchServeConfiguration",
"configurationField": "configuration", "description": "Names of metrics to
filter." },
+ "metricsPort": { "index": 19, "kind": "property", "displayName": "Metrics
Port", "group": "metrics", "label": "metrics", "required": false, "type":
"integer", "javaType": "int", "deprecated": false, "autowired": false,
"secret": false, "defaultValue": 8082, "configurationClass":
"org.apache.camel.component.torchserve.TorchServeConfiguration",
"configurationField": "configuration", "description": "The port of the metrics
API endpoint." },
+ "inferenceKey": { "index": 20, "kind": "property", "displayName":
"Inference Key", "group": "security", "label": "inference,security",
"required": false, "type": "string", "javaType": "java.lang.String",
"deprecated": false, "autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.torchserve.TorchServeConfiguration",
"configurationField": "configuration", "description": "The token authorization
key for accessing the inference API." },
+ "managementKey": { "index": 21, "kind": "property", "displayName":
"Management Key", "group": "security", "label": "management,security",
"required": false, "type": "string", "javaType": "java.lang.String",
"deprecated": false, "autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.torchserve.TorchServeConfiguration",
"configurationField": "configuration", "description": "The token authorization
key for accessing the management API." }
+ },
+ "headers": {
+ "CamelTorchServeModelName": { "index": 0, "kind": "header", "displayName":
"", "group": "producer", "label": "", "required": false, "javaType": "String",
"deprecated": false, "deprecationNote": "", "autowired": false, "secret":
false, "description": "The name of model.", "constantName":
"org.apache.camel.component.torchserve.TorchServeConstants#MODEL_NAME" },
+ "CamelTorchServeModelVersion": { "index": 1, "kind": "header",
"displayName": "", "group": "producer", "label": "", "required": false,
"javaType": "String", "deprecated": false, "deprecationNote": "", "autowired":
false, "secret": false, "description": "The version of model.", "constantName":
"org.apache.camel.component.torchserve.TorchServeConstants#MODEL_VERSION" },
+ "CamelTorchServeUrl": { "index": 2, "kind": "header", "displayName": "",
"group": "producer", "label": "", "required": false, "javaType": "String",
"deprecated": false, "deprecationNote": "", "autowired": false, "secret":
false, "description": "Model archive download url, support local file or
HTTP(s) protocol. For S3, consider using pre-signed url.", "constantName":
"org.apache.camel.component.torchserve.TorchServeConstants#URL" },
+ "CamelTorchServeRegisterOptions": { "index": 3, "kind": "header",
"displayName": "", "group": "producer", "label": "", "required": false,
"javaType":
"org.apache.camel.component.torchserve.client.model.RegisterOptions",
"deprecated": false, "deprecationNote": "", "autowired": false, "secret":
false, "description": "Additional options for the register operation.",
"constantName":
"org.apache.camel.component.torchserve.TorchServeConstants#REGISTER_OPTIONS" },
+ "CamelTorchServeScaleWorkerOptions": { "index": 4, "kind": "header",
"displayName": "", "group": "producer", "label": "", "required": false,
"javaType":
"org.apache.camel.component.torchserve.client.model.ScaleWorkerOptions",
"deprecated": false, "deprecationNote": "", "autowired": false, "secret":
false, "description": "Additional options for the scale-worker operation.",
"constantName":
"org.apache.camel.component.torchserve.TorchServeConstants#SCALE_WORKER_OPTIONS"
},
+ "CamelTorchServeUnrsegisterOptions": { "index": 5, "kind": "header",
"displayName": "", "group": "producer", "label": "", "required": false,
"javaType":
"org.apache.camel.component.torchserve.client.model.UnregisterOptions",
"deprecated": false, "deprecationNote": "", "autowired": false, "secret":
false, "description": "Additional options for the unregister operation.",
"constantName":
"org.apache.camel.component.torchserve.TorchServeConstants#UNREGISTER_OPTIONS"
},
+ "CamelTorchServeListLimit": { "index": 6, "kind": "header", "displayName":
"", "group": "producer", "label": "", "required": false, "javaType": "Integer",
"deprecated": false, "deprecationNote": "", "autowired": false, "secret":
false, "description": "The maximum number of items to return for the list
operation. When this value is present, TorchServe does not return more than the
specified number of items, but it might return fewer. This value is optional.
If you include a value, it [...]
+ "CamelTorchServeListNextPageToken": { "index": 7, "kind": "header",
"displayName": "", "group": "producer", "label": "", "required": false,
"javaType": "String", "deprecated": false, "deprecationNote": "", "autowired":
false, "secret": false, "description": "The token to retrieve the next set of
results for the list operation. TorchServe provides the token when the response
from a previous call has more results than the maximum page size.",
"constantName": "org.apache.camel.component [...]
+ "CamelTorchServeMetricsName": { "index": 8, "kind": "header",
"displayName": "", "group": "producer", "label": "", "required": false,
"javaType": "String", "deprecated": false, "deprecationNote": "", "autowired":
false, "secret": false, "description": "Names of metrics to filter.",
"constantName":
"org.apache.camel.component.torchserve.TorchServeConstants#METRICS_NAME" }
+ },
+ "properties": {
+ "api": { "index": 0, "kind": "path", "displayName": "Api", "group":
"producer", "label": "", "required": true, "type": "string", "javaType":
"java.lang.String", "enum": [ "inference", "management", "metrics" ],
"deprecated": false, "deprecationNote": "", "autowired": false, "secret":
false, "description": "The TorchServe API" },
+ "operation": { "index": 1, "kind": "path", "displayName": "Operation",
"group": "producer", "label": "", "required": true, "type": "string",
"javaType": "java.lang.String", "enum": [ "ping", "predictions",
"explanations", "register", "scale-worker", "describe", "unregister", "list",
"set-default", "metrics" ], "deprecated": false, "deprecationNote": "",
"autowired": false, "secret": false, "description": "The API operation" },
+ "modelName": { "index": 2, "kind": "parameter", "displayName": "Model
Name", "group": "common", "label": "common", "required": false, "type":
"string", "javaType": "java.lang.String", "deprecated": false, "autowired":
false, "secret": false, "configurationClass":
"org.apache.camel.component.torchserve.TorchServeConfiguration",
"configurationField": "configuration", "description": "The name of model." },
+ "modelVersion": { "index": 3, "kind": "parameter", "displayName": "Model
Version", "group": "common", "label": "common", "required": false, "type":
"string", "javaType": "java.lang.String", "deprecated": false, "autowired":
false, "secret": false, "configurationClass":
"org.apache.camel.component.torchserve.TorchServeConfiguration",
"configurationField": "configuration", "description": "The version of model." },
+ "lazyStartProducer": { "index": 4, "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 produc [...]
+ "inferenceAddress": { "index": 5, "kind": "parameter", "displayName":
"Inference Address", "group": "inference", "label": "inference", "required":
false, "type": "string", "javaType": "java.lang.String", "deprecated": false,
"autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.torchserve.TorchServeConfiguration",
"configurationField": "configuration", "description": "The address of the
inference API endpoint." },
+ "inferencePort": { "index": 6, "kind": "parameter", "displayName":
"Inference Port", "group": "inference", "label": "inference", "required":
false, "type": "integer", "javaType": "int", "deprecated": false, "autowired":
false, "secret": false, "defaultValue": 8080, "configurationClass":
"org.apache.camel.component.torchserve.TorchServeConfiguration",
"configurationField": "configuration", "description": "The port of the
inference API endpoint." },
+ "listLimit": { "index": 7, "kind": "parameter", "displayName": "List
Limit", "group": "management", "label": "management", "required": false,
"type": "integer", "javaType": "int", "deprecated": false, "autowired": false,
"secret": false, "defaultValue": 100, "configurationClass":
"org.apache.camel.component.torchserve.TorchServeConfiguration",
"configurationField": "configuration", "description": "The maximum number of
items to return for the list operation. When this value is presen [...]
+ "listNextPageToken": { "index": 8, "kind": "parameter", "displayName":
"List Next Page Token", "group": "management", "label": "management",
"required": false, "type": "string", "javaType": "java.lang.String",
"deprecated": false, "autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.torchserve.TorchServeConfiguration",
"configurationField": "configuration", "description": "The token to retrieve
the next set of results for the list operation. TorchSer [...]
+ "managementAddress": { "index": 9, "kind": "parameter", "displayName":
"Management Address", "group": "management", "label": "management", "required":
false, "type": "string", "javaType": "java.lang.String", "deprecated": false,
"autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.torchserve.TorchServeConfiguration",
"configurationField": "configuration", "description": "The address of the
management API endpoint." },
+ "managementPort": { "index": 10, "kind": "parameter", "displayName":
"Management Port", "group": "management", "label": "management", "required":
false, "type": "integer", "javaType": "int", "deprecated": false, "autowired":
false, "secret": false, "defaultValue": 8081, "configurationClass":
"org.apache.camel.component.torchserve.TorchServeConfiguration",
"configurationField": "configuration", "description": "The port of the
management API endpoint." },
+ "registerOptions": { "index": 11, "kind": "parameter", "displayName":
"Register Options", "group": "management", "label": "management", "required":
false, "type": "object", "javaType":
"org.apache.camel.component.torchserve.client.model.RegisterOptions",
"deprecated": false, "autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.torchserve.TorchServeConfiguration",
"configurationField": "configuration", "description": "Additional options for
the regist [...]
+ "scaleWorkerOptions": { "index": 12, "kind": "parameter", "displayName":
"Scale Worker Options", "group": "management", "label": "management",
"required": false, "type": "object", "javaType":
"org.apache.camel.component.torchserve.client.model.ScaleWorkerOptions",
"deprecated": false, "autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.torchserve.TorchServeConfiguration",
"configurationField": "configuration", "description": "Additional options for
[...]
+ "unregisterOptions": { "index": 13, "kind": "parameter", "displayName":
"Unregister Options", "group": "management", "label": "management", "required":
false, "type": "object", "javaType":
"org.apache.camel.component.torchserve.client.model.UnregisterOptions",
"deprecated": false, "autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.torchserve.TorchServeConfiguration",
"configurationField": "configuration", "description": "Additional options for
the [...]
+ "url": { "index": 14, "kind": "parameter", "displayName": "Url", "group":
"management", "label": "management", "required": false, "type": "string",
"javaType": "java.lang.String", "deprecated": false, "autowired": false,
"secret": false, "configurationClass":
"org.apache.camel.component.torchserve.TorchServeConfiguration",
"configurationField": "configuration", "description": "Model archive download
url, support local file or HTTP(s) protocol. For S3, consider using pre-signed
url." },
+ "metricsAddress": { "index": 15, "kind": "parameter", "displayName":
"Metrics Address", "group": "metrics", "label": "metrics", "required": false,
"type": "string", "javaType": "java.lang.String", "deprecated": false,
"autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.torchserve.TorchServeConfiguration",
"configurationField": "configuration", "description": "The address of the
metrics API endpoint." },
+ "metricsName": { "index": 16, "kind": "parameter", "displayName": "Metrics
Name", "group": "metrics", "label": "metrics", "required": false, "type":
"string", "javaType": "java.lang.String", "deprecated": false, "autowired":
false, "secret": false, "configurationClass":
"org.apache.camel.component.torchserve.TorchServeConfiguration",
"configurationField": "configuration", "description": "Names of metrics to
filter." },
+ "metricsPort": { "index": 17, "kind": "parameter", "displayName": "Metrics
Port", "group": "metrics", "label": "metrics", "required": false, "type":
"integer", "javaType": "int", "deprecated": false, "autowired": false,
"secret": false, "defaultValue": 8082, "configurationClass":
"org.apache.camel.component.torchserve.TorchServeConfiguration",
"configurationField": "configuration", "description": "The port of the metrics
API endpoint." },
+ "inferenceKey": { "index": 18, "kind": "parameter", "displayName":
"Inference Key", "group": "security", "label": "inference,security",
"required": false, "type": "string", "javaType": "java.lang.String",
"deprecated": false, "autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.torchserve.TorchServeConfiguration",
"configurationField": "configuration", "description": "The token authorization
key for accessing the inference API." },
+ "managementKey": { "index": 19, "kind": "parameter", "displayName":
"Management Key", "group": "security", "label": "management,security",
"required": false, "type": "string", "javaType": "java.lang.String",
"deprecated": false, "autowired": false, "secret": false, "configurationClass":
"org.apache.camel.component.torchserve.TorchServeConfiguration",
"configurationField": "configuration", "description": "The token authorization
key for accessing the management API." }
+ }
+}
diff --git
a/core/camel-main/src/generated/resources/org/apache/camel/main/components.properties
b/core/camel-main/src/generated/resources/org/apache/camel/main/components.properties
index 3502089f41a..df0aaa04167 100644
---
a/core/camel-main/src/generated/resources/org/apache/camel/main/components.properties
+++
b/core/camel-main/src/generated/resources/org/apache/camel/main/components.properties
@@ -320,10 +320,12 @@ stub
tahu-edge
tahu-host
telegram
+tensorflow-serving
thrift
thymeleaf
tika
timer
+torchserve
twilio
twitter-directmessage
twitter-search
diff --git
a/dsl/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/ComponentsBuilderFactory.java
b/dsl/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/ComponentsBuilderFactory.java
index 625d974e2bf..16dbc3c41e8 100644
---
a/dsl/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/ComponentsBuilderFactory.java
+++
b/dsl/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/ComponentsBuilderFactory.java
@@ -4322,6 +4322,20 @@ public interface ComponentsBuilderFactory {
static TelegramComponentBuilderFactory.TelegramComponentBuilder telegram()
{
return TelegramComponentBuilderFactory.telegram();
}
+ /**
+ * TensorFlow Serving (camel-tensorflow-serving)
+ * Provide access to TensorFlow Serving model servers to run inference with
+ * TensorFlow saved models remotely
+ *
+ * Category: ai
+ * Since: 4.10
+ * Maven coordinates: org.apache.camel:camel-tensorflow-serving
+ *
+ * @return the dsl builder
+ */
+ static
TensorflowServingComponentBuilderFactory.TensorflowServingComponentBuilder
tensorflowServing() {
+ return TensorflowServingComponentBuilderFactory.tensorflowServing();
+ }
/**
* Thrift (camel-thrift)
* Call and expose remote procedures (RPC) with Apache Thrift data format
@@ -4375,6 +4389,20 @@ public interface ComponentsBuilderFactory {
static TimerComponentBuilderFactory.TimerComponentBuilder timer() {
return TimerComponentBuilderFactory.timer();
}
+ /**
+ * TorchServe (camel-torchserve)
+ * Provide access to PyTorch TorchServe servers to run inference with
+ * PyTorch models remotely
+ *
+ * Category: ai
+ * Since: 4.9
+ * Maven coordinates: org.apache.camel:camel-torchserve
+ *
+ * @return the dsl builder
+ */
+ static TorchserveComponentBuilderFactory.TorchserveComponentBuilder
torchserve() {
+ return TorchserveComponentBuilderFactory.torchserve();
+ }
/**
* Twilio (camel-twilio)
* Interact with Twilio REST APIs using Twilio Java SDK.
diff --git
a/dsl/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/TensorflowServingComponentBuilderFactory.java
b/dsl/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/TensorflowServingComponentBuilderFactory.java
new file mode 100644
index 00000000000..00ab47792d4
--- /dev/null
+++
b/dsl/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/TensorflowServingComponentBuilderFactory.java
@@ -0,0 +1,248 @@
+/* Generated by camel build tools - do NOT edit this file! */
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.camel.builder.component.dsl;
+
+import javax.annotation.processing.Generated;
+import org.apache.camel.Component;
+import org.apache.camel.builder.component.AbstractComponentBuilder;
+import org.apache.camel.builder.component.ComponentBuilder;
+import
org.apache.camel.component.tensorflow.serving.TensorFlowServingComponent;
+
+/**
+ * Provide access to TensorFlow Serving model servers to run inference with
+ * TensorFlow saved models remotely
+ *
+ * Generated by camel build tools - do NOT edit this file!
+ */
+@Generated("org.apache.camel.maven.packaging.ComponentDslMojo")
+public interface TensorflowServingComponentBuilderFactory {
+
+ /**
+ * TensorFlow Serving (camel-tensorflow-serving)
+ * Provide access to TensorFlow Serving model servers to run inference with
+ * TensorFlow saved models remotely
+ *
+ * Category: ai
+ * Since: 4.10
+ * Maven coordinates: org.apache.camel:camel-tensorflow-serving
+ *
+ * @return the dsl builder
+ */
+ static TensorflowServingComponentBuilder tensorflowServing() {
+ return new TensorflowServingComponentBuilderImpl();
+ }
+
+ /**
+ * Builder for the TensorFlow Serving component.
+ */
+ interface TensorflowServingComponentBuilder extends
ComponentBuilder<TensorFlowServingComponent> {
+
+ /**
+ * The configuration.
+ *
+ * The option is a:
+ *
<code>org.apache.camel.component.tensorflow.serving.TensorFlowServingConfiguration</code>
type.
+ *
+ * Group: producer
+ *
+ * @param configuration the value to set
+ * @return the dsl builder
+ */
+ default TensorflowServingComponentBuilder
configuration(org.apache.camel.component.tensorflow.serving.TensorFlowServingConfiguration
configuration) {
+ doSetProperty("configuration", configuration);
+ return this;
+ }
+
+ /**
+ * Required servable name.
+ *
+ * The option is a: <code>java.lang.String</code> type.
+ *
+ * Group: common
+ *
+ * @param modelName the value to set
+ * @return the dsl builder
+ */
+ default TensorflowServingComponentBuilder modelName(java.lang.String
modelName) {
+ doSetProperty("modelName", modelName);
+ return this;
+ }
+
+ /**
+ * Optional choice of which version of the model to use. Use this
+ * specific version number.
+ *
+ * The option is a: <code>java.lang.Long</code> type.
+ *
+ * Group: common
+ *
+ * @param modelVersion the value to set
+ * @return the dsl builder
+ */
+ default TensorflowServingComponentBuilder modelVersion(java.lang.Long
modelVersion) {
+ doSetProperty("modelVersion", modelVersion);
+ return this;
+ }
+
+ /**
+ * Optional choice of which version of the model to use. Use the
version
+ * associated with the given label.
+ *
+ * The option is a: <code>java.lang.String</code> type.
+ *
+ * Group: common
+ *
+ * @param modelVersionLabel the value to set
+ * @return the dsl builder
+ */
+ default TensorflowServingComponentBuilder
modelVersionLabel(java.lang.String modelVersionLabel) {
+ doSetProperty("modelVersionLabel", modelVersionLabel);
+ return this;
+ }
+
+ /**
+ * A named signature to evaluate. If unspecified, the default signature
+ * will be used.
+ *
+ * The option is a: <code>java.lang.String</code> type.
+ *
+ * Group: common
+ *
+ * @param signatureName the value to set
+ * @return the dsl builder
+ */
+ default TensorflowServingComponentBuilder
signatureName(java.lang.String signatureName) {
+ doSetProperty("signatureName", signatureName);
+ return this;
+ }
+
+
+ /**
+ * The target URI of the client. See:
+ *
https://grpc.github.io/grpc-java/javadoc/io/grpc/Grpc.html#newChannelBuilder%28java.lang.String,io.grpc.ChannelCredentials%29.
+ *
+ * The option is a: <code>java.lang.String</code> type.
+ *
+ * Default: localhost:8500
+ * Group: common
+ *
+ * @param target the value to set
+ * @return the dsl builder
+ */
+ default TensorflowServingComponentBuilder target(java.lang.String
target) {
+ doSetProperty("target", target);
+ return this;
+ }
+
+
+ /**
+ * 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.
+ *
+ * The option is a: <code>boolean</code> type.
+ *
+ * Default: false
+ * Group: producer
+ *
+ * @param lazyStartProducer the value to set
+ * @return the dsl builder
+ */
+ default TensorflowServingComponentBuilder lazyStartProducer(boolean
lazyStartProducer) {
+ doSetProperty("lazyStartProducer", lazyStartProducer);
+ return this;
+ }
+
+
+ /**
+ * Whether autowiring is enabled. This is used for automatic autowiring
+ * options (the option must be marked as autowired) by looking up in
the
+ * registry to find if there is a single instance of matching type,
+ * which then gets configured on the component. This can be used for
+ * automatic configuring JDBC data sources, JMS connection factories,
+ * AWS Clients, etc.
+ *
+ * The option is a: <code>boolean</code> type.
+ *
+ * Default: true
+ * Group: advanced
+ *
+ * @param autowiredEnabled the value to set
+ * @return the dsl builder
+ */
+ default TensorflowServingComponentBuilder autowiredEnabled(boolean
autowiredEnabled) {
+ doSetProperty("autowiredEnabled", autowiredEnabled);
+ return this;
+ }
+
+ /**
+ * The credentials of the client.
+ *
+ * The option is a: <code>io.grpc.ChannelCredentials</code>
+ * type.
+ *
+ * Group: security
+ *
+ * @param credentials the value to set
+ * @return the dsl builder
+ */
+ default TensorflowServingComponentBuilder
credentials(io.grpc.ChannelCredentials credentials) {
+ doSetProperty("credentials", credentials);
+ return this;
+ }
+ }
+
+ class TensorflowServingComponentBuilderImpl
+ extends AbstractComponentBuilder<TensorFlowServingComponent>
+ implements TensorflowServingComponentBuilder {
+ @Override
+ protected TensorFlowServingComponent buildConcreteComponent() {
+ return new TensorFlowServingComponent();
+ }
+ private
org.apache.camel.component.tensorflow.serving.TensorFlowServingConfiguration
getOrCreateConfiguration(TensorFlowServingComponent component) {
+ if (component.getConfiguration() == null) {
+ component.setConfiguration(new
org.apache.camel.component.tensorflow.serving.TensorFlowServingConfiguration());
+ }
+ return component.getConfiguration();
+ }
+ @Override
+ protected boolean setPropertyOnComponent(
+ Component component,
+ String name,
+ Object value) {
+ switch (name) {
+ case "configuration": ((TensorFlowServingComponent)
component).setConfiguration((org.apache.camel.component.tensorflow.serving.TensorFlowServingConfiguration)
value); return true;
+ case "modelName":
getOrCreateConfiguration((TensorFlowServingComponent)
component).setModelName((java.lang.String) value); return true;
+ case "modelVersion":
getOrCreateConfiguration((TensorFlowServingComponent)
component).setModelVersion((java.lang.Long) value); return true;
+ case "modelVersionLabel":
getOrCreateConfiguration((TensorFlowServingComponent)
component).setModelVersionLabel((java.lang.String) value); return true;
+ case "signatureName":
getOrCreateConfiguration((TensorFlowServingComponent)
component).setSignatureName((java.lang.String) value); return true;
+ case "target":
getOrCreateConfiguration((TensorFlowServingComponent)
component).setTarget((java.lang.String) value); return true;
+ case "lazyStartProducer": ((TensorFlowServingComponent)
component).setLazyStartProducer((boolean) value); return true;
+ case "autowiredEnabled": ((TensorFlowServingComponent)
component).setAutowiredEnabled((boolean) value); return true;
+ case "credentials":
getOrCreateConfiguration((TensorFlowServingComponent)
component).setCredentials((io.grpc.ChannelCredentials) value); return true;
+ default: return false;
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git
a/dsl/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/TorchserveComponentBuilderFactory.java
b/dsl/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/TorchserveComponentBuilderFactory.java
new file mode 100644
index 00000000000..ab1f2ebaa79
--- /dev/null
+++
b/dsl/camel-componentdsl/src/generated/java/org/apache/camel/builder/component/dsl/TorchserveComponentBuilderFactory.java
@@ -0,0 +1,475 @@
+/* Generated by camel build tools - do NOT edit this file! */
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.camel.builder.component.dsl;
+
+import javax.annotation.processing.Generated;
+import org.apache.camel.Component;
+import org.apache.camel.builder.component.AbstractComponentBuilder;
+import org.apache.camel.builder.component.ComponentBuilder;
+import org.apache.camel.component.torchserve.TorchServeComponent;
+
+/**
+ * Provide access to PyTorch TorchServe servers to run inference with PyTorch
+ * models remotely
+ *
+ * Generated by camel build tools - do NOT edit this file!
+ */
+@Generated("org.apache.camel.maven.packaging.ComponentDslMojo")
+public interface TorchserveComponentBuilderFactory {
+
+ /**
+ * TorchServe (camel-torchserve)
+ * Provide access to PyTorch TorchServe servers to run inference with
+ * PyTorch models remotely
+ *
+ * Category: ai
+ * Since: 4.9
+ * Maven coordinates: org.apache.camel:camel-torchserve
+ *
+ * @return the dsl builder
+ */
+ static TorchserveComponentBuilder torchserve() {
+ return new TorchserveComponentBuilderImpl();
+ }
+
+ /**
+ * Builder for the TorchServe component.
+ */
+ interface TorchserveComponentBuilder extends
ComponentBuilder<TorchServeComponent> {
+
+ /**
+ * The configuration.
+ *
+ * The option is a:
+ *
<code>org.apache.camel.component.torchserve.TorchServeConfiguration</code>
type.
+ *
+ * Group: producer
+ *
+ * @param configuration the value to set
+ * @return the dsl builder
+ */
+ default TorchserveComponentBuilder
configuration(org.apache.camel.component.torchserve.TorchServeConfiguration
configuration) {
+ doSetProperty("configuration", configuration);
+ return this;
+ }
+
+ /**
+ * The name of model.
+ *
+ * The option is a: <code>java.lang.String</code> type.
+ *
+ * Group: common
+ *
+ * @param modelName the value to set
+ * @return the dsl builder
+ */
+ default TorchserveComponentBuilder modelName(java.lang.String
modelName) {
+ doSetProperty("modelName", modelName);
+ return this;
+ }
+
+ /**
+ * The version of model.
+ *
+ * The option is a: <code>java.lang.String</code> type.
+ *
+ * Group: common
+ *
+ * @param modelVersion the value to set
+ * @return the dsl builder
+ */
+ default TorchserveComponentBuilder modelVersion(java.lang.String
modelVersion) {
+ doSetProperty("modelVersion", modelVersion);
+ return this;
+ }
+
+
+ /**
+ * 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.
+ *
+ * The option is a: <code>boolean</code> type.
+ *
+ * Default: false
+ * Group: producer
+ *
+ * @param lazyStartProducer the value to set
+ * @return the dsl builder
+ */
+ default TorchserveComponentBuilder lazyStartProducer(boolean
lazyStartProducer) {
+ doSetProperty("lazyStartProducer", lazyStartProducer);
+ return this;
+ }
+
+
+ /**
+ * Whether autowiring is enabled. This is used for automatic autowiring
+ * options (the option must be marked as autowired) by looking up in
the
+ * registry to find if there is a single instance of matching type,
+ * which then gets configured on the component. This can be used for
+ * automatic configuring JDBC data sources, JMS connection factories,
+ * AWS Clients, etc.
+ *
+ * The option is a: <code>boolean</code> type.
+ *
+ * Default: true
+ * Group: advanced
+ *
+ * @param autowiredEnabled the value to set
+ * @return the dsl builder
+ */
+ default TorchserveComponentBuilder autowiredEnabled(boolean
autowiredEnabled) {
+ doSetProperty("autowiredEnabled", autowiredEnabled);
+ return this;
+ }
+
+
+ /**
+ * Used for enabling or disabling all consumer based health checks from
+ * this component.
+ *
+ * The option is a: <code>boolean</code> type.
+ *
+ * Default: true
+ * Group: health
+ *
+ * @param healthCheckConsumerEnabled the value to set
+ * @return the dsl builder
+ */
+ default TorchserveComponentBuilder healthCheckConsumerEnabled(boolean
healthCheckConsumerEnabled) {
+ doSetProperty("healthCheckConsumerEnabled",
healthCheckConsumerEnabled);
+ return this;
+ }
+
+
+ /**
+ * Used for enabling or disabling all producer based health checks from
+ * this component. Notice: Camel has by default disabled all producer
+ * based health-checks. You can turn on producer checks globally by
+ * setting camel.health.producersEnabled=true.
+ *
+ * The option is a: <code>boolean</code> type.
+ *
+ * Default: true
+ * Group: health
+ *
+ * @param healthCheckProducerEnabled the value to set
+ * @return the dsl builder
+ */
+ default TorchserveComponentBuilder healthCheckProducerEnabled(boolean
healthCheckProducerEnabled) {
+ doSetProperty("healthCheckProducerEnabled",
healthCheckProducerEnabled);
+ return this;
+ }
+
+ /**
+ * The address of the inference API endpoint.
+ *
+ * The option is a: <code>java.lang.String</code> type.
+ *
+ * Group: inference
+ *
+ * @param inferenceAddress the value to set
+ * @return the dsl builder
+ */
+ default TorchserveComponentBuilder inferenceAddress(java.lang.String
inferenceAddress) {
+ doSetProperty("inferenceAddress", inferenceAddress);
+ return this;
+ }
+
+
+ /**
+ * The port of the inference API endpoint.
+ *
+ * The option is a: <code>int</code> type.
+ *
+ * Default: 8080
+ * Group: inference
+ *
+ * @param inferencePort the value to set
+ * @return the dsl builder
+ */
+ default TorchserveComponentBuilder inferencePort(int inferencePort) {
+ doSetProperty("inferencePort", inferencePort);
+ return this;
+ }
+
+
+ /**
+ * The maximum number of items to return for the list operation. When
+ * this value is present, TorchServe does not return more than the
+ * specified number of items, but it might return fewer. This value is
+ * optional. If you include a value, it must be between 1 and 1000,
+ * inclusive. If you do not include a value, it defaults to 100.
+ *
+ * The option is a: <code>int</code> type.
+ *
+ * Default: 100
+ * Group: management
+ *
+ * @param listLimit the value to set
+ * @return the dsl builder
+ */
+ default TorchserveComponentBuilder listLimit(int listLimit) {
+ doSetProperty("listLimit", listLimit);
+ return this;
+ }
+
+ /**
+ * The token to retrieve the next set of results for the list
operation.
+ * TorchServe provides the token when the response from a previous call
+ * has more results than the maximum page size.
+ *
+ * The option is a: <code>java.lang.String</code> type.
+ *
+ * Group: management
+ *
+ * @param listNextPageToken the value to set
+ * @return the dsl builder
+ */
+ default TorchserveComponentBuilder listNextPageToken(java.lang.String
listNextPageToken) {
+ doSetProperty("listNextPageToken", listNextPageToken);
+ return this;
+ }
+
+ /**
+ * The address of the management API endpoint.
+ *
+ * The option is a: <code>java.lang.String</code> type.
+ *
+ * Group: management
+ *
+ * @param managementAddress the value to set
+ * @return the dsl builder
+ */
+ default TorchserveComponentBuilder managementAddress(java.lang.String
managementAddress) {
+ doSetProperty("managementAddress", managementAddress);
+ return this;
+ }
+
+
+ /**
+ * The port of the management API endpoint.
+ *
+ * The option is a: <code>int</code> type.
+ *
+ * Default: 8081
+ * Group: management
+ *
+ * @param managementPort the value to set
+ * @return the dsl builder
+ */
+ default TorchserveComponentBuilder managementPort(int managementPort) {
+ doSetProperty("managementPort", managementPort);
+ return this;
+ }
+
+ /**
+ * Additional options for the register operation.
+ *
+ * The option is a:
+ *
<code>org.apache.camel.component.torchserve.client.model.RegisterOptions</code>
type.
+ *
+ * Group: management
+ *
+ * @param registerOptions the value to set
+ * @return the dsl builder
+ */
+ default TorchserveComponentBuilder
registerOptions(org.apache.camel.component.torchserve.client.model.RegisterOptions
registerOptions) {
+ doSetProperty("registerOptions", registerOptions);
+ return this;
+ }
+
+ /**
+ * Additional options for the scale-worker operation.
+ *
+ * The option is a:
+ *
<code>org.apache.camel.component.torchserve.client.model.ScaleWorkerOptions</code>
type.
+ *
+ * Group: management
+ *
+ * @param scaleWorkerOptions the value to set
+ * @return the dsl builder
+ */
+ default TorchserveComponentBuilder
scaleWorkerOptions(org.apache.camel.component.torchserve.client.model.ScaleWorkerOptions
scaleWorkerOptions) {
+ doSetProperty("scaleWorkerOptions", scaleWorkerOptions);
+ return this;
+ }
+
+ /**
+ * Additional options for the unregister operation.
+ *
+ * The option is a:
+ *
<code>org.apache.camel.component.torchserve.client.model.UnregisterOptions</code>
type.
+ *
+ * Group: management
+ *
+ * @param unregisterOptions the value to set
+ * @return the dsl builder
+ */
+ default TorchserveComponentBuilder
unregisterOptions(org.apache.camel.component.torchserve.client.model.UnregisterOptions
unregisterOptions) {
+ doSetProperty("unregisterOptions", unregisterOptions);
+ return this;
+ }
+
+ /**
+ * Model archive download url, support local file or HTTP(s) protocol.
+ * For S3, consider using pre-signed url.
+ *
+ * The option is a: <code>java.lang.String</code> type.
+ *
+ * Group: management
+ *
+ * @param url the value to set
+ * @return the dsl builder
+ */
+ default TorchserveComponentBuilder url(java.lang.String url) {
+ doSetProperty("url", url);
+ return this;
+ }
+
+ /**
+ * The address of the metrics API endpoint.
+ *
+ * The option is a: <code>java.lang.String</code> type.
+ *
+ * Group: metrics
+ *
+ * @param metricsAddress the value to set
+ * @return the dsl builder
+ */
+ default TorchserveComponentBuilder metricsAddress(java.lang.String
metricsAddress) {
+ doSetProperty("metricsAddress", metricsAddress);
+ return this;
+ }
+
+ /**
+ * Names of metrics to filter.
+ *
+ * The option is a: <code>java.lang.String</code> type.
+ *
+ * Group: metrics
+ *
+ * @param metricsName the value to set
+ * @return the dsl builder
+ */
+ default TorchserveComponentBuilder metricsName(java.lang.String
metricsName) {
+ doSetProperty("metricsName", metricsName);
+ return this;
+ }
+
+
+ /**
+ * The port of the metrics API endpoint.
+ *
+ * The option is a: <code>int</code> type.
+ *
+ * Default: 8082
+ * Group: metrics
+ *
+ * @param metricsPort the value to set
+ * @return the dsl builder
+ */
+ default TorchserveComponentBuilder metricsPort(int metricsPort) {
+ doSetProperty("metricsPort", metricsPort);
+ return this;
+ }
+
+ /**
+ * The token authorization key for accessing the inference API.
+ *
+ * The option is a: <code>java.lang.String</code> type.
+ *
+ * Group: security
+ *
+ * @param inferenceKey the value to set
+ * @return the dsl builder
+ */
+ default TorchserveComponentBuilder inferenceKey(java.lang.String
inferenceKey) {
+ doSetProperty("inferenceKey", inferenceKey);
+ return this;
+ }
+
+ /**
+ * The token authorization key for accessing the management API.
+ *
+ * The option is a: <code>java.lang.String</code> type.
+ *
+ * Group: security
+ *
+ * @param managementKey the value to set
+ * @return the dsl builder
+ */
+ default TorchserveComponentBuilder managementKey(java.lang.String
managementKey) {
+ doSetProperty("managementKey", managementKey);
+ return this;
+ }
+ }
+
+ class TorchserveComponentBuilderImpl
+ extends AbstractComponentBuilder<TorchServeComponent>
+ implements TorchserveComponentBuilder {
+ @Override
+ protected TorchServeComponent buildConcreteComponent() {
+ return new TorchServeComponent();
+ }
+ private org.apache.camel.component.torchserve.TorchServeConfiguration
getOrCreateConfiguration(TorchServeComponent component) {
+ if (component.getConfiguration() == null) {
+ component.setConfiguration(new
org.apache.camel.component.torchserve.TorchServeConfiguration());
+ }
+ return component.getConfiguration();
+ }
+ @Override
+ protected boolean setPropertyOnComponent(
+ Component component,
+ String name,
+ Object value) {
+ switch (name) {
+ case "configuration": ((TorchServeComponent)
component).setConfiguration((org.apache.camel.component.torchserve.TorchServeConfiguration)
value); return true;
+ case "modelName": getOrCreateConfiguration((TorchServeComponent)
component).setModelName((java.lang.String) value); return true;
+ case "modelVersion":
getOrCreateConfiguration((TorchServeComponent)
component).setModelVersion((java.lang.String) value); return true;
+ case "lazyStartProducer": ((TorchServeComponent)
component).setLazyStartProducer((boolean) value); return true;
+ case "autowiredEnabled": ((TorchServeComponent)
component).setAutowiredEnabled((boolean) value); return true;
+ case "healthCheckConsumerEnabled": ((TorchServeComponent)
component).setHealthCheckConsumerEnabled((boolean) value); return true;
+ case "healthCheckProducerEnabled": ((TorchServeComponent)
component).setHealthCheckProducerEnabled((boolean) value); return true;
+ case "inferenceAddress":
getOrCreateConfiguration((TorchServeComponent)
component).setInferenceAddress((java.lang.String) value); return true;
+ case "inferencePort":
getOrCreateConfiguration((TorchServeComponent)
component).setInferencePort((int) value); return true;
+ case "listLimit": getOrCreateConfiguration((TorchServeComponent)
component).setListLimit((int) value); return true;
+ case "listNextPageToken":
getOrCreateConfiguration((TorchServeComponent)
component).setListNextPageToken((java.lang.String) value); return true;
+ case "managementAddress":
getOrCreateConfiguration((TorchServeComponent)
component).setManagementAddress((java.lang.String) value); return true;
+ case "managementPort":
getOrCreateConfiguration((TorchServeComponent)
component).setManagementPort((int) value); return true;
+ case "registerOptions":
getOrCreateConfiguration((TorchServeComponent)
component).setRegisterOptions((org.apache.camel.component.torchserve.client.model.RegisterOptions)
value); return true;
+ case "scaleWorkerOptions":
getOrCreateConfiguration((TorchServeComponent)
component).setScaleWorkerOptions((org.apache.camel.component.torchserve.client.model.ScaleWorkerOptions)
value); return true;
+ case "unregisterOptions":
getOrCreateConfiguration((TorchServeComponent)
component).setUnregisterOptions((org.apache.camel.component.torchserve.client.model.UnregisterOptions)
value); return true;
+ case "url": getOrCreateConfiguration((TorchServeComponent)
component).setUrl((java.lang.String) value); return true;
+ case "metricsAddress":
getOrCreateConfiguration((TorchServeComponent)
component).setMetricsAddress((java.lang.String) value); return true;
+ case "metricsName": getOrCreateConfiguration((TorchServeComponent)
component).setMetricsName((java.lang.String) value); return true;
+ case "metricsPort": getOrCreateConfiguration((TorchServeComponent)
component).setMetricsPort((int) value); return true;
+ case "inferenceKey":
getOrCreateConfiguration((TorchServeComponent)
component).setInferenceKey((java.lang.String) value); return true;
+ case "managementKey":
getOrCreateConfiguration((TorchServeComponent)
component).setManagementKey((java.lang.String) value); return true;
+ default: return false;
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git
a/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/EndpointBuilderFactory.java
b/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/EndpointBuilderFactory.java
index 22f306dcffe..16573623537 100644
---
a/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/EndpointBuilderFactory.java
+++
b/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/EndpointBuilderFactory.java
@@ -336,11 +336,13 @@ public interface EndpointBuilderFactory
org.apache.camel.builder.endpoint.dsl.TahuEdgeEndpointBuilderFactory.TahuEdgeBuilders,
org.apache.camel.builder.endpoint.dsl.TahuHostEndpointBuilderFactory.TahuHostBuilders,
org.apache.camel.builder.endpoint.dsl.TelegramEndpointBuilderFactory.TelegramBuilders,
+
org.apache.camel.builder.endpoint.dsl.TensorFlowServingEndpointBuilderFactory.TensorFlowServingBuilders,
org.apache.camel.builder.endpoint.dsl.ThriftEndpointBuilderFactory.ThriftBuilders,
org.apache.camel.builder.endpoint.dsl.ThymeleafEndpointBuilderFactory.ThymeleafBuilders,
org.apache.camel.builder.endpoint.dsl.TikaEndpointBuilderFactory.TikaBuilders,
org.apache.camel.builder.endpoint.dsl.TimerEndpointBuilderFactory.TimerBuilders,
org.apache.camel.builder.endpoint.dsl.Timestream2EndpointBuilderFactory.Timestream2Builders,
+
org.apache.camel.builder.endpoint.dsl.TorchServeEndpointBuilderFactory.TorchServeBuilders,
org.apache.camel.builder.endpoint.dsl.Translate2EndpointBuilderFactory.Translate2Builders,
org.apache.camel.builder.endpoint.dsl.TwilioEndpointBuilderFactory.TwilioBuilders,
org.apache.camel.builder.endpoint.dsl.TwitterDirectMessageEndpointBuilderFactory.TwitterDirectMessageBuilders,
diff --git
a/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/EndpointBuilders.java
b/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/EndpointBuilders.java
index 47370e3cbe7..1d7ebc08024 100644
---
a/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/EndpointBuilders.java
+++
b/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/EndpointBuilders.java
@@ -333,11 +333,13 @@ public interface EndpointBuilders
org.apache.camel.builder.endpoint.dsl.TahuEdgeEndpointBuilderFactory,
org.apache.camel.builder.endpoint.dsl.TahuHostEndpointBuilderFactory,
org.apache.camel.builder.endpoint.dsl.TelegramEndpointBuilderFactory,
+
org.apache.camel.builder.endpoint.dsl.TensorFlowServingEndpointBuilderFactory,
org.apache.camel.builder.endpoint.dsl.ThriftEndpointBuilderFactory,
org.apache.camel.builder.endpoint.dsl.ThymeleafEndpointBuilderFactory,
org.apache.camel.builder.endpoint.dsl.TikaEndpointBuilderFactory,
org.apache.camel.builder.endpoint.dsl.TimerEndpointBuilderFactory,
org.apache.camel.builder.endpoint.dsl.Timestream2EndpointBuilderFactory,
+
org.apache.camel.builder.endpoint.dsl.TorchServeEndpointBuilderFactory,
org.apache.camel.builder.endpoint.dsl.Translate2EndpointBuilderFactory,
org.apache.camel.builder.endpoint.dsl.TwilioEndpointBuilderFactory,
org.apache.camel.builder.endpoint.dsl.TwitterDirectMessageEndpointBuilderFactory,
diff --git
a/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/StaticEndpointBuilders.java
b/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/StaticEndpointBuilders.java
index 9c741712064..76eb2712904 100644
---
a/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/StaticEndpointBuilders.java
+++
b/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/StaticEndpointBuilders.java
@@ -14513,6 +14513,52 @@ public class StaticEndpointBuilders {
public static TelegramEndpointBuilderFactory.TelegramEndpointBuilder
telegram(String componentName, String path) {
return TelegramEndpointBuilderFactory.endpointBuilder(componentName,
path);
}
+ /**
+ * TensorFlow Serving (camel-tensorflow-serving)
+ * Provide access to TensorFlow Serving model servers to run inference with
+ * TensorFlow saved models remotely
+ *
+ * Category: ai
+ * Since: 4.10
+ * Maven coordinates: org.apache.camel:camel-tensorflow-serving
+ *
+ * Syntax: <code>tensorflow-serving:api</code>
+ *
+ * Path parameter: api (required)
+ * The TensorFlow Serving API
+ * There are 5 enums and the value can be one of: model-status,
+ * model-metadata, classify, regress, predict
+ *
+ * @param path api
+ * @return the dsl builder
+ */
+ public static
TensorFlowServingEndpointBuilderFactory.TensorFlowServingEndpointBuilder
tensorflowServing(String path) {
+ return tensorflowServing("tensorflow-serving", path);
+ }
+ /**
+ * TensorFlow Serving (camel-tensorflow-serving)
+ * Provide access to TensorFlow Serving model servers to run inference with
+ * TensorFlow saved models remotely
+ *
+ * Category: ai
+ * Since: 4.10
+ * Maven coordinates: org.apache.camel:camel-tensorflow-serving
+ *
+ * Syntax: <code>tensorflow-serving:api</code>
+ *
+ * Path parameter: api (required)
+ * The TensorFlow Serving API
+ * There are 5 enums and the value can be one of: model-status,
+ * model-metadata, classify, regress, predict
+ *
+ * @param componentName to use a custom component name for the endpoint
+ * instead of the default name
+ * @param path api
+ * @return the dsl builder
+ */
+ public static
TensorFlowServingEndpointBuilderFactory.TensorFlowServingEndpointBuilder
tensorflowServing(String componentName, String path) {
+ return
TensorFlowServingEndpointBuilderFactory.endpointBuilder(componentName, path);
+ }
/**
* Thrift (camel-thrift)
* Call and expose remote procedures (RPC) with Apache Thrift data format
@@ -14707,6 +14753,64 @@ public class StaticEndpointBuilders {
public static TimerEndpointBuilderFactory.TimerEndpointBuilder
timer(String componentName, String path) {
return TimerEndpointBuilderFactory.endpointBuilder(componentName,
path);
}
+ /**
+ * TorchServe (camel-torchserve)
+ * Provide access to PyTorch TorchServe servers to run inference with
+ * PyTorch models remotely
+ *
+ * Category: ai
+ * Since: 4.9
+ * Maven coordinates: org.apache.camel:camel-torchserve
+ *
+ * Syntax: <code>torchserve:api/operation</code>
+ *
+ * Path parameter: api (required)
+ * The TorchServe API
+ * There are 3 enums and the value can be one of: inference, management,
+ * metrics
+ *
+ * Path parameter: operation (required)
+ * The API operation
+ * There are 10 enums and the value can be one of: ping, predictions,
+ * explanations, register, scale-worker, describe, unregister, list,
+ * set-default, metrics
+ *
+ * @param path api/operation
+ * @return the dsl builder
+ */
+ public static TorchServeEndpointBuilderFactory.TorchServeEndpointBuilder
torchserve(String path) {
+ return torchserve("torchserve", path);
+ }
+ /**
+ * TorchServe (camel-torchserve)
+ * Provide access to PyTorch TorchServe servers to run inference with
+ * PyTorch models remotely
+ *
+ * Category: ai
+ * Since: 4.9
+ * Maven coordinates: org.apache.camel:camel-torchserve
+ *
+ * Syntax: <code>torchserve:api/operation</code>
+ *
+ * Path parameter: api (required)
+ * The TorchServe API
+ * There are 3 enums and the value can be one of: inference, management,
+ * metrics
+ *
+ * Path parameter: operation (required)
+ * The API operation
+ * There are 10 enums and the value can be one of: ping, predictions,
+ * explanations, register, scale-worker, describe, unregister, list,
+ * set-default, metrics
+ *
+ * @param componentName to use a custom component name for the endpoint
+ * instead of the default name
+ * @param path api/operation
+ * @return the dsl builder
+ */
+ public static TorchServeEndpointBuilderFactory.TorchServeEndpointBuilder
torchserve(String componentName, String path) {
+ return TorchServeEndpointBuilderFactory.endpointBuilder(componentName,
path);
+ }
/**
* Twilio (camel-twilio)
* Interact with Twilio REST APIs using Twilio Java SDK.
diff --git
a/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/TensorFlowServingEndpointBuilderFactory.java
b/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/TensorFlowServingEndpointBuilderFactory.java
new file mode 100644
index 00000000000..818bb6fa8e2
--- /dev/null
+++
b/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/TensorFlowServingEndpointBuilderFactory.java
@@ -0,0 +1,387 @@
+/* Generated by camel build tools - do NOT edit this file! */
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.camel.builder.endpoint.dsl;
+
+import java.util.*;
+import java.util.concurrent.*;
+import java.util.function.*;
+import java.util.stream.*;
+import javax.annotation.processing.Generated;
+import org.apache.camel.builder.EndpointConsumerBuilder;
+import org.apache.camel.builder.EndpointProducerBuilder;
+import org.apache.camel.builder.endpoint.AbstractEndpointBuilder;
+
+/**
+ * Provide access to TensorFlow Serving model servers to run inference with
+ * TensorFlow saved models remotely
+ *
+ * Generated by camel build tools - do NOT edit this file!
+ */
+@Generated("org.apache.camel.maven.packaging.EndpointDslMojo")
+public interface TensorFlowServingEndpointBuilderFactory {
+
+ /**
+ * Builder for endpoint for the TensorFlow Serving component.
+ */
+ public interface TensorFlowServingEndpointBuilder
+ extends
+ EndpointProducerBuilder {
+ default AdvancedTensorFlowServingEndpointBuilder advanced() {
+ return (AdvancedTensorFlowServingEndpointBuilder) this;
+ }
+
+ /**
+ * Required servable name.
+ *
+ * The option is a: <code>java.lang.String</code> type.
+ *
+ * Group: common
+ *
+ * @param modelName the value to set
+ * @return the dsl builder
+ */
+ default TensorFlowServingEndpointBuilder modelName(String modelName) {
+ doSetProperty("modelName", modelName);
+ return this;
+ }
+ /**
+ * Optional choice of which version of the model to use. Use this
+ * specific version number.
+ *
+ * The option is a: <code>java.lang.Long</code> type.
+ *
+ * Group: common
+ *
+ * @param modelVersion the value to set
+ * @return the dsl builder
+ */
+ default TensorFlowServingEndpointBuilder modelVersion(Long
modelVersion) {
+ doSetProperty("modelVersion", modelVersion);
+ return this;
+ }
+ /**
+ * Optional choice of which version of the model to use. Use this
+ * specific version number.
+ *
+ * The option will be converted to a <code>java.lang.Long</code> type.
+ *
+ * Group: common
+ *
+ * @param modelVersion the value to set
+ * @return the dsl builder
+ */
+ default TensorFlowServingEndpointBuilder modelVersion(String
modelVersion) {
+ doSetProperty("modelVersion", modelVersion);
+ return this;
+ }
+ /**
+ * Optional choice of which version of the model to use. Use the
version
+ * associated with the given label.
+ *
+ * The option is a: <code>java.lang.String</code> type.
+ *
+ * Group: common
+ *
+ * @param modelVersionLabel the value to set
+ * @return the dsl builder
+ */
+ default TensorFlowServingEndpointBuilder modelVersionLabel(String
modelVersionLabel) {
+ doSetProperty("modelVersionLabel", modelVersionLabel);
+ return this;
+ }
+ /**
+ * A named signature to evaluate. If unspecified, the default signature
+ * will be used.
+ *
+ * The option is a: <code>java.lang.String</code> type.
+ *
+ * Group: common
+ *
+ * @param signatureName the value to set
+ * @return the dsl builder
+ */
+ default TensorFlowServingEndpointBuilder signatureName(String
signatureName) {
+ doSetProperty("signatureName", signatureName);
+ return this;
+ }
+ /**
+ * The target URI of the client. See:
+ *
https://grpc.github.io/grpc-java/javadoc/io/grpc/Grpc.html#newChannelBuilder%28java.lang.String,io.grpc.ChannelCredentials%29.
+ *
+ * The option is a: <code>java.lang.String</code> type.
+ *
+ * Default: localhost:8500
+ * Group: common
+ *
+ * @param target the value to set
+ * @return the dsl builder
+ */
+ default TensorFlowServingEndpointBuilder target(String target) {
+ doSetProperty("target", target);
+ return this;
+ }
+ /**
+ * The credentials of the client.
+ *
+ * The option is a: <code>io.grpc.ChannelCredentials</code> type.
+ *
+ * Group: security
+ *
+ * @param credentials the value to set
+ * @return the dsl builder
+ */
+ default TensorFlowServingEndpointBuilder
credentials(io.grpc.ChannelCredentials credentials) {
+ doSetProperty("credentials", credentials);
+ return this;
+ }
+ /**
+ * The credentials of the client.
+ *
+ * The option will be converted to a
+ * <code>io.grpc.ChannelCredentials</code> type.
+ *
+ * Group: security
+ *
+ * @param credentials the value to set
+ * @return the dsl builder
+ */
+ default TensorFlowServingEndpointBuilder credentials(String
credentials) {
+ doSetProperty("credentials", credentials);
+ return this;
+ }
+ }
+
+ /**
+ * Advanced builder for endpoint for the TensorFlow Serving component.
+ */
+ public interface AdvancedTensorFlowServingEndpointBuilder
+ extends
+ EndpointProducerBuilder {
+ default TensorFlowServingEndpointBuilder basic() {
+ return (TensorFlowServingEndpointBuilder) this;
+ }
+
+ /**
+ * 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.
+ *
+ * The option is a: <code>boolean</code> type.
+ *
+ * Default: false
+ * Group: producer (advanced)
+ *
+ * @param lazyStartProducer the value to set
+ * @return the dsl builder
+ */
+ default AdvancedTensorFlowServingEndpointBuilder
lazyStartProducer(boolean lazyStartProducer) {
+ doSetProperty("lazyStartProducer", lazyStartProducer);
+ return this;
+ }
+ /**
+ * 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.
+ *
+ * The option will be converted to a <code>boolean</code> type.
+ *
+ * Default: false
+ * Group: producer (advanced)
+ *
+ * @param lazyStartProducer the value to set
+ * @return the dsl builder
+ */
+ default AdvancedTensorFlowServingEndpointBuilder
lazyStartProducer(String lazyStartProducer) {
+ doSetProperty("lazyStartProducer", lazyStartProducer);
+ return this;
+ }
+ }
+
+ public interface TensorFlowServingBuilders {
+ /**
+ * TensorFlow Serving (camel-tensorflow-serving)
+ * Provide access to TensorFlow Serving model servers to run inference
+ * with TensorFlow saved models remotely
+ *
+ * Category: ai
+ * Since: 4.10
+ * Maven coordinates: org.apache.camel:camel-tensorflow-serving
+ *
+ * @return the dsl builder for the headers' name.
+ */
+ default TensorFlowServingHeaderNameBuilder tensorflowServing() {
+ return TensorFlowServingHeaderNameBuilder.INSTANCE;
+ }
+ /**
+ * TensorFlow Serving (camel-tensorflow-serving)
+ * Provide access to TensorFlow Serving model servers to run inference
+ * with TensorFlow saved models remotely
+ *
+ * Category: ai
+ * Since: 4.10
+ * Maven coordinates: org.apache.camel:camel-tensorflow-serving
+ *
+ * Syntax: <code>tensorflow-serving:api</code>
+ *
+ * Path parameter: api (required)
+ * The TensorFlow Serving API
+ * There are 5 enums and the value can be one of: model-status,
+ * model-metadata, classify, regress, predict
+ *
+ * @param path api
+ * @return the dsl builder
+ */
+ default TensorFlowServingEndpointBuilder tensorflowServing(String
path) {
+ return
TensorFlowServingEndpointBuilderFactory.endpointBuilder("tensorflow-serving",
path);
+ }
+ /**
+ * TensorFlow Serving (camel-tensorflow-serving)
+ * Provide access to TensorFlow Serving model servers to run inference
+ * with TensorFlow saved models remotely
+ *
+ * Category: ai
+ * Since: 4.10
+ * Maven coordinates: org.apache.camel:camel-tensorflow-serving
+ *
+ * Syntax: <code>tensorflow-serving:api</code>
+ *
+ * Path parameter: api (required)
+ * The TensorFlow Serving API
+ * There are 5 enums and the value can be one of: model-status,
+ * model-metadata, classify, regress, predict
+ *
+ * @param componentName to use a custom component name for the endpoint
+ * instead of the default name
+ * @param path api
+ * @return the dsl builder
+ */
+ default TensorFlowServingEndpointBuilder tensorflowServing(String
componentName, String path) {
+ return
TensorFlowServingEndpointBuilderFactory.endpointBuilder(componentName, path);
+ }
+
+ }
+ /**
+ * The builder of headers' name for the TensorFlow Serving component.
+ */
+ public static class TensorFlowServingHeaderNameBuilder {
+ /**
+ * The internal instance of the builder used to access to all the
+ * methods representing the name of headers.
+ */
+ private static final TensorFlowServingHeaderNameBuilder INSTANCE = new
TensorFlowServingHeaderNameBuilder();
+
+ /**
+ * The target of the client. See:
+ *
https://grpc.github.io/grpc-java/javadoc/io/grpc/Grpc.html#newChannelBuilder%28java.lang.String,io.grpc.ChannelCredentials%29.
+ *
+ * The option is a: {@code String} type.
+ *
+ * Group: producer
+ *
+ * @return the name of the header {@code TensorFlowServingTarget}.
+ */
+ public String tensorFlowServingTarget() {
+ return "CamelTensorFlowServingTarget";
+ }
+ /**
+ * The credentials of the client.
+ *
+ * The option is a: {@code io.grpc.ChannelCredentials} type.
+ *
+ * Group: producer
+ *
+ * @return the name of the header {@code TensorFlowServingCredentials}.
+ */
+ public String tensorFlowServingCredentials() {
+ return "CamelTensorFlowServingCredentials";
+ }
+ /**
+ * Required servable name.
+ *
+ * The option is a: {@code String} type.
+ *
+ * Group: producer
+ *
+ * @return the name of the header {@code TensorFlowServingModelName}.
+ */
+ public String tensorFlowServingModelName() {
+ return "CamelTensorFlowServingModelName";
+ }
+ /**
+ * Optional choice of which version of the model to use. Use this
+ * specific version number.
+ *
+ * The option is a: {@code long} type.
+ *
+ * Group: producer
+ *
+ * @return the name of the header {@code
TensorFlowServingModelVersion}.
+ */
+ public String tensorFlowServingModelVersion() {
+ return "CamelTensorFlowServingModelVersion";
+ }
+ /**
+ * Optional choice of which version of the model to use. Use the
version
+ * associated with the given label.
+ *
+ * The option is a: {@code String} type.
+ *
+ * Group: producer
+ *
+ * @return the name of the header {@code
+ * TensorFlowServingModelVersionLabel}.
+ */
+ public String tensorFlowServingModelVersionLabel() {
+ return "CamelTensorFlowServingModelVersionLabel";
+ }
+ /**
+ * A named signature to evaluate. If unspecified, the default signature
+ * will be used.
+ *
+ * The option is a: {@code String} type.
+ *
+ * Group: producer
+ *
+ * @return the name of the header {@code
+ * TensorFlowServingSignatureName}.
+ */
+ public String tensorFlowServingSignatureName() {
+ return "CamelTensorFlowServingSignatureName";
+ }
+ }
+ static TensorFlowServingEndpointBuilder endpointBuilder(String
componentName, String path) {
+ class TensorFlowServingEndpointBuilderImpl extends
AbstractEndpointBuilder implements TensorFlowServingEndpointBuilder,
AdvancedTensorFlowServingEndpointBuilder {
+ public TensorFlowServingEndpointBuilderImpl(String path) {
+ super(componentName, path);
+ }
+ }
+ return new TensorFlowServingEndpointBuilderImpl(path);
+ }
+}
\ No newline at end of file
diff --git
a/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/TorchServeEndpointBuilderFactory.java
b/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/TorchServeEndpointBuilderFactory.java
new file mode 100644
index 00000000000..546c7f5572f
--- /dev/null
+++
b/dsl/camel-endpointdsl/src/generated/java/org/apache/camel/builder/endpoint/dsl/TorchServeEndpointBuilderFactory.java
@@ -0,0 +1,683 @@
+/* Generated by camel build tools - do NOT edit this file! */
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.camel.builder.endpoint.dsl;
+
+import java.util.*;
+import java.util.concurrent.*;
+import java.util.function.*;
+import java.util.stream.*;
+import javax.annotation.processing.Generated;
+import org.apache.camel.builder.EndpointConsumerBuilder;
+import org.apache.camel.builder.EndpointProducerBuilder;
+import org.apache.camel.builder.endpoint.AbstractEndpointBuilder;
+
+/**
+ * Provide access to PyTorch TorchServe servers to run inference with PyTorch
+ * models remotely
+ *
+ * Generated by camel build tools - do NOT edit this file!
+ */
+@Generated("org.apache.camel.maven.packaging.EndpointDslMojo")
+public interface TorchServeEndpointBuilderFactory {
+
+ /**
+ * Builder for endpoint for the TorchServe component.
+ */
+ public interface TorchServeEndpointBuilder
+ extends
+ EndpointProducerBuilder {
+ default AdvancedTorchServeEndpointBuilder advanced() {
+ return (AdvancedTorchServeEndpointBuilder) this;
+ }
+
+ /**
+ * The name of model.
+ *
+ * The option is a: <code>java.lang.String</code> type.
+ *
+ * Group: common
+ *
+ * @param modelName the value to set
+ * @return the dsl builder
+ */
+ default TorchServeEndpointBuilder modelName(String modelName) {
+ doSetProperty("modelName", modelName);
+ return this;
+ }
+ /**
+ * The version of model.
+ *
+ * The option is a: <code>java.lang.String</code> type.
+ *
+ * Group: common
+ *
+ * @param modelVersion the value to set
+ * @return the dsl builder
+ */
+ default TorchServeEndpointBuilder modelVersion(String modelVersion) {
+ doSetProperty("modelVersion", modelVersion);
+ return this;
+ }
+ /**
+ * The address of the inference API endpoint.
+ *
+ * The option is a: <code>java.lang.String</code> type.
+ *
+ * Group: inference
+ *
+ * @param inferenceAddress the value to set
+ * @return the dsl builder
+ */
+ default TorchServeEndpointBuilder inferenceAddress(String
inferenceAddress) {
+ doSetProperty("inferenceAddress", inferenceAddress);
+ return this;
+ }
+ /**
+ * The port of the inference API endpoint.
+ *
+ * The option is a: <code>int</code> type.
+ *
+ * Default: 8080
+ * Group: inference
+ *
+ * @param inferencePort the value to set
+ * @return the dsl builder
+ */
+ default TorchServeEndpointBuilder inferencePort(int inferencePort) {
+ doSetProperty("inferencePort", inferencePort);
+ return this;
+ }
+ /**
+ * The port of the inference API endpoint.
+ *
+ * The option will be converted to a <code>int</code> type.
+ *
+ * Default: 8080
+ * Group: inference
+ *
+ * @param inferencePort the value to set
+ * @return the dsl builder
+ */
+ default TorchServeEndpointBuilder inferencePort(String inferencePort) {
+ doSetProperty("inferencePort", inferencePort);
+ return this;
+ }
+ /**
+ * The maximum number of items to return for the list operation. When
+ * this value is present, TorchServe does not return more than the
+ * specified number of items, but it might return fewer. This value is
+ * optional. If you include a value, it must be between 1 and 1000,
+ * inclusive. If you do not include a value, it defaults to 100.
+ *
+ * The option is a: <code>int</code> type.
+ *
+ * Default: 100
+ * Group: management
+ *
+ * @param listLimit the value to set
+ * @return the dsl builder
+ */
+ default TorchServeEndpointBuilder listLimit(int listLimit) {
+ doSetProperty("listLimit", listLimit);
+ return this;
+ }
+ /**
+ * The maximum number of items to return for the list operation. When
+ * this value is present, TorchServe does not return more than the
+ * specified number of items, but it might return fewer. This value is
+ * optional. If you include a value, it must be between 1 and 1000,
+ * inclusive. If you do not include a value, it defaults to 100.
+ *
+ * The option will be converted to a <code>int</code> type.
+ *
+ * Default: 100
+ * Group: management
+ *
+ * @param listLimit the value to set
+ * @return the dsl builder
+ */
+ default TorchServeEndpointBuilder listLimit(String listLimit) {
+ doSetProperty("listLimit", listLimit);
+ return this;
+ }
+ /**
+ * The token to retrieve the next set of results for the list
operation.
+ * TorchServe provides the token when the response from a previous call
+ * has more results than the maximum page size.
+ *
+ * The option is a: <code>java.lang.String</code> type.
+ *
+ * Group: management
+ *
+ * @param listNextPageToken the value to set
+ * @return the dsl builder
+ */
+ default TorchServeEndpointBuilder listNextPageToken(String
listNextPageToken) {
+ doSetProperty("listNextPageToken", listNextPageToken);
+ return this;
+ }
+ /**
+ * The address of the management API endpoint.
+ *
+ * The option is a: <code>java.lang.String</code> type.
+ *
+ * Group: management
+ *
+ * @param managementAddress the value to set
+ * @return the dsl builder
+ */
+ default TorchServeEndpointBuilder managementAddress(String
managementAddress) {
+ doSetProperty("managementAddress", managementAddress);
+ return this;
+ }
+ /**
+ * The port of the management API endpoint.
+ *
+ * The option is a: <code>int</code> type.
+ *
+ * Default: 8081
+ * Group: management
+ *
+ * @param managementPort the value to set
+ * @return the dsl builder
+ */
+ default TorchServeEndpointBuilder managementPort(int managementPort) {
+ doSetProperty("managementPort", managementPort);
+ return this;
+ }
+ /**
+ * The port of the management API endpoint.
+ *
+ * The option will be converted to a <code>int</code> type.
+ *
+ * Default: 8081
+ * Group: management
+ *
+ * @param managementPort the value to set
+ * @return the dsl builder
+ */
+ default TorchServeEndpointBuilder managementPort(String
managementPort) {
+ doSetProperty("managementPort", managementPort);
+ return this;
+ }
+ /**
+ * Additional options for the register operation.
+ *
+ * The option is a:
+ *
<code>org.apache.camel.component.torchserve.client.model.RegisterOptions</code>
type.
+ *
+ * Group: management
+ *
+ * @param registerOptions the value to set
+ * @return the dsl builder
+ */
+ default TorchServeEndpointBuilder
registerOptions(org.apache.camel.component.torchserve.client.model.RegisterOptions
registerOptions) {
+ doSetProperty("registerOptions", registerOptions);
+ return this;
+ }
+ /**
+ * Additional options for the register operation.
+ *
+ * The option will be converted to a
+ *
<code>org.apache.camel.component.torchserve.client.model.RegisterOptions</code>
type.
+ *
+ * Group: management
+ *
+ * @param registerOptions the value to set
+ * @return the dsl builder
+ */
+ default TorchServeEndpointBuilder registerOptions(String
registerOptions) {
+ doSetProperty("registerOptions", registerOptions);
+ return this;
+ }
+ /**
+ * Additional options for the scale-worker operation.
+ *
+ * The option is a:
+ *
<code>org.apache.camel.component.torchserve.client.model.ScaleWorkerOptions</code>
type.
+ *
+ * Group: management
+ *
+ * @param scaleWorkerOptions the value to set
+ * @return the dsl builder
+ */
+ default TorchServeEndpointBuilder
scaleWorkerOptions(org.apache.camel.component.torchserve.client.model.ScaleWorkerOptions
scaleWorkerOptions) {
+ doSetProperty("scaleWorkerOptions", scaleWorkerOptions);
+ return this;
+ }
+ /**
+ * Additional options for the scale-worker operation.
+ *
+ * The option will be converted to a
+ *
<code>org.apache.camel.component.torchserve.client.model.ScaleWorkerOptions</code>
type.
+ *
+ * Group: management
+ *
+ * @param scaleWorkerOptions the value to set
+ * @return the dsl builder
+ */
+ default TorchServeEndpointBuilder scaleWorkerOptions(String
scaleWorkerOptions) {
+ doSetProperty("scaleWorkerOptions", scaleWorkerOptions);
+ return this;
+ }
+ /**
+ * Additional options for the unregister operation.
+ *
+ * The option is a:
+ *
<code>org.apache.camel.component.torchserve.client.model.UnregisterOptions</code>
type.
+ *
+ * Group: management
+ *
+ * @param unregisterOptions the value to set
+ * @return the dsl builder
+ */
+ default TorchServeEndpointBuilder
unregisterOptions(org.apache.camel.component.torchserve.client.model.UnregisterOptions
unregisterOptions) {
+ doSetProperty("unregisterOptions", unregisterOptions);
+ return this;
+ }
+ /**
+ * Additional options for the unregister operation.
+ *
+ * The option will be converted to a
+ *
<code>org.apache.camel.component.torchserve.client.model.UnregisterOptions</code>
type.
+ *
+ * Group: management
+ *
+ * @param unregisterOptions the value to set
+ * @return the dsl builder
+ */
+ default TorchServeEndpointBuilder unregisterOptions(String
unregisterOptions) {
+ doSetProperty("unregisterOptions", unregisterOptions);
+ return this;
+ }
+ /**
+ * Model archive download url, support local file or HTTP(s) protocol.
+ * For S3, consider using pre-signed url.
+ *
+ * The option is a: <code>java.lang.String</code> type.
+ *
+ * Group: management
+ *
+ * @param url the value to set
+ * @return the dsl builder
+ */
+ default TorchServeEndpointBuilder url(String url) {
+ doSetProperty("url", url);
+ return this;
+ }
+ /**
+ * The address of the metrics API endpoint.
+ *
+ * The option is a: <code>java.lang.String</code> type.
+ *
+ * Group: metrics
+ *
+ * @param metricsAddress the value to set
+ * @return the dsl builder
+ */
+ default TorchServeEndpointBuilder metricsAddress(String
metricsAddress) {
+ doSetProperty("metricsAddress", metricsAddress);
+ return this;
+ }
+ /**
+ * Names of metrics to filter.
+ *
+ * The option is a: <code>java.lang.String</code> type.
+ *
+ * Group: metrics
+ *
+ * @param metricsName the value to set
+ * @return the dsl builder
+ */
+ default TorchServeEndpointBuilder metricsName(String metricsName) {
+ doSetProperty("metricsName", metricsName);
+ return this;
+ }
+ /**
+ * The port of the metrics API endpoint.
+ *
+ * The option is a: <code>int</code> type.
+ *
+ * Default: 8082
+ * Group: metrics
+ *
+ * @param metricsPort the value to set
+ * @return the dsl builder
+ */
+ default TorchServeEndpointBuilder metricsPort(int metricsPort) {
+ doSetProperty("metricsPort", metricsPort);
+ return this;
+ }
+ /**
+ * The port of the metrics API endpoint.
+ *
+ * The option will be converted to a <code>int</code> type.
+ *
+ * Default: 8082
+ * Group: metrics
+ *
+ * @param metricsPort the value to set
+ * @return the dsl builder
+ */
+ default TorchServeEndpointBuilder metricsPort(String metricsPort) {
+ doSetProperty("metricsPort", metricsPort);
+ return this;
+ }
+ /**
+ * The token authorization key for accessing the inference API.
+ *
+ * The option is a: <code>java.lang.String</code> type.
+ *
+ * Group: security
+ *
+ * @param inferenceKey the value to set
+ * @return the dsl builder
+ */
+ default TorchServeEndpointBuilder inferenceKey(String inferenceKey) {
+ doSetProperty("inferenceKey", inferenceKey);
+ return this;
+ }
+ /**
+ * The token authorization key for accessing the management API.
+ *
+ * The option is a: <code>java.lang.String</code> type.
+ *
+ * Group: security
+ *
+ * @param managementKey the value to set
+ * @return the dsl builder
+ */
+ default TorchServeEndpointBuilder managementKey(String managementKey) {
+ doSetProperty("managementKey", managementKey);
+ return this;
+ }
+ }
+
+ /**
+ * Advanced builder for endpoint for the TorchServe component.
+ */
+ public interface AdvancedTorchServeEndpointBuilder
+ extends
+ EndpointProducerBuilder {
+ default TorchServeEndpointBuilder basic() {
+ return (TorchServeEndpointBuilder) this;
+ }
+
+ /**
+ * 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.
+ *
+ * The option is a: <code>boolean</code> type.
+ *
+ * Default: false
+ * Group: producer (advanced)
+ *
+ * @param lazyStartProducer the value to set
+ * @return the dsl builder
+ */
+ default AdvancedTorchServeEndpointBuilder lazyStartProducer(boolean
lazyStartProducer) {
+ doSetProperty("lazyStartProducer", lazyStartProducer);
+ return this;
+ }
+ /**
+ * 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.
+ *
+ * The option will be converted to a <code>boolean</code> type.
+ *
+ * Default: false
+ * Group: producer (advanced)
+ *
+ * @param lazyStartProducer the value to set
+ * @return the dsl builder
+ */
+ default AdvancedTorchServeEndpointBuilder lazyStartProducer(String
lazyStartProducer) {
+ doSetProperty("lazyStartProducer", lazyStartProducer);
+ return this;
+ }
+ }
+
+ public interface TorchServeBuilders {
+ /**
+ * TorchServe (camel-torchserve)
+ * Provide access to PyTorch TorchServe servers to run inference with
+ * PyTorch models remotely
+ *
+ * Category: ai
+ * Since: 4.9
+ * Maven coordinates: org.apache.camel:camel-torchserve
+ *
+ * @return the dsl builder for the headers' name.
+ */
+ default TorchServeHeaderNameBuilder torchserve() {
+ return TorchServeHeaderNameBuilder.INSTANCE;
+ }
+ /**
+ * TorchServe (camel-torchserve)
+ * Provide access to PyTorch TorchServe servers to run inference with
+ * PyTorch models remotely
+ *
+ * Category: ai
+ * Since: 4.9
+ * Maven coordinates: org.apache.camel:camel-torchserve
+ *
+ * Syntax: <code>torchserve:api/operation</code>
+ *
+ * Path parameter: api (required)
+ * The TorchServe API
+ * There are 3 enums and the value can be one of: inference,
management,
+ * metrics
+ *
+ * Path parameter: operation (required)
+ * The API operation
+ * There are 10 enums and the value can be one of: ping, predictions,
+ * explanations, register, scale-worker, describe, unregister, list,
+ * set-default, metrics
+ *
+ * @param path api/operation
+ * @return the dsl builder
+ */
+ default TorchServeEndpointBuilder torchserve(String path) {
+ return
TorchServeEndpointBuilderFactory.endpointBuilder("torchserve", path);
+ }
+ /**
+ * TorchServe (camel-torchserve)
+ * Provide access to PyTorch TorchServe servers to run inference with
+ * PyTorch models remotely
+ *
+ * Category: ai
+ * Since: 4.9
+ * Maven coordinates: org.apache.camel:camel-torchserve
+ *
+ * Syntax: <code>torchserve:api/operation</code>
+ *
+ * Path parameter: api (required)
+ * The TorchServe API
+ * There are 3 enums and the value can be one of: inference,
management,
+ * metrics
+ *
+ * Path parameter: operation (required)
+ * The API operation
+ * There are 10 enums and the value can be one of: ping, predictions,
+ * explanations, register, scale-worker, describe, unregister, list,
+ * set-default, metrics
+ *
+ * @param componentName to use a custom component name for the endpoint
+ * instead of the default name
+ * @param path api/operation
+ * @return the dsl builder
+ */
+ default TorchServeEndpointBuilder torchserve(String componentName,
String path) {
+ return
TorchServeEndpointBuilderFactory.endpointBuilder(componentName, path);
+ }
+
+ }
+ /**
+ * The builder of headers' name for the TorchServe component.
+ */
+ public static class TorchServeHeaderNameBuilder {
+ /**
+ * The internal instance of the builder used to access to all the
+ * methods representing the name of headers.
+ */
+ private static final TorchServeHeaderNameBuilder INSTANCE = new
TorchServeHeaderNameBuilder();
+
+ /**
+ * The name of model.
+ *
+ * The option is a: {@code String} type.
+ *
+ * Group: producer
+ *
+ * @return the name of the header {@code TorchServeModelName}.
+ */
+ public String torchServeModelName() {
+ return "CamelTorchServeModelName";
+ }
+ /**
+ * The version of model.
+ *
+ * The option is a: {@code String} type.
+ *
+ * Group: producer
+ *
+ * @return the name of the header {@code TorchServeModelVersion}.
+ */
+ public String torchServeModelVersion() {
+ return "CamelTorchServeModelVersion";
+ }
+ /**
+ * Model archive download url, support local file or HTTP(s) protocol.
+ * For S3, consider using pre-signed url.
+ *
+ * The option is a: {@code String} type.
+ *
+ * Group: producer
+ *
+ * @return the name of the header {@code TorchServeUrl}.
+ */
+ public String torchServeUrl() {
+ return "CamelTorchServeUrl";
+ }
+ /**
+ * Additional options for the register operation.
+ *
+ * The option is a: {@code
+ * org.apache.camel.component.torchserve.client.model.RegisterOptions}
+ * type.
+ *
+ * Group: producer
+ *
+ * @return the name of the header {@code TorchServeRegisterOptions}.
+ */
+ public String torchServeRegisterOptions() {
+ return "CamelTorchServeRegisterOptions";
+ }
+ /**
+ * Additional options for the scale-worker operation.
+ *
+ * The option is a: {@code
+ *
org.apache.camel.component.torchserve.client.model.ScaleWorkerOptions} type.
+ *
+ * Group: producer
+ *
+ * @return the name of the header {@code TorchServeScaleWorkerOptions}.
+ */
+ public String torchServeScaleWorkerOptions() {
+ return "CamelTorchServeScaleWorkerOptions";
+ }
+ /**
+ * Additional options for the unregister operation.
+ *
+ * The option is a: {@code
+ *
org.apache.camel.component.torchserve.client.model.UnregisterOptions}
+ * type.
+ *
+ * Group: producer
+ *
+ * @return the name of the header {@code TorchServeUnrsegisterOptions}.
+ */
+ public String torchServeUnrsegisterOptions() {
+ return "CamelTorchServeUnrsegisterOptions";
+ }
+ /**
+ * The maximum number of items to return for the list operation. When
+ * this value is present, TorchServe does not return more than the
+ * specified number of items, but it might return fewer. This value is
+ * optional. If you include a value, it must be between 1 and 1000,
+ * inclusive. If you do not include a value, it defaults to 100.
+ *
+ * The option is a: {@code Integer} type.
+ *
+ * Group: producer
+ *
+ * @return the name of the header {@code TorchServeListLimit}.
+ */
+ public String torchServeListLimit() {
+ return "CamelTorchServeListLimit";
+ }
+ /**
+ * The token to retrieve the next set of results for the list
operation.
+ * TorchServe provides the token when the response from a previous call
+ * has more results than the maximum page size.
+ *
+ * The option is a: {@code String} type.
+ *
+ * Group: producer
+ *
+ * @return the name of the header {@code TorchServeListNextPageToken}.
+ */
+ public String torchServeListNextPageToken() {
+ return "CamelTorchServeListNextPageToken";
+ }
+ /**
+ * Names of metrics to filter.
+ *
+ * The option is a: {@code String} type.
+ *
+ * Group: producer
+ *
+ * @return the name of the header {@code TorchServeMetricsName}.
+ */
+ public String torchServeMetricsName() {
+ return "CamelTorchServeMetricsName";
+ }
+ }
+ static TorchServeEndpointBuilder endpointBuilder(String componentName,
String path) {
+ class TorchServeEndpointBuilderImpl extends AbstractEndpointBuilder
implements TorchServeEndpointBuilder, AdvancedTorchServeEndpointBuilder {
+ public TorchServeEndpointBuilderImpl(String path) {
+ super(componentName, path);
+ }
+ }
+ return new TorchServeEndpointBuilderImpl(path);
+ }
+}
\ No newline at end of file
diff --git
a/dsl/camel-kamelet-main/src/generated/resources/camel-component-known-dependencies.properties
b/dsl/camel-kamelet-main/src/generated/resources/camel-component-known-dependencies.properties
index 3a95ab32a3c..b42f0ec98c8 100644
---
a/dsl/camel-kamelet-main/src/generated/resources/camel-component-known-dependencies.properties
+++
b/dsl/camel-kamelet-main/src/generated/resources/camel-component-known-dependencies.properties
@@ -323,10 +323,12 @@ org.apache.camel.component.stub.StubComponent=camel:stub
org.apache.camel.component.tahu.TahuEdgeComponent=camel:tahu
org.apache.camel.component.tahu.TahuHostComponent=camel:tahu
org.apache.camel.component.telegram.TelegramComponent=camel:telegram
+org.apache.camel.component.tensorflow.serving.TensorFlowServingComponent=camel:tensorflow-serving
org.apache.camel.component.thrift.ThriftComponent=camel:thrift
org.apache.camel.component.thymeleaf.ThymeleafComponent=camel:thymeleaf
org.apache.camel.component.tika.TikaComponent=camel:tika
org.apache.camel.component.timer.TimerComponent=camel:timer
+org.apache.camel.component.torchserve.TorchServeComponent=camel:torchserve
org.apache.camel.component.twilio.TwilioComponent=camel:twilio
org.apache.camel.component.twitter.directmessage.TwitterDirectMessageComponent=camel:twitter
org.apache.camel.component.twitter.search.TwitterSearchComponent=camel:twitter
diff --git
a/tooling/maven/camel-package-maven-plugin/src/main/java/org/apache/camel/maven/packaging/MojoHelper.java
b/tooling/maven/camel-package-maven-plugin/src/main/java/org/apache/camel/maven/packaging/MojoHelper.java
index 0cb06f8df16..9a31c02f27e 100644
---
a/tooling/maven/camel-package-maven-plugin/src/main/java/org/apache/camel/maven/packaging/MojoHelper.java
+++
b/tooling/maven/camel-package-maven-plugin/src/main/java/org/apache/camel/maven/packaging/MojoHelper.java
@@ -42,7 +42,8 @@ public final class MojoHelper {
dir.resolve("camel-langchain4j-embeddings"),
dir.resolve("camel-langchain4j-tokenizer"),
dir.resolve("camel-langchain4j-tools"),
dir.resolve("camel-langchain4j-web-search"),
dir.resolve("camel-qdrant"),
dir.resolve("camel-milvus"),
- dir.resolve("camel-pinecone"),
dir.resolve("camel-kserve"));
+ dir.resolve("camel-pinecone"),
dir.resolve("camel-kserve"),
+ dir.resolve("camel-torchserve"),
dir.resolve("camel-tensorflow-serving"));
case "camel-as2":
return
Collections.singletonList(dir.resolve("camel-as2-component"));
case "camel-avro-rpc":