… | |
… | |
26 | =head1 DESCRIPTION |
26 | =head1 DESCRIPTION |
27 | |
27 | |
28 | This module is an L<AnyEvent> user, you need to make sure that you use and |
28 | This module is an L<AnyEvent> user, you need to make sure that you use and |
29 | run a supported event loop. |
29 | run a supported event loop. |
30 | |
30 | |
31 | This module implements asynchronous DBI access my forking or executing |
31 | This module implements asynchronous DBI access by forking or executing |
32 | separate "DBI-Server" processes and sending them requests. |
32 | separate "DBI-Server" processes and sending them requests. |
33 | |
33 | |
34 | It means that you can run DBI requests in parallel to other tasks. |
34 | It means that you can run DBI requests in parallel to other tasks. |
35 | |
35 | |
36 | The overhead for very simple statements ("select 0") is somewhere |
36 | The overhead for very simple statements ("select 0") is somewhere |
… | |
… | |
250 | delete $self->{ww}; |
250 | delete $self->{ww}; |
251 | delete $self->{fh}; |
251 | delete $self->{fh}; |
252 | |
252 | |
253 | $@ = $error; |
253 | $@ = $error; |
254 | |
254 | |
|
|
255 | if ($self->{on_error}) { |
255 | $self->{on_error}($self, $filename, $line, $fatal) |
256 | $self->{on_error}($self, $filename, $line, $fatal); |
256 | if $self->{on_error}; |
257 | return unless $fatal; |
|
|
258 | } |
257 | |
259 | |
258 | die "$error at $filename, line $line\n"; |
260 | die "$error at $filename, line $line\n"; |
259 | } |
261 | } |
260 | |
262 | |
261 | sub _req { |
263 | sub _req { |