FirebirdSQL / firebird

Firebird server, client and tools
https://www.firebirdsql.org/
1.23k stars 212 forks source link

Async write for security#.fdb as default [CORE5942] #6198

Open firebird-automations opened 5 years ago

firebird-automations commented 5 years ago

Submitted by: Basil A. Sidorov (basid)

Make write asinc for security#⁠.fdb as default option. Motivation: lowered IO-load for environment with many short-lived connections.

Workaround: change attribute manualy via two restart Firebird server.

firebird-automations commented 5 years ago

Commented by: Sean Leyne (seanleyne)

99.9% of access to Security database is reads, so a change to "Forced Writes" setting would have very, very little impact.

firebird-automations commented 5 years ago

Commented by: @dyemanov

Sean, every "read" (auth check) is performed in a separate transaction and thus modifies at least two pages - header and TIP. However, this shouldn't be an issue starting with 3.0.2, see CORE5434 (SuperServer only though). So I suppose this topic is either about v2.5 or about Classic. More details are required from the author.

firebird-automations commented 5 years ago

Commented by: Basil A. Sidorov (basid)

I'm implement "edge case" - get server version via services from multi-threaded (java) application. Unexpected result: with "write async" time of test is increased by 10 percent. I'm take "some time-out".

firebird-automations commented 5 years ago

Commented by: Basil A. Sidorov (basid)

"Wrong result - is result also".

security.db = $(dir_secDb)/security3.fdb { RemoteAccess = false DefaultDbCachePages = 50 }

If increase DefaultDbCachePages up to security#⁠.fdb size (500 pages or more) disk IO is minimal (3.0SuperServer).

Please clouse ticket or change default for firebird.conf.