Skip to content

Commit ba7c688

Browse files
author
Satya B
committed
merge 5.0-bugteam to 5.1-bugteam
2 parents 47a9a25 + 4465e30 commit ba7c688

5 files changed

Lines changed: 11 additions & 13 deletions

File tree

include/my_base.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -441,7 +441,8 @@ enum ha_base_keytype {
441441
#define HA_ERR_INITIALIZATION 174 /* Error during initialization */
442442
#define HA_ERR_FILE_TOO_SHORT 175 /* File too short */
443443
#define HA_ERR_WRONG_CRC 176 /* Wrong CRC on page */
444-
#define HA_ERR_LAST 176 /* Copy of last error nr */
444+
#define HA_ERR_TOO_MANY_CONCURRENT_TRXS 177 /*Too many active concurrent transactions */
445+
#define HA_ERR_LAST 177 /* Copy of last error nr */
445446

446447
/* Number of different errors */
447448
#define HA_ERR_ERRORS (HA_ERR_LAST - HA_ERR_FIRST + 1)

mysys/my_handler_errors.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,7 @@ static const char *handler_error_messages[]=
6262
"The event could not be processed no other hanlder error happened",
6363
"Got a fatal error during initialzaction of handler",
6464
"File to short; Expected more data in file",
65-
"Read page with wrong checksum"
65+
"Read page with wrong checksum",
66+
"Too many active concurrent transactions"
6667
};
6768

sql/handler.cc

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -342,6 +342,7 @@ int ha_init_errors(void)
342342
SETMSG(HA_ERR_TABLE_READONLY, ER(ER_OPEN_AS_READONLY));
343343
SETMSG(HA_ERR_AUTOINC_READ_FAILED, ER(ER_AUTOINC_READ_FAILED));
344344
SETMSG(HA_ERR_AUTOINC_ERANGE, ER(ER_WARN_DATA_OUT_OF_RANGE));
345+
SETMSG(HA_ERR_TOO_MANY_CONCURRENT_TRXS, ER(ER_TOO_MANY_CONCURRENT_TRXS));
345346

346347
/* Register the error messages for use with my_error(). */
347348
return my_error_register(errmsgs, HA_ERR_FIRST, HA_ERR_LAST);
@@ -2747,6 +2748,9 @@ void handler::print_error(int error, myf errflag)
27472748
case HA_ERR_AUTOINC_ERANGE:
27482749
textno= ER_WARN_DATA_OUT_OF_RANGE;
27492750
break;
2751+
case HA_ERR_TOO_MANY_CONCURRENT_TRXS:
2752+
textno= ER_TOO_MANY_CONCURRENT_TRXS;
2753+
break;
27502754
default:
27512755
{
27522756
/* The error was "unknown" to this function.

sql/share/errmsg.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6201,3 +6201,5 @@ ER_TEMPORARY_NAME
62016201
ER_RENAMED_NAME
62026202
eng "Renamed"
62036203
swe "Namn�ndrad"
6204+
ER_TOO_MANY_CONCURRENT_TRXS
6205+
eng "Too many active concurrent transactions"

storage/innobase/handler/ha_innodb.cc

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -734,17 +734,7 @@ convert_error_code_to_mysql(
734734
return(HA_ERR_LOCK_TABLE_FULL);
735735
} else if (error == DB_TOO_MANY_CONCURRENT_TRXS) {
736736

737-
/* Once MySQL add the appropriate code to errmsg.txt then
738-
we can get rid of this #ifdef. NOTE: The code checked by
739-
the #ifdef is the suggested name for the error condition
740-
and the actual error code name could very well be different.
741-
This will require some monitoring, ie. the status
742-
of this request on our part.*/
743-
#ifdef ER_TOO_MANY_CONCURRENT_TRXS
744-
return(ER_TOO_MANY_CONCURRENT_TRXS);
745-
#else
746-
return(HA_ERR_RECORD_FILE_FULL);
747-
#endif
737+
return(HA_ERR_TOO_MANY_CONCURRENT_TRXS);
748738

749739
} else if (error == DB_UNSUPPORTED) {
750740

0 commit comments

Comments
 (0)