Local paths
The system is distributed, but different logical roles running on different servers require access to the same files. For example, role ws has saved a file to the IVR script, the ivr role executes the playback component and checks for the file, and the mg role performs the playback component. There are tons of examples like this, and they all require file system unity between servers.
Fundamentally, there are several different kinds of catalogs in the "Incoplax" system:
-
A synchronization folder from which files are automatically distributed to servers according to their destination.
-
A network storage folder on a site, posting to which makes a file accessible from other servers on that site.
-
A network folder of global storage, placing it in which makes the file accessible from other servers of all sites.
-
A local temporary folder for the node, placing it in which is temporary and makes the file inaccessible to other servers, is cleared when the node starts.
-
A write folder used by media gateways to store RTP traffic.
-
Network storage folders of call recordings, which can be either global or site specific, there can be many of them and each mixer is configured to save to a specific one.
The root directories for the above categories are configured in configuration for each server separately.
Absolute and relative direct paths of OS
An absolute or relative path is a level 1 reference to a file.
Working with level 1 paths in scripts is prohibited.
Root keys set in the config
Root folders by type are level 2 references to a file.
Working with level 2 paths in scripts is prohibited.
Types of pathways:
rshare.sign
A service file whose presence indicates to the "Incoplax" system that the network directory is connected.
-
Necessary for operation of system services with catalogs
:SITESHARE
and:GLOBALSHARE
. -
The file must be created on a connected NAS. If there is no network connection, the file disappears, the system realizes that the directory is not available.
-
If NAS is not used, a file is created directly in the
:SITESHARE
or:GLOBALSHARE
directory of the server.
rshare
To test execute:
hd rshare.sign
Result:
00000000 72 73 68 61 72 65 |rshare| 00000006
Working with the file system in scenarios
All dynamic file designations must use one of the specialized prefixes (level 3).
Only level 3 paths are allowed in scripts.
No backtracking allowed (/..)
.
DFSync (domain file sync)
Static information synchronized across all servers of all sites within 10-20 seconds. It is divided into generic and domain-specific. Directories with domains are synchronized on servers owned by the sites where the domain is served.
prefix | Description |
---|---|
|
:SYNC + get_subpath_common() :SYNC/common/ /home/era/media/ + common/ . |
|
:SYNC + get_subpath_domain(Domain) + get_subpath_common() :SYNC/domains/[domain]/common/ /home/era/media/ + domains/domain.org/common/ . |
|
:SYNC + get_subpath_domain(Domain) + get_subpath_data() :SYNC/domains/[domain]/data/ /home/era/media/ + domains/domain.org/data/ . |
|
:SYNC + get_subpath_script_static(Domain, ScriptType, ScriptId) :SYNC/domains/[domain]/scripts/<SCRIPT_TYPE>/<SCRIPT_ID>/static/ /home/era/media/ + domains/domain.org/ + scripts/ivr/1233-43223-43213411234/static/ . |
|
:SYNC + get_subpath_script_data(Domain, ScriptType, ScriptId), :SYNC/domains/[domain]/scripts/<SCRIPT_TYPE>/<SCRIPT_ID>/data/ /home/era/media/ + domains/domain.org/ + scripts/ivr/1233-43223-43213411234/data/ . |
NFS
Shared network directories. Categorized into intra-site and global.
prefix | Description |
---|---|
|
:GLOBALSHARE + get_subpath_public() :GLOBALSHARE/public/ /home/era/globals/ + public . |
|
:GLOBALSHARE + get_subpath_domain(Domain) + get_subpath_data() :GLOBALSHARE/domains/[Domain]/data/ /home/era/globals/ + domains/domain.org/data/ . |
|
:GLOBALSHARE + get_subpath_script_data(Domain, ScriptType, ScriptId) :GLOBALSHARE/domains/[Domain]/scripts/[ScriptType]/[ScriptId]/data/ /home/era/globals/ + domains/domain.org/scripts/ivr/1233-43223-43213411234/data/ . |
|
:SITESHARE + get_subpath_public() :SITESHARE/public/ /home/era/nfs/ + public . |
|
:SITESHARE + get_subpath_domain(Domain) + get_subpath_data() :SITESHARE/domains/[Domain]/data/ /home/era/nfs/ + domains/domain.org/data/ . |
|
:SITESHARE + get_subpath_script_data(Domain, ScriptType, ScriptId) :SITESHARE/domains/[Domain]/scripts/[ScriptType]/[ScriptId]/data/ /home/era/nfs/ + domains/domain.org/scripts/ivr/1233-43223-43213411234/data/ . |
LFS
Local intra-server directories.
prefix | Description |
---|---|
|
:LOCAL + ScriptId + Pid :LOCAL/[ScriptId]/[Pid]/ /home/temp/era/ + temp/nodename/ + 12341234-1234-1234-1234-123412341234/0.123.0/ . |