Codota Logo
org.restlet.ext.platform.internal
Code IndexAdd Codota to your IDE (free)

How to use org.restlet.ext.platform.internal

Best Java code snippets using org.restlet.ext.platform.internal (Showing top 20 results out of 315)

  • Add the Codota plugin to your IDE and get smart completions
private void myMethod () {
Gson g =
  • Codota Iconnew Gson()
  • Codota IconGsonBuilder gsonBuilder;gsonBuilder.create()
  • Codota Iconnew GsonBuilder().create()
  • Smart code suggestions by Codota
}
origin: org.restlet.gae/org.restlet.ext.platform

  @Override
  public void run() {
    agentFilter.refreshRestletCloudFilterIfRevisionChanged();
  }
}
origin: org.restlet.jee/org.restlet.ext.platform

/**
 * Create a new RestletCloudFilter with the specified configuration.
 * 
 * @param context
 *            The current context.
 * @param restletCloudConfig
 *            The RestletCloudService configuration.
 */
public RestletCloudFilter(Context context, RestletCloudConfig restletCloudConfig,
             boolean agentEnabled, boolean firewallEnabled,
             List<FirewallRule> firewallRules) {
  super(context);
  this.firewallRules = firewallRules;
  this.firewallEnabled = firewallEnabled;
  this.restletCloudConfig = restletCloudConfig;
  this.agentEnabled = agentEnabled;
  this.context = context;
  validateRedirection(restletCloudConfig);
  if (agentEnabled) {
    validateAgentConfiguration(restletCloudConfig);
    modulesSettings = ModulesSettingsModule.getModulesSettings(
        restletCloudConfig, null);
  }
  refreshRestletCloudFilter();
}
origin: org.restlet.jse/org.restlet.ext.platform

/**
 * Retrieves the modules settings from the service and updates the filter.
 */
public void refreshRestletCloudFilterIfRevisionChanged() {
  try {
    ModulesSettings newModulesSettings = ModulesSettingsModule
        .getModulesSettings(restletCloudConfig, modulesSettings);
    if (newModulesSettings != null) {
      modulesSettings = newModulesSettings;
      LOGGER.info("Updating modules settings");
      refreshRestletCloudFilter();
    }
  } catch (Exception e) {
    LOGGER.log(Level.WARNING,
        "Unable to retrieve agent settings from platform", e);
  }
}
origin: org.restlet.jee/org.restlet.ext.platform

@Override
public Filter createInboundFilter(Context context) {
  RestletCloudConfig restletCloudConfig = new RestletCloudConfig();
  restletCloudConfig.setAgentCellId(agentCellId);
  restletCloudConfig.setAgentCellVersion(agentCellVersion);
  restletCloudConfig.setAgentServiceUrl(agentServiceUrl);
  restletCloudConfig.setAgentLogin(agentLogin);
  restletCloudConfig.setAgentPassword(agentPassword);
  restletCloudConfig.setReverseProxyEnabled(reverseProxyEnabled);
  restletCloudConfig.setReverseProxyTargetUrl(reverseProxyTargetUrl);
  restletCloudConfig.setAgentAnalyticsBufferSize(agentAnalyticsBufferSize);
  restletCloudConfig.setAgentAnalyticsPostPeriodInSecond(agentAnalyticsPostPeriodInSecond);
  restletCloudFilter = new RestletCloudFilter(context, restletCloudConfig,
      agentEnabled, firewallEnabled, firewallRules);
  if (agentEnabled && agentRefreshPeriodInSecond > 0) {
    TimerTask task = new AgentConfigurationTimerTask(restletCloudFilter);
    agentRefreshTimer = new Timer(true);
    long agentRefreshPeriodInMs = TimeUnit.SECONDS.toMillis(agentRefreshPeriodInSecond);
    agentRefreshTimer.scheduleAtFixedRate(task, agentRefreshPeriodInMs,
        agentRefreshPeriodInMs);
    LOGGER.info("Setting agent refresh timer every "
        + TimeUnit.SECONDS.toMinutes(agentRefreshPeriodInSecond)
        + " minutes");
  }
  return restletCloudFilter;
}
origin: org.restlet.gae/org.restlet.ext.platform

  /**
   * Validates the redirection URL
   * 
   * @param config
   *            The service's configuration
   */
  public void validateRedirection(RestletCloudConfig config) {
    if (config.isReverseProxyEnabled()
        && StringUtils.isNullOrEmpty(config.getReverseProxyTargetUrl())) {
      throw new IllegalArgumentException(
          "The redirection url is mandatory when redirection is enabled");
    }
  }
}
origin: org.restlet.jse/org.restlet.ext.platform

