Skip to content
  • Kailasnath Nagarkar's avatar
    b1cc9332
    Bug #27714748: @@PARSER_MAX_MEM_SIZE DOES NOT WORK FOR ROUTINES · b1cc9332
    Kailasnath Nagarkar authored
    ISSUE: parser_max_mem_size variable specifies the maximum amount
    of memory that should be used by the parser.
    Server should return error if parser requires more memory.
    This does not happen in case of routines.
    This is because of the following:
    The value of parser_max_mem_size is stored in thd's mem_root.
    While parsing SPs, an intermediate mem_root variable is used.
    This intermediate mem_root has default value of zero for maximum
    memory capacity and error reporting on reaching maximum memory
    utilization is disabled.
    Due to this, no error is reported.
    
    SOLUTION:
    Set value of maximum memory capacity and error reporting setting
    for intermediate mem_root to that of thd's maximum memory
    capacity and error reporting setting.
    b1cc9332
    Bug #27714748: @@PARSER_MAX_MEM_SIZE DOES NOT WORK FOR ROUTINES
    Kailasnath Nagarkar authored
    ISSUE: parser_max_mem_size variable specifies the maximum amount
    of memory that should be used by the parser.
    Server should return error if parser requires more memory.
    This does not happen in case of routines.
    This is because of the following:
    The value of parser_max_mem_size is stored in thd's mem_root.
    While parsing SPs, an intermediate mem_root variable is used.
    This intermediate mem_root has default value of zero for maximum
    memory capacity and error reporting on reaching maximum memory
    utilization is disabled.
    Due to this, no error is reported.
    
    SOLUTION:
    Set value of maximum memory capacity and error reporting setting
    for intermediate mem_root to that of thd's maximum memory
    capacity and error reporting setting.
Loading