Hi again, During the last week I am going through the project's source code, now I've got a general view about the relation between major components of monkey server. Meanwhile, I'm also doing some research on relational database asynchronous libraries.
After checking out and evaluating some available C libraries, here are some summings-up: For PostgreSQL, the official c library libpq natively supports async database access.[1] Seems we don't need third-party lib, a wrapper around the official lib may suit our need. For MySQL, libmysqlclient use blocking calls, and doesn't have a true async interface. Some availabe async thrid party libraries for MySQL: 1.MySAC[2]: written in C, latest version 1.1.1(released on June 06,2011), not active development 2.libdrizzle[3]: written in C/C++, latest version 5.1.3(released on Feb 07, 2013), active development 3.mysqlplus[4]: mainly written in C/C++ and some Ruby, not active development. All of the above libs do not seem to be widely used. Also there are other libraries which are mainly written in Java, JavaScript, Perl, Ruby. As an alternative, MariaDB supports non-blocking operations in the client-library starting with version 5.5.21.[5] And the library is MySQL-compatible.[6] I think this one may be a better choice becasue MariaDB comes with a better community support. There's already a node.js binding that makes use of MariaDB's non-blocking client API.[7] A tutorial on how to use MariaDB's non-blocking client API is avaiable here.[8] And here are some questions: 1.Should we implement a connection pooling mechanism in the MySQL and PostgreSQL Duda I/O extentions? Or leave this to the user? 2.Should the thrid party library be purely written in C? My following works: 1.get familiar with the async database client API 2.write some code with the existing duda package to understand how they interact with web service p.s. Due to the asynchronous nature of node.js, I think the popular node-mysql[9] and node-postgres[10] modules may provide us some reference. [1]libpq/asynchronous command processing http://www.postgresql.org/docs/9.2/static/libpq-async.html [2]MySAC(MySQL Simple Asynchronous Clinet) http://www.arpalert.org/mysac.html [3]Drizzle Client & Protocol Library https://launchpad.net/libdrizzle [4]mysqlplus https://github.com/oldmoe/mysqlplus [5]About Non-blocking Operation in the Client Library https://kb.askmonty.org/en/about-non-blocking-operation-in-the-client-library/ [6]MariaDB Client Library for C https://kb.askmonty.org/en/mariadb-client-library-for-c/ [7]mariasql https://npmjs.org/package/mariasql [8]Using the non-blocking library https://kb.askmonty.org/en/about-non-blocking-operation-in-the-client-library/ [9]felixge/node-mysql https://github.com/felixge/node-mysql [10]brianc/node-postgres https://github.com/brianc/node-postgres Best Regards, swpd On Thu, Apr 11, 2013 at 2:27 AM, Zen Shell <[email protected]> wrote: > Hi Eduardo, > > Thank you very much for your advices! > > I am reading about this great and informative article now. > > :) > Regards, > swpd > > > > On Thu, Apr 11, 2013 at 2:20 AM, Eduardo Silva <[email protected]> wrote: > >> Hi Zen, >> >> >> On Wed, Apr 10, 2013 at 12:16 PM, Zen Shell <[email protected]> wrote: >> >>> Hi all, >>> My name is Zeying Xie(@swpd on irc).I am an undergraduate student from >>> China. >>> I am more than willing to participate in the GSOC 2013 program and code >>> for Monkey this summer.The performance and compact size of Monkey has >>> caught my attention. It's a good place to learn about web server, >>> communication protocols details, network programming and lots of stuffs. >>> >>> After reading the GSOC ideas[http://monkey-project.com/gsoc2013/ideas] >>> of Monkey project, I found the "Add MySQL and PostgreSQL extensions to Duda >>> I/O" project very interesting and would like to contribute to it. >>> * >>> My Skills:* >>> I am fimiliar with C programming(3 years' experience). >>> I've totally switched to Linux for more than 2 years and have a good >>> knowledge of Linux and the development toolchains. >>> I have experience in working with relational database. >>> I have a good understanding of common data structures and algorithms. >>> >>> Currently I am getting myself fimiliar with Monkey's design and code >>> base. >>> I need some guides on where to start with the database extensions >>> project. >>> Any suggestions or comments would be very appreciated, Thanks in >>> advance! >>> :) >>> >>> >> before to get into the project it self, get familiar with the Monkey >> Architecture and how Duda works: >> >> >> http://edsiper.linuxchile.cl/blog/2013/02/27/architecture-of-a-linux-based-web-server/ >> >> >> Check http://duda.io , our git repositories >> git.monkey-project.com(duda-examples) and understand the relation between >> them, as weel what >> means a Duda Package and how the API objects are mapped, >> >> feel free to reach us on irc.freenode.net #monkey >> >> best, >> >> -- >> Eduardo Silva >> http://edsiper.linuxchile.cl >> http://www.monkey-project.com >> > >
_______________________________________________ Monkey mailing list [email protected] http://lists.monkey-project.com/listinfo/monkey
