Monthly Archives: November 2009

Call a method of object with string in JavaScript

var call_user_func = function(obj, method) { return eval('obj.' + method).apply(obj, Array.prototype.slice.call(arguments, 2)); } var test1 = { method1: function(arg1, arg2, arg3) { return alert(arg1 + arg2 + arg3); } } call_user_func(test1, 'method1', 1, 2, 3); It works on Firefox3, Safari4, IE6.
Posted in Uncategorized | Leave a comment

tpcc-mysql rough benchmark for Amazon RDS

I tried to do tpcc-mysql benchmark for Amazon RDS. Before do that, did the same test for EC2 small instance. From EC2 small instance to small. Fedora8 and MySQL 5.0.45. Default configuration. (no change for a my.cnf; innodb_buffer_pool_size = 8388608) # mysql -h domU-12-31-39-06-7C-86.compute-1.internal -u mymasteruser -p mysql> grant all privileges on tpcc.* to tpcc@'%' identified by [...]
Posted in Tweak | Tagged , | 1 Comment
  • About

    I'm Nobu, a web developer living in Mountain View, CA. Feel free to comment on any posts. I'm also tweeting on twitter.

  • Archives

  • Recent Posts