@Override
public Filter createInboundFilter(Context context) {
  RestletCloudConfig restletCloudConfig = new RestletCloudConfig();
  restletCloudConfig.setAgentCellId(agentCellId);
  restletCloudConfig.setAgentCellVersion(agentCellVersion);
  restletCloudConfig.setAgentServiceUrl(agentServiceUrl);
  restletCloudConfig.setAgentLogin(agentLogin);
  restletCloudConfig.setAgentPassword(agentPassword);
  restletCloudConfig.setReverseProxyEnabled(reverseProxyEnabled);
  restletCloudConfig.setReverseProxyTargetUrl(reverseProxyTargetUrl);
  restletCloudConfig.setAgentAnalyticsBufferSize(agentAnalyticsBufferSize);
  restletCloudConfig.setAgentAnalyticsPostPeriodInSecond(agentAnalyticsPostPeriodInSecond);
  restletCloudFilter = new RestletCloudFilter(context, restletCloudConfig,
      agentEnabled, firewallEnabled, firewallRules);
  if (agentEnabled && agentRefreshPeriodInSecond > 0) {
    TimerTask task = new AgentConfigurationTimerTask(restletCloudFilter);
    agentRefreshTimer = new Timer(true);
    long agentRefreshPeriodInMs = TimeUnit.SECONDS.toMillis(agentRefreshPeriodInSecond);
    agentRefreshTimer.scheduleAtFixedRate(task, agentRefreshPeriodInMs,
        agentRefreshPeriodInMs);
    LOGGER.info("Setting agent refresh timer every "
        + TimeUnit.SECONDS.toMinutes(agentRefreshPeriodInSecond)
        + " minutes");
  }
  return restletCloudFilter;
}
origin: org.restlet.gae/org.restlet.ext.platform

/**
 * Create a new RestletCloudFilter with the specified configuration.
 * 
 * @param context
 *            The current context.
 * @param restletCloudConfig
 *            The RestletCloudService configuration.
 */
public RestletCloudFilter(Context context, RestletCloudConfig restletCloudConfig,
             boolean agentEnabled, boolean firewallEnabled,
             List<FirewallRule> firewallRules) {
  super(context);
  this.firewallRules = firewallRules;
  this.firewallEnabled = firewallEnabled;
  this.restletCloudConfig = restletCloudConfig;
  this.agentEnabled = agentEnabled;
  this.context = context;
  validateRedirection(restletCloudConfig);
  if (agentEnabled) {
    validateAgentConfiguration(restletCloudConfig);
    modulesSettings = ModulesSettingsModule.getModulesSettings(
        restletCloudConfig, null);
  }
  refreshRestletCloudFilter();
}
origin: org.restlet.jse/org.restlet.ext.platform

  /**
   * Validates the redirection URL
   * 
   * @param config
   *            The service's configuration
   */
  public void validateRedirection(RestletCloudConfig config) {
    if (config.isReverseProxyEnabled()
        && StringUtils.isNullOrEmpty(config.getReverseProxyTargetUrl())) {
      throw new IllegalArgumentException(
          "The redirection url is mandatory when redirection is enabled");
    }
  }
}
origin: org.restlet.jee/org.restlet.ext.platform

/**
 * Retrieves the modules settings from the service and updates the filter.
 */
public void refreshRestletCloudFilterIfRevisionChanged() {
  try {
    ModulesSettings newModulesSettings = ModulesSettingsModule
        .getModulesSettings(restletCloudConfig, modulesSettings);
    if (newModulesSettings != null) {
      modulesSettings = newModulesSettings;
      LOGGER.info("Updating modules settings");
      refreshRestletCloudFilter();
    }
  } catch (Exception e) {
    LOGGER.log(Level.WARNING,
        "Unable to retrieve agent settings from platform", e);
  }
}
origin: org.restlet.jee/org.restlet.ext.platform

  @Override
  public void run() {
    agentFilter.refreshRestletCloudFilterIfRevisionChanged();
  }
}
origin: org.restlet.osgi/org.restlet.ext.platform

