[
https://issues.apache.org/jira/browse/SOLR-16346?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17623129#comment-17623129
]
ASF subversion and git services commented on SOLR-16346:
--------------------------------------------------------
Commit 4711e21834284552a501d5992df78398d2df4492 in solr's branch
refs/heads/branch_9x from Jason Gerlowski
[ https://gitbox.apache.org/repos/asf?p=solr.git;h=4711e218342 ]
SOLR-16346: Generate OpenAPI spec
This commit introduces the 'swagger-gradle-plugin' build-plugin to
Solr's gradle build. Currently, it's invoked through a new task,
'resolve', that scans the solr-core classpath and generates an OpenAPI
spec based on any detected JAX-RS APIs.
This spec (located in the 'core' module's `build/generated/openapi`
directory) can be used out of the box by any OpenAPI compatible
tooling, such as the code-generator offered by 'swagger' or the web UI
offered by 'Redocly'. Closer integration with some of this tooling,
particularly as it relates to code-generation, should come in upcoming
commits.
> Generate (and use) OpenAPI spec for v2 APIs
> -------------------------------------------
>
> Key: SOLR-16346
> URL: https://issues.apache.org/jira/browse/SOLR-16346
> Project: Solr
> Issue Type: Improvement
> Security Level: Public(Default Security Level. Issues are Public)
> Components: v2 API
> Affects Versions: main (10.0)
> Reporter: Jason Gerlowski
> Assignee: Jason Gerlowski
> Priority: Major
> Time Spent: 2h 50m
> Remaining Estimate: 0h
>
> An integration with [OpenAPI|https://www.openapis.org/] and its tooling has a
> lot to offer Solr. Once generated, an OpenAPI specification can be used to:
> * [generate clients|https://github.com/OpenAPITools/openapi-generator] for
> multiple programming languages
> * power a web UI to document and help users craft API calls (e.g.
> [redoc|https://github.com/Redocly/redoc]
> * [detect breaking API changes|https://github.com/Azure/openapi-diff] across
> releases.
> Of course, these benefits are only useful if we take pains to document our
> API inputs and outputs (probably with annotations that live directly in our
> Java code). But I think there's enough upside to be worth that trouble.
> This ticket aims to cover integrating OpenAPI into our gradle build, so that
> a single task can be used to generate an OpenAPI spec. (It might also make
> sense to use this ticket to cover generating client bindings for one or more
> languages.)
--
This message was sent by Atlassian Jira
(v8.20.10#820010)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]