GoogleCloudPlatform / esp-v2

A service proxy that provides API management capabilities using Google Service Infrastructure.
https://cloud.google.com/endpoints/
Apache License 2.0
260 stars 167 forks source link

Support for OpenAPI 3.0 in Cloud endpoint while using ESP-v2 base image #500

Open mejuhi opened 3 years ago

mejuhi commented 3 years ago

We have a requirement where we want to use additional features available in OpenAPI 3.0 but not in OpenAPI 2.0. From the available documentation, it seems like cloud endpoint/ esp-v2 only supports OpenAPI 2.0

We would like to know if there are any plans for supporting OpenAPI 3.0, or its already in development and we will have the support for OpenAPI 3.0 soon.

qiwzhang commented 3 years ago

We don't have plan to support it.

Please see https://github.com/cloudendpoints/esp/issues/446

ESP only uses very basic fields, http_method and path. We don't validate any message fields. We will not use any new features from 3.0. One workaround is you can use 3.0 in other places, but convert your spec to 2.0 for ESP.

nicobao commented 3 years ago

@qiwzhang We are GCP customers. If we want to use OpenAPI v3 for other purposes, ESP not supporting V3 forces us to generate two OpenAPI docs from our codebase: v2 and v3. But generating v2 and v3 requires different tools and so it makes things unecessarily complicated. For example, to generate OpenAPI V2 doc for Google ESP one has to use SpringFox in Java, and to generate OpenApi V3 one has to use spring-docs which are two different librairies... Your work-around suggestion to generate v2 from v3 doesn't have any official and established solutions. Would it possible for Google to consider supporting V3?

qiwzhang commented 3 years ago

I linked this request to this issue.

bhoogter commented 3 years ago

Ridiculous question, but if asking customers to use an automated converter from OAS3.0 down to S2.0 seems like such a good idea, esp considering that the underlying engine only uses minimal fields, then why on Earth can't Google just put an automated transform "under the hood" from 3.0 -> 2.0, where no one knows and no one frankly cares,, and can actually claim some level of OAS3.0 support all the while providing better support for customers? I mean the ticket linked above was opened over three years ago... Wouldn't that better support the customer?

husseyd commented 2 years ago

Agree w/above - This is a pretty serious requirement to make both Cloud Endpoints and API Gateway serious options. Apigee X is too heavy for some use cases, and these more managed options are seeming outdated.

nika-pr commented 6 days ago

Has anyone found an elegant solution yet as to how to use OepnAPI documents based on the OpenAPI 3.0 specification on Google Cloud, ideally managed/serverless?