Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve exception messages #535

Merged
merged 2 commits into from
Sep 13, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -203,7 +203,7 @@ public void doGet(HttpServletRequest request, HttpServletResponse response) {
// plain ol' 404
} catch (FileNotFoundException e) {
// e.printStackTrace();
sendErrorResponse(response, HttpServletResponse.SC_NOT_FOUND, e.getMessage());
sendErrorResponse(response, HttpServletResponse.SC_NOT_FOUND, "FileNotFound: No such file or directory");

// DAP2Exception bad url
} catch (BadURLException e) {
Expand Down
4 changes: 2 additions & 2 deletions tds/src/main/java/thredds/server/wfs/WFSController.java
Original file line number Diff line number Diff line change
Expand Up @@ -261,8 +261,8 @@ private WFSExceptionWriter checkParametersForError(String request, String versio
// Last check to see if typenames is specified, must be for GetFeature, DescribeFeatureType
if (typeName == null) {
return new WFSExceptionWriter(
"WFS server error. For the specifed request, parameter typename or typenames must be specified.", request,
"MissingParameterValue");
"WFS server error. For the specifed request, parameter typename or typenames must be specified.",
"request", "MissingParameterValue");
}
}

Expand Down
Loading