Go to primary content
Oracle® Retail Predictive Application Server Cloud Edition Administration Guide
Release 19.0
F25569-31
  Go To Table Of Contents
Contents

Previous
Previous
 
Next
Next
 

13 Uploading and Downloading Batch Files

This chapter describes the file upload/download process.

This chapter contains the following sections:

For the batches that load data, the Administrator must upload the relevant input files for the data to the SFTP server before running the batch. After running any export task, the exported files can be found in the export location of the SFTP server.

For details regarding file contents and formatting of the upload and download files, see the Oracle Retail Merchandise Financial Planning Cloud Service Implementation Guide.

Adding Authorized Keys

This section describes the process to generate a 2048 bit RSA key and add the same to the SFTP server. This is done with the help of the WinSCP tool on Windows. However, the same can be done using ssh-keygen on Linux as well.

Prerequisites:

  • The WinSCP tool must be installed before performing the following process.

  • The Private/Public keys must be generated and the Public key must be associated with your SFTP Account for the file upload/Download.

  1. Launch WinSCP and select Tools > Run PuttyGen.

  2. Select SSH-2 RSA for the type of key to generate and enter 2048 for the number of bits in a generated key field. Click Generate.

  3. Move the mouse over the blank space in the window until the key is generated. Moving the mouse over the blank space creates a random pattern which is used for key generation.

    Figure 13-2 Key Generator Progress

    Description of Figure 13-2 follows
    Description of ''Figure 13-2 Key Generator Progress''

  4. Once the key is generated, click Save public key to save the public key to a file.

  5. Click Save private key to save the private key to a file. Confirm to save it with or without a passphrase.

  6. Open an SR with Oracle Support, to associate the public key with your SFTP account (attach the key with the SR).

Logging In to WinSCP

The upload steps use the private key generated in the Adding Authorized Keys section.

  1. Launch WinSCP and connect to <SFTP Server> using port 22.

  2. Enter the user name and click Advanced.

  3. Click Authentication.

  4. In the Private Key File field, click Browse and select the private key created in the Adding Authorized Keys section.

    Figure 13-3 Advanced Site Settings

    Description of Figure 13-3 follows
    Description of ''Figure 13-3 Advanced Site Settings''

  5. After loading the private key file, click OK.

    Figure 13-4 Private Key File Loaded

    Description of Figure 13-4 follows
    Description of ''Figure 13-4 Private Key File Loaded''

  6. Click Login. The window does not prompt for a password and logs in to the SFTP server. Provide a passphrase if one has been set up.

Uploading the Batch File

The following diagram provides an overview of the FTP/internal holding area/domain and how the files move.

Figure 13-5 File Movement Between Internal Holding Area and Domain

Description of Figure 13-5 follows
Description of ''Figure 13-5 File Movement Between Internal Holding Area and Domain''

The following steps walk you through the process to upload batch (data/Hierarchy) file. For information about the administration tasks that require uploading batch files, see "Batch Administration."

For information about the file contents of various exports and formatting, see the information on data load in the Oracle Retail Merchandise Financial Planning Cloud Edition Implementation Guide.

To upload the batch file:

  1. Log in to WinSCP. Follow the steps in "Logging In to WinSCP."

  2. Transfer all the data files to the directory /<SFTP User>.

  3. Create a directory named COMMAND under /<SFTP User> if it does not already exist.

  4. Change to the /<SFTP User>/COMMAND directory.

  5. Transfer an empty file named COMPLETE.

  6. Run the required batch/task from the Online Administration Tools.

File Downloads

The following steps walk you through the process of accessing download files. For information about the administration tasks that create different exports from the applications, see "Batch Administration."

For information about the file contents of various exports and formatting, see the information on exports in the Oracle Retail Merchandise Financial Planning Cloud Service Implementation Guide.

To download files:

  1. Log in to WinSCP. Follow the steps in "Logging In to WinSCP."

  2. Change the directory to /<SFTP User>/EXPORT or /<SFTP User>/Export/logs (for log files).

  3. Create a directory named COMMAND under /<SFTP User>/EXPORT if it does not already exist.

  4. Change to the /<SFTP User>/EXPORT/COMMAND directory.

  5. Transfer an empty file named COMPLETE.

  6. Run the required batch/task from the Online Administration Tools.

  7. Download all the data files. The log files are in tar.gz format.


    Note:

    The log file names are appended with the success/fail text in it along with the time stamp for easy identification.

    The format is the status of the task, followed by the task name and timestamp. For example, success.eebatch_exec.batch_daily.20190611220325.tar.gz.

    For a failure, the code return is also appended. For example, failure.1.eebatch_exportmeas.lpcp.20190604020554.tar.gz.


Download Requests

All downloads for exporting to Excel, exporting text, and exporting task status log files are asynchronous in order to prevent timeouts.

The times are expressed in milliseconds and are positive integers. The polling interval must be less than the timeout. Ideally there must be multiple polling request prior to a timeout. The default polling interval is 1000 (1 sec) and the default timeout is 3600000 (1 hr).

The config properties are:

download.pollinterval - The polling interval from the client's browser to the application server. The polling interval is the period of time between each network request used to check if the download is ready. Once the download is ready or timed out the polling will stop.

download.pollinterval=1000

download.timeout - The time to wait for the download to be ready before cancelling the request.

download.timeout=3600000