Example usage for java.util.logging Level SEVERE

List of usage examples for java.util.logging Level SEVERE

Introduction

In this page you can find the example usage for java.util.logging Level SEVERE.

Prototype

Level SEVERE

To view the source code for java.util.logging Level SEVERE.

Click Source Link

Document

SEVERE is a message level indicating a serious failure.

Usage

From source file:fedroot.dacs.http.DacsResponse.java

public DacsResponse(HttpResponse httpResponse) throws DacsException {
    this.httpResponse = httpResponse;
    if (httpResponse.getEntity() != null) {
        try { // we use a BufferedHttpEntity so we can reset the input stream  after a DacsCheckRequest
            this.inputStream = new BufferedHttpEntity(httpResponse.getEntity()).getContent();
        } catch (IOException ex) {
            logger.log(Level.SEVERE, null, ex);
            throw new DacsException(ex.getLocalizedMessage());
        }//w ww . ja  v a  2  s . c o  m
    }
}

From source file:org.shareok.data.commons.uuid.ObjectUUIDGeneratorImpl.java

public ObjectUUIDGeneratorImpl() {
    try {//w w  w  .  j  a va 2 s .com
        generator = Generators.nameBasedGenerator(NameBasedGenerator.NAMESPACE_DNS,
                MessageDigest.getInstance("SHA1"));
        generator = Generators.nameBasedGenerator(getRepoUuidV5(), MessageDigest.getInstance("SHA1"));
    } catch (NoSuchAlgorithmException ex) {
        Logger.getLogger(ObjectUUIDGeneratorImpl.class.getName()).log(Level.SEVERE, null, ex);
    }
}

From source file:flink.FlowSchema.java

@Override
public Flow deserialize(byte[] message) {
    Flow flow;//from   w  w  w.j a  va2  s .  c o  m
    try {
        flow = mapper.readValue(message, Flow.class);
    } catch (IOException ex) {
        Logger.getLogger(Job.class.getName()).log(Level.SEVERE, null, ex);
        return new Flow();
    }
    return flow;
}

From source file:br.com.itfox.utils.Utils.java

public static String dateFormat(String date_s) {
    String dateFormated = "";
    try {//from w w w.  j  av a 2s .co  m
        //String date_s = "2011-01-18 00:00:00.0";

        // *** note that it's "yyyy-MM-dd hh:mm:ss" not "yyyy-mm-dd hh:mm:ss"
        SimpleDateFormat dt = new SimpleDateFormat("dd/MM/yy");
        Date date = dt.parse(date_s);

        // *** same for the format String below
        SimpleDateFormat dt1 = new SimpleDateFormat("yyyy-MM-dd");
        dateFormated = dt1.format(date);
        //System.out.println(dateFormated);
    } catch (ParseException ex) {
        Logger.getLogger(Utils.class.getName()).log(Level.SEVERE, null, ex);
    }
    return dateFormated;
}

From source file:com.ut.healthelink.jobs.loadBatches.java

@Override
public void execute(JobExecutionContext context) throws JobExecutionException {

    try {//  www. j  a  v a 2 s  . c  o  m
        SpringBeanAutowiringSupport.processInjectionBasedOnCurrentContext(this);
        transactionInManager.loadBatches();
    } catch (Exception ex) {
        try {
            throw new Exception("Error occurred trying to load batch files from schedule task", ex);
        } catch (Exception ex1) {
            Logger.getLogger(loadBatches.class.getName()).log(Level.SEVERE, null, ex1);
        }
    }

}

From source file:com.aaasec.sigserv.cscommon.SqLiteConnectionPool.java

/**
 * Gets a database connection from the connection pool for the provided connection URL.
 * If the connection URL is called for the first time, a new database connection pool
 * is created, else the connection pool created for that connection URL is used.
 * @param dbUrl The database source URL/* w ww  .j a v  a  2s.com*/
 * @return Database connection
 */
public static Connection getConnection(String dbUrl, String userName, String password) throws SQLException {
    try {
        Class.forName("org.sqlite.JDBC");
    } catch (ClassNotFoundException ex) {
        LOG.log(Level.SEVERE, null, ex);
    }
    DataSource dataSource = getDataSource(dbUrl, userName, password);
    Connection conn = null;
    conn = dataSource.getConnection();
    return conn;
}

From source file:Database.Handler.java

private Handler() {
    try {//from w w  w  .  j a va 2  s  . co  m
        Class.forName("com.mysql.jdbc.Driver");
    } catch (ClassNotFoundException ex) {
        Logger.getLogger(Handler.class.getName()).log(Level.SEVERE, null, ex);
    }
}

From source file:com.au.splashinc.JControl.Load.JsonLoader.java

@Override
public void LoadConfig() {
    JSONParser parser = new JSONParser();
    try {//w  ww  . j a  va2s  . c om
        Object obj = parser.parse(new FileReader(location));
        JSONObject jsonObject = (JSONObject) obj;
        //Do stuff probably in another class
    } catch (IOException | ParseException ex) {
        Logger.getLogger(JsonLoader.class.getName()).log(Level.SEVERE, null, ex);
    }
}

From source file:com.ut.healthelink.jobs.MoveSFTPFiles.java

@Override
public void execute(JobExecutionContext context) throws JobExecutionException {

    try {// w  w w  . ja v a 2s  .  c o  m
        SpringBeanAutowiringSupport.processInjectionBasedOnCurrentContext(this);
        transactionInManager.moveSFTPFiles();
    } catch (Exception ex) {
        try {
            throw new Exception("Error occurred trying to move SFTP files from schedule task", ex);
        } catch (Exception ex1) {
            Logger.getLogger(MoveSFTPFiles.class.getName()).log(Level.SEVERE, null, ex1);
        }
    }

}