Type:
Bug
Priority:
Major
Resolution:
Fixed
Affects Version/s:
1.4.1 , 1.4.2 , 1.4.3 , 1.4.4 , 1.4.5 , 1.4.6 , 1.5.2
Statement calling procedures with fetch size (result streaming) will not finished in a stable state, according to fetch size value and procedure resultset size.
Example :
/*
DELIMITER $$
Create procedure testCallWithFetchSize ()
BEGIN
SELECT 1;
SELECT 2;
END$$
DELIMITER;
*/
try (Statement statement = sharedConnection.createStatement()) {
statement.setFetchSize( 1 );
try (ResultSet resultSet = statement.executeQuery( "CALL testCallWithFetchSize()" )) {
int rowCount = 0 ;
while (resultSet.next()) {
rowCount++;
}
}
}
//next query will fail.
Procedure result differ from other query, since can have differents results.
JDBC indicate that procedures are normally called using CallableStatement , but there is not reason to block that for PrepareStatement/statement.
Diego Dupin
made changes -
2016-09-26 15:42
Field
Original Value
New Value
Description
Statement calling procedures with fetch size (result streaming) will not finished in a stable state, according to fetch size value and procedure resultset size.
Example :
/*
DELIMITER $$
Create procedure testCallWithFetchSize ()
BEGIN
SELECT 1;
SELECT 2;
END$$
DELIMITER;
*/
{code:java}
try (Statement statement = sharedConnection.createStatement()) {
statement.setFetchSize(1);
try (ResultSet resultSet = statement.executeQuery("CALL testCallWithFetchSize()")) {
int rowCount = 0;
while(resultSet.next()) {
rowCount++;
}
}
}
//next query will fail.
{code}
Procedure result differ from other query, since procedures can have differents results. Fetch size does work using CallableStatement, but not with PrepareStatement/Statement.
JDBC indicate that procedures are normally called using [https://docs.oracle.com/javase/7/docs/api/java/sql/CallableStatement.html |CallableStatement], but there is not reason to block that for PrepareStatement/statement.
Statement calling procedures with fetch size (result streaming) will not finished in a stable state, according to fetch size value and procedure resultset size.
Example :
/*
DELIMITER $$
Create procedure testCallWithFetchSize ()
BEGIN
SELECT 1;
SELECT 2;
END$$
DELIMITER;
*/
{code:java}
try (Statement statement = sharedConnection.createStatement()) {
statement.setFetchSize(1);
try (ResultSet resultSet = statement.executeQuery("CALL testCallWithFetchSize()")) {
int rowCount = 0;
while(resultSet.next()) {
rowCount++;
}
}
}
//next query will fail.
{code}
Procedure result differ from other query, since can have differents results.
JDBC indicate that procedures are normally called using [https://docs.oracle.com/javase/7/docs/api/java/sql/CallableStatement.html |CallableStatement], but there is not reason to block that for PrepareStatement/statement.
Diego Dupin
made changes -
2016-09-26 15:43
Description
Statement calling procedures with fetch size (result streaming) will not finished in a stable state, according to fetch size value and procedure resultset size.
Example :
/*
DELIMITER $$
Create procedure testCallWithFetchSize ()
BEGIN
SELECT 1;
SELECT 2;
END$$
DELIMITER;
*/
{code:java}
try (Statement statement = sharedConnection.createStatement()) {
statement.setFetchSize(1);
try (ResultSet resultSet = statement.executeQuery("CALL testCallWithFetchSize()")) {
int rowCount = 0;
while(resultSet.next()) {
rowCount++;
}
}
}
//next query will fail.
{code}
Procedure result differ from other query, since can have differents results.
JDBC indicate that procedures are normally called using [https://docs.oracle.com/javase/7/docs/api/java/sql/CallableStatement.html |CallableStatement], but there is not reason to block that for PrepareStatement/statement.
Statement calling procedures with fetch size (result streaming) will not finished in a stable state, according to fetch size value and procedure resultset size.
Example :
/*
DELIMITER $$
Create procedure testCallWithFetchSize ()
BEGIN
SELECT 1;
SELECT 2;
END$$
DELIMITER;
*/
{code:java}
try (Statement statement = sharedConnection.createStatement()) {
statement.setFetchSize(1);
try (ResultSet resultSet = statement.executeQuery("CALL testCallWithFetchSize()")) {
int rowCount = 0;
while(resultSet.next()) {
rowCount++;
}
}
}
//next query will fail.
{code}
Procedure result differ from other query, since can have differents results.
JDBC indicate that procedures are normally called using [CallableStatement|https://docs.oracle.com/javase/7/docs/api/java/sql/CallableStatement.html ] , but there is not reason to block that for PrepareStatement/statement.
Diego Dupin
made changes -
2016-09-26 15:44
Summary
Streaming issue when using procedures not in callableStatement
Streaming issue when using procedures in PrepareStatement/Statement
Diego Dupin
made changes -
2016-09-26 17:01
Status
Open
[ 1
]
In Progress
[ 3
]
Diego Dupin
made changes -
2016-09-27 09:55
Resolution
Fixed
[ 1
]
Status
In Progress
[ 3
]
Closed
[ 6
]
Sergei Golubchik
made changes -
2021-12-06 21:27
Workflow
MariaDB v3
[ 77234
]
MariaDB v4
[ 134909
]
{"report":{"fcp":1158.4000005722046,"ttfb":339.6000003814697,"pageVisibility":"visible","entityId":58234,"key":"jira.project.issue.view-issue","isInitial":true,"threshold":1000,"elementTimings":{},"userDeviceMemory":8,"userDeviceProcessors":64,"apdex":0.5,"journeyId":"73f06c40-0876-4e4c-a140-58f1e88118a6","navigationType":0,"readyForUser":1275.3000001907349,"redirectCount":0,"resourceLoadedEnd":1957,"resourceLoadedStart":361.4000005722046,"resourceTiming":[{"duration":264.19999980926514,"initiatorType":"link","name":"https://jira.mariadb.org/s/2c21342762a6a02add1c328bed317ffd-CDN/lu2cib/820016/12ta74/0a8bac35585be7fc6c9cc5a0464cd4cf/_/download/contextbatch/css/_super/batch.css","startTime":361.4000005722046,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":361.4000005722046,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":625.6000003814697,"responseStart":0,"secureConnectionStart":0},{"duration":264.19999980926514,"initiatorType":"link","name":"https://jira.mariadb.org/s/7ebd35e77e471bc30ff0eba799ebc151-CDN/lu2cib/820016/12ta74/494e4c556ecbb29f90a3d3b4f09cb99c/_/download/contextbatch/css/jira.browse.project,project.issue.navigator,jira.view.issue,jira.general,jira.global,atl.general,-_super/batch.css?agile_global_admin_condition=true&jag=true&jira.create.linked.issue=true&slack-enabled=true&whisper-enabled=true","startTime":361.70000076293945,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":361.70000076293945,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":625.9000005722046,"responseStart":0,"secureConnectionStart":0},{"duration":274.30000019073486,"initiatorType":"script","name":"https://jira.mariadb.org/s/0917945aaa57108d00c5076fea35e069-CDN/lu2cib/820016/12ta74/0a8bac35585be7fc6c9cc5a0464cd4cf/_/download/contextbatch/js/_super/batch.js?locale=en","startTime":361.9000005722046,"connectEnd":361.9000005722046,"connectStart":361.9000005722046,"domainLookupEnd":361.9000005722046,"domainLookupStart":361.9000005722046,"fetchStart":361.9000005722046,"redirectEnd":0,"redirectStart":0,"requestStart":361.9000005722046,"responseEnd":636.2000007629395,"responseStart":636.2000007629395,"secureConnectionStart":361.9000005722046},{"duration":359.69999980926514,"initiatorType":"script","name":"https://jira.mariadb.org/s/2d8175ec2fa4c816e8023260bd8c1786-CDN/lu2cib/820016/12ta74/494e4c556ecbb29f90a3d3b4f09cb99c/_/download/contextbatch/js/jira.browse.project,project.issue.navigator,jira.view.issue,jira.general,jira.global,atl.general,-_super/batch.js?agile_global_admin_condition=true&jag=true&jira.create.linked.issue=true&locale=en&slack-enabled=true&whisper-enabled=true","startTime":362.1000003814697,"connectEnd":362.1000003814697,"connectStart":362.1000003814697,"domainLookupEnd":362.1000003814697,"domainLookupStart":362.1000003814697,"fetchStart":362.1000003814697,"redirectEnd":0,"redirectStart":0,"requestStart":362.1000003814697,"responseEnd":721.8000001907349,"responseStart":721.8000001907349,"secureConnectionStart":362.1000003814697},{"duration":389,"initiatorType":"script","name":"https://jira.mariadb.org/s/a9324d6758d385eb45c462685ad88f1d-CDN/lu2cib/820016/12ta74/c92c0caa9a024ae85b0ebdbed7fb4bd7/_/download/contextbatch/js/atl.global,-_super/batch.js?locale=en","startTime":362.4000005722046,"connectEnd":362.4000005722046,"connectStart":362.4000005722046,"domainLookupEnd":362.4000005722046,"domainLookupStart":362.4000005722046,"fetchStart":362.4000005722046,"redirectEnd":0,"redirectStart":0,"requestStart":362.4000005722046,"responseEnd":751.4000005722046,"responseStart":751.4000005722046,"secureConnectionStart":362.4000005722046},{"duration":389.3999996185303,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2cib/820016/12ta74/1.0/_/download/batch/jira.webresources:calendar-en/jira.webresources:calendar-en.js","startTime":362.6000003814697,"connectEnd":362.6000003814697,"connectStart":362.6000003814697,"domainLookupEnd":362.6000003814697,"domainLookupStart":362.6000003814697,"fetchStart":362.6000003814697,"redirectEnd":0,"redirectStart":0,"requestStart":362.6000003814697,"responseEnd":752,"responseStart":752,"secureConnectionStart":362.6000003814697},{"duration":389.6000003814697,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2cib/820016/12ta74/1.0/_/download/batch/jira.webresources:calendar-localisation-moment/jira.webresources:calendar-localisation-moment.js","startTime":362.80000019073486,"connectEnd":362.80000019073486,"connectStart":362.80000019073486,"domainLookupEnd":362.80000019073486,"domainLookupStart":362.80000019073486,"fetchStart":362.80000019073486,"redirectEnd":0,"redirectStart":0,"requestStart":362.80000019073486,"responseEnd":752.4000005722046,"responseStart":752.4000005722046,"secureConnectionStart":362.80000019073486},{"duration":447.30000019073486,"initiatorType":"link","name":"https://jira.mariadb.org/s/b04b06a02d1959df322d9cded3aeecc1-CDN/lu2cib/820016/12ta74/a2ff6aa845ffc9a1d22fe23d9ee791fc/_/download/contextbatch/css/jira.global.look-and-feel,-_super/batch.css","startTime":363,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":363,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":810.3000001907349,"responseStart":0,"secureConnectionStart":0},{"duration":389.69999980926514,"initiatorType":"script","name":"https://jira.mariadb.org/rest/api/1.0/shortcuts/820016/47140b6e0a9bc2e4913da06536125810/shortcuts.js?context=issuenavigation&context=issueaction","startTime":363.20000076293945,"connectEnd":363.20000076293945,"connectStart":363.20000076293945,"domainLookupEnd":363.20000076293945,"domainLookupStart":363.20000076293945,"fetchStart":363.20000076293945,"redirectEnd":0,"redirectStart":0,"requestStart":363.20000076293945,"responseEnd":752.9000005722046,"responseStart":752.9000005722046,"secureConnectionStart":363.20000076293945},{"duration":447.19999980926514,"initiatorType":"link","name":"https://jira.mariadb.org/s/3ac36323ba5e4eb0af2aa7ac7211b4bb-CDN/lu2cib/820016/12ta74/d176f0986478cc64f24226b3d20c140d/_/download/contextbatch/css/com.atlassian.jira.projects.sidebar.init,-_super,-project.issue.navigator,-jira.view.issue/batch.css?jira.create.linked.issue=true","startTime":363.4000005722046,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":363.4000005722046,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":810.6000003814697,"responseStart":0,"secureConnectionStart":0},{"duration":387.5,"initiatorType":"script","name":"https://jira.mariadb.org/s/5d5e8fe91fbc506585e83ea3b62ccc4b-CDN/lu2cib/820016/12ta74/d176f0986478cc64f24226b3d20c140d/_/download/contextbatch/js/com.atlassian.jira.projects.sidebar.init,-_super,-project.issue.navigator,-jira.view.issue/batch.js?jira.create.linked.issue=true&locale=en","startTime":368.1000003814697,"connectEnd":368.1000003814697,"connectStart":368.1000003814697,"domainLookupEnd":368.1000003814697,"domainLookupStart":368.1000003814697,"fetchStart":368.1000003814697,"redirectEnd":0,"redirectStart":0,"requestStart":368.1000003814697,"responseEnd":755.6000003814697,"responseStart":755.6000003814697,"secureConnectionStart":368.1000003814697},{"duration":1075.8999996185303,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2cib/820016/12ta74/1.0/_/download/batch/jira.webresources:bigpipe-js/jira.webresources:bigpipe-js.js","startTime":369.1000003814697,"connectEnd":369.1000003814697,"connectStart":369.1000003814697,"domainLookupEnd":369.1000003814697,"domainLookupStart":369.1000003814697,"fetchStart":369.1000003814697,"redirectEnd":0,"redirectStart":0,"requestStart":369.1000003814697,"responseEnd":1445,"responseStart":1445,"secureConnectionStart":369.1000003814697},{"duration":1543.3999996185303,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2cib/820016/12ta74/1.0/_/download/batch/jira.webresources:bigpipe-init/jira.webresources:bigpipe-init.js","startTime":369.1000003814697,"connectEnd":369.1000003814697,"connectStart":369.1000003814697,"domainLookupEnd":369.1000003814697,"domainLookupStart":369.1000003814697,"fetchStart":369.1000003814697,"redirectEnd":0,"redirectStart":0,"requestStart":369.1000003814697,"responseEnd":1912.5,"responseStart":1912.5,"secureConnectionStart":369.1000003814697},{"duration":604,"initiatorType":"xmlhttprequest","name":"https://jira.mariadb.org/rest/webResources/1.0/resources","startTime":841.5,"connectEnd":841.5,"connectStart":841.5,"domainLookupEnd":841.5,"domainLookupStart":841.5,"fetchStart":841.5,"redirectEnd":0,"redirectStart":0,"requestStart":841.5,"responseEnd":1445.5,"responseStart":1445.5,"secureConnectionStart":841.5},{"duration":765.6999998092651,"initiatorType":"script","name":"https://www.google-analytics.com/analytics.js","startTime":1196.3000001907349,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":1196.3000001907349,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":1962,"responseStart":0,"secureConnectionStart":0},{"duration":503.19999980926514,"initiatorType":"link","name":"https://jira.mariadb.org/s/d5715adaadd168a9002b108b2b039b50-CDN/lu2cib/820016/12ta74/be4b45e9cec53099498fa61c8b7acba4/_/download/contextbatch/css/jira.project.sidebar,-_super,-project.issue.navigator,-jira.general,-jira.browse.project,-jira.view.issue,-jira.global,-atl.general,-com.atlassian.jira.projects.sidebar.init/batch.css?agile_global_admin_condition=true&jag=true&jira.create.linked.issue=true&slack-enabled=true&whisper-enabled=true","startTime":1453.8000001907349,"connectEnd":0,"connectStart":0,"domainLookupEnd":0,"domainLookupStart":0,"fetchStart":1453.8000001907349,"redirectEnd":0,"redirectStart":0,"requestStart":0,"responseEnd":1957,"responseStart":0,"secureConnectionStart":0},{"duration":477.6000003814697,"initiatorType":"script","name":"https://jira.mariadb.org/s/d41d8cd98f00b204e9800998ecf8427e-CDN/lu2cib/820016/12ta74/e65b778d185daf5aee24936755b43da6/_/download/contextbatch/js/browser-metrics-plugin.contrib,-_super,-project.issue.navigator,-jira.view.issue,-atl.general/batch.js?agile_global_admin_condition=true&jag=true&jira.create.linked.issue=true&slack-enabled=true&whisper-enabled=true","startTime":1458.3000001907349,"connectEnd":1458.3000001907349,"connectStart":1458.3000001907349,"domainLookupEnd":1458.3000001907349,"domainLookupStart":1458.3000001907349,"fetchStart":1458.3000001907349,"redirectEnd":0,"redirectStart":0,"requestStart":1458.3000001907349,"responseEnd":1935.9000005722046,"responseStart":1935.9000005722046,"secureConnectionStart":1458.3000001907349},{"duration":478.3999996185303,"initiatorType":"script","name":"https://jira.mariadb.org/s/097ae97cb8fbec7d6ea4bbb1f26955b9-CDN/lu2cib/820016/12ta74/be4b45e9cec53099498fa61c8b7acba4/_/download/contextbatch/js/jira.project.sidebar,-_super,-project.issue.navigator,-jira.general,-jira.browse.project,-jira.view.issue,-jira.global,-atl.general,-com.atlassian.jira.projects.sidebar.init/batch.js?agile_global_admin_condition=true&jag=true&jira.create.linked.issue=true&locale=en&slack-enabled=true&whisper-enabled=true","startTime":1459.9000005722046,"connectEnd":1459.9000005722046,"connectStart":1459.9000005722046,"domainLookupEnd":1459.9000005722046,"domainLookupStart":1459.9000005722046,"fetchStart":1459.9000005722046,"redirectEnd":0,"redirectStart":0,"requestStart":1459.9000005722046,"responseEnd":1938.3000001907349,"responseStart":1938.3000001907349,"secureConnectionStart":1459.9000005722046}],"fetchStart":0,"domainLookupStart":0,"domainLookupEnd":0,"connectStart":0,"connectEnd":0,"requestStart":147,"responseStart":340,"responseEnd":354,"domLoading":344,"domInteractive":1988,"domContentLoadedEventStart":1988,"domContentLoadedEventEnd":2082,"domComplete":2387,"loadEventStart":2387,"loadEventEnd":2388,"userAgent":"Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; ClaudeBot/1.0; +claudebot@anthropic.com)","marks":[{"name":"bigPipe.sidebar-id.start","time":1917.1000003814697},{"name":"bigPipe.sidebar-id.end","time":1918},{"name":"bigPipe.activity-panel-pipe-id.start","time":1918.1000003814697},{"name":"bigPipe.activity-panel-pipe-id.end","time":1920.2000007629395},{"name":"activityTabFullyLoaded","time":2103.4000005722046}],"measures":[],"correlationId":"730bf7d76614f6","effectiveType":"4g","downlink":10,"rtt":0,"serverDuration":127,"dbReadsTimeInMs":16,"dbConnsTimeInMs":26,"applicationHash":"9d11dbea5f4be3d4cc21f03a88dd11d8c8687422","experiments":[]}}