Comments - MySQL "Wishlist" Session from an online travel agency
Content reproduced on this site is the property of its respective owners,
and this content is not reviewed in advance by MariaDB. The views, information and opinions
expressed by this content do not necessarily represent those of MariaDB or any other party.
I added MWL#203 "Add efficient support for BLOB and VARCHAR to HEAP/MEMORY"
This should solve both this issue and also other issues with data going to disk that doesn't have to.
I estimate this to be around 60 hours development time + 16 hour testing.
We have 'kind of' a 'C' library for this that is used by mysqlbinlog; It's far from easy to make the binary log available for scripting languages as the structure is quite complex and each event (and there are many of these) have their own format. Any ideas of how to do this are appreciated (even a suggested interface would help).
It's however relatively easy to conditionally add more data to the binary log. What information is it that you would like us to do?
Feel free to add what you like to MWL#204
MariaDB already have the statement stored in the binary log so this may already be partly solved. See http://kb.askmonty.org/en/annotate_rows_log_event
If not, please update MWL#204 with what you need!
I tried to find an existing definition for this (I am sure some other database has this) but could not find it.
The best I have come up with so far is (for single table delete's):
is to use the DB2 syntax:
DELETE from (SELECT column_list from single_table WHERE ... ORDER BY)
another option would be
DELETE FROM table_name WHERE ... [LIMIT #]] SELECT expression_list
I have added the above to: MWL#205 DELETE with result set
Doing UPDATE's is a bit harder from a syntax point of view. Lets think about that when the DELETE problem is solved. The LAST_VALUE() function Eric is working on may solve this.
That is also an option.
We created a long time ago MWL#31 "global transaction id" to solve this issue, but that is for the moment on hold waiting (we are waiting for a developer at another company to post his solution that he has worked a long time one before continuing).
Lately Kristian has been working on a sub part of this: MWL#175 "Unique ID in binlog event metadata"
The above should likely solve your problems. Please comment!
I have now created MWL#206 for all replication task that gives more parallelism.
I have added the following tasks as sub tasks for the above:
Kristian has created MWL#201 "Multi-source replication" to handle this.
For this I don't have a simple solution. I have however recorded this into MWL#209 "Setting up a new slave easily" to allow Kristian to comment.
MariaDB 5.3 supports already the command:
FLUSH TABLE WITH READ LOCK AND DISABLE CHECKPOINT.
I have added MWL#210 "Make all replication variables changeable without server restart"
The main problem is that some of the variables are very hard to change, so it's best to take these one by one.
I have added all replication variables to the MWL#210. Can you mark those that are most important to make changeable?
I have added this as MWL#211 conflict resolution for RBR replication
This one is however not an easy task. Kristian needs to write a high level description for this.
I have created MWL#21 "Compressed binary log" for this.
Already in MySQL 5.5
I have added MLW#213 Run SP on binary log rotation. (Not much to add except of the above)
The main problem is to run this asynchronously. We do have a thread designed for things like this, so it may not be that hard.
This is already done in MySQL 5.6
Kristian has done an excellent specification for this at: MWL#192 "optional nonblocking client API"
Would that satisfy your needs?
To be able to do this, I would need a spec for you of the API.
This is close to impossible to do. Functional indexes are notable easier to do.
I have recorded this in MWL#214 "Make Indexes first level objects" I also added: MWL#215 "Functional indexes"
I got a little to ambitious in trying to do it right, but this is now done in MariaDB 5.3
It's documented here http://kb.askmonty.org/en/progress-reporting and I expect that a lot of MySQL clients will support this soon!
In MariaDB 5.5 there is as far as I know some work done to make ALTER TABLE fast with InnoDB and with ADD/DROP INDEX. We have to come back to this question when we have MariaDB 5.5 ready and can look at the code.
In Aria it would be easy to add columns and drop not key columns instantly. For other storage engines this is probably harder.
I hope that for the near future the facebook solution should be good enough... (at least it's a workable solution).
The MWL#137 covers this.
Before doing this, we would need to do a deeper investigation to create a proper low level description of this. The current estimate for doing the low level design is 24 hours.
Does the MWL#137 cover this ? Why can't you do SAVEPOINTS instead ?
Based on our discussion we have added to MariaDB a variable '@@in_transaction' which will be 1 if one has executed either a BEGIN statement or if one has accessed a table and autocommit is not enabled.
Hopefully this should solve your problem.
The new page format with auto recovery uses a little more space than MyISAM but not much.
When compressing it with aria_pack it uses exactly the same space as MyISAM.
This is relatively easy to do. MWL#216
Correct.
As I helped solve one of your GET_LOCK() usages (for priority queues) I would like to know if the above is still relevant.
I did add one task regarding this: MWL#217 Get list of active GET_LOCK
Another issue could be if you are using blobs, in which case the join will use disk based tables. In this case the Aria storage engine for internal temp tables may help. Making MEMORY tables capable of handling BLOB's and big VARCHAR (MWL#203) may also help.
The worklog items we have for explain are:
I added an overview task MWL#218 "Better EXPLAIN" to link to all EXPLAIN tasks.
I was of the impression that Igor had yet another explain task. I will ask him about this.
Added MWL#219 "Query statistics" that should handle most of the requested things.
An example:
SELECT * from t1 where character_key=10;
The above key would match the following strings:
'9.999990000000099999', '10', ' 10', '10a', '10.01' etc
In theory MariaDB could internally replace the above comparison of character key with:
where character_key>"" and character_key <CHAR(ASCII(32)+1) and character key >="9.99999" and character_key<= "10.5" and character_key=10;
The above would however only work reasonable for constants, not when comparing a integer key with a character key.
In MariaDB/MySQL you can use the following variables to catch bad queries:
Saying that table scan is not allowed is not practical as if there is tables with only a few rows a table scan is the best access method.
MySQL also can log queries not using an index in the slow log, which is good. But, can we make such implied casts somehow cause an error optionally, that would make that SQL easier to find in Development.
I have recorded this in MWL#220 Disallow table scan in SELECT
Can you please remind me of what this was ?
Something else?
Added
I added task: MWL#221 "move InnoDB data files between servers"
But I don't have anyone available that could do this task just now.
Please explain what the issue is. LOAD DATA LOCAL INFILE works as follows:
MWL#222 "Make all innodb variables changeable without server restart"
It would be nice to get a list of the variables that you find most important. (As XtraDB is not our most core competence, fixing these takes a little more efforts than other tasks).
MWL#223 "Handle millions of tables (add data dictionary)"
We have already tried to do this twice in MySQL Ab. Maybe its time to get it right this time.
MWL#198.
I will ask Sergei to add some more meat for this worklog.
I created: MWL#224 "Handle millions of users & roles"
I will ask Sergei to do some estimates of this.
MLW#225 Cache VIEW's
Thanks for a clear explanation. However adding true table spaces to InnoDB is probably one-two man years of works and not practical for us to do.
The problem is that file systems will always evolve faster than any internal implementation of table spaces, so the benefit will not be that great.
MWL#226 "Replace the MYISAM mysql.* tables with Aria / XtraDB"
For this task the time estimate is very approximative. We would need to do some testing to be able to give a correct estimate.
Yes, they are not good, but you don't need and should not use them (performance is terrible) so don't think this should be a big problem
MWL#227 Add time types that contains timezone
MWL#228 Dynamic ENUM
This is a very specific task for you. We can do it but I would prioritize this a lower than other more general tasks.
I added MWL#229, but this is not a trivial task...
I assume the questions is one could use InnoDB temporary tables as internal temporary tables inside MariaDB?
This is not trivial to do because:
The interface for the internal temporary tables is a bit different than for normal tables (not much, but still).
The internal temporary tables can do things that not normal engines can:
I think that it would be notable more work to use InnoDB for internal temporary tables than fixing the MEMORY engine. With InnoDB there is also a chance that at the end we would notice that it doesn't work...