Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id BC10C200C15 for ; Wed, 8 Feb 2017 19:27:29 +0100 (CET) Received: by cust-asf.ponee.io (Postfix) id BAEB2160B5A; Wed, 8 Feb 2017 18:27:29 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id 0F793160B49 for ; Wed, 8 Feb 2017 19:27:28 +0100 (CET) Received: (qmail 85070 invoked by uid 500); 8 Feb 2017 18:27:23 -0000 Mailing-List: contact dev-help@camel.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@camel.apache.org Delivered-To: mailing list dev@camel.apache.org Received: (qmail 85059 invoked by uid 99); 8 Feb 2017 18:27:22 -0000 Received: from git1-us-west.apache.org (HELO git1-us-west.apache.org) (140.211.11.23) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 08 Feb 2017 18:27:22 +0000 Received: by git1-us-west.apache.org (ASF Mail Server at git1-us-west.apache.org, from userid 33) id CFCF0DFBDB; Wed, 8 Feb 2017 18:27:22 +0000 (UTC) From: zregvart To: dev@camel.apache.org Reply-To: dev@camel.apache.org Message-ID: Subject: [GitHub] camel pull request #1454: CAMEL-10809 Introduce configurator SPI for rest su... Content-Type: text/plain Date: Wed, 8 Feb 2017 18:27:22 +0000 (UTC) archived-at: Wed, 08 Feb 2017 18:27:29 -0000 GitHub user zregvart opened a pull request: https://github.com/apache/camel/pull/1454 CAMEL-10809 Introduce configurator SPI for rest support in camel-core This removes the `SwaggerRestProducerFactory` and moves the responsibility of configuring rest clients to a new SPI (`RestEndpointConfigurer`). The rest endpoint URI has been changed to allow for syntax like: rest:[:componentSpecific] Or in case of Swagger: rest:swagger:getPetById?apiDoc=petstore.json The SPI is discovered in the `META-INF/services/org/apache/camel/rest` properties file with the prefix `configurer.` so any other components wishing to configure rest endpoints via this configurer SPI should add `rest` file with `configurer.class` property. I would like feedback on the following issues: - instead of `META-INF/.../rest` use different properties file? - design of the RestEndpointConfigurer SPI interface (for instance: is it sufficient so that it can be used to plug in headers, or authentication callbacks for rest) - integration with service discovery ({{service:...}})? - properties missing from Swagger specification (notably host, and port) -- current idea is that that should be provided from `RestConfiguration` You can merge this pull request into a Git repository by running: $ git pull https://github.com/zregvart/camel CAMEL-10809 Alternatively you can review and apply these changes as the patch at: https://github.com/apache/camel/pull/1454.patch To close this pull request, make a commit to your master/trunk branch with (at least) the following in the commit message: This closes #1454 ---- commit 59515f67706e588c2a86f2ba180be62c3264eb3a Author: Zoran Regvart Date: 2017-02-08T18:25:44Z CAMEL-10809 Introduce configurator SPI for rest... ... support in camel-core This removes the `SwaggerRestProducerFactory` and moves the responsibility of configuring rest clients to a new SPI (`RestEndpointConfigurer`). The rest endpoint URI has been changed to allow for syntax like: rest:[:componentSpecific] Or in case of Swagger: rest:swagger:getPetById?apiDoc=petstore.json The SPI is discovered in the `META-INF/services/org/apache/camel/rest` properties file with the prefix `configurer.` so any other components wishing to configure rest endpoints via this configurer SPI should add `rest` file with `configurer.class` property. I would like feedback on the following issues: - instead of `META-INF/.../rest` use different properties file? - design of the RestEndpointConfigurer SPI interface (for instance: is it sufficient so that it can be used to plug in headers, or authentication callbacks for rest) - integration with service discovery ({{service:...}})? - properties missing from Swagger specification (notably host, and port) -- current idea is that that should be provided from `RestConfiguration` ---- --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastructure@apache.org or file a JIRA ticket with INFRA. ---