Example usage for java.util.logging Level FINER

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

Introduction

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

Prototype

Level FINER

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

Click Source Link

Document

FINER indicates a fairly detailed tracing message.

Usage

From source file:org.b3log.solo.repository.impl.CommentRepositoryImpl.java

@Override
public int removeComments(final String onId) throws RepositoryException {
    final List<JSONObject> comments = getComments(onId, 1, Integer.MAX_VALUE);

    for (final JSONObject comment : comments) {
        final String commentId = comment.optString(Keys.OBJECT_ID);
        remove(commentId);/*from  w  ww  .jav a  2  s .  c  o m*/
    }

    LOGGER.log(Level.FINER, "Removed comments[onId={0}, removedCnt={1}]",
            new Object[] { onId, comments.size() });

    return comments.size();
}

From source file:org.jenkinsci.plugins.dockerhub.notification.Coordinator.java

public void onTriggered(@Nonnull Job job, @Nonnull WebHookPayload payload) {
    logger.log(Level.FINER, "Job {0} triggered for payload: {1}",
            new Object[] { job.getFullDisplayName(), payload });
    TriggerStore.getInstance().triggered(payload, job);
}

From source file:com.adr.taskexecutor.ui.TaskExecutorRemote.java

/** Creates new form TaskExecutorRemote */
public TaskExecutorRemote() {
    initComponents();// www.  j  a  v a 2  s . co  m

    jLoggingLevel.addItem(Level.SEVERE);
    jLoggingLevel.addItem(Level.WARNING);
    jLoggingLevel.addItem(Level.INFO);
    jLoggingLevel.addItem(Level.CONFIG);
    jLoggingLevel.addItem(Level.FINE);
    jLoggingLevel.addItem(Level.FINER);
    jLoggingLevel.addItem(Level.FINEST);
    jLoggingLevel.addItem(Level.OFF);
    jLoggingLevel.addItem(Level.ALL);

    jURL.setText(Configuration.getInstance().getPreference("remote.serverurl",
            "http://localhost/taskexecutoree/executetask"));
    jLoggingLevel.setSelectedItem(Level
            .parse(Configuration.getInstance().getPreference("remote.logginglevel", Level.INFO.toString())));
    jTrace.setSelected(Boolean
            .parseBoolean(Configuration.getInstance().getPreference("remote.trace", Boolean.FALSE.toString())));
    jStats.setSelected(Boolean
            .parseBoolean(Configuration.getInstance().getPreference("remote.stats", Boolean.TRUE.toString())));
}

From source file:org.b3log.solo.service.TagQueryService.java

/**
 * Gets a tag by the specified tag title.
 *
 * @param tagTitle the specified tag title
 * @return for example,/*ww  w. ja v a 2s  .c  o  m*/
 * <pre>
 * {
 *     "tag": {
 *         "oId": "",
 *         "tagTitle": "",
 *         "tagReferenceCount": int,
 *         "tagPublishedRefCount": int
 *     }
 * }
 * </pre>, returns {@code null} if not found
 * @throws ServiceException service exception
 */
public JSONObject getTagByTitle(final String tagTitle) throws ServiceException {
    try {
        final JSONObject ret = new JSONObject();

        final JSONObject tag = tagRepository.getByTitle(tagTitle);

        if (null == tag) {
            return null;
        }

        ret.put(Tag.TAG, tag);

        LOGGER.log(Level.FINER, "Got an tag[title={0}]", tagTitle);

        return ret;
    } catch (final RepositoryException e) {
        LOGGER.log(Level.SEVERE, "Gets an article failed", e);
        throw new ServiceException(e);
    }
}

From source file:name.richardson.james.bukkit.alias.persistence.InetAddressRecordManager.java

public List<InetAddressRecord> list() {
    logger.log(Level.FINER, "Listing all InetAddressRecords.");
    Query<InetAddressRecord> query = database.createQuery(InetAddressRecord.class);
    return query.findList();
}

From source file:mendeley2kindle.KindleDAO.java

public void open(String kindleLocal) throws IOException, JSONException {
    this.kindleLocal = kindleLocal;

    File path = new File(kindleLocal);
    File file = new File(path, KINDLE_COLLECTIONS_JSON);
    log.log(Level.FINER, "Loading collections data: " + file);
    if (file.exists() && file.canRead()) {
        FileReader fr = new FileReader(file);
        StringBuilder sb = new StringBuilder();
        char[] buf1 = new char[2048];
        for (int read = 0; (read = fr.read(buf1)) > 0;)
            sb.append(buf1, 0, read);/* w w  w .j  ava2s  .c o m*/

        collections = new JSONObject(sb.toString());
        log.log(Level.FINE, "Loaded kindle collections: " + path);
    } else {
        log.log(Level.FINE, "Kindle collections data " + file + " not found. Creating...");
        collections = new JSONObject();
    }
    isOpened = true;
}

