src/main/java/pityoulish/pod/server/Main.java
protected static void readEnvVars()
    throws Exception
  {
    String envvar = null;
    String value = null;
    try {
      envvar = BOARD_CAPACITY_ENV;
      value = System.getenv(envvar);
      if (value != null)
         board_capacity = toInt(value, 1, 8000);

      envvar = JRMI_HOSTNAME_ENV;
      value = System.getenv(envvar);
      if (value != null)
         System.getProperties().setProperty("java.rmi.server.hostname", value);

      envvar = JRMI_REGISTRY_PORT_ENV;
      value = System.getenv(envvar);
      if (value != null)
         jrmi_registry_port = toInt(value, 1025, 65535);

      envvar = JRMI_OBJECTS_PORT_ENV;
      value = System.getenv(envvar);
      if (value != null)
         jrmi_objects_port = toInt(value, 1025, 65535);

      envvar = SOCKETS_PORT_ENV;
      value = System.getenv(envvar);
      if (value != null)
         sockets_port = toInt(value, 1025, 65535);

    } catch (Exception x) {
      LOGGER.log(Level.CONFIG, envvar, x);
      throw new Exception(envvar+": "+x.getMessage(), x);
    }
  }
/**
   * Reads the relevant environment variables.
   * The default values of the configuration variables will be overwritten
   * with the setting from the environment variables, if set.
   *
   * @throws Exception   if one of the env vars is invalid
   */
Reads the relevant environment variables.
The default values of the configuration variables will be overwritten
with the setting from the environment variables, if set.

@throws Exception   if one of the env vars is invalid
Reads the relevant environment variables . The default values of the configuration variables will be overwritten with the setting from the environment variables if set . @throws Exception if one of the env vars is invalid
protected static void readEnvVars()
    throws Exception
  {
    String envvar = null;
    String value = null;
    try {
      envvar = BOARD_CAPACITY_ENV;
      value = System.getenv(envvar);
      if (value != null)
         board_capacity = toInt(value, 1, 8000);
      envvar = JRMI_HOSTNAME_ENV;
      value = System.getenv(envvar);
      if (value != null)
         System.getProperties().setProperty("java.rmi.server.hostname", value);
      envvar = JRMI_REGISTRY_PORT_ENV;
      value = System.getenv(envvar);
      if (value != null)
         jrmi_registry_port = toInt(value, 1025, 65535);
      envvar = JRMI_OBJECTS_PORT_ENV;
      value = System.getenv(envvar);
      if (value != null)
         jrmi_objects_port = toInt(value, 1025, 65535);
      envvar = SOCKETS_PORT_ENV;
      value = System.getenv(envvar);
      if (value != null)
         sockets_port = toInt(value, 1025, 65535);
    } catch (Exception x) {
      LOGGER.log(Level.CONFIG, envvar, x);
      throw new Exception(envvar+": "+x.getMessage(), x);
    }
  }
protected static void readEnvVars ( ) throws Exception { String envvar = null ; String value = null ; try { envvar = BOARD_CAPACITY_ENV ; value = System . getenv ( envvar ) ; if ( value != null ) board_capacity = toInt ( value , 1 , 8000 ) ; envvar = JRMI_HOSTNAME_ENV ; value = System . getenv ( envvar ) ; if ( value != null ) System . getProperties ( ) . setProperty ( "java.rmi.server.hostname" , value ) ; envvar = JRMI_REGISTRY_PORT_ENV ; value = System . getenv ( envvar ) ; if ( value != null ) jrmi_registry_port = toInt ( value , 1025 , 65535 ) ; envvar = JRMI_OBJECTS_PORT_ENV ; value = System . getenv ( envvar ) ; if ( value != null ) jrmi_objects_port = toInt ( value , 1025 , 65535 ) ; envvar = SOCKETS_PORT_ENV ; value = System . getenv ( envvar ) ; if ( value != null ) sockets_port = toInt ( value , 1025 , 65535 ) ; } catch ( Exception x ) { LOGGER . log ( Level . CONFIG , envvar , x ) ; throw new Exception ( envvar + ": " + x . getMessage ( ) , x ) ; } }
Reads the relevant environment variables.
Reads the relevant environment variables .