Package com.caucho.config

Examples of com.caucho.config.ConfigException


    if ("hessian".equals(type))
      _isHessianSerialization = true;
    else if ("java".equals(type))
      _isHessianSerialization = false;
    else
      throw new ConfigException(L.l("'{0}' is an unknown valud for serialization-type.  The valid types are 'hessian' and 'java'.",
                                    type));
  }
View Full Code Here


    else if (reuse.equalsIgnoreCase("false") || reuse.equalsIgnoreCase("no"))
      _reuseSessionId = FALSE;
    else if (reuse.equalsIgnoreCase("all"))
      _reuseSessionId = TRUE;
    else
      throw new ConfigException(L.l("'{0}' is an invalid value for reuse-session-id.  'true' or 'false' are the allowed values.",
                                    reuse));
  }
View Full Code Here

   * Returns the maximum number of sessions.
   */
  public void setSessionMax(int max)
  {
    if (max < 1)
      throw new ConfigException(L.l("session-max '{0}' is too small.  session-max must be a positive number", max));

    _sessionMax = max;
  }
View Full Code Here

  public void init()
  {
    if (_sessionSaveMode == SAVE_ON_SHUTDOWN
        && (_alwaysSaveSession == SET_TRUE
            || _alwaysLoadSession == SET_TRUE))
      throw new ConfigException(L.l("save-mode='on-shutdown' cannot be used with <always-save-session/> or <always-load-session/>"));
    _sessions = new LruCache<String,SessionImpl>(_sessionMax);
    _sessionIter = _sessions.values();

    if (_sessionStore != null)
      _sessionStore.setIdleTimeoutMillis(_sessionTimeout);
View Full Code Here

  @PostConstruct
  public void init()
  {
    if (_remoteUser == null)
      throw new ConfigException(L.l("'value' is a required attribute for {0}",
                                    getClass().getSimpleName()));
  }
View Full Code Here

    if (type.equals("Container"))
      _isContainerTransaction = true;
    else if (type.equals("Bean"))
      _isContainerTransaction = false;
    else
      throw new ConfigException(
          L.l("'{0}' is an unknown transaction-type.  transaction-type must be 'Container' or 'Bean'.",
              type));
  }
View Full Code Here

    // if (getLocalList().size() != 0 || getRemoteList().size() != 0) {
    if (_localList.size() != 0 || _remoteList.size() != 0) {
    } else if (interfaceList.size() == 0) {
      // Session bean no-interface view.
    } else if (interfaceList.size() != 1)
      throw new ConfigException(
          L.l("'{0}' has multiple interfaces, but none are marked as @Local or @Remote.\n{1}",
              type.getJavaClass().getName(), interfaceList.toString()));
    else {
      addLocalType(interfaceList.get(0));
    }
View Full Code Here

  {
    int p = address.lastIndexOf(':');
    int q = address.lastIndexOf(']');

    if (p < 0 && q < p)
      throw new ConfigException(L.l("'{0}' is an invalid address because it does not specify the port.",
                                    address));

    String host = address.substring(0, p);
    int port = Integer.parseInt(address.substring(p + 1));
View Full Code Here

  }

  public void addAddress(String address)
  {
    if (_serverPool != null)
      throw new ConfigException(L.l("Multiple backend load balancing requires Resin Professional."));

    _serverPool = createServerPool(address);
  }
View Full Code Here

  }

  public void init()
  {
    if (_serverPool == null)
      throw new ConfigException(L.l("Load-balancing requires at least one server address."));
  }
View Full Code Here

TOP

Related Classes of com.caucho.config.ConfigException

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.