This is an automated email from the ASF dual-hosted git repository.

davsclaus 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 363375a6fb2 CAMEL-20105: camel-micromemter - Make it easier to use 
from camel-jbang
363375a6fb2 is described below

commit 363375a6fb214ea2220bc2d169543cf3d63cd4b7
Author: Claus Ibsen <[email protected]>
AuthorDate: Fri Nov 17 09:47:32 2023 +0100

    CAMEL-20105: camel-micromemter - Make it easier to use from camel-jbang
---
 .../resources/auto-configure/camel-micrometer.joor | 35 ----------------------
 .../camel-microprofile-metrics.properties          | 18 -----------
 .../camel-main-known-dependencies.properties       |  3 +-
 3 files changed, 2 insertions(+), 54 deletions(-)

diff --git 
a/dsl/camel-kamelet-main/src/main/resources/auto-configure/camel-micrometer.joor
 
b/dsl/camel-kamelet-main/src/main/resources/auto-configure/camel-micrometer.joor
deleted file mode 100644
index 99df4cf0441..00000000000
--- 
a/dsl/camel-kamelet-main/src/main/resources/auto-configure/camel-micrometer.joor
+++ /dev/null
@@ -1,35 +0,0 @@
-/*
- * 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.
- */
-var answer = "";
-var registry = context.getRegistry();
-var mr = registry.lookupByNameAndType("metricsRegistry", 
io.micrometer.core.instrument.MeterRegistry.class);
-if (mr == null) {
-    // automatic create metrics registry
-    answer = "Auto-configuring camel-micrometer: Creating default 
MeterRegistry";
-    mr = new io.micrometer.core.instrument.simple.SimpleMeterRegistry();
-    registry.bind("metricsRegistry", mr);
-    // also setup metrics as route policy factory to capture route level 
details
-    var rpf = new 
org.apache.camel.component.micrometer.routepolicy.MicrometerRoutePolicyFactory();
-    rpf.setMeterRegistry(mr);
-    context.addRoutePolicyFactory(rpf);
-    // and setup dev console
-    var dcr = 
context.getCamelContextExtension().getContextPlugin(org.apache.camel.console.DevConsoleRegistry.class);
-    if (dcr != null) {
-        dcr.register(new 
org.apache.camel.component.micrometer.MicrometerConsole());
-    }
-}
-return answer;
\ No newline at end of file
diff --git 
a/dsl/camel-kamelet-main/src/main/resources/auto-configure/camel-microprofile-metrics.properties
 
b/dsl/camel-kamelet-main/src/main/resources/auto-configure/camel-microprofile-metrics.properties
deleted file mode 100644
index cee803c34ca..00000000000
--- 
a/dsl/camel-kamelet-main/src/main/resources/auto-configure/camel-microprofile-metrics.properties
+++ /dev/null
@@ -1,18 +0,0 @@
-## ---------------------------------------------------------------------------
-## 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.
-## ---------------------------------------------------------------------------
-
-dependency=io.smallrye:smallrye-metrics:3.0.5
\ No newline at end of file
diff --git 
a/dsl/camel-kamelet-main/src/main/resources/camel-main-known-dependencies.properties
 
b/dsl/camel-kamelet-main/src/main/resources/camel-main-known-dependencies.properties
index 390d037732d..97d0d682ba2 100644
--- 
a/dsl/camel-kamelet-main/src/main/resources/camel-main-known-dependencies.properties
+++ 
b/dsl/camel-kamelet-main/src/main/resources/camel-main-known-dependencies.properties
@@ -28,4 +28,5 @@ org.apache.camel.component.cxf.jaxws.CxfEndpoint = 
camel:cxf-soap
 org.apache.camel.component.cxf.jaxrs.CxfRsEndpoint = camel:cxf-rest
 META-INF/services/org/apache/camel/restapi/openapi = camel:openapi-java
 META-INF/services/org/apache/camel/modelxml-dumper = camel:xml-io
-META-INF/services/org/apache/camel/modelyaml-dumper = camel:yaml-io
\ No newline at end of file
+META-INF/services/org/apache/camel/modelyaml-dumper = camel:yaml-io
+META-INF/services/org/apache/camel/micrometer-prometheus = 
camel:micrometer-prometheus

Reply via email to