Home |  MySQL Buzz |  FAQ |  Feeds |  Submit your blog feed |  Feedback |  Archive |  Aggregate feed RSS 2.0 English Deutsch Español Français Italiano 日本語 Русский Português 中文
Previous 30 Newer Entries Showing entries 91 to 120 of 245 Next 30 Older Entries

Displaying posts with tag: Programming (reset)

Tech Messages | 2010-04-24
+0 Vote Up -0Vote Down

A special extended edition of Tech Messages for 2010-04-15 through 2010-04-24:

  [Read more...]
Fixing MySQL group commit (part 3)
+2 Vote Up -0Vote Down

This is the third and final article in a series about group commit in MySQL. The first article discussed the background: group commit in MySQL does not work when the binary log is enabled. The second article explained the part of the InnoDB code that is responsible for the problem.

So how do we fix group commit in MySQL? As we saw in the second article of this series, we can just eliminate the prepare_commit_mutex from InnoDB, extend the binary logging to do group commit by itself, and that would solve the problem.

However, we might be able to do even better. As explained in the first article, with binary logging

  [Read more...]
Fixing MySQL group commit (part 2)
+3 Vote Up -0Vote Down

This is the second in a series of three articles about ideas for implementing full support for group commit in MariaDB. The first article discussed the background: group commit in MySQL does not work when the binary log is enabled. See also the third article.

Internally, InnoDB (and hence XtraDB) do support group commit. The way this works is seen in the innobase_commit() function. The work in this function is split into two parts. First, a "fast" part, which registers the commit in memory:

    trx->flush_log_later = TRUE;
    trx->flush_log_later = FALSE;
Second, a "slow" part, which writes and fsync's the commit to disk to make it durable:

  [Read more...]
Fixing MySQL group commit (part 1)
+4 Vote Up -1Vote Down

This is the first in a series of three articles about ideas for implementing full support for group commit in MariaDB (for the other parts see the second and third articles). Group commit is an important optimisation for databases that helps mitigate the latency of physically writing data to permanent storage. Group commit can have a dramatic effect on performance, as the following graph shows:

The rising blue and yellow lines show transactions per second when group commit is working, showing greatly improved throughput as the parallelism (number of concurrently running transactions) increases. The flat red and green lines show transactions per second with no group

  [Read more...]
Debugging memory leaks in plugins with Valgrind
+2 Vote Up -0Vote Down

I had an interesting IRC discussion the other day with Monty Taylor about what turned out to be a limitation in Valgrind with respect to debugging memory leaks in dynamically loaded plugins.

Monty Taylor's original problem was with Drizzle, but as it turns out, it is common to all of the MySQL-derived code bases. When there is a memory leak from an allocation in a dynamically loaded plugin, Valgrind will detect the leak, but the part of the stack trace that is within the plugin shows up as an unhelpful three question marks "???":

==1287== 400 bytes in 4 blocks are definitely lost in loss record 5 of 8
==1287==    at 0x4C22FAB: malloc (vg_replace_malloc.c:207)
==1287==    by 0x126A2186: ???
==1287==    by 0x7C8E01: ha_initialize_handlerton(st_plugin_int*) (handler.cc:429)
==1287==    by 0x88ADD6:

  [Read more...]
Reviewed: Python Testing by Daniel Arbuckle
+0 Vote Up -0Vote Down

I’ve recently had the pleasure of reading “Python Testing: An easy and convenient approach to testing your python projects” from Packt Publishing. It’s been a quick read but a solid set of instructions on the different methods for the subject.

The book starts out very quickly with details about the various methods that are available, the means of automation for testing, and of course the environment you’d want to be in for working on the subjects that the book covers. It then, in the second chapter, moves into the guts of testing by describing the basics of doctest via syntax and some simple examples, and then moves on to a real world example via the AVL tree. It’s all very basic

  [Read more...]
Event based programming vs threading by Rob von Behren, Jeremy Condit and Eric Brewer
+0 Vote Up -0Vote Down

Saw this interesting paper about highly concurrent programming methods and figured the word should be spread! It’s not new material but it’s a good read. See the full article here: http://www.usenix.org/events/hotos03/tech/full_papers/vonbehren/vonbehren_html/

“Highly concurrent applications such as Internet servers and transaction processing databases present a number of challenges to application designers. First, handling large numbers of concurrent tasks requires the use of scalable data structures. Second, these systems typically operate near maximum capacity, which creates resource contention and high sensitivity to scheduling decisions; overload must be handled with care to avoid thrashing. Finally, race conditions and subtle corner cases are common, which makes

  [Read more...]
