Performance improvement to sourcing ydb_env_set under some conditions
Final Release Note
Sourcing ydb_env_set
is more robust as it uses PIPE devices rather than the ZSYSTEM command. PIPE devices are more efficient and give YottaDB more control. Previously, depending on the environment in which ydb_env_set
was sourced, it could execute slowly. [#787 (closed)]
Description
If I set in .bashrc
export ydb_chset="UTF-8"
source /usr/local/lib/yottadb/r132/ydb_env_set`
then loading KDE seesion after login increases by 2 minutes.
If I write all yottadb-related variables to a file, then everything happens instantly.
. ~/.ydb_env
When I launched the htop
during the load of KDE session, I saw more than a dozen parallel running yottadb processes:
/usr/local/lib/yottadb/r132/yottadb -run set^%YDBENV
Apparently they cannot work correctly in parallel and slow down each other.
I have not seen a similar problem with the environment script of GT.M.
Content of .ydb_env
export ydb_dir='/home/inetstar/.yottadb'
export gtmdir='/home/inetstar/.fis-gtm'
export ydb_rel='r1.32_x86_64'
export gtmver='V6.3-010_x86_64'
export ydb_chset='UTF-8'
export ydb_sav_8706_ydb_chset='UTF-8'
export gtm_chset='UTF-8'
export ydb_icu_version='69.1'
export gtm_icu_version='69.1'
export ydb_dist='/usr/local/lib/yottadb/r132'
export gtm_dist='/usr/local/lib/yottadb/r132'
export ydb_repl_instance='/home/inetstar/.yottadb/r1.32_x86_64/g/yottadb.repl'
export gtm_repl_instance='/home/inetstar/.yottadb/r1.32_x86_64/g/yottadb.repl'
export ydb_retention='42'
export gtm_retention='42'
export ydb_gbldir='/home/inetstar/.yottadb/r1.32_x86_64/g/yottadb.gld'
export gtmgbldir='/home/inetstar/.yottadb/r1.32_x86_64/g/yottadb.gld'
export ydb_routines='/home/inetstar/.yottadb/r1.32_x86_64/o/utf8*(/home/inetstar/.yottadb/r1.32_x86_64/r /home/inetstar/.yottadb/r) /usr/local/lib/yottadb/r132/utf8/libyottadbutil.so'
export gtmroutines='/home/inetstar/.yottadb/r1.32_x86_64/o/utf8*(/home/inetstar/.yottadb/r1.32_x86_64/r /home/inetstar/.yottadb/r) /usr/local/lib/yottadb/r132/utf8/libyottadbutil.so'
export ydb_log='/tmp/yottadb/r1.32_x86_64'
export gtm_log='/tmp/yottadb/r1.32_x86_64'
export ydb_tmp='/tmp/yottadb/r1.32_x86_64'
export gtm_tmp='/tmp/yottadb/r1.32_x86_64'
export ydb_etrap='Write:(0=$STACK) "Error occurred: ",$ZStatus,!'
export gtm_etrap='Write:(0=$STACK) "Error occurred: ",$ZStatus,!'
export ydb_procstuckexec='/usr/local/lib/yottadb/r132/yottadb -run %YDBPROCSTUCKEXEC'
export gtm_procstuckexec='/usr/local/lib/yottadb/r132/yottadb -run %YDBPROCSTUCKEXEC'
export LD_LIBRARY_PATH='/usr/local/lib/yottadb/r132'
export PATH='/usr/local/lib/yottadb/r132:/home/inetstar/bin:/home/inetstar/bin:/home/inetstar/bin:/opt/hosting/clients:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/opt/bin:/usr/lib/llvm/12/bin:/opt/mysql5.5/bin:/opt/php5/bin'
export ydb_sav_8706_PATH='/home/inetstar/bin:/home/inetstar/bin:/home/inetstar/bin:/opt/hosting/clients:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/opt/bin:/usr/lib/llvm/12/bin:/opt/mysql5.5/bin:/opt/php5/bin'
export ydb_unset_8706="ydb_dir gtmdir ydb_rel gtmver ydb_sav_8706_ydb_chset gtm_chset ydb_icu_version gtm_icu_version ydb_dist gtm_dist ydb_repl_instance gtm_repl_instance ydb_retention gtm_retention ydb_gbldir gtmgbldir ydb_routines gtmroutines ydb_log gtm_log ydb_tmp gtm_tmp ydb_etrap gtm_etrap ydb_procstuckexec gtm_procstuckexec LD_LIBRARY_PATH ydb_sav_8706_PATH"
alias gde="$ydb_dist/yottadb -run GDE"
Draft Release Note
Sourcing ydb_env_set
is more robust as it uses PIPE devices rather than the ZSYSTEM command. PIPE devices are more efficient and give YottaDB more control. Previously, depending on the environment in which ydb_env_set
was sourced, it could cause performance issues. [#787 (closed)]