![]() | |
#61
| |||
| |||
|
|
On 26.09.2011 18:50, The Natural Philosopher wrote: Or 10s of requests per minute. I would guess that depends on how much bandwidth you have. Theres not many NICs can keep up with a big CPU and lots of ran,,, Therefore, if you send files slowly and the new requests build up, DB connections and buffers follow suit. yes, but it doesn't matter, because the files cant crawl out any faster |
#62
| |||
| |||
|
|
Axel Schwenke wrote: The Natural Philosopher <tnp (AT) invalid (DOT) invalid> wrote: Axel Schwenke wrote: [snip] That was worth the reading. Thank you. ..and also suggest ways in which one aspect of MySQL COULD be improved.. It's not terribly much what you can change shorthand. - the server/client protocol cannot be changed without breaking compatibility to third-party connectors - the storage engine API cannot be changed without breaking compatibility to third-party storage engines - the extra copy in the buffer pool cannot be avoided at all however there is some light at the end of the tunnel: There is support for SHM transport if you use Windoze. I guess this is mostly due to the abominable performance of other IPC methods in Windoze <eg When server-side prepared statements were introduced (in 5.0) a new BLOP API call was added to send a BLOB to the server in pieces. This not only lifts the max_allowed_packet limit, it also makes communication more memory efficient. Unfortunately the same was not implemented for reading BLOBs (please don't ask me why, it sooo makes no sense). Still there is hope that the missing piece will be implemented some time. If one thinks about the problem in more depth, then you come to the conclusion that the POSIX file I/O API is close to perfect and you want to duplicate it for access to BLOBs. Specifically you need seek() and the ability to access only parts of a BLOB. sendfile() and splice() would then be the whipped cream on top And of course not of that is news for the people working at MySQL AB^W^W Sun Micr^W^W Oracle: http://forge.mysql.com/worklog/task.php?id=1042 http://forge.mysql.com/worklog/task.php?id=3583 yerss. SO it looks like PROVIDED the blobs are below full 'in memory' size its not a huge overhead...but once they start to exhaust RAM you are in deep shit. as in "Practical limit is some 256-512M on 32bit Boxes" Good enough for images, but not large multipage PDFS with embedded images. |
#63
| |||
| |||
|
|
connections and buffers follow suit. yes, but it doesn't matter, because the files cant crawl out any faster anyway.. Er... actually, for this exact reason it does matter. You fill up the |
#64
| |||
| |||
|
|
On 26.09.2011 20:27, The Natural Philosopher wrote: connections and buffers follow suit. yes, but it doesn't matter, because the files cant crawl out any faster anyway.. Er... actually, for this exact reason it does matter. You fill up the memory with lingering buffers for hundreds of files. |
#65
| |||
| |||
|
|
On 26.09.2011 20:27, The Natural Philosopher wrote: connections and buffers follow suit. yes, but it doesn't matter, because the files cant crawl out any faster anyway.. Er... actually, for this exact reason it does matter. You fill up the memory with lingering buffers for hundreds of files. |
#66
| |||
| |||
|
|
same happens serving em off disk.. |
#67
| |||
| |||
|
|
On 26.09.2011 21:15, The Natural Philosopher wrote: same happens serving em off disk.. Not even nearly on that scale. Read what Axel wrote in this here thread 2011-09-26@14:31UTC. I did. |
#68
| |||
| |||
|
|
On 26.09.2011 21:15, The Natural Philosopher wrote: same happens serving em off disk.. Not even nearly on that scale. |
|
Read what Axel wrote in this here thread |
#69
| |||
| |||
|
|
The point is, that the MySQL server has 3 copies of the row before even the first byte is sent to the MySQL client (web server). The fourth and maybe fifth copy of the data exists before even a single byte is sent to the HTTP client (browser). So in high load conditions it's better to ask MySQL for a number of |
#70
| |||
| |||
|
|
On 27.09.2011 09:13, Axel Schwenke wrote: The point is, that the MySQL server has 3 copies of the row before even the first byte is sent to the MySQL client (web server). The fourth and maybe fifth copy of the data exists before even a single byte is sent to the HTTP client (browser). So in high load conditions it's better to ask MySQL for a number of short datasets, that is - fetch a set of rows from primary table with joined _conditions_ and then fetch rows from joined tables with /FK IN(...)/. This way the memory is freed up quickly. Is that correct? |
![]() |
| Thread Tools | |
| Display Modes | |
| |