… | |
… | |
20 | This can be used to make parallel sql requests using Coro, or to do other |
20 | This can be used to make parallel sql requests using Coro, or to do other |
21 | stuff while mysql is rumbling in the background. |
21 | stuff while mysql is rumbling in the background. |
22 | |
22 | |
23 | =head2 CAVEAT |
23 | =head2 CAVEAT |
24 | |
24 | |
25 | Note that this module must be linked against exactly the same |
25 | Note that this module must be linked against exactly the same (shared, |
26 | F<libmysqlclient> library as DBD::mysql, otherwise it will not work. |
26 | possibly not working with all OSes) F<libmysqlclient> library as |
|
|
27 | DBD::mysql, otherwise it will not work. |
27 | |
28 | |
28 | Also, while this module makes database handles non-blocking, you still |
29 | Also, while this module makes database handles non-blocking, you still |
29 | cannot run multiple requests in parallel on the same database handle. If |
30 | cannot run multiple requests in parallel on the same database handle. If |
30 | you want to run multiple queries in parallel, you have to create multiple |
31 | you want to run multiple queries in parallel, you have to create multiple |
31 | database connections, one for each thread that runs queries. Not doing so |
32 | database connections, one for each thread that runs queries. Not doing so |
… | |
… | |
87 | |
88 | |
88 | sub readable { &Coro::Handle::FH::readable } |
89 | sub readable { &Coro::Handle::FH::readable } |
89 | sub writable { &Coro::Handle::FH::writable } |
90 | sub writable { &Coro::Handle::FH::writable } |
90 | |
91 | |
91 | BEGIN { |
92 | BEGIN { |
92 | our $VERSION = '1.01'; |
93 | our $VERSION = '1.02'; |
93 | |
94 | |
94 | require XSLoader; |
95 | require XSLoader; |
95 | XSLoader::load Coro::Mysql::, $VERSION; |
96 | XSLoader::load Coro::Mysql::, $VERSION; |
96 | } |
97 | } |
97 | |
98 | |