You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by GitBox <gi...@apache.org> on 2020/01/02 16:01:03 UTC

[GitHub] [camel-quarkus] oscerd opened a new pull request #584: Added AWS-Lambda extension

oscerd opened a new pull request #584: Added AWS-Lambda extension
URL: https://github.com/apache/camel-quarkus/pull/584
 
 
   Fixes #563 

----------------------------------------------------------------
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

[GitHub] [camel-quarkus] oscerd merged pull request #584: Added AWS-Lambda extension

Posted by GitBox <gi...@apache.org>.
oscerd merged pull request #584: Added AWS-Lambda extension
URL: https://github.com/apache/camel-quarkus/pull/584
 
 
   

----------------------------------------------------------------
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

[GitHub] [camel-quarkus] oscerd commented on issue #584: Added AWS-Lambda extension

Posted by GitBox <gi...@apache.org>.
oscerd commented on issue #584: Added AWS-Lambda extension
URL: https://github.com/apache/camel-quarkus/pull/584#issuecomment-570252143
 
 
   ok to test

----------------------------------------------------------------
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

[GitHub] [camel-quarkus] oscerd commented on a change in pull request #584: Added AWS-Lambda extension

Posted by GitBox <gi...@apache.org>.
oscerd commented on a change in pull request #584: Added AWS-Lambda extension
URL: https://github.com/apache/camel-quarkus/pull/584#discussion_r362537782
 
 

 ##########
 File path: extensions/aws-lambda/deployment/src/main/java/org/apache/camel/quarkus/component/aws/lambda/deployment/AwsLambdaProcessor.java
 ##########
 @@ -0,0 +1,81 @@
+/*
+ * 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.aws.lambda.deployment;
+
+import java.util.Collection;
+import java.util.stream.Collectors;
+
+import org.apache.camel.component.aws.lambda.LambdaConfiguration;
+import org.jboss.jandex.ClassInfo;
+import org.jboss.jandex.DotName;
+import org.jboss.jandex.IndexView;
+
+import com.amazonaws.partitions.model.CredentialScope;
+import com.amazonaws.partitions.model.Endpoint;
+import com.amazonaws.partitions.model.Partition;
+import com.amazonaws.partitions.model.Partitions;
+import com.amazonaws.partitions.model.Region;
+import com.amazonaws.partitions.model.Service;
+
+import io.quarkus.deployment.annotations.BuildProducer;
+import io.quarkus.deployment.annotations.BuildStep;
+import io.quarkus.deployment.builditem.CombinedIndexBuildItem;
+import io.quarkus.deployment.builditem.ExtensionSslNativeSupportBuildItem;
+import io.quarkus.deployment.builditem.FeatureBuildItem;
+import io.quarkus.deployment.builditem.nativeimage.NativeImageResourceBuildItem;
+import io.quarkus.deployment.builditem.nativeimage.ReflectiveClassBuildItem;
+
+class AwsLambdaProcessor {
+
+    public static final String AWS_LAMBDA_APPLICATION_ARCHIVE_MARKERS = "com/amazonaws";
+
+    private static final String FEATURE = "camel-aws-lambda";
+
+    @BuildStep
+    FeatureBuildItem feature() {
+        return new FeatureBuildItem(FEATURE);
+    }
+
+    @BuildStep
+    ExtensionSslNativeSupportBuildItem activateSslNativeSupport() {
+        return new ExtensionSslNativeSupportBuildItem(FEATURE);
+    }
+
+    @BuildStep(applicationArchiveMarkers = { AWS_LAMBDA_APPLICATION_ARCHIVE_MARKERS })
+    void process(CombinedIndexBuildItem combinedIndexBuildItem,
+            BuildProducer<ReflectiveClassBuildItem> reflectiveClass,
+            BuildProducer<NativeImageResourceBuildItem> resource) {
+
+        IndexView view = combinedIndexBuildItem.getIndex();
 
 Review comment:
   I'll do a full clean up after merging this extension. I still need to make some updates after the aws-commons extension introduction
   
   

----------------------------------------------------------------
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

[GitHub] [camel-quarkus] jamesnetherton commented on a change in pull request #584: Added AWS-Lambda extension

Posted by GitBox <gi...@apache.org>.
jamesnetherton commented on a change in pull request #584: Added AWS-Lambda extension
URL: https://github.com/apache/camel-quarkus/pull/584#discussion_r362532430
 
 

 ##########
 File path: extensions/aws-lambda/deployment/src/main/java/org/apache/camel/quarkus/component/aws/lambda/deployment/AwsLambdaProcessor.java
 ##########
 @@ -0,0 +1,81 @@
+/*
+ * 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.aws.lambda.deployment;
+
+import java.util.Collection;
+import java.util.stream.Collectors;
+
+import org.apache.camel.component.aws.lambda.LambdaConfiguration;
+import org.jboss.jandex.ClassInfo;
+import org.jboss.jandex.DotName;
+import org.jboss.jandex.IndexView;
+
+import com.amazonaws.partitions.model.CredentialScope;
+import com.amazonaws.partitions.model.Endpoint;
+import com.amazonaws.partitions.model.Partition;
+import com.amazonaws.partitions.model.Partitions;
+import com.amazonaws.partitions.model.Region;
+import com.amazonaws.partitions.model.Service;
+
+import io.quarkus.deployment.annotations.BuildProducer;
+import io.quarkus.deployment.annotations.BuildStep;
+import io.quarkus.deployment.builditem.CombinedIndexBuildItem;
+import io.quarkus.deployment.builditem.ExtensionSslNativeSupportBuildItem;
+import io.quarkus.deployment.builditem.FeatureBuildItem;
+import io.quarkus.deployment.builditem.nativeimage.NativeImageResourceBuildItem;
+import io.quarkus.deployment.builditem.nativeimage.ReflectiveClassBuildItem;
+
+class AwsLambdaProcessor {
+
+    public static final String AWS_LAMBDA_APPLICATION_ARCHIVE_MARKERS = "com/amazonaws";
+
+    private static final String FEATURE = "camel-aws-lambda";
+
+    @BuildStep
+    FeatureBuildItem feature() {
+        return new FeatureBuildItem(FEATURE);
+    }
+
+    @BuildStep
+    ExtensionSslNativeSupportBuildItem activateSslNativeSupport() {
+        return new ExtensionSslNativeSupportBuildItem(FEATURE);
+    }
+
+    @BuildStep(applicationArchiveMarkers = { AWS_LAMBDA_APPLICATION_ARCHIVE_MARKERS })
+    void process(CombinedIndexBuildItem combinedIndexBuildItem,
+            BuildProducer<ReflectiveClassBuildItem> reflectiveClass,
+            BuildProducer<NativeImageResourceBuildItem> resource) {
+
+        IndexView view = combinedIndexBuildItem.getIndex();
 
 Review comment:
   Is the `CombinedIndexBuildItem` usage required? Likewise the `getImplementations` method.

----------------------------------------------------------------
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