@Override
public Filter createInboundFilter(Context context) {
  RestletCloudConfig restletCloudConfig = new RestletCloudConfig();
  restletCloudConfig.setAgentCellId(agentCellId);
  restletCloudConfig.setAgentCellVersion(agentCellVersion);
  restletCloudConfig.setAgentServiceUrl(agentServiceUrl);
  restletCloudConfig.setAgentLogin(agentLogin);
  restletCloudConfig.setAgentPassword(agentPassword);
  restletCloudConfig.setReverseProxyEnabled(reverseProxyEnabled);
  restletCloudConfig.setReverseProxyTargetUrl(reverseProxyTargetUrl);
  restletCloudConfig.setAgentAnalyticsBufferSize(agentAnalyticsBufferSize);
  restletCloudConfig.setAgentAnalyticsPostPeriodInSecond(agentAnalyticsPostPeriodInSecond);
  restletCloudFilter = new RestletCloudFilter(context, restletCloudConfig,
      agentEnabled, firewallEnabled, firewallRules);
  if (agentEnabled && agentRefreshPeriodInSecond > 0) {
    TimerTask task = new AgentConfigurationTimerTask(restletCloudFilter);
    agentRefreshTimer = new Timer(true);
    long agentRefreshPeriodInMs = TimeUnit.SECONDS.toMillis(agentRefreshPeriodInSecond);
    agentRefreshTimer.scheduleAtFixedRate(task, agentRefreshPeriodInMs,
        agentRefreshPeriodInMs);
    LOGGER.info("Setting agent refresh timer every "
        + TimeUnit.SECONDS.toMinutes(agentRefreshPeriodInSecond)
        + " minutes");
  }
  return restletCloudFilter;
}
origin: org.restlet.jse/org.restlet.ext.platform

/**
 * Create a new RestletCloudFilter with the specified configuration.
 * 
 * @param context
 *            The current context.
 * @param restletCloudConfig
 *            The RestletCloudService configuration.
 */
public RestletCloudFilter(Context context, RestletCloudConfig restletCloudConfig,
             boolean agentEnabled, boolean firewallEnabled,
             List<FirewallRule> firewallRules) {
  super(context);
  this.firewallRules = firewallRules;
  this.firewallEnabled = firewallEnabled;
  this.restletCloudConfig = restletCloudConfig;
  this.agentEnabled = agentEnabled;
  this.context = context;
  validateRedirection(restletCloudConfig);
  if (agentEnabled) {
    validateAgentConfiguration(restletCloudConfig);
    modulesSettings = ModulesSettingsModule.getModulesSettings(
        restletCloudConfig, null);
  }
  refreshRestletCloudFilter();
}
origin: org.restlet.jee/org.restlet.ext.platform

  /**
   * Validates the redirection URL
   * 
   * @param config
   *            The service's configuration
   */
  public void validateRedirection(RestletCloudConfig config) {
    if (config.isReverseProxyEnabled()
        && StringUtils.isNullOrEmpty(config.getReverseProxyTargetUrl())) {
      throw new IllegalArgumentException(
          "The redirection url is mandatory when redirection is enabled");
    }
  }
}
origin: org.restlet.osgi/org.restlet.ext.platform

/**
 * Retrieves the modules settings from the service and updates the filter.
 */
public void refreshRestletCloudFilterIfRevisionChanged() {
  try {
    ModulesSettings newModulesSettings = ModulesSettingsModule
        .getModulesSettings(restletCloudConfig, modulesSettings);
    if (newModulesSettings != null) {
      modulesSettings = newModulesSettings;
      LOGGER.info("Updating modules settings");
      refreshRestletCloudFilter();
    }
  } catch (Exception e) {
    LOGGER.log(Level.WARNING,
        "Unable to retrieve agent settings from platform", e);
  }
}
origin: org.restlet.osgi/org.restlet.ext.platform

  @Override
  public void run() {
    agentFilter.refreshRestletCloudFilterIfRevisionChanged();
  }
}
origin: org.restlet.gae/org.restlet.ext.platform

