#Sending Miscellaneous Files to Server
The API Controller offers the added benefit of enabling clients to transmit non-Open iT related files to the server. This feature is particularly advantageous in scenarios where clients are required to send mapping files from their local machines. Currently, clients are only allowed to send files only from a single directory to the server. While this limitation is in effect, users may need to consolidate relevant files into a specific directory for seamless transmission.
To configure sending of files to the server:
On the client machine, open
apicontroller.xml
in the Components directory, which is by default inC:\Program Files\OpeniT\Core\Configuration\Components
.Locate object node
upload_misc
and set the value of its subobject nodedir
to the path of the directory containing the miscellaneous files.apicontroller.xmlExample: apicontroller.xmlSave the file.
Open a command prompt with Administrator level privileges.
Go to the bin directory, which is by default in
C:\Program Files\OpeniT\Core\bin
, run the command:Command SyntaxExampleUpdate the configuration file, run the command:
Command Syntax
The files from the client will be uploaded to the server in $ROOT_DATA_DIR\misc
, which is by default in C:\ProgramData\OpeniT\Data\misc
.
#Retaining Client Source Files
The API Controller deletes the source files upon sending them to the server by default. However, in the case of sending miscellaneous files to the server, it is not advisable to delete the source file upon sending. Instead, it is recommended to retain the source files to ensure data integrity and avoid unintended loss.
The retention of client source files is enabled by default. If disabled, follow these instructions to enable:
On the client machine, open
apicontroller.xml
in the Components directory, which is by default inC:\Program Files\OpeniT\Core\Configuration\Components
.Locate object node
upload_misc
and make sure the value of its subobject nodekeep_data
is true.apicontroller.xmlSave the changes.
Open a command prompt with Administrator level privileges.
Go to the bin directory, which is by default in
C:\Program Files\OpeniT\Core\bin
, run the command:Command SyntaxExampleUpdate the configuration file, run the command:
Command Syntax
#Enabling Scheduler to Send Files to Server
By default, this scheduler job is not enabled. If enabled, the API Controller will send the client files to the server once a day.
Follow these instructions to enable:
Open a command prompt with Administrator level privileges.
Go to the bin directory, which is by default in
C:\Program Files\OpeniT\Core\bin
, run the command:Command SyntaxExampleOnce in the directory, activate the sending of miscellaneous files, run the command:
Command Syntax
#Force Send Client Files to Server
After configuring the APIController, you can force the client to send files to the server:
Go to the bin directory, which is by default in
C:\Program Files\OpeniT\Core\bin
, run the command:Command SyntaxExampleRun the following command:
Command SyntaxCheck that the files from the client are uploaded to the server in
$ROOT_DATA_DIR\misc
, which is by default inC:\ProgramData\OpeniT\Data\misc
.