You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@camel.apache.org by GitBox <gi...@apache.org> on 2019/10/01 09:04:51 UTC

[GitHub] [camel-quarkus] ppalaga commented on a change in pull request #201: Fix #184 Leverage platform http service

ppalaga commented on a change in pull request #201: Fix #184 Leverage platform http service
URL: https://github.com/apache/camel-quarkus/pull/201#discussion_r329950196
 
 

 ##########
 File path: extensions/platform-http/runtime/src/main/java/org/apache/camel/quarkus/component/platform/http/runtime/PlatformHttpRecorder.java
 ##########
 @@ -0,0 +1,24 @@
+package org.apache.camel.quarkus.component.platform.http.runtime;
+
+import org.apache.camel.component.platform.http.PlatformHttpComponent;
+import org.apache.camel.component.platform.http.PlatformHttpConstants;
+import org.apache.camel.component.platform.http.spi.PlatformHttpEngine;
+import org.apache.camel.quarkus.core.runtime.CamelRuntime;
+import org.apache.camel.spi.Registry;
+
+import io.quarkus.arc.runtime.BeanContainer;
+import io.quarkus.runtime.RuntimeValue;
+import io.quarkus.runtime.annotations.Recorder;
+
+@Recorder
+public class PlatformHttpRecorder {
+
+    public void registerBeans(RuntimeValue<CamelRuntime> runtime, BeanContainer beanContainer) {
+        final Registry registry = runtime.getValue().getRegistry();
+        final QuarkusPlatformHttpEngine engine = beanContainer.instance(QuarkusPlatformHttpEngine.class);
 
 Review comment:
   In bb474bb, the bean container is not involved. The `QuarkusPlatformHttpEngine` is created in the recorder though, which is in line with the requirement of Quarkus that the runtime objects should not be created inside BuildSteps.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services