-
Notifications
You must be signed in to change notification settings - Fork 0
Concept Global Flags
Maruf Çetin edited this page Sep 1, 2026
·
1 revision
Turkce Dokumantasyon | English Documentation
Category: Configuration & Flags
Subsystem: Core Environment Management (AmberDB::Base)
Entry Type: Global Configuration Guide
Global Flags govern the overarching runtime behavior, regional locale preferences, user audit tracking, write-protection security modes, and memory/disk optimization policies of an AmberDB instance.
Global flags are initialized in $adb = AmberDB->new(cfg => { ... }) and can be inspected or mutated deterministically at runtime via $adb->config("flag_name", $value).
| Flag Name | Data Type | Default | Description |
|---|---|---|---|
language |
string |
"en" |
Active AmberDB::Locale regional language ("en", "tr", "de", "fr", "es", "ja", "ru", "ar", "az"). Dictates case folding, phonetic search, and UCA collation. |
user |
string |
"" |
User identifier for audit trail logging (log_owner / .aut). Appended to changelogs on modifications. |
simple |
boolean |
0 |
Simple Mode. Bypasses schema loading and indexing to interact directly with raw Berkeley DB hash tables. |
no_write |
boolean |
0 |
Read-Only Protection. Intercepts and blocks all insert, modify, and delete invocations. |
no_backup |
boolean |
0 |
Disables writing continuous audit entries to backup/YYYY/YYYY-MM-DD.csv. |
buffer_write |
boolean |
0 |
Disk Staging Buffer. Diverts writes to transient buffer/*.tmp files instead of primary tables. |
keys_only |
boolean |
0 |
Returns scalar ID arrays instead of full record payloads, minimizing memory during large scans. |
jnktype |
string |
"A" |
Junk tier query selector: 'A' (Hot/Master), 'B' (Cold/Junk), 'AB', or 'BA'. |
auto_id |
boolean |
1 |
Dictates 64-bit auto-increment ID generation (0 requires explicit external IDs). |
keep_deleted |
boolean |
0 |
Global soft-delete policy (moves erased records into .del recycle store). |
log_owner |
boolean |
0 |
Global user action audit logging policy (maintains .aut ledger). |
use AmberDB;
# 1. Initialize instance with global flags
my $adb = AmberDB->new(
cfg => {
language => "en", # English locale rules
user => "admin_editor",# Active authenticated user
no_backup => 0, # Keep WAL active
},
path => { dbase_dir => "./dbstore" }
);
# 2. Query flag state at runtime
my $current_lang = $adb->config("language"); # "en"
# 3. Mutate global flags dynamically
$adb->config("no_write", 1); # Lock database into read-only mode
# 4. Stream IDs with keys_only
$adb->config("keys_only", 1);
my ($total, @id_list) = $adb->read_all("catalog_products", 0, 100);
$adb->config("keys_only", 0); # Reset back to full record modeAmberDB — High-Performance Schema-Driven NoSQL Database Engine for Perl.
Copyright 2005-2026 Maruf Cetin. Released under the Artistic License 2.0.
CPAN · GitHub Repository · Issue Tracker
- Berkeley DB (DB_File) Engine
- AmberDB Table Schema
- Global Flags
- Table Schema Flags
- Directory Structure
- File Structure (Extensions)
- Repeat Blocks
- Auto-Increment ID
- ASCII ID
- Relational Records
- Record Anatomy
- JOIN-Free Architecture
- Packed Binary Index
- Strict 2PL Locking
- Undo Journal & Rollback
- Tiered Junk Indexing
- Disjunctive Faceting
- Phonetic Accent Search
- 2-Pillar Disaster Recovery
- RAM-Disk Acceleration
- In-Memory Schema Mutation
- Simple Mode
- new
- config
- set_datadir
- insert_id
- insert_list
- modify_id
- modify_list
- delete_id
- delete_list
- read_id
- read_all
- read_list
- exist_id
- exist_list
- exist_table
- table_count
- table_keys
- table_lastid
- table_attr
- table_create
- field_fetch
- field_filter
- search_table
- facet_menu
- field_fltkeys
- field_allfltkeys
- facet_rules
- slug_read
- slug_fetch
- transact_start
- transact_end
- transact_commit
- transact_rollback
- transact_recover
- flock_open
- flock_close
- cache_setup
- cache_read
- cache_write
- cache_delete
- cache_preload
- cache_ensure
- buffer_write
- buffer_read
- buffer_delete
- recs_scan
- recs_get
- recs_put
- recs_del
- locale_uc
- locale_lc
- locale_sort
- locale_to_ascii
- locale_num2text
- locale_format_currency
- locale_format_date
- array_sort
- array_punch
- array_filter
- array_sublist
- deep_copy
- log_owner
- use_counter
- use_junk
- keep_deleted
- auto_id
- buffer_write
- simple
- no_write
- no_backup
- jnktype
- keys_only
- id_type
- language
- .db · .table · .dbase
- .inx · .fld · .src
- .fac · .srt · .slg
- .unq · .del · .aut
- .cnt · .txn · .amberdb
- .csv · .cache · .tmp