Showing entries 31 to 40 of 47
« 10 Newer Entries | 7 Older Entries »
Displaying posts with tag: udf (reset)
Gearman for MySQL


If you haven't yet heard about Gearman, it's time to have a look at it. Its distributed client server architecture are a perfect match for today's cloud oriented applications.
When talking about Gearman, much stress is often given on its scalability features, such as map/reduce and distributed loads. But Gearman has also a distinctive advantage in the feature department, because of its design that I like to describe as cooperation of the fittest.

While a traditional application is written entirely in a given language, or it must find ways of integrating multiple languages parts, Gearman encourages easy cooperation between parts written in different languages, eliminating the need …

[Read more]
memcached Functions for Drizzle now in main tree!

What a great day! I see that the drizzle team has merged in my (and Padraig O'Sullivan's) memcached Functions for Drizzle (UDFs). I'm really glad to have this in drizzle now as it adds a means of interacting with memcached from within Drizzle. I have most functions from the MySQL branch implemented now as well. I'm extremely grateful to Padraig O'Sullivan for getting this project off the ground. I was a bit stuck with the new API and C++ when I first attempted these and he designed the class setup and had the major functions working which I then picked up and added more functions as well as tests. I was also glad to have the drizzle team add in my sleep() UDF which allowed me to test expirations in these memcached functions.

These functions have some similar, but very little code from the memcached Functions for MySQL. The new UDF API is completely different than MySQL's UDF API. You have to create a class for each function that is a …

[Read more]
Having fun with Tokyo Tyrant

I decided to thee other day to investigate using Tokyo Tyrant because I was interested in the fact it has a memcached protocol and I wanted to get a feel for how it works with my memcached functions for MySQL (UDF). Matt Ingenthron came up with a good term recently: Mem-capable, which Tokyo Tyrant is. I find any key/value storage to be of great interest, particularly those that you simply change the port your memcached client is connecting and simply use it the same way you would memcached.

So, just what is Tokyo Tyrant?

Tokyo Tyrant is a database server, written by Mikio Hirabayashi, for Tokyo Cabinet. It provides for concurrent remote connections to Tokyo Cabinet . It provides its own binary protocol as well as a memcached and HTTP compatibility protocols. It also has C, Perl, PHP, Java, Erlang, Python and Ruby bindings. Other features Tokyo Tyrant offers:

* Hot backup and update log
* Async …

[Read more]
Memcached Functions for MySQL and Moxi: a great combination

Working at Northscale has been a lot of great fun lately! I have finally figured out how to get puppet to set up a stock Amazon instance with everything we need and have been impressed with how you can automate system setup with puppet. I remember when I worked at Grazr how much of a hassle it was for us to have to rebuild systems. Something like Puppet would have been a godsend.

Today I though I would post about how cool moxi is. If you don't know, moxi is a memcached proxy (http://labs.northscale.com/moxi/) which allows you to move any complexity of having to set up the list of memcached servers you are using. Also, moxi has some great features such as:

* De-duplication of requests for popular keys
* A front cache, L1 cache to avoid network hops
* Fire and forget SET (Like an async SET) this means "set a value, but don't wait to know if it …

[Read more]
capttofu @ 2009-07-31T12:23:00

I'm pleased to announce the release of the Memcached Functions for MySQL, version 1.0.

This release contains several changes, per the ChangeLog:

1.0 Thursday, July 30, 2009 12:00:00 EST 2009
* Fixed issue of setting NULLs with user-defined variables (Thanks to
Jean-Jacques Moortgat at aol dot com !)
* Fixed issue of obtaining a NULL value FROM memcached
* All set functions now return 0 (failure) or 1 (success)
* Other cleanups
* More tests

Importantly, there was an issue that I blogged about several days ago where in the UDF API, if you pass a user-defined variable that is set to NULL to memc_set(), the length of the argument is 8192 even though the value of the argument itself is NULL, which caused much unhappiness in MySQL (crash). That is fixed by setting the length to 0 if the argument itself is NULL. Also fixed is obtaining the NULL value from memcached using …

[Read more]
Memcached Functions For MySQL 0.9 Released

I'm glad to announce the release of Memcached Functions for MySQL version 0.9. This version contains a couple bug fixes:

* Switched to using calloc() instead of malloc(), check for return value
* Changed memc_servers_set() to not create a new connection when one already exists, free first

Also added:

* memc_server_version()

mysql> select memc_server_version('127.0.0.1:11211')\G
*************************** 1. row ***************************
memc_server_version('127.0.0.1:11211'): Server: 127.0.0.1 (11211) version 1.2.6

I'm glad to get development moving along again. The book really took a ton of time, so now I can get this project moving along. Version 0.10 I'll be adding even more functionality. I'll get some ideas at the user's conference next week as well. One thing I need to get working properly is the ability to set a value in a specific …

[Read more]
Memcached Functions for MySQL version 0.8 Released

I'm pleased to announce the release of the Memcached Functions for MySQL, version 0.8.

This version includes a bunch of fixes for behavior setting and retrieval. You now have:

Ability to fetch a behavior:

memc_server_behavior_get();

All behaviors can be set now successfully with memc_server_behavior_set()

Boolean:

select memc_behavior_set('MEMCACHED_BEHAVIOR_BUFFER_REQUESTS', '1');

Name of a value (string):

select memc_behavior_set('MEMCACHED_BEHAVIOR_HASH','MEMCACHED_HASH_MD5' );

Numeric:

select memc_behavior_set('MEMCACHED_BEHAVIOR_SOCKET_SEND_SIZE', 60000);

Also, you can now list the distribution types to use when calling memc_server_behavior_set('MEMCACHED_BEHAVIOR_DISTRIBUTION', ''), which produces a list of all the distrubution types:

select …

[Read more]
Repository for MySQL UDFs: new sys_eval() function

Thanks to Bernardo Damele, the lib_mysqludf_sys package hosted by the Repository for MySQL UDFs can now boast a new sys_eval() function. You can read the details here on his blog. Bernardo also created a similar function for PostgreSQL.

Thank you, Bernardo!!!

sys_eval() is quite like

[Read more]
Memcached UDFs for MySQL version 0.6 Released

I've taken some time out of writing my book to get some coding down, and I'm pleased to announce the release of the Memcached Functions for MySQL, version 0.6. This release includes:

* Complete rewrite of error handling
* Build configuration fixes/improvements from Trond Nordby (Thanks!)
* Fixed memc_server_count
* More tests

You can find the release information-- repository and source at:

http://tangent.org/586/Memcached_Functions_for_MySQL.html

As well as

http://patg.net/downloads/memcached_functions_mysql-0.6.tar.gz

Have fun! More to come...

Writing to the MySQL error log

In almost all application development situations, one needs to log debug information now and then. In almost all production systems, one needs to log serious error events somewhere too.

So, what can you do? Create a log table? Sprinkle your code with SELECT 'Debug: ...' statements?

At the UDF Repository for MySQL, we now have a solution to log messages to the MySQL error log: a user-defined function called log_error().

Currently it is all very crude: the log_error function takes one argument and writes it to the mysql_error log, appending a line …

[Read more]
Showing entries 31 to 40 of 47
« 10 Newer Entries | 7 Older Entries »