summaryrefslogtreecommitdiff
path: root/include/my_sys.h
diff options
context:
space:
mode:
authorunknown <dlenev@jabberwock.localdomain>2004-04-02 00:47:20 +0400
committerunknown <dlenev@jabberwock.localdomain>2004-04-02 00:47:20 +0400
commit210871eed09beefd8b075c6b4d3a01a250be4666 (patch)
treedfc52e593ad673b6bc6c3758338f9b94e68f3daa /include/my_sys.h
parentc51e7f3a1482febd0205fef34feb6514e5f4420b (diff)
downloadmariadb-git-210871eed09beefd8b075c6b4d3a01a250be4666.tar.gz
WL#775 "Add status variable identifying binlog_cache_size shortage"
Added two status variables: binlog_cache_use - counts number of transactions that used somehow transaction temporary binary log. binlog_cache_disk_use - counts number of transactions that required disk I/O for storing info in this this binary log. include/my_sys.h: Added disk_writes member to the IO_CACHE structure for counting number of times when IO_CACHE was forced to write to disk. mysql-test/r/rpl_relayrotate.result: Fixed test result since added test for binlog_cache_use and binlog_cache_disk_use status variables. mysql-test/t/rpl_relayrotate.test: Added test for binlog_cache_use and binlog_cache_disk_use status variables. Now dropping t1 table on master too. mysys/mf_iocache.c: Added disk_writes member to the IO_CACHE structure for counting number of times when IO_CACHE was forced to write to disk. sql/handler.cc: Added support for binlog_cache_use and binlog_cache_disk_use status variable. First one is incremented if transaction used somehow transaction temporary binary log (doesn't matter in memory only or with writes to disk), the second one is incremented if this binary log was flushed to disk at some point. sql/mysql_priv.h: Added declaration of status variables binlog_cache_use and binlog_cache_disk_use. sql/mysqld.cc: Added status variables binlog_cache_use and binlog_cache_disk_use. BitKeeper/etc/logging_ok: Logging to logging@openlogging.org accepted
Diffstat (limited to 'include/my_sys.h')
-rw-r--r--include/my_sys.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/include/my_sys.h b/include/my_sys.h
index a97ddcce40d..8beaa00eb16 100644
--- a/include/my_sys.h
+++ b/include/my_sys.h
@@ -412,6 +412,11 @@ typedef struct st_io_cache /* Used when cacheing files */
IO_CACHE_CALLBACK pre_read;
IO_CACHE_CALLBACK post_read;
IO_CACHE_CALLBACK pre_close;
+ /*
+ Counts the number of times, when we were forced to use disk. We use it to
+ increase the binlog_cache_disk_use status variable.
+ */
+ ulong disk_writes;
void* arg; /* for use by pre/post_read */
char *file_name; /* if used with 'open_cached_file' */
char *dir,*prefix;