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

[Get] exception on request service #126

Merged
merged 2 commits into from
Jan 29, 2025
Merged
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 @@ -228,7 +228,7 @@ public List<Session> getRestSessionsForSearch(JqueryRequestSessionFilter jsf) th
getColumns(
REST_SESSION, ID, API_NAME, METHOD,
PROTOCOL, PATH, QUERY, STATUS, SIZE_IN, SIZE_OUT,
START, END, USER
START, END, USER, ERR_TYPE, ERR_MSG
))
.columns(getColumns(INSTANCE, APP_NAME))
.filters(REST_SESSION.column(INSTANCE_ENV).eq(INSTANCE.column(ID)));
Expand All @@ -252,6 +252,7 @@ public List<Session> getRestSessionsForSearch(JqueryRequestSessionFilter jsf) th
session.setName(rs.getString(API_NAME.reference()));
session.setUser(rs.getString(USER.reference()));
session.setAppName(rs.getString(APP_NAME.reference()));
session.setException(getExceptionInfoIfNotNull(rs.getString(ERR_TYPE.reference()), rs.getString(ERR_MSG.reference())));
sessions.add(session);
}
return sessions;
Expand Down Expand Up @@ -519,6 +520,8 @@ private List<RestRequest> getRestRequests(List<String> cdSessions) throws SQLExc
REST_REQUEST, ID, PROTOCOL, AUTH, HOST, PORT, PATH, QUERY, METHOD, STATUS, SIZE_IN,
SIZE_OUT, CONTENT_ENCODING_IN, CONTENT_ENCODING_OUT, START, END, THREAD, REMOTE, PARENT
))
.columns(getColumns(EXCEPTION, ERR_TYPE, ERR_MSG))
.joins(REST_REQUEST.join(EXCEPTION_JOIN).build())
//.columns(REST_REQUEST.column(PARENT).as("test"), EXCEPTION.column(PARENT).as("test2"))
.filters(REST_REQUEST.column(PARENT).in(cdSessions.toArray()))
.orders(REST_REQUEST.column(START).order());
Expand All @@ -544,6 +547,7 @@ private List<RestRequest> getRestRequests(List<String> cdSessions) throws SQLExc
out.setEnd(fromNullableTimestamp(rs.getTimestamp(END.reference())));
out.setThreadName(rs.getString(THREAD.reference()));
out.setAuthScheme(rs.getString(AUTH.reference()));
out.setException(getExceptionInfoIfNotNull(rs.getString(ERR_TYPE.reference()), rs.getString(ERR_MSG.reference())));
outs.add(out);
}
return outs;
Expand Down Expand Up @@ -576,6 +580,8 @@ private List<LocalRequest> getLocalRequests(List<String> cdSessions) throws SQLE
.columns(getColumns(
LOCAL_REQUEST, ID, NAME, LOCATION, START, END, USER, THREAD, STATUS, PARENT
))
.columns(getColumns(EXCEPTION, ERR_TYPE, ERR_MSG))
.joins(LOCAL_REQUEST.join(EXCEPTION_JOIN).build())
.filters(LOCAL_REQUEST.column(PARENT).in(cdSessions.toArray()))
.orders(LOCAL_REQUEST.column(START).order());
return v.build().execute(ds, rs -> {
Expand All @@ -591,6 +597,7 @@ private List<LocalRequest> getLocalRequests(List<String> cdSessions) throws SQLE
out.setUser(rs.getString(USER.reference()));
out.setThreadName(rs.getString(THREAD.reference()));
out.setStatus(rs.getBoolean(STATUS.reference()));
out.setException(getExceptionInfoIfNotNull(rs.getString(ERR_TYPE.reference()), rs.getString(ERR_MSG.reference())));
outs.add(out);
}
return outs;
Expand Down