- 14 Aug, 2018 3 commits
-
-
Monty authored
-
Monty authored
-
Michael Widenius authored
-
- 13 Aug, 2018 2 commits
-
-
Jacob Mathew authored
The problem occurs because the statement generated by Spider used an internal function name, ADD_TIME. This problem has been corrected by the fix for bug MDEV-16878 within the server, which enables Spider to generate the statement using the actual SQL function name. I have made some additional changes within Spider to fix related problems that I observed while testing. Author: Jacob Mathew. First Reviewer: Alexander Barkov. Second Reviewer: Kentoku Shiba. Cherry-Picked: Commit 4b6dccc8 on branch bb-10.3-MDEV-16398
-
Marko Mäkelä authored
This will change the InnoDB encrypted redo log format only. Unencrypted redo log will keep using the MariaDB 10.3 format. In the new encrypted redo log format, 4 additional bytes will be reserved in the redo log block trailer for storing the encryption key version. For performance reasons, the encryption key rotation (checking if the latest encryption key version is being used) is only done at log_checkpoint(). LOG_HEADER_FORMAT_CURRENT: Remove. LOG_HEADER_FORMAT_ENC_10_4: The encrypted 10.4 format. LOG_BLOCK_KEY: The encryption key version field. LOG_BLOCK_TRL_SIZE: Remove. log_t: Add accessors framing_size(), payload_size(), trailer_offset(), to be used instead of referring to LOG_BLOCK_TRL_SIZE. log_crypt_t: An operation passed to log_crypt(). log_crypt(): Perform decryption, encryption, or encryption with key rotation. Return an error if key rotation at decryption fails. On encryption, keep using the previous key if the rotation fails. At startup, old-format encrypted redo log may be written before the redo log is upgraded (rebuilt) to the latest format. log_write_up_to(): Add the parameter rotate_key=false. log_checkpoint(): Invoke log_write_up_to() with rotate_key=true.
-
- 12 Aug, 2018 1 commit
-
-
Varun Gupta authored
We hit this assert during the create of a temporary table field because the current code does not handle the case when the value of the NAME_CONST function is NULL. Fixed this by allowing creation of temporary table fields even for the case when NAME_CONST returns NULL value. Introduced tmp_table_field_from_field_type_maybe_null() function in Item class so both Item_basic_value and Item_name_const can use it. Introduced a virtual method get_func_item() in the Item class.
-
- 11 Aug, 2018 8 commits
-
-
Vladislav Vaintroub authored
Do not attempt to set TCP_NODELAY on Unix domain socket.
-
Vladislav Vaintroub authored
-
Vladislav Vaintroub authored
-
Alexander Barkov authored
A cleanup for MDEV-16939: avoid timeval initialization related problems in the future (compilation failures on Windows) Adding a helper class Timeval, to initialize "struct timeval" in a safe way. As a bonus, adding a method Timeval::trunc(), so the caller now can have one line instead of five lines (declaration, initializations of sec and usec, truncation, passing to store_TIMEVAL()).
-
Vladislav Vaintroub authored
-
Alexander Barkov authored
-
Alexander Barkov authored
The affected code is well covered by tests for MDEV-8766. Adding only the missing part: the old mode OLD_MODE_ZERO_DATE_TIME_CAST in combination with 0000-MM-00 and YYYY-00-00. The old mode in combination with 0000-00-DD was already covered, so was the new mode with all types of DATETIME values.
-
Alexander Barkov authored
Since MDEV-15091, the "lengh" parameter to str_to_time() and str_to_datetime() is of type size_t rather than uint. Fixing Time(), Temporal_with_date() and Datetime() constructors accordingly.
-
- 10 Aug, 2018 3 commits
-
-
Alexander Barkov authored
The bug did not affect behaviour in any way though :)
-
Alexander Barkov authored
MDEV-16935 Change the parameter of Field_xxx::store_TIME_with_dec() to const Datetime* and const Time*
-
Alexander Barkov authored
-
- 09 Aug, 2018 4 commits
-
-
Alexander Barkov authored
MDEV-16928 Move MYSQL_TIME initialization from Field_xxx::store_time_dec() to new constructors Time() and Datetime()
-
Alexander Barkov authored
-
Monty authored
-
Alexander Barkov authored
- Adding a helper class Sec6 to store (neg,seconds,microseconds) - Adding a helper class VSec6 (Sec6 with a flag for "IS NULL") - Wrapping related functions as methods of Sec6; * number_to_datetime() * number_to_time() * my_decimal2seconds() * Item::get_seconds() * A big piece of code in Item_func_sec_to_time::get_date() - Using the new classes in places where second-to-temporal conversion takes place: * Field_timestamp::store(double) * Field_timestamp::store(longlong) * Field_timestamp_with_dec::store_decimal(my_decimal) * Field_temporal_with_date::store(double) * Field_temporal_with_date::store(longlong) * Field_time::store(double) * Field_time::store(longlong) * Field_time::store_decimal(my_decimal) * Field_temporal_with_date::store_decimal(my_decimal) * get_interval_value() * Item_func_sec_to_time::get_date() * Item_func_from_unixtime::get_date() * Item_func_maketime::get_date() This change simplifies these methods and functions a lot. - Warnings are now sent at VSec6 initialization time, when the source data is available in its original data type representation. If Sec6::to_time() or Sec6::to_datetime() truncate data again during conversion to MYSQL_TIME, they send warnings, but only if no warnings were sent during VSec6 initialization. This helps prevents double warnings. The call for val_str() in Item_func_sec_to_time::get_date() is not needed any more, so it's removed. This change actually fixes the problem. As a good effect, FROM_UNIXTIME() and MAKETIME() now also send warnings in case if the seconds arguments is out of range. Previously these functions returned NULL silently. - Splitting the code in the global function make_truncated_value_warning() into a number of methods THD::raise_warning_xxxx(). This was needed to reuse the logic that chooses between: * ER_TRUNCATED_WRONG_VALUE * ER_WRONG_VALUE * ER_TRUNCATED_WRONG_VALUE_FOR_FIELD for non-temporal data types (Sec6). - Removing: * Item::get_seconds() * number_to_time_with_warn() as this code now resides inside methods of Sec6. - Cleanup (changes that are not directly related to the fix): * Removing calls for field_name_or_null() and passing NULL instead in Item_func_hybrid_field_type::get_date_from_{int|real}_op, because Item_func_hybrid_field_type::field_name_or_null() always returns NULL * Replacing a number of calls for make_truncated_value_warning() to calls for THD::raise_warning_xxx(). In these places we know that the execution went through a certain branch of make_truncated_value_warning(), (e.g. the exact error code is known, or field name is always NULL, or field name is always not-NULL). So calls for the entire make_truncated_value_warning() after splitting are not necessary.
-
- 07 Aug, 2018 5 commits
-
-
Otto Kekäläinen authored
If something was built using a build dependency, it will automatically be a install dependency via ${shlibs:Depends}, so no need to define it manually. This also fixes a bug related to a over autobake-deb.sh mangling the control file architecture field on Trusty and Jessie.
-
Monty authored
-
Alexander Barkov authored
Changing data types for: - seconds from longlong to ulonglong - microseconds from long to ulong in: - parameters of calc_time_diff() - parameters of calc_time_from_sec() - Members of Sec6_add This will help to reuse the code easier: all other functions use ulonglong+long for seconds/microsecond, e.g.: - number_to_time() - number_to_datetime() - number_to_datetime_with_warn() - Field_temporal_with_date::store_decimal() - my_decimal2seconds() - Item::get_seconds()
-
Monty authored
-
Alexander Barkov authored
Adding classes VDec and VDec2_lazy, according to the task description. This patch removes around 250 duplicate code lines.
-
- 05 Aug, 2018 6 commits
-
-
Otto Kekäläinen authored
This also better matches the package order in downstream, so it makes it easier to compare upstream and downstream. Also wrap-and-sort.
-
Otto Kekäläinen authored
After this there will be no need to maintain line numbers, as the extent of the sed deletion will automatically be until next empty line.
-
Otto Kekäläinen authored
-
Otto Kekäläinen authored
-
Otto Kekäläinen authored
- Update package names that had -10.3 to -10.4 - Update conflicts/breaks/replaces of to include now also 10.3, just like 10.3 had the same relationship to 10.2 - Remove some old (<< ${source:Version}) not needed anymore as we are not moving files around inside the 10.4 releases (at least yet). - Ensure all plugins depend on server or client binaries from the same release so that they for sure are binary API compatible.
-
Otto Kekäläinen authored
-
- 04 Aug, 2018 1 commit
-
-
Igor Babaev authored
Due to an obvious bug in st_select_lex_unit::reset_distinct() a union without duplicates of more than 2 selects could return a result set containing duplicate rows if this union was enclosed in ().
-
- 03 Aug, 2018 1 commit
-
-
Alexander Barkov authored
-
- 02 Aug, 2018 3 commits
-
-
Alexander Barkov authored
-
Alexander Barkov authored
-
Rasmus Johansson authored
-
- 01 Aug, 2018 2 commits
-
-
Alexander Barkov authored
-
Galina Shalygina authored
The bug appeares because of the lamely saved list of multiple equalities. To fix it and_new_conditions_to_optimized_cond() was changed.
-
- 31 Jul, 2018 1 commit
-
-
Alexander Barkov authored
-