-
Type:
Defect
-
Resolution: Done
-
Priority:
Standard
-
Affects Version/s: 2.1.5
-
Component/s: None
-
None
-
Sprint 154
We received several thousand requests for .nc files that don't actually exist in our system.
Instead of receiving an html based 404 result, the gateway was generating a 500 internal server error.
Here is the exception text:
javax.servlet.ServletException: Could not resolve view with name 'common/error/object-not-found' in servlet with name 'gateway'
What was happening, is that spring, was resolving the .nc extension to the application/x-netcdf mime-type. Then spring was trying to find a view resolver for that mime-type, but, of course, we do not have a view resolver for that mime-type and therefore, the exception above was being created.
Acceptance Criteria:
For now, we are planning on extending the ContentNegotiatingViewResolver and to use the text/html view resolver as a default if we cannot find any other view resolvers.
Instead of receiving an html based 404 result, the gateway was generating a 500 internal server error.
Here is the exception text:
javax.servlet.ServletException: Could not resolve view with name 'common/error/object-not-found' in servlet with name 'gateway'
What was happening, is that spring, was resolving the .nc extension to the application/x-netcdf mime-type. Then spring was trying to find a view resolver for that mime-type, but, of course, we do not have a view resolver for that mime-type and therefore, the exception above was being created.
Acceptance Criteria:
For now, we are planning on extending the ContentNegotiatingViewResolver and to use the text/html view resolver as a default if we cannot find any other view resolvers.