-
Notifications
You must be signed in to change notification settings - Fork 349
Docker User Guide
There are two parts of the combination of Docker and esProc –Server side and Client side. At the Server side, the Docker administrator manages resources and distribute them among users; at the Client side, users can access esProc on the service side directly from the esProc IDE and executescript files on servers.
To access server side from client side, click Tool -> Docker login/Docker logout in esProc IDE to log in or log out Docker.
IP: When there are multiple physical machines, IP is the main server physical machine’s IP.
Port: The port number correspondingto configuration file docker_server.xml’s tag.
Username and password: Username and password configured in user management file docker_users.xml.
In the user management file docker_users.xmlconfigured at the server side, the tag has three subdirectories –config, script and data, which store configuration file, splx file and the data file. All of them are maintained by the administratoron the server side.
(1) Call script file test.splx
Below is cellset parameter test.splx file, where arg1 is the parameter passed to it:
A | |
---|---|
1 | =arg1+" world!" |
The Server admin needs to place test.splx file in the scriptdirectory of the current user on the server, such as /opt/app/aaa/script. Call test.splx file on the client side:
Single machine single port:
A | |
---|---|
1 | =callx("test.splx","hello";["192.168.18.161:8281"]) |
Single machine multiple ports:
A | |
---|---|
1 | =callx("test.splx","hello";["192.168.18.161:8281","192.168.18.161:8282"]) |
Multiple machines single port:
A | |
---|---|
1 | =callx("test.splx","hello";["192.168.18.161:8281","192.168.18.162:8281"]) |
Multiple machines multiple ports:
A | |
---|---|
1 | =callx("test.splx","hello";["192.168.18.161:8281","192.168.18.162:8282"]) |
(2) Call data file
The server administrator puts EMPLOYEE.xls in the datadirectory of the current user on the server, such as /opt/app/aaa/data:
A | |
---|---|
1 | =file("EMPLOYEE.xls","192.168.18.161:8281") |
2 | =A1.xlsopen() |
(3) Call configuration file
Reference raqsoftConfig.xml file in esProc\config directory when you need to use JDBC –put raqsoftConfig.xml file where JDBC is configured in the config directory of the current user on the server, such as/opt/app/aaa/config.
Note: The esProc serial number also needs to be configured in raqsoftConfig.xml.
Scenario 1: Use a built-in database in Docker-esProc
DockerServer administrator only needs to start the built-in Demo database and configure raqsoftConfig.xml. Demo database type is HSQL, and configurations for the other types of databases are similar. Reference esProc Tutorial - Database Configuration for detailed configurations.
Start Demo data source:
Add a data source in raqsoftConfig.xml:
Scenario 2: Use a database outside Docker-esProc
DockerServer administrator places database driver in public resource directory’s jdbc directory, configures the database in raqsoftConfig.xml, and puts the configuration file in the current user’s config directory.
Public resource directory:
Note: The extlib directory in the public resource directory is the map of external libraries.
SPL Resource: SPL Official Website | SPL Blog | Download esProc SPL | SPL Source Code