From source file:de.lohndirekt.print.IppHttpConnection.java

/**
 * @param uri/*from w w w  .  j av  a  2 s.c o m*/
 * @param user
 * @param passwd
 * @param useStream
 */
public IppHttpConnection(URI uri, String user, String passwd) {
    try {
        httpConn = new HttpClient();
        method = new PostMethod(toHttpURI(uri).toString());
        method.addRequestHeader("Content-type", "application/ipp");
        method.addRequestHeader("Accept", "text/html, image/gif, image/jpeg, *; q=.2, */*; q=.2");
        method.setRequestContentLength(EntityEnclosingMethod.CONTENT_LENGTH_AUTO);
        // authentication
        if (user != null && user.trim().length() > 0) {
            if (log.isLoggable(Level.FINER)) {
                log.log(Level.SEVERE, "Using username: " + user + " , passwd.length " + passwd.length());
            }
            method.setDoAuthentication(true);
            Credentials creds = new UsernamePasswordCredentials(user, passwd);
            httpConn.getState().setCredentials(null, toHttpURI(uri).getHost(), creds);

        }

    } catch (Exception e) {
        log.log(Level.SEVERE, e.getMessage(), e);
    }
}

From source file:org.cloudifysource.esc.driver.provisioning.openstack.OpenStackNovaClient.java

/**
 * Create a new VM instance./*from w w w  .j a va2s .co  m*/
 * 
 * @param request
 *            The request.
 * @return The server details.
 * @throws OpenstackException
 *             Thrown when a problem occurs with the request.
 */
public NovaServer createServer(final NovaServerResquest request) throws OpenstackException {
    final String computeRequest = JsonUtils.toJson(request, false);
    if (logger.isLoggable(Level.FINER)) {
        logger.log(Level.FINER, "Request=createServer: " + computeRequest);
    }
    final String response = this.doPost("servers", computeRequest);
    final NovaServer nsr = JsonUtils.unwrapRootToObject(NovaServer.class, response);
    return nsr;
}

From source file:eu.flatworld.worldexplorer.layer.bmng.BMNGHTTPProvider.java

@Override
public void run() {
    while (true) {
        while (getQueueSize() != 0) {
            Tile tile = peekTile();//from  ww w. j  a  v a2 s . co m
            synchronized (tile) {
                String s = String.format(BMNGLayer.HTTP_BASE, year, month, tile.getL(), tile.getX(),
                        tile.getY());
                LogX.log(Level.FINER, s);
                GetMethod gm = new GetMethod(s);
                gm.setRequestHeader("User-Agent", WorldExplorer.USER_AGENT);
                try {
                    int response = client.executeMethod(gm);
                    LogX.log(Level.FINEST, NAME + " " + response + " " + s);
                    if (response == HttpStatus.SC_OK) {
                        InputStream is = gm.getResponseBodyAsStream();
                        BufferedImage bi = ImageIO.read(is);
                        is.close();
                        if (bi != null) {
                            tile.setImage(bi);
                        }
                    }
                } catch (Exception ex) {
                    LogX.log(Level.FINER, "", ex);
                } finally {
                    gm.releaseConnection();
                }
                LogX.log(Level.FINEST, NAME + " dequeueing: " + tile);
                unqueueTile(tile);
            }
            firePropertyChange(P_DATAREADY, null, tile);
            Thread.yield();
        }
        firePropertyChange(P_IDLE, false, true);
        try {
            Thread.sleep(QUEUE_SLEEP_TIME);
        } catch (Exception ex) {
        }
        ;
    }
}

From source file:com.granule.json.utils.internal.JSONSAXHandler.java

/**
 * Constructor.//from  w w w.ja  v  a2  s  .  c o m
 * @param os The outputStream to write the resulting JSON to.  Same as JSONSAXHander(os,false);
 * @throws IOException Thrown if an error occurs during streaming out, or XML read.
 */
public JSONSAXHandler(OutputStream os) throws IOException {
    if (logger.isLoggable(Level.FINER))
        logger.entering(className, "JSONHander(OutputStream) <constructor>");

    this.osWriter = new OutputStreamWriter(os, "UTF-8");
    this.compact = true;

    if (logger.isLoggable(Level.FINER))
        logger.exiting(className, "JSONHander(OutputStream) <constructor>");
}