Package com.caucho.config

Examples of com.caucho.config.ConfigException


    if (port == -1)
      port = findPort(client);

    if (port == 0) {
      throw new ConfigException(L.l("HTTP listener {0}:{1} was not found",
                                    address, port));
    }

    String user = args.getArg("-user");
    String password = args.getArg("-password");

    try {
      Constructor c = scalingClientClass.getConstructor(String.class,
                                                        int.class,
                                                        String.class,
                                                        String.class);

      ResinScalingClient scaingClient;
      scaingClient = (ResinScalingClient) c.newInstance(address,
                                                        port,
                                                        user,
                                                        password);

      return scaingClient;
    } catch (Exception e) {
      throw new ConfigException(e.getMessage(), e);
    }
  }
View Full Code Here


    throws ConfigException
  {
    // super.init();

    if (_target == null) {
      throw new ConfigException(L.l("'target' is a required attribute of '{0}' because Resin needs to know the destination URL.",
                                    getClass().getSimpleName()));
    }

    /*
    if (getRegexp() == null && getFullUrlRegexp() == null)
View Full Code Here

  @PostConstruct
  public void init()
    throws ConfigException
  {
    if (_name == null &&  !_isEnabled && _enableAt == null)
        throw new ConfigException(L.l("{0} requires 'name' if enabled='false' and enable-at is undefined",
                                      getTagName()));
    if (_enableAt != null)
      _enableAlarmListener = new EnableAlarmListener(this, _enableAt, true);

    if (_disableAt != null)
View Full Code Here

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

                                    WebAppDeployClient deployClient);

  protected final void fillInVersion(CommitBuilder commit, String version) {
    String []parts = version.split("\\.");
    if (parts.length < 2)
      throw new ConfigException(L.l(
        "erroneous version '{0}'. Version expected in format %d.%d[.%d[.%s]]",
        version));

    int major = Integer.parseInt(parts[0]);
    int minor = Integer.parseInt(parts[1]);
View Full Code Here

    if (port == -1)
      port = findPort(client);

    if (port == 0) {
      throw new ConfigException(L.l("HTTP listener {0}:{1} was not found",
                                    address, port));
    }
   
    String user = args.getArg("-user");
    String password = args.getArg("-password");
View Full Code Here

  @Override
  @PostConstruct
  public void init()
  {
    if (_path == null)
      throw new ConfigException(L.l("'path' attribute missing from resin:import."));

    if (getName() == null)
      setName(_path.getNativePath());

    try {
View Full Code Here

        setMatchRule(matchRule);

        return;
      }
      else {
        throw new ConfigException(L.l("Required file '{0}' can not be read for import.",
                                      _path.getNativePath()));
      }

      Config config = new Config();
View Full Code Here

     */
    public void addJava(Path path)
      throws ConfigException
    {
      if (! path.canRead())
        throw new ConfigException(L.l("<java> module {0} must be a valid path.",
                                      path));
    }
View Full Code Here

  }

  public void setInit(ContainerProgram init)
  {
    if (_protocolClass == null)
      throw new ConfigException(L.l("<init> requires a protocol class"));

    _init = init;
  }
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.