jamesnetherton commented on code in PR #8523: URL: https://github.com/apache/camel-quarkus/pull/8523#discussion_r3079582529
########## extensions/ibm-watson-language/deployment/src/main/java/org/apache/camel/quarkus/component/ibm/watson/language/deployment/IbmWatsonLanguageProcessor.java: ########## @@ -0,0 +1,74 @@ +/* + * 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.quarkus.component.ibm.watson.language.deployment; + +import io.quarkus.deployment.annotations.BuildStep; +import io.quarkus.deployment.builditem.FeatureBuildItem; +import io.quarkus.deployment.builditem.IndexDependencyBuildItem; + +/** + * Quarkus extension processor for IBM Watson Natural Language Understanding support. + * <p> + * <b>Known Limitation in Native Mode:</b> + * In GraalVM native mode, Watson SDK cannot load {@code java-sdk-version.properties} and + * {@code sdk-core-version.properties}, resulting in warning logs: + * + * <pre> + * WARNING [com.ibm.watson.common.SdkCommon] Could not load java-sdk-version.properties + * WARNING [com.ibm.cloud.sdk.core.util.RequestUtils] Could not load file: sdk-core-version.properties Review Comment: This worked fine for me: ``` @BuildStep void addResources(BuildProducer<NativeImageResourceBuildItem> nativeImageResource) { nativeImageResource.produce(new NativeImageResourceBuildItem("java-sdk-version.properties")); nativeImageResource.produce(new NativeImageResourceBuildItem("sdk-core-version.properties")); } ``` Your code snippet has the raw `BuildProducer resource`. Not sure if that perhaps makes it not work. -- 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. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
