New functions have been added to XATMI sub-system, which is intended to be used by user for doing debug logging of their applications.
List of the function:
extern NDRX_API void tplogdumpdiff(int lev, char *comment, void *ptr1, void *ptr2, int len);
extern NDRX_API void tplogdump(int lev, char *comment, void *ptr, int len);
extern NDRX_API void tplog(int lev, char *message);
extern NDRX_API int tploggetreqfile(char *filename, int bufsize);
extern NDRX_API int tplogconfig(int logger, int lev, char *debug_string, char *module,
extern NDRX_API void tplogclosereqfile(void);
extern NDRX_API void tplogclosethread(void);
extern NDRX_API void tplogsetreqfile_direct(char *filename);
extern NDRX_API int tplogsetreqfile(char **data, char *filename, char *filesvc);
extern NDRX_API int tploggetbufreqfile(char *data, char *filename, int bufsize);
extern NDRX_API int tplogdelbufreqfile(char *data);
extern NDRX_API void tplogprintubf(int lev, char *title, UBFH *p_ub);
See the man pages of these function, and additional information can be found in ex_devguide document.
INI Based configuration system¶
Enduro/X 3.3.1 now can be configured by using ini file (or files) instead of environment variables, ndrxdebug.conf and q.conf.
Two new environment variables now are added to the system:
2. and optional NDRX_CCTAG which allows processes to specify the subsection of Enduro/X system settings.
The configurations sections are:
[@global] - environment variables for process (see ex_env(5))
[@debug] - debug configuration per binary (see ndrxdebug.conf(5))
[@queue] - persistent queue configurations.
If you use NDRX_CCTAG or specify the "cctag" for ATMI server, then Enduro/X will scan for sections like (e.g. cctag=TAG1):
[@global/TAG1] and then [@global]
[@debug/TAG1] and then [@debug]
[@queue/TAG1] and then [@debug]
cctag can contain multiple tags, which are separated by '/'. In that case multiple lockups will be made with base section combination.
Configuration server available for user applications¶
New configuration server is being added "cconfsrv" which can be used by applications to use Enduro/X framework for application configuration. The user application can call the "@CCONFIG" server in two modes: A) for getting the exact section, B) for listing the sections. See cconfsrv(8) for more details. The idea behind this is that user can do the programming under Enduro/X in multiple languages (C/Go/Perl/Python/PHP/NodeJs) and these modules typically needs configuration. It would be waste of time if for each of the languages developer would need to think how to read the configuration from config files with natlibraries.ies. The Enduro/X offers standard XATMI micro-service call for reading the ini files in common way for whole application, no matter in which language it is programmed.
The version gate be get at github: https://github.com/endurox-dev/endurox
or prebuilt version for Ubuntu 14.04 64bit is here: https://www.endurox.org/attachments/download/49/endurox-3.3.1-1.ubuntu14_04.x86_64.deb
After the log working process the package is available here: https://github.com/endurox-dev/endurox-php. Now PHP users can enjoin the Distributed Transaction Processing and Microservices architecture provided by Enduro/X package.