camunda / camunda-bpm-platform

Flexible framework for workflow and decision automation with BPMN and DMN. Integration with Quarkus, Spring, Spring Boot, CDI.
https://camunda.com/
Apache License 2.0
4.11k stars 1.55k forks source link

Generate REST documentation from OpenAPI specification #2876

Closed mboskamp closed 1 year ago

mboskamp commented 1 year ago

User Story (Required on creation)

As a user, I want to find up-to-date information about the REST API on a dedicated documentation page. As a developer, I want to generate the REST API documentation from the existing OpenAPI specification to reduce the manual maintenance of two sources.

Functional Requirements (Required before implementation)

Technical Requirements (Required before implementation)

Breakdown

tasso94 commented 1 year ago

Hi @mboskamp,

I submitted the following PRs for review:

You can find the CI results either directly on the PR or in my comments.

Best, Tassilo

mboskamp commented 1 year ago

@tasso94, The following PRs are ready for (re-)review:

mboskamp commented 1 year ago

Some things that came to my mind while working on the new docs:

tasso94 commented 1 year ago

Hi @mboskamp,

I added some review hints on your PRs.

Since this is a bigger impactful change, can we publish redirects + documentation changes on stage before we merge the PRs to test it a little bit manually? You can involve in that too.

Regarding your comments above:

Best, Tassilo

mboskamp commented 1 year ago

@tasso94, I implemented the review hints and left a response in two cases because there are open questions.

Do you think it would be too high of a risk to merge the PRs to test them on stage? What other option do we have to publish the redirects + documentation on stage?

Regarding the ordering of the endpoints: According to one of the developers the endpoints are grouped by tags (obviously). The tag order is the one defined in the tags object. Inside a tag the endpoints are ordered as they appear in the JSON. I believe we don't apply any special order when generating the JSON so they appear in the order the files are structured in the file system.

tasso94 commented 1 year ago

@mboskamp, I thought about it more, and the minimally invasive approach would be:

  1. Only merge the changes for stage/.htaccess with master
  2. Run https://ci.cambpm.camunda.cloud/view/Docs/job/docs/job/camunda-docs-static-config/
  3. Merge the changes for camunda-docs-manual with master
  4. Job to stage docs is automatically triggered
  5. Try out if everything works as expected on stage
  6. Apply changes to redirects and/or merge the changes for live/.htaccess with master as well
  7. Run https://ci.cambpm.camunda.cloud/view/Docs/job/docs/job/camunda-docs-static-config/
  8. Make the develop docs public https://ci.cambpm.camunda.cloud/view/Docs/job/docs/job/camunda-docs-release%20(manual-develop)/

The worst that can happen if we merge everything without some stage testing is that the docs experience downtime. That has happened to me at least once in the past due to an erroneous rewrite rule. That might impact internal departments and external users (might create some load in support and the forum). Also, our Google ranking could be affected if we don't revert immediately.

Should we create a follow-up ticket to improve the order of the tags?

mboskamp commented 1 year ago

@tasso94, I scheduled the testing for Monday 21st. Let's use the list from your previous comment to merge the docs-manual changes and redirects to stage so we can test it a bit.

For the ordering of the endpoints in the docs I created a follow-up issue: #2958

mboskamp commented 1 year ago

The testing is done and the changes are reverted for now. We will merge everything with the next alpha release (7.19.0-alpha2) on December 12th.