Skip to content

Commit

Permalink
CB-4377. Error text is more detailed to export large sql result (#2274)
Browse files Browse the repository at this point in the history
* CB-4377. Error text is more detailed to export large sql result

* CB-4377. Error text is more detailed to export large sql result

* CB-4377. Fixed typo in error message

* CB-4377. Fixed typo in error message

---------

Co-authored-by: Daria Marutkina <[email protected]>
  • Loading branch information
DenisSinelnikov and dariamarutkina authored Jan 10, 2024
1 parent 51bbc59 commit 8f66979
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,9 @@ public String createLobFile(DBCSession session) throws DBCException, IOException
}
if (binaryValue.length > fileSizeLimit.longValue()) {
throw new DBQuotaException(
"Data export quota exceeded", CBConstants.QUOTA_PROP_FILE_LIMIT, fileSizeLimit.longValue(), binaryValue.length);
"Data export quota exceeded \n Please increase the resourceQuotas parameter in configuration",
CBConstants.QUOTA_PROP_FILE_LIMIT, fileSizeLimit.longValue(), binaryValue.length
);
}
Path file = DATA_EXPORT_FOLDER.resolve(exportFileName);
Files.write(file, binaryValue);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -215,7 +215,9 @@ public void fetchRow(DBCSession session, DBCResultSet resultSet) throws DBCExcep
super.fetchRow(session, resultSet);
if (fileSizeLimit != null && getBytesWritten() > fileSizeLimit.longValue()) {
throw new DBQuotaException(
"Data export quota exceeded", QUOTA_PROP_FILE_LIMIT, fileSizeLimit.longValue(), getBytesWritten());
"Data export quota exceeded \n Please increase the resourceQuotas parameter in configuration",
QUOTA_PROP_FILE_LIMIT, fileSizeLimit.longValue(), getBytesWritten()
);
}
}
};
Expand Down

0 comments on commit 8f66979

Please sign in to comment.