Commit graph

179 commits

Author SHA1 Message Date
osku
44a14a1791 Fix all function declarations to have the correct number of '=' characters. 2006-02-20 12:12:22 +00:00
osku
5ea7253fae Enhance InnoDB SQL parser:
Add support for NOT NULL in column definitions.

 Support INTEGER as an alias for INT.

 Add pars/make_bison.sh to automate parser generation.
2006-02-20 07:51:37 +00:00
osku
490dbe099a dtype_print(): Fix printing of prtype. 2006-02-17 12:58:39 +00:00
jan
10791b70ad Merge r199 from branches/5.0:
Port a change from MySQL.

Bug#8841 - CHECKSUM TABLE is broken in MyISAM
Fixed test results.
2006-02-17 07:37:51 +00:00
jan
c80a7a5078 Port a change from MySQL:
WL#1563 - Modify MySQL to support fast CREATE/DROP INDEX
Change "duplicate key" message to print key name
instead of key number.
2006-02-17 07:10:22 +00:00
osku
e3d753ab40 Add support for BINARY(n) and BLOB types in the InnoDB SQL parser. 2006-02-16 14:01:42 +00:00
marko
87839def7f buf_block_init(): Reset magic_n, buf_fix_count and io_fix to avoid
testing uninitialized variables.  (Bug #17405)
2006-02-16 07:27:54 +00:00
marko
de58802cd1 sync_thread_add_level(): Replace the if-else if-else if-...-else
chain with an equivalent switch block.
2006-02-15 09:15:54 +00:00
marko
3dc3f2a83e Replace assertions on constant conditions with preprocessor conditions. 2006-02-15 09:00:03 +00:00
marko
9ba96ba058 Revert the changes to os0file.c that were accidentally committed in r181:
os_file_create_tmpfile(): Replace the UNIV_HOTBACKUP specific
implementation with a run-time assertion failure.
2006-02-13 12:07:01 +00:00
marko
fb345eefe5 Revert r148 until MySQL AB has finally merged the code to the 5.1 tree:
Port r146 from branches/5.0:

Make innodb_flush_log_at_trx_commit a settable global variable.
2006-02-13 11:57:38 +00:00
osku
190829d2e5 Fix failing innodb.test (missing "connection default;"). 2006-02-13 09:44:33 +00:00
marko
a2ea4c42c9 Merge r175 from branches/5.0:
fil_extend_space_to_desired_size(): in UNIV_HOTBACKUP builds,
do not touch srv_data_file_sizes[] or srv_n_data_files.
2006-02-10 10:16:50 +00:00
osku
08af835d23 Apply InnoDB-specific parts of the fix for bug #9680, wrong error from
cascading update.
2006-02-10 09:16:35 +00:00
osku
3d98fd8b2a Port r172 from branches/5.0:
Fix bug #17126, CHECK TABLE blocking other queries, by releasing the
btr_search_latch periodically during the adaptive hash table validation.
2006-02-09 15:44:27 +00:00
osku
4a6b2c7022 Port r170 from branches/5.0:
Fix bug #16827, better error message if ibdata files omitted from my.cnf.
2006-02-09 12:46:53 +00:00
marko
93a75f3e9a Remove the unused field fixed_offs from dict_field_t. 2006-02-07 13:08:46 +00:00
marko
7c6d2796d8 Merge r167 from branches/5.0: Add a missing newline to the
LAST FOREIGN KEY ERROR section in SHOW INNODB STATUS output (Bug #16814).

dict_foreign_error_report(): Always print a newline after invoking
dict_print_info_on_foreign_key_in_create_format().
2006-02-06 10:36:04 +00:00
marko
ae63a417ba Port r165 from branches/5.0: Port a change from MySQL:
innodb_cache.test: save and restore query_cache_size
2006-02-06 09:08:58 +00:00
marko
77550dd2cb Port r161 from branches/5.0: Avoid breaking --with-debug builds on QNX
and other systems whose compiler pretends to be GCC 2.

univ.i: Outside __WIN__, define UNIV_INLINE as static inline.
2006-01-27 14:43:12 +00:00
marko
9b1c2825ff Import mysql-5.1-new changeset 1.1945.48.1 (Anthony Curtis):
Finalize storage engine plugins

ha_innodb.cc: remove unwanted handlerton entries; changes for show status
2006-01-27 10:17:02 +00:00
marko
82381c6bef Import mysql-5.1-new changeset 1.2012.1.8 (Sergei Golubchik):
WL#2935 - SHOW STATUS support in plugins

ha_innodb.cc, ha_innodb.h: s/struct show_var_st/SHOW_VAR/
2006-01-27 09:57:01 +00:00
marko
a99f33bb33 Import mysql-5.1-new changeset 1.2012.1.6 (Sergei Golubchik):
Remove the declaration of innodb_export_status(), as it will
from now on be invoked via a function pointer in innobase_hton.
2006-01-27 09:45:57 +00:00
marko
a4f11935e1 Import mysql-5.1-new changeset 1.2011.1.1 (Alexander Barkov):
WL#1324 table name to file name encoding

ha_innobase::create(): do not remove .frm extension

row_is_mysql_tmp_table_name(): replace '#' with '@0023'
2006-01-27 09:41:19 +00:00
marko
bf58448f97 Import those changes from mysql-5.1-new ChangeSet 1.1979 (Lars Thalmann)
that were not part of r154.  (Bug #3300)

innodb.test, innodb.result: Remove binlog related tests, because they
are not InnoDB specific; they merely require a transactional table.

ha_innobase::ha_innobase(): Add HA_PRIMARY_KEY_ALLOW_RANDOM_ACCESS
to table_flags.

ha_innobase::rnd_init(): Disable semi-consistent read for random access.
2006-01-27 09:34:55 +00:00
marko
f6e307752d Port r142 of branches/5.0 (from MySQL):
NetWare specific change to increase thread stack size.
2006-01-26 13:12:11 +00:00
marko
e62060724f Implement semi-consistent read to reduce lock conflicts at the cost
of breaking serializability.  (Bug #3300)

ha_innobase::unlock_row(): reset the "did semi consistent read" flag

ha_innobase::was_semi_consistent_read(),
ha_innobase::try_semi_consistent_read(): new methods

row_prebuilt_t, row_create_prebuilt(): add field row_read_type for
keeping track of semi-consistent reads

row_vers_build_for_semi_consistent_read(),
row_sel_build_committed_vers_for_mysql(): new functions

row_search_for_mysql(): implement semi-consistent reads
2006-01-26 10:45:27 +00:00
marko
65caba82a4 Port r152 from branches/5.0: Account for a race condition when dropping the
adaptive hash index for a B-tree page.  (Bug #16582)

btr_search_drop_page_hash_index(): Retry the operation if a hash index
with different parameters was built meanwhile.  Add diagnostics for the
case that hash node pointers to the page remain.  This fix is from Heikki.

btr_search_info_update_hash(), btr_search_info_update_slow():
Document the parameter "info" as in/out.
2006-01-24 12:13:44 +00:00
marko
382f47da7f Port r150 from branches/5.0: Port r19 from innodb-4.1/trunk:
Keep track on unflushed modifications to file spaces.  When there are tens
of thousands of file spaces, flushing all files in fil_flush_file_spaces()
would be very slow.  (Bug #15653)

fil_flush_file_spaces(): Only flush unflushed file spaces.

fil_space_t, fil_system_t: Add a list of unflushed spaces.
2006-01-23 13:47:55 +00:00
osku
6b530a167a Sync array optimizations, most importantly signal_object changed to not
call os_event_set while holding the sync array mutex.

Idea by Heikki, implementation by Osku, bug-fixes and other changes by
Heikki, and final review and cleanup by Osku.
2006-01-20 17:20:52 +00:00
marko
6234dd648e Port r146 from branches/5.0:
Make innodb_flush_log_at_trx_commit a settable global variable.
2006-01-19 13:31:02 +00:00
marko
34f1d3e6d6 Port r145 from branches/5.0:
Make innodb_thread_concurrency 0 by default, and extend the useable
range from 0 to 1000 (0 disables the thread throttling).

Remove SRV_CONCURRENCY_THRESHOLD (20).  The magic value to
disable the thread throttling is 0 from now on.
2006-01-19 13:30:20 +00:00
osku
8993745f05 Do not reset cell->wait_object to NULL when a cell in sync array is freed
since this can lead to problems.
2006-01-18 10:56:36 +00:00
osku
8c66ed2c3b Port r139 from branches/5.0:
From MySQL:

Fix bug #15108 (mysqld crashes when innodb_log_file_size is set > 4GB).
2006-01-18 10:52:53 +00:00
osku
36ef155646 Remove incorrect warning printed in sync0arr.c. 2006-01-17 14:49:11 +00:00
osku
a7d6161a1f Port r136 from branches/5.0 (slightly tweaked for 5.1):
Add BUILD/compile-innodb script.
2006-01-17 14:02:20 +00:00
jan
04e8d675c5 Forward port r133 from branches/5.0:
Remember to use noninlined versions of the functions
on ha_innodb.cc !
2006-01-17 13:08:48 +00:00
marko
0695353e23 Port r132 from branches/5.0: Port r15 from innodb-4.1:
Do not mistake TABLENAME_ibfk_0 for auto-generated id (Bug #16387).

dict_table_get_highest_foreign_id(): Ignore foreign constraint identifiers
starting with the pattern TABLENAME_ibfk_0.

innodb.test, innodb.result: Add test case.
2006-01-12 16:48:34 +00:00
osku
86e48ce5f9 Forward port r123 from branches/5.0:
Replace goto in os_event_wait with a normal loop.
2006-01-12 09:20:15 +00:00
jan
1cae280896 Forward port r127 from branches/5.0:
Fixed a bug #16229 MySQL/InnoDB uses full explicit table locks 
in trigger processing. Take a InnoDB table lock only if user has explicitly
requested a table lock. Added some additional comments to store_lock() and 
external_lock(). Added test cases for a bug. Fixed some code style errors.
2006-01-12 09:16:11 +00:00
jan
191ae582a2 Forward port r108 from from branches/5.0:
Fixed bug #15308: Problem of Order with Enum Column in 
Primary Key. Added a new test case for bug #14056.
2006-01-12 08:58:56 +00:00
jan
f94253678c Forward port r120 from branches/5.0:
Added diagnostic code trx_print() to 
innobase_query_caching_of_table_permitted() to find reason
why we are holding adaptive search latch.
2006-01-12 08:42:46 +00:00
marko
2ba82679b3 Port r125 from branches/5.0:
dict_load_columns(): Set the charset-collation code
DATA_MYSQL_BINARY_CHARSET_COLL for those binary string columns
that lack a charset-collation code, i.e., the tables were created
with an older version of MySQL/InnoDB than 4.1.2.  (Bug #16298)
2006-01-11 13:19:16 +00:00
osku
9fad661fea Forward port r121 from branches/5.0:
Optimize sync array behavior by not having the woken threads reserve the
sync array mutex.
2006-01-10 11:38:47 +00:00
marko
dd42a65a69 Port r118 from branches/5.0:
Remove some declarations of unused global variables and member variables
of class ha_innobase.
2006-01-05 07:54:34 +00:00
osku
df9fc54d97 Forward port r115 from branches/5.0:
Fix bug #16157, a crash when innodb_log_group_home_dir is set to an empty
string. This patch is from Heikki.
2006-01-04 12:52:45 +00:00
marko
33bc8a79a4 Port r114 from branches/5.0:
lock_rec_unlock(): Initialize local variable release_lock, in order to avoid
dereferencing an uninitialized pointer when no lock exists on rec.

This bug was introduced in r103 of branches/5.0, ported as r104 to trunk.
2006-01-03 13:54:05 +00:00
marko
7515828b3e Merge r112 from branches/5.0:
os_file_handle_error(): Map the error codes EXDEV, ENOTDIR, and EISDIR
to the new code OS_FILE_PATH_ERROR.  Treat this code as OS_FILE_PATH_ERROR.
This fixes the crash on RENAME TABLE when the .ibd file is a symbolic link
to a different file system.  (Bug #15991)
2006-01-03 13:36:55 +00:00
marko
6162aa3915 Port r110 from branches/5.0:
Do not log empty binlog file name at transaction commit.

trx_commit_off_kernel(): Do not write empty trx->mysql_log_file_name.
2005-12-30 12:39:17 +00:00
marko
8f7f6b3c2a Port r106 from branches/5.0:
Protect the increment and decrement operations on the statistic variables
os_n_pending_writes and os_n_pending_reads with os_file_count_mutex.
2005-12-20 15:22:49 +00:00