Four short links: 31 March 2010
+0 Vote Up -0Vote Down

  • ZeroMQ -- bold claim of "Fastest. Messaging. Ever." LGPL, C++ with bindings for many languages, past version 2 already. (via edd on Twitter)
  • Prediction Market News (David Pennock) -- HSX is going to be a real marketplace with real $. The real HSX will of course say goodbye to the virtual specialist and the opening weekend adjust, two facets of the game that make it fun to play, but that create significant amounts of (virtual) wealth out of thin air. The Cantor Gaming group is engaged in other interesting initiatives. They are taking over a sportsbook in Las Vegas and turning it into more of a derivatives exchange with live in-game betting, a step toward my dream of a geek-friendly
  •   [Read more...]
    Kontrollcomm – remote database and system command execution webapp
    +2 Vote Up -0Vote Down
    I’m pleased to announce the first release of Kontrollcomm – “The Server Command Automation Interface” is a web-based application that automates remote command execution on linux and unix based servers. There are three main areas of the application: Hosts, Templates, and Commands. The use is very simple: all of your hosts are setup in the [...]
    Reviewed: Managing Software Development with SVN and Trac
    +0 Vote Up -0Vote Down

    I’ve recently been migrating my wiki/documentation for Kontrollbase to Trac. For those that are not aware, Trac is a web-based documentation/wiki/Subversion tool that is used by countless number of software projects. Subversion, of course, is a software collaboration and code management repository that manages branches/tags/trunk files with revision control. It’s one of the most heavily used open-source code repositories available. Given that I use SVN (subversion) for all of my software applications and am now using Trac, the book “Managing Software Development with Trac and Subversion” by David J Murphy comes as a useful and great

      [Read more...]
    Building MySQL Server with CMake on Linux/Unix
    Employee +4 Vote Up -0Vote Down

    CMake is a cross-platform, open-source build system, maintained by Kitware, Inc.

    From the CMake.org home page:

    CMake is a family of tools designed to build, test and package software. CMake is used to control the software compilation process using simple platform and compiler independent configuration files. CMake generates native makefiles and workspaces that can be used in the compiler environment of your choice.

    It has been used for building the MySQL Server on Windows since MySQL 5.0 – the initial CMake build support was added in August 2006.


      [Read more...]
    Kontrollkit – new version is available for download!
    +0 Vote Up -0Vote Down
    Just a quick notice to let everyone know that there is a new version of Kontrollkit available. There are two new scripts included as well as some good updates to the my.cnf files. You can download the new version here: http://kontrollsoft.com/software-downloads kt-mysql-systemcheck – generates a report for point-in-time system status that is useful for troubleshooting MySQL [...]
    Tech Messages | 2010-02-24
    +0 Vote Up -0Vote Down

    A special extended edition of Tech Messages for 2010-02-20 through 2010-02-24:

      [Read more...]
    Is emacs not coloring your Python comments?
    +0 Vote Up -1Vote Down

    This is a simple matter with a simple solution that might help someone save time and confusion. Emacs wasn’t coloring my comments correctly so I went ahead and had it change them to red-italic. If you are having similar issues you can drop the following into your home directory’s .emacs file. Enjoy. Keep in mind that if you are using emacs in a terminal session as opposed to the X-server gui then you will not see the italics.

    (global-font-lock-mode 1)
    '(gud-gdb-command-name "gdb --annotate=1")
    '(large-file-warning-threshold nil))
    '(font-lock-comment-face ((((class color) (background light)) (:foreground "red" :slant italic)))))

    Here's An Exclusive 10% Off NuSphere PHPEd Discount Coupon Code (Also Includes NuCoder And PHPDoc)
    +0 Vote Up -0Vote Down


    I don't know about you, but I can't imagine doing my PHP development without an IDE with a debugger anymore.

    It autocompletes for me, it lets me step through each line of code, jumping around the project, execute and change the code flow on the fly, and does many other things that make me feel cozy, comfortable, and efficient at PHP development (as opposed to, say, CPP which makes me feel cold and lonely).

    There are many PHP IDEs out there and I've tried most of them (including the free PHPEclipse and PDT for Eclipse) but kept coming back to NuSphere's PHPEd every time. The other ones

      [Read more...]
    RESTful PHP Web Services – reviewed
    +1 Vote Up -0Vote Down

    I’ve been using a lot of RESTful services these days and have been waiting for a good book that is dedicated to the topic. I recently received a copy of ‘RESTful PHP Web Services’, which does a successful job of outlining proven concepts in current web technology. If you want to learn the methods for creating and consuming RESTful services then you will find many examples in this book. From the architectural plans to well thought out code samples, the book covers a lot of ground in a relatively quick read.

    The first chapter gives the reader a quick introduction to RESTful services and the most common PHP frameworks in use at the time of writing. I particularly enjoyed the section on the Zend framework due to

      [Read more...]
    Rediscovering Programming with Python, Cocoa and PyObjC
    Employee +0 Vote Up -0Vote Down

    Use PyObjC to code Python under the Mac Cocoa framework, and MySQLdb to interface with MySQL! That’s the advice I got in reply to my recent blog. The discussions were so inspiring that I spent all time when out running yesterday daydreaming about how wonderful it will be to rediscover the aesthetics of programming and regain the control over my personal IT.

    So, to recap a bit of my thinking: Once a programmer, always a programmer. If you’ve learned how to code and to master your own IT life to a certain degree, you get used to it. At

      [Read more...]
    Follow-up To Loading CSS And JS Conditionally
    +0 Vote Up -0Vote Down

    First of all, I'd like to thank everyone who read and gave their 2 cents about the [WordPress Plugin Development] How To Include CSS and JavaScript Conditionally And Only When Needed By The Posts post. The article was well received and will hopefully spark some optimizations around loading styles and scripts.

    Here are some discussions and mentions around the web:

      [Read more...]
    Four short links: 11 January 2010
    +0 Vote Up -0Vote Down

  • mytop -- a MySQL top implementation to show you why your server is so damn slow right now.
  • What Could Kill Elegant High-Value Participatory Project? -- The problem was not that the system was buggy or hard to use, but that it disrupted staff expectations and behavior. It introduced new challenges for staff [...]. Rather than adapt to these challenges, they removed the system. [...] No librarian would get rid of all the Harry Potter books because they are "too popular." No museum would stop offering an educational program that was "too successful." These are familiar challenges that come with the job and are seen to have benefit. But if tagging creates a line or people spend too much time
  •   [Read more...]
    mysql-snmp 1.0 – SNMP monitoring for MySQL
    +1 Vote Up -0Vote Down

    I’m really proud to announce the release of the version 1.0 of mysql-snmp.

    What is mysql-snmp?

    mysql-snmp is a mix between the excellent MySQL Cacti Templates and a Net-SNMP agent. The idea is that combining the power of the MySQL Cacti Templates and any SNMP based monitoring would unleash a powerful mysql monitoring system. Of course this project favorite monitoring system is OpenNMS.

    mysql-snmp is shipped with the necessary OpenNMS configuration files, but any other SNMP monitoring software can be used (provided

      [Read more...]
    Materialized view makes login process 25k times faster
    +0 Vote Up -1Vote Down
    It may sound like a dramatic number, and that’s because it is. One thing that is enjoyable about working on beta applications is finding new solutions and better methods to improve the user experience. The original method for displaying the recent addition of overview analytics data in the beta version of Kontrollbase was to run [...]
    How To Fix Intermittent MySQL Errcode 13 Errors On Windows
    +4 Vote Up -0Vote Down

    The Problem

    I've had MySQL on my Windows 7 laptop for a bit (as part of wampserver), mostly for local offline WordPress development.

    However, even though MySQL is relatively stable, I've been observing a vast quantity of intermittent MySQL errors, as reported by WordPress in the PHP error log (C:\wamp\logs\php_error.log). Here are some examples:

    [05-Jan-2010 09:47:51] WordPress database error Error on delete of
    'C:\Windows\TEMP\#sql17e0_1a2_6.MYD' (Errcode: 13) for query SELECT t.*, tt.*
    FROM wp_terms AS t INNER JOIN wp_term_taxonomy AS tt ON tt.term_id = t.term_id
    INNER JOIN wp_term_relationships AS tr ON tr.term_taxonomy_id =
    tt.term_taxonomy_id WHERE tt.taxonomy IN
      [Read more...]
    Fixing a MariaDB package bug
    +4 Vote Up -0Vote Down

    One of the things that I am really happy about in MariaDB is that we have our releases available as apt (and yum for Centos) repositories. This is largely thanks to being able to build this on the OurDelta package build infrastructure (which again builds on things like the Debian packaging scripts for MySQL).

    Something like the Debian apt-get package system (which is also used by Ubuntu) is one of the major innovations in the Free Software world in my opinion. Debian has spent many years refining this system to where it is today. Want to run the mysql client, but it isn't installed? Just try to run it on your local Ubuntu host:

        $ mysql
        The program 'mysql' can be found in the following packages:
         * mysql-client-5.0
         * mysql-client-5.1
        Try: sudo apt-get install <selected package>
        -bash: mysql:

      [Read more...]
    Back from SAPO Codebits in Lisbon - a summary
    Employee +1 Vote Up -0Vote Down

    Last week, my colleagues Giuseppe, Kai and myself attended the SAPO Codebits event in Lisbon, Portugal. Codebits is an annual, invite-only hacking event, which went on for three days. The venue they chose this year was the "Cordoaria", a former rope factory located in the Belém district, close to the 25 de Abril Bridge (which is an impressive sight!). I have been told that the Cordoaria is the longest building in Portugal and I have no doubts about that! The building is so long that the crew used bicycles to get from one end to the other. I've taken a number of

      [Read more...]
    Debugging and ripple effects
    +0 Vote Up -0Vote Down

    Like I said earlier, every tiny change that the test suite reveals after code changes is significant. I caught a very subtle “bug” today in recent changes to mk-query-digest (a.k.a. mqd). If you like to read about subtle bugs, read on.

    An mqd test on sample file slow023.txt began to differ after some pretty extensive code changes of late:

    > # Query 1: 0 QPS, 0x concurrency, ID 0x2CFD93750B99C734 at byte 0 ________

    The ID which depends on the query’s fingerprint has changed. It’s very important that we don’t suddenly change these on users because these IDs are pivotal in trend analyses with mqd’s --review-history option. First some background info on the recent code changes and then the little story

      [Read more...]
    Aspects and benefits of distributed version control systems (DVCS)
    Employee +2 Vote Up -0Vote Down

    This blog post is a by-product of my preparation work for an upcoming talk titled "Why you should be using a distributed version control system (DVCS) for your project" at SAPO Codebits in Lisbon (December 3-5, 2009). Publishing these thoughts prior to the conference serves two purposes: getting some peer review on my findings and acting as a teaser for the actual talk. So please let me know — did I cover the relevant aspects or did I miss anything? What's your take on DVCS vs. the centralized approach? Why do you prefer one over the other? I'm looking forward to your comments!

    Even though there are several distributed alternatives available for some years now (with

      [Read more...]
    Zero is a big number
    +0 Vote Up -0Vote Down

    I made changes to mk-query-digest yesterday that I didn’t expect to cause any adverse affects. On the contrary, several tests began to fail because a single new but harmless line began to appear in the expected output: “Databases 0″. Perhaps I’m preaching to the choir, as you are all fantastic, thorough and flawless programmers, but as for myself I’ve learned to never take a single failed test for granted.

    One time a test failed because some values differed by a millisecond or two. Being curious I investigated and found that our standard deviation equation was just shy of perfect. I fixed it and spent hours cross-checking the myriad tiny values with my TI calculator. Probably no one cared about 0.023 vs. 0.022 but it’s the cultivation of a disposition towards perfection that matters.

    My innocuous changes yesterday introduced a case of

      [Read more...]
    Four short links: 26 October 2009
    +0 Vote Up -0Vote Down

  • Toiling in the Data Mines -- Tom Armitage describes the process that Berg calls "material exploration". Programmers very rarely talk about what their work feels like to do, and that's a shame. Material explorations are something I've really only done since I've joined BERG, and both times have felt very similar - in that they were very, very different to writing production code for an understood product. They demand code to be used as a sculpting tool, rather than as an engineering material, and I wanted to explain the knock-on effects of that: not just in terms of what I do, and the kind of code that's appropriate for that, but also in terms of how I feel as I work on these explorations. Even if the section on the code itself
  •   [Read more...]
    Building MariaDB/MySQL with Buildbot and KVM
    +5 Vote Up -1Vote Down

    Testing and automation. These two are key to ensuring high quality of software releases.

    Ever since I worked briefly in the team at MySQL AB that is responsible for creating the binary (and source) packages of MySQL releases, I have had the vision of a fully automated release procedure. Whenever someone pushes a new commit to the release branch revision control tree, the continuous integration test framework should kick in and do all the steps needed for producing release packages:

    • Checkout the new revision.
    • Build a source tarball, and save it.
    • For each platform, build a binary package from the source tarball. The build should be done in a freshly installed machine without any revision control checkouts, previous build trees, or extra installed software, to ensure that no unwanted

      [Read more...]
    IntelliJ IDEA Open Sourced
    Employee +0 Vote Up -0Vote Down

    With IntelliJ now being available under an Open Source license, developers have another option to choose from when it comes to Java-based IDEs/Frameworks (Eclipse and NetBeans being the other two prominent ones). Choice is always good, and being an Open Source enthusiast, I of course welcome JetBrain's move!

    However, as I'm not really a heavy GUI-based IDE user myself, I can't really comment on which one is the best. These kind of discussions tend to turn into a Holy War anyway... In the end it's likely that each of them gets the job done and you have to come to your own conclusions, based on your personal preference and requirements.

    I personally would be interested in

      [Read more...]
    Previous 30 Newer Entries Showing entries 91 to 120 of 245 Next 30 Older Entries

    Planet MySQL © 1995, 2014, Oracle Corporation and/or its affiliates   Legal Policies | Your Privacy Rights | Terms of Use

    Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.