database benchmark performace mysql vs cache vs system vs directory file

44 views
Skip to first unread message

Danilo Santos

unread,
Apr 11, 2020, 3:04:15 PM4/11/20
to H2 Database
exists one https://database.serverbenchmark.com/ like https://gpu.userbenchmark.com/ or https://cpu.userbenchmark.com/

why are there still people using mysql instead of 1 portable database like h2database?

how does the database cache system work? is it faster than the operating system's directory system? or that sqlite?


Noel Grandin

unread,
Apr 11, 2020, 3:36:37 PM4/11/20
to H2 Database
On Sat, 11 Apr 2020 at 21:04, Danilo Santos <danilo.s...@hotmail.com> wrote:

Not that I am aware of. Lots of databases prohibit the publication of unauthorised benchmarks, so it is a little tricky.

 
why are there still people using mysql instead of 1 portable database like h2database?


There are a lot of features in different databases, and different tradeoffs. Your job as a developer is to find the database that has the right tradeoffs for your application.
how does the database cache system work? is it faster than the operating system's directory system? or that sqlite?


We have two cache systems, a fairly normal LRU cache and a scan-resistant LRU cache. Our cache is more "efficient" than the operating systems cache for the specific purpose of serving rows, but that is because our cache operates at a different level.


Danilo Santos

unread,
Apr 11, 2020, 4:33:04 PM4/11/20
to H2 Database
has cache to analyze the frequency of the line and position it for a faster query in the future based on the probability that the lines appear?

Noel Grandin

unread,
Apr 12, 2020, 2:50:52 AM4/12/20
to H2 Database
Not really, look up how an LRU cache works e.g.

Danilo Santos

unread,
Apr 13, 2020, 12:44:54 PM4/13/20
to H2 Database
as I understand it, this is copying and pasting a frequent part of the storage file into another smaller storage file.

but I was wondering if it would be faster to insert data directly into the directory system instead of storage files.

on the internet there are several theories, but none shows a benchmark, and I think that 1 creator of 1 database may have tested adversarial databases to analyze performance.

they say sqlite is 70% faster than the file system, but I can’t understand why, I still don’t have the means to test whether it’s true and I don’t even find test videos like they do on video cards even for ram, processor, ghz, core due to fps

Noel Grandin

unread,
Apr 13, 2020, 12:52:48 PM4/13/20
to H2 Database
I'm sorry to say, but you need to do more reading on how caches work, that is not at all how it functions.

A brief overview of our architecture is here:

When people say that SQLite is faster than the filesystem, they mean it is faster for the specific use-case of storing and retrieving structured records.
It can be faster because it knows more about the structure and access-pattern of the data than the filesystem.


Reply all
Reply to author
Forward
0 new messages