Skip to main content

Using MarkLogic Content Pump (mlcp)

mlcp Reverse Proxy Support Using Path-Based Routing

Starting in 11.1.0, mlcp supports connecting to MarkLogic server through a reverse proxy using path-based routing. The base paths need to be configured in the proxy configuration, which maps a base path to a specific port (MarkLogic Application Server).

These parameters are used with this feature:

  • -base_path: URL that maps to a port on the destination MarkLogic application server.

    Note

    When -base_path is specified, -restrict_hosts will be automatically set to true. You also need to configure the reverse proxy to use the SessionID cookie generated by MarkLogic Server for session affinity. You might also need to enable session affinity or sticky sessions in your load balancer. The exact configuration steps depend on the proxy. See your proxy documentation for details. 

  • -host: URL of the reverse proxy.

  • -port: URL of port that the reverse proxy listens to.

Note

Digest and certificate authentication are not currently supported when running behind a reverse proxy or a load balancer configured with path-based routing. Configure the MarkLogic app servers to use either basic auth over HTTPS or one of the other supported authentication mechanisms.

Example:

# Windows users, see Modifying the Example Commands for Windows
mlcp.sh import -mode local -host proxy.marklogic.com \
   -base_path "/test/marklogic/app-services/" \
   -port 8080 \ 
   -username user \ 
   -password password \ 
   -document_type xml \
   -input_file_type delimited_text -delimiter "," 
   -input_file_path input/