Bhavesh Amre created RANGER-5630:
------------------------------------
Summary: Swagger UI requests non-existent swagger.json instead of
generated openapi.json
Key: RANGER-5630
URL: https://issues.apache.org/jira/browse/RANGER-5630
Project: Ranger
Issue Type: Bug
Components: Ranger
Affects Versions: 3.0.0
Reporter: Bhavesh Amre
Assignee: Bhavesh Amre
Fix For: 3.0.0
The API documentation page exposed through {{/apidocs/swagger.html}} is not
functional. When users access the Swagger UI, it displays *"Failed to load API
definition"* and no API documentation is rendered.
Investigation shows that Swagger UI is configured to fetch the API
specification from {{{}swagger.json{}}}, while the Ranger build process
generates and packages the specification as {{{}openapi.json{}}}. Because
{{swagger.json}} does not exist in the deployed application, Swagger UI
receives an HTTP 404 response and fails to load the API definition.
*Observed Behavior*
* {{/apidocs/swagger.html}} loads successfully.
* Swagger UI static assets (JS/CSS) are served correctly.
* Request to {{/apidocs/swagger.json}} returns HTTP 404.
* API documentation is not displayed.
*Expected Behavior*
* Swagger UI should load the generated OpenAPI specification and render the
API documentation successfully.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)