1. 18 Mar, 2008 2 commits
    • unknown's avatar
      Merge adventure.(none):/home/thek/Development/cpp/bug25175/my51-bug25175 · ef82f206
      unknown authored
      into  adventure.(none):/home/thek/Development/cpp/mysql-5.1-runtime
      
      
      ef82f206
    • unknown's avatar
      Bug#25175 Too much memory used by MySQL grant system · 00182991
      unknown authored
      Each time the server reloads privileges containing table grants, the 
      system will allocate too much memory than needed because of badly
      chosen growth prediction in the underlying dynamic arrays.
      
      This patch introduces a new signature to the hash container initializer
      which enables a much more pessimistic approach in favour for more
      efficient memory useage.
      
      This patch was supplied by Google Inc.
      
      
      include/hash.h:
        * New signature for _hash_init.
        * Defined new function hash_init2 which takes growth_size argument.
      mysys/hash.c:
        * New signature for _hash_init.
      sql/sql_acl.cc:
        * Changed hash_init signature so that it takes a 'growth_size' smaller
        than the default. Each time a GRANT_TABLE is allocated a pre-allocated
        dynamic array is instantiated. A large growth size can result in too
        many unused hash-entries per table-entry and thus be a waste of free
        memory.
      00182991
  2. 13 Mar, 2008 4 commits
    • unknown's avatar
      Merge bk-internal.mysql.com:/home/bk/mysql-5.1-runtime · 64cba9ba
      unknown authored
      into  mysql.com:/Users/davi/mysql/mysql-5.1-runtime
      
      
      64cba9ba
    • unknown's avatar
      Bug#34891 sp_notembedded.test fails sporadically · 416ab853
      unknown authored
      The problem is that since MyISAM's concurrent_insert is on by
      default some concurrent SELECT statements might not see changes
      made by INSERT statements in other connections, even if the
      INSERT statement has returned.
      
      The solution is to disable concurrent_insert so that INSERT
      statements returns after the data is actually visible to other
      statements.
      
      
      mysql-test/r/flush_read_lock_kill.result:
        Restore old value of @@global.concurrent_insert
      mysql-test/r/kill.result:
        Restore old value of @@global.concurrent_insert
      mysql-test/r/sp_notembedded.result:
        Update test case result
      mysql-test/t/flush_read_lock_kill.test:
        Restore old value of @@global.concurrent_insert so it
        doesn't affect other tests.
      mysql-test/t/kill.test:
        Restore old value of @@global.concurrent_insert so it
        doesn't affect other tests.
      mysql-test/t/sp_notembedded.test:
        Disable and restore concurrent_insert value at the end of the
        test case. The test case for Bug 29936 requires that the inserted
        rows need to be visible before a SELECT statement is queued in
        another connection.
        
        Remove sleep at the start of the test, it's not necessary to log
        the result of the processlist command, showing the warnings has
        the same end result.
      416ab853
    • unknown's avatar
      Merge quad.:/mnt/raid/alik/MySQL/devel/5.1-rt · 1f3c062b
      unknown authored
      into  quad.:/mnt/raid/alik/MySQL/devel/bug-35074/5.1-rt-bug35074
      
      
      1f3c062b
    • unknown's avatar
      Fix for Bug#35074: max_used_connections is not correct. · c167501b
      unknown authored
      The problem was that number of threads was used to calculate
      max_used_connections.
      
      The fix is to use number of active connections.
      
      
      mysql-test/r/connect.result:
        Update result file.
      mysql-test/t/connect.test:
        - Add a test case for Bug#35074: max_used_connections is not correct;
        - Make a test case for Bug#33507 more stable.
      sql/mysqld.cc:
        Use number of connections insetad of threads
        to calculate max_used_connections.
      c167501b
  3. 12 Mar, 2008 6 commits
    • unknown's avatar
      Fix manual merge. · 054341a6
      unknown authored
      054341a6
    • unknown's avatar
      Fix for Bug#33507: Event scheduler creates more threads · b279be38
      unknown authored
      than max_connections -- which results in user lockout.
      
      The problem was that the variable thread_count that contains
      the number of active threads was interpreted as a number of
      active connections.
      
      The fix is to introduce a new counter for active connections.
      
      
      mysql-test/r/connect.result:
        A test case for Bug#33507: Event scheduler creates more threads
        than max_connections -- which results in user lockout.
      mysql-test/t/connect.test:
        A test case for Bug#33507: Event scheduler creates more threads
        than max_connections -- which results in user lockout.
      sql/mysql_priv.h:
        1. Polishing: login_connection() and end_connection() need not
           to be public.
        
        2. Introduce connection_count -- a variable to contain the number
           of active connections. It is protected by LOCK_connection_count.
      sql/mysqld.cc:
        Use connection_count to count active connections.
      sql/sql_connect.cc:
        1. Use connection_count to count active connections.
        2. Make login_connection(), end_connection() private for the module
        as they had to be.
      b279be38
    • unknown's avatar
      Fix manual merge. · d80e7ce4
      unknown authored
      d80e7ce4
    • unknown's avatar
      Merge quad.:/mnt/raid/alik/MySQL/devel/5.0-rt · d958f298
      unknown authored
      into  quad.:/mnt/raid/alik/MySQL/devel/5.1-rt-merged
      
      
      sql/sql_delete.cc:
        Manually merged.
      d958f298
    • unknown's avatar
      A fix for Bug#34643: TRUNCATE crash if trigger and foreign key. · 326c4e90
      unknown authored
        
      In cases when TRUNCATE was executed by invoking mysql_delete() rather
      than by table recreation (for example, when TRUNCATE was issued on
      InnoDB table with is referenced by foreign key) triggers were invoked.
      In debug builds this also led to crash because of an assertion, which
      assumes that some preliminary actions take place before trigger 
      invocation, which doesn't happen in case of TRUNCATE.
      
      The fix is not to execute triggers in mysql_delete() when this
      function is used by TRUNCATE.
      
      
      mysql-test/r/trigger-trans.result:
        Update result file.
      mysql-test/t/trigger-trans.test:
        A test case for Bug#34643: TRUNCATE crash if trigger and foreign key.
      sql/sql_delete.cc:
        Do not process triggers in TRUNCATE.
      326c4e90
    • unknown's avatar
      Merge quad.:/mnt/raid/alik/MySQL/devel/5.0-rt · b0fda34b
      unknown authored
      into  quad.:/mnt/raid/alik/MySQL/devel/5.1-rt
      
      
      tests/mysql_client_test.c:
        Manually merged.
      b0fda34b
  4. 10 Mar, 2008 1 commit
  5. 06 Mar, 2008 2 commits
    • unknown's avatar
      Bug#35103 mysql_client_test::test_bug29948 causes sporadic failures · aafb492d
      unknown authored
      Disable test case for bug 29948, which is causing sporadically
      failures in other tests inside mysql_client_test.
      
      
      tests/mysql_client_test.c:
        Disable test case.
      aafb492d
    • unknown's avatar
      Bug#25132 disabled query cache: Qcache_free_blocks = 1 · c184cd63
      unknown authored
      The initial value of free memory blocks in 0. When the query cache is enabled 
      a new memory block gets allocated and is assigned number 1. The free memory
      block is later split each time query cache memory is allocated for new blocks.
      This means that the free memory block counter won't be reduced to zero when
      the number of allocated blocks are zero, but rather one. To avoid confusion
      this patch changes this behavior so that the free memory block counter is
      reset to zero when the query cache is disabled.
      Note that when the query cache is enabled and resized the free memory block
      counter was still calculated correctly.
      
      
      mysql-test/r/query_cache.result:
        test case
      mysql-test/t/query_cache.test:
        test case
      sql/sql_cache.cc:
        Restore the memory block count to 0 for consistency.
      c184cd63
  6. 05 Mar, 2008 1 commit
  7. 04 Mar, 2008 5 commits
  8. 03 Mar, 2008 1 commit
  9. 29 Feb, 2008 2 commits
  10. 28 Feb, 2008 6 commits
    • unknown's avatar
      Merge buzz.(none):/home/davi/mysql-5.0-runtime · 05480a88
      unknown authored
      into  buzz.(none):/home/davi/mysql-5.1-runtime
      
      
      mysql-test/r/ps.result:
        Auto merged
      mysql-test/t/limit.test:
        Auto merged
      mysql-test/t/ps.test:
        Auto merged
      sql/item.h:
        Auto merged
      sql/item_func.cc:
        Auto merged
      sql/sql_class.h:
        Auto merged
      sql/item.cc:
        Auto merged
      mysql-test/suite/rpl/r/rpl_user_variables.result:
        Manual merge
      mysql-test/suite/rpl/t/rpl_user_variables.test:
        Manual merge
      sql/sql_yacc.yy:
        Manual merge
      05480a88
    • unknown's avatar
      Post-merge fix for Bug 33851. The initialization order of members · 8b779456
      unknown authored
      must match the order which they were declared in the class definition. 
      
      
      sql/item.cc:
        Fix initialization order, parameter was the last one declared.
      8b779456
    • unknown's avatar
      Bug#34655 Compile error · 33a4e760
      unknown authored
      Rename client_last_error to last_error and client_last_errno to last_errno
      to not break connectors which use the internal net structure for error handling.
      
      
      include/mysql_com.h:
        Rename client_last_error to last_error, client_last_errno to last_errno.
      include/mysql_h.ic:
        Rename client_last_error to last_error, client_last_errno to last_errno.
      libmysql/libmysql.c:
        Rename client_last_error to last_error, client_last_errno to last_errno.
      libmysql/manager.c:
        Rename client_last_error to last_error, client_last_errno to last_errno.
      libmysqld/lib_sql.cc:
        Rename client_last_error to last_error, client_last_errno to last_errno.
      libmysqld/libmysqld.c:
        Rename client_last_error to last_error, client_last_errno to last_errno.
      server-tools/instance-manager/mysql_connection.cc:
        Rename client_last_error to last_error, client_last_errno to last_errno.
      sql/log_event.cc:
        Rename client_last_error to last_error, client_last_errno to last_errno.
      sql-common/client.c:
        Rename client_last_error to last_error, client_last_errno to last_errno.
      sql/log_event_old.cc:
        Rename client_last_error to last_error, client_last_errno to last_errno.
      sql/net_serv.cc:
        Rename client_last_error to last_error, client_last_errno to last_errno.
      sql/repl_failsafe.cc:
        Rename client_last_error to last_error, client_last_errno to last_errno.
      33a4e760
    • unknown's avatar
      Bug#33851 Passing UNSIGNED param to EXECUTE returns ERROR 1210 · 1164e2bc
      unknown authored
      The problem is that passing anything other than a integer to a limit
      clause in a prepared statement would fail. This limitation was introduced
      to avoid replication problems (e.g: replicating the statement with a
      string argument would cause a parse failure in the slave).
      
      The solution is to convert arguments to the limit clause to a integer
      value and use this converted value when persisting the query to the log.
      
      
      mysql-test/r/limit.result:
        Update test case result.
      mysql-test/r/ps.result:
        Add test case result for Bug#33851
      mysql-test/r/rpl_user_variables.result:
        Test case result for replication of prepared statement with
        limit clause.
      mysql-test/t/limit.test:
        Test parameters to limit clause.
      mysql-test/t/ps.test:
        Add test case for Bug#33851
      mysql-test/t/rpl_user_variables.test:
        Test replication of a parameter which value is converted.
      sql/item.cc:
        Convert value to integer if it's a parameter to a limit clause.
      sql/item.h:
        Flag signal that item is a parameter to a limit clause.
      sql/item_func.cc:
        Const member functions, object is not mutated.
      sql/sql_class.h:
        Const member functions, object is not mutated.
      sql/sql_yacc.yy:
        Flag that item is a parameter to a limit clause.
      1164e2bc
    • unknown's avatar
      Disable test case due to Bug#34891: sp_notembedded.test fails · 944f2599
      unknown authored
      sporadically.
      
      
      mysql-test/r/sp_notembedded.result:
        Disable test case.
      mysql-test/t/sp_notembedded.test:
        Disable test case.
      944f2599
    • unknown's avatar
      Fix for Bug#34852: SHOW OPEN TABLES output is not repeatable · ce7b8e12
      unknown authored
      (show_check.test fails sporadically).
      
      Fix test case for Bug#12183 to make it stable.
      
      
      mysql-test/r/show_check.result:
        Fix result file.
      mysql-test/t/show_check.test:
        Make test case for Bug#12183 stable.
      ce7b8e12
  11. 27 Feb, 2008 7 commits
  12. 26 Feb, 2008 3 commits
    • unknown's avatar
      Merge quad.:/mnt/raid/alik/MySQL/devel/5.0-rt · fe7035a7
      unknown authored
      into  quad.:/mnt/raid/alik/MySQL/devel/5.1-rt
      
      
      mysql-test/r/view.result:
        Auto merged
      fe7035a7
    • unknown's avatar
      Merge quad.:/mnt/raid/alik/MySQL/devel/5.1 · 336f2c7e
      unknown authored
      into  quad.:/mnt/raid/alik/MySQL/devel/5.1-rt-merged
      
      
      client/mysqltest.c:
        Auto merged
      mysql-test/r/view.result:
        Auto merged
      sql/ha_ndbcluster.cc:
        Auto merged
      sql/ha_ndbcluster_binlog.cc:
        Auto merged
      sql/handler.cc:
        Auto merged
      sql/log_event.cc:
        Auto merged
      sql/mysql_priv.h:
        Auto merged
      sql/mysqld.cc:
        Auto merged
      sql/set_var.cc:
        Auto merged
      sql/sql_class.cc:
        Auto merged
      sql/sql_connect.cc:
        Auto merged
      sql/sql_parse.cc:
        Auto merged
      tests/mysql_client_test.c:
        Auto merged
      mysql-test/suite/rpl_ndb/t/disabled.def:
        Manually merged.
      mysql-test/t/disabled.def:
        Manually merged.
      336f2c7e
    • unknown's avatar
      Merge quad.:/mnt/raid/alik/MySQL/devel/5.0 · a86e504f
      unknown authored
      into  quad.:/mnt/raid/alik/MySQL/devel/5.0-rt-merged
      
      
      mysql-test/r/view.result:
        Auto merged
      a86e504f