AO Logo
 
  
  
  
With Username
With Properties
AO
AO Industries, Inc.
Application Infrastructure ProviderApplication Infrastructure Provider
Sign UpWhat's NewClient AreaContact UsSite Map
 
your location:   home page ··· aoserv platform ··· software components ··· aoserv client ··· how to ··· establishing a connection ··· connecting using properties file
Connecting Using Properties File

Description
The username and password for connections may be stored in the AO Serv Client properties file named /com/aoindustries/aoserv/client/aoserv-client.properties. The default properties look like the following:
aoserv.client.username=
aoserv.client.password=

# List of supported protocols
aoserv.client.protocols=tcp

# Socket specific parameters
aoserv.client.tcp.hostname=master.aoindustries.com
aoserv.client.tcp.port=4582
aoserv.client.tcp.connection.pool.size=8

By placing this resource in your CLASSPATH before aoserv-client.jar, you can override the default settings. Adding the username and password for your connection will avoid login prompts for the aosh and allow you to use the AOServConnector.getConnector() call to establish connections.
aoserv.client.username=my_username
aoserv.client.password=my_strong_password

# List of supported protocols
aoserv.client.protocols=tcp

# Socket specific parameters
aoserv.client.tcp.hostname=master.aoindustries.com
aoserv.client.tcp.port=4582
aoserv.client.tcp.connection.pool.size=8

AOSH Commands
First, log into the server using either SSH or Telnet, preferably SSH. Once authenticated, type:

For interactive mode: aosh -i
For script mode: aosh

Simple API
import com.aoindustries.aoserv.client.SimpleAOClient;

// ...

SimpleAOClient aoClient=new SimpleAOClient();

// ...

Full API
import com.aoindustries.aoserv.client.*;

// ...

AOServConnector aoConn=new AOServConnector();

// ...
Copyright © 2000-2025 AO Industries, Inc.