Examples of ServletBasedEnvironment


Examples of br.com.caelum.vraptor.environment.ServletBasedEnvironment

   
    super.init(cfg);
   
    try {
     
      Environment environment = new ServletBasedEnvironment(getServletContext());
     
      if(!"production".equalsIgnoreCase(environment.getName())){
        return;
      }
   
      final String url = "http://localhost:8080" + cfg.getServletContext().getContextPath() + "/jobs/configure";
View Full Code Here

Examples of br.com.caelum.vraptor.environment.ServletBasedEnvironment

  private ErrorMailer mailer;

  @Override
  public void init() throws ServletException {
    try {
      ServletBasedEnvironment env = new ServletBasedEnvironment(this.getServletContext());
      Mailer mailer = new MailerFactory(env).getInstance();
      this.mailer = new ErrorMailer(mailer, env);
    } catch (IOException e) {
      throw new ServletException("Unable to initialize error servlet", e);
    }
View Full Code Here

Examples of br.com.caelum.vraptor.environment.ServletBasedEnvironment

  private ErrorMailer mailer;

  @Override
  public void init() throws ServletException {
    try {
      ServletBasedEnvironment env = new ServletBasedEnvironment(this.getServletContext());
      ExecutorService pool = Executors.newCachedThreadPool();
      DefaultAsyncMailer impl = new DefaultAsyncMailer(pool, new AmazonSESMailer(env));
      mailer = new ErrorMailer(impl, env);
    } catch (IOException e) {
      throw new ServletException("Unable to initialize error servlet", e);
View Full Code Here

Examples of br.com.caelum.vraptor.environment.ServletBasedEnvironment

  private static Logger logger = LoggerFactory.getLogger(ErrorLoggerServlet.class);

  @Override
  public void init() throws ServletException {
    try {
      env = new ServletBasedEnvironment(this.getServletContext());
      Mailer mailer = new MailerFactory(env).getInstance();
      this.mailer = new ErrorMailer(mailer);
    } catch (IOException e) {
      throw new ServletException("Unable to initialize error servlet", e);
    }
View Full Code Here

Examples of br.com.caelum.vraptor.environment.ServletBasedEnvironment

  private static Logger logger = LoggerFactory.getLogger(ErrorLoggerServlet.class);

  @Override
  public void init() throws ServletException {
    try {
      env = new ServletBasedEnvironment(this.getServletContext());
      Mailer mailer = new MailerFactory(env).getInstance();
      this.mailer = new ErrorMailer(mailer);
    } catch (IOException e) {
      throw new ServletException("Unable to initialize error servlet", e);
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.