2.4. Quarkus アプリケーションの実行
以下の手順に従って、Red Hat build of HawtIO を Quarkus アプリケーションにアタッチできます。
手順:
io.hawt:hawtio-quarkusおよびサポートする Camel Quarkus エクステンションをpom.xmlの依存関係に追加します。<dependencyManagement> <dependencies> <dependency> <groupId>io.hawt</groupId> <artifactId>hawtio-bom</artifactId> <version>4.2.0.redhat-00034</version> <type>pom</type> <scope>import</scope> </dependency> </dependencies> <!-- ... other BOMs or dependencies ... --> </dependencyManagement> <dependencies> <dependency> <groupId>io.hawt</groupId> <artifactId>hawtio-quarkus</artifactId> </dependency> <!-- Mandatory for enabling Camel management via JMX / Red Hat buuld of HawtIO --> <dependency> <groupId>org.apache.camel.quarkus</groupId> <artifactId>camel-quarkus-management</artifactId> </dependency> <!-- (Optional) Required for Red Hat buuld of HawtIO Camel route diagram tab --> <dependency> <groupId>org.apache.camel.quarkus</groupId> <artifactId>camel-quarkus-jaxb</artifactId> </dependency> <!-- ... other dependencies ... --> </dependencies>application.propertiesに次の設定を追加して認証を無効にします。quarkus.hawtio.authenticationEnabled = false- 認証を設定することもできます。「Quarkus 認証メカニズム」を参照してください。
次のように、開発モードで Quarkus アプリケーションを使用して Red Hat build of HawtIO を実行します。
mvn compile quarkus:dev- http://localhost:8080/hawtio/ を開いて、Red Hat build of HawtIO コンソールを表示します。