@Override
public Filter createInboundFilter(Context context) {
  RestletCloudConfig restletCloudConfig = new RestletCloudConfig();
  restletCloudConfig.setAgentCellId(agentCellId);
  restletCloudConfig.setAgentCellVersion(agentCellVersion);
  restletCloudConfig.setAgentServiceUrl(agentServiceUrl);
  restletCloudConfig.setAgentLogin(agentLogin);
  restletCloudConfig.setAgentPassword(agentPassword);
  restletCloudConfig.setReverseProxyEnabled(reverseProxyEnabled);
  restletCloudConfig.setReverseProxyTargetUrl(reverseProxyTargetUrl);
  restletCloudConfig.setAgentAnalyticsBufferSize(agentAnalyticsBufferSize);
  restletCloudConfig.setAgentAnalyticsPostPeriodInSecond(agentAnalyticsPostPeriodInSecond);
  restletCloudFilter = new RestletCloudFilter(context, restletCloudConfig,
      agentEnabled, firewallEnabled, firewallRules);
  if (agentEnabled && agentRefreshPeriodInSecond > 0) {
    TimerTask task = new AgentConfigurationTimerTask(restletCloudFilter);
    agentRefreshTimer = new Timer(true);
    long agentRefreshPeriodInMs = TimeUnit.SECONDS.toMillis(agentRefreshPeriodInSecond);
    agentRefreshTimer.scheduleAtFixedRate(task, agentRefreshPeriodInMs,
        agentRefreshPeriodInMs);
    LOGGER.info("Setting agent refresh timer every "
        + TimeUnit.SECONDS.toMinutes(agentRefreshPeriodInSecond)
        + " minutes");
  }
  return restletCloudFilter;
}
origin: org.restlet.osgi/org.restlet.ext.platform

/**
 * Create a new RestletCloudFilter with the specified configuration.
 * 
 * @param context
 *            The current context.
 * @param restletCloudConfig
 *            The RestletCloudService configuration.
 */
public RestletCloudFilter(Context context, RestletCloudConfig restletCloudConfig,
             boolean agentEnabled, boolean firewallEnabled,
             List<FirewallRule> firewallRules) {
  super(context);
  this.firewallRules = firewallRules;
  this.firewallEnabled = firewallEnabled;
  this.restletCloudConfig = restletCloudConfig;
  this.agentEnabled = agentEnabled;
  this.context = context;
  validateRedirection(restletCloudConfig);
  if (agentEnabled) {
    validateAgentConfiguration(restletCloudConfig);
    modulesSettings = ModulesSettingsModule.getModulesSettings(
        restletCloudConfig, null);
  }
  refreshRestletCloudFilter();
}
origin: org.restlet.osgi/org.restlet.ext.platform

  /**
   * Validates the redirection URL
   * 
   * @param config
   *            The service's configuration
   */
  public void validateRedirection(RestletCloudConfig config) {
    if (config.isReverseProxyEnabled()
        && StringUtils.isNullOrEmpty(config.getReverseProxyTargetUrl())) {
      throw new IllegalArgumentException(
          "The redirection url is mandatory when redirection is enabled");
    }
  }
}
origin: org.restlet.gae/org.restlet.ext.platform

/**
 * Retrieves the modules settings from the service and updates the filter.
 */
public void refreshRestletCloudFilterIfRevisionChanged() {
  try {
    ModulesSettings newModulesSettings = ModulesSettingsModule
        .getModulesSettings(restletCloudConfig, modulesSettings);
    if (newModulesSettings != null) {
      modulesSettings = newModulesSettings;
      LOGGER.info("Updating modules settings");
      refreshRestletCloudFilter();
    }
  } catch (Exception e) {
    LOGGER.log(Level.WARNING,
        "Unable to retrieve agent settings from platform", e);
  }
}
origin: org.restlet.jse/org.restlet.ext.platform

  @Override
  public void run() {
    agentFilter.refreshRestletCloudFilterIfRevisionChanged();
  }
}
org.restlet.ext.platform.internal

Most used classes

  • RestletCloudConfig
    TODO I'm not convinced by the presence of such configuration bean. The service really hosts the conf
  • RestletCloudFilter
  • AgentConfigurationException
  • AgentConfigurationTimerTask
  • AgentException
  • AuthenticationSettings,
  • CallLog,
  • CallLogs,
  • Credentials,
  • FirewallIpFilter,
  • FirewallRateLimit,
  • FirewallSettings,
  • ModulesSettings,
  • OperationAuthorization,
  • User,
  • AnalyticsHandler$AsyncCallLogsPostTask,
  • AnalyticsHandler,
  • AnalyticsModule,
  • AuthenticationModule$AgentVerifier
Codota Logo
  • Products

    Search for Java codeSearch for JavaScript codeEnterprise
  • IDE Plugins

    IntelliJ IDEAWebStormAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogCodota Academy Plugin user guide Terms of usePrivacy policyJava Code IndexJavascript Code Index
Get Codota for your IDE now