List of usage examples for java.util.logging Level INFO
Level INFO
To view the source code for java.util.logging Level INFO.
Click Source Link
From source file:org.openspaces.focalserver.FocalServer.java
public void shutdown() { Logger logger = Logger.getLogger(FocalServer.class.getName()); logger.log(Level.INFO, "FocalServer Shutdown."); System.exit(0);/*from w ww . j a va2 s.co m*/ }
From source file:com.mycompany.web.filter.RequestUtil.java
private void prepareRequestParamMap() { String postData = getPostData(); if (postData != null && !"".equals(postData)) { requestParamMap = new HashMap<String, String>(); String[] params = postData.split("&"); for (String param : params) { String[] nameValuePair = param.split("="); if (nameValuePair[0] != null && nameValuePair[1] != null) { requestParamMap.put(nameValuePair[0], nameValuePair[1]); }// w w w . j a va 2 s . co m } } Logger.getLogger(RequestUtil.class.getName()).log(Level.INFO, requestParamMap.toString()); }
From source file:com.microsoft.azure.AzureVMCloudVerificationTask.java
@Override public void execute(final TaskListener arg0) throws IOException, InterruptedException { LOGGER.log(Level.INFO, "AzureVMCloudVerificationTask: execute: start"); if (cloudNames != null && !cloudNames.isEmpty()) { // Walk the list of clouds and verify the configuration. If an element // is not found (perhaps a removed cloud, removes from the list) synchronized (cloudNamesLock) { List<String> toRemove = new ArrayList<String>(); for (String cloudName : cloudNames) { LOGGER.log(Level.INFO, "AzureVMCloudVerificationTask: execute: verifying cloud {0}", cloudName); AzureVMCloud cloud = getCloud(cloudName); // Unknown cloud. Maybe the name changed since the cloud name // was registered. Remove from the list if (cloud == null) { LOGGER.log(Level.INFO, "AzureVMCloudVerificationTask: execute: subscription {0} not found, skipping", cloudName);/*from w ww . ja va 2s . c o m*/ // Remove toRemove.add(cloudName); continue; } // If already verified, skip if (cloud.isConfigurationValid()) { LOGGER.log(Level.INFO, "AzureVMCloudVerificationTask: execute: subscription {0} already verifed", cloudName); // Update the count. cloud.setVirtualMachineCount(getVirtualMachineCount(cloud)); continue; } // Verify. Update the VM count before setting to valid if (verifyConfiguration(cloud)) { LOGGER.log(Level.INFO, "AzureVMCloudVerificationTask: execute: {0} verified", cloudName); // Update the count cloud.setVirtualMachineCount(getVirtualMachineCount(cloud)); // We grab the current VM count and cloud.setConfigurationValid(true); continue; } // Not valid! Remains in list. LOGGER.log(Level.INFO, "AzureVMCloudVerificationTask: execute: {0} not verified, has errors", cloudName); } // Remove items as necessary for (String cloudName : toRemove) { cloudNames.remove(cloudName); } } } if (cloudTemplates != null && !cloudTemplates.isEmpty()) { // Now walk the templates and verify. // Unlike the clouds, verified templates are removed from the list upon // verification (or left if they do not verify) synchronized (templatesLock) { List<String> toRemove = new ArrayList<String>(); LOGGER.log(Level.INFO, "AzureVMCloudVerificationTask: execute: verifying {0} template(s)", cloudTemplates.size()); for (Map.Entry<String, String> entry : cloudTemplates.entrySet()) { String templateName = entry.getKey(); String cloudName = entry.getValue(); LOGGER.log(Level.INFO, "AzureVMCloudVerificationTask: execute: verifying {0} in {1}", new Object[] { templateName, cloudName }); AzureVMCloud cloud = getCloud(cloudName); // If the cloud is null, could mean that the cloud details changed // between the last time we ran this task if (cloud == null) { LOGGER.log(Level.INFO, "AzureVMCloudVerificationTask: execute: parent cloud not found for {0} in {1}", new Object[] { templateName, cloudName }); toRemove.add(templateName); continue; } AzureVMAgentTemplate agentTemplate = cloud.getAzureAgentTemplate(templateName); // Template could have been removed since the last time we ran verification if (agentTemplate == null) { LOGGER.log(Level.INFO, "AzureVMCloudVerificationTask: execute: could not retrieve agent template named {0} in {1}", new Object[] { templateName, cloudName }); toRemove.add(templateName); continue; } // Determine whether we need to verify the template if (agentTemplate.isTemplateVerified()) { LOGGER.log(Level.INFO, "AzureVMCloudVerificationTask: execute: template {0} in {1} already verified", new Object[] { templateName, cloudName }); // Good to go, nothing more to check here. Add to removal list. toRemove.add(templateName); continue; } // The template is not yet verified. Do so now try { List<String> errors = agentTemplate.verifyTemplate(); if (errors.isEmpty()) { LOGGER.log(Level.INFO, "AzureVMCloudVerificationTask: execute: {0} verified succesfully", templateName); // Verified, set the template to verified. agentTemplate.setTemplateVerified(true); // Reset the status details agentTemplate.setTemplateStatusDetails(""); } else { String details = StringUtils.join(errors, "\n"); LOGGER.log(Level.INFO, "AzureVMCloudVerificationTask: execute: {0} could not be verified:\n{1}", new Object[] { templateName, details }); // Set the status details to the set of messages agentTemplate.setTemplateStatusDetails(details); } } catch (Exception e) { // Log, but ignore overall LOGGER.log(Level.INFO, "AzureVMCloudVerificationTask: execute: got exception while verifying {0}:\n{1}", new Object[] { templateName, e.toString() }); } } // Remove items as necessary for (String templateName : toRemove) { cloudTemplates.remove(templateName); } } } LOGGER.info("AzureVMCloudVerificationTask: execute: end"); }
From source file:com.neophob.sematrix.core.osc.PixelControllerOscServer.java
@Override public void handleOscMessage(OscMessage oscIn) { //sanity check if (StringUtils.isBlank(oscIn.getPattern())) { LOG.log(Level.INFO, "Ignore empty OSC message..."); return;// w w w . j a v a2 s . c om } String pattern = oscIn.getPattern(); ValidCommands command; try { command = ValidCommands.valueOf(pattern); } catch (Exception e) { LOG.log(Level.WARNING, "Unknown message: " + pattern, e); return; } String[] msg = new String[1 + command.getNrOfParams()]; msg[0] = pattern; if (oscIn.getBlob() == null && command.getNrOfParams() > 0 && command.getNrOfParams() != oscIn.getArgs().length) { String args = oscIn.getArgs() == null ? "null" : "" + oscIn.getArgs().length; LOG.log(Level.WARNING, "Parameter cound missmatch, expected: {0} available: {1} ", new String[] { "" + command.getNrOfParams(), "" + args }); return; } //ignore nr of parameter for osc generator if (command != ValidCommands.OSC_GENERATOR1 && command != ValidCommands.OSC_GENERATOR2) { for (int i = 0; i < command.getNrOfParams(); i++) { msg[1 + i] = oscIn.getArgs()[i]; } } LOG.log(Level.INFO, "Recieved OSC message: {0}", msg); MessageProcessor.processMsg(msg, true, oscIn.getBlob()); //notfiy gui if an osc message arrives Collector.getInstance().notifyGuiUpdate(); }
From source file:org.newinstance.tnt.service.TaskServiceImpl.java
@Override public void saveTask(final Task task, final String ownerName) { final Owner existingOwner = ownerRepository.findByName(ownerName); // create new owner if name does not exist in database yet if (existingOwner == null) { LOG.log(Level.INFO, "Creating new owner with name: " + ownerName); final Owner owner = new Owner(); owner.setName(ownerName);//from ww w .jav a2s .c o m // persist new owner ownerRepository.save(owner); task.setOwner(owner); } else { task.setOwner(existingOwner); } taskRepository.save(task); }
From source file:jp.pigumer.web.StompConfig.java
@Override public void configureClientInboundChannel(ChannelRegistration registration) { registration.setInterceptors(new ChannelInterceptorAdapter() { @Override// w w w . ja v a 2s . c om public Message<?> preSend(Message<?> message, MessageChannel channel) { StompHeaderAccessor accessor = StompHeaderAccessor.wrap(message); if (accessor.getCommand() == StompCommand.SUBSCRIBE) { LOGGER.log(Level.INFO, String.format("%s: %s", channel, message)); } return message; } }); }
From source file:cfa.vo.iris.ComponentLoader.java
public final void loadComponent(Class<? extends IrisComponent> componentClass) { try {// www. j a v a 2s. co m Logger.getLogger(ComponentLoader.class.getName()).log(Level.INFO, "Loading class: " + componentClass.getName()); IrisComponent component = componentClass.newInstance(); components.add(component); } catch (Exception ex) { String message = "Could not construct component " + componentClass.getName(); System.err.println(message); Logger.getLogger(ComponentLoader.class.getName()).log(Level.SEVERE, message, ex); failures.add(componentClass.getName()); } }
From source file:org.blockfreie.element.hydrogen.murikate.ApplicationUtil.java
/** * Returns application wide property./* w w w . j a v a2s . co m*/ * * @param key * the name of property to retrieve * @return the value of property */ public static String getProperty(String key) { String result = null; String classname = new Throwable().getStackTrace()[1].getClassName(); String saltedkey = String.format("%s.%s", classname, key); result = PROPERTY.getProperty(saltedkey); result = (result == null) ? PROPERTY.getProperty(key) : result; LOGGER.log(Level.INFO, String.format("%s:%s", saltedkey, result)); return result; }
From source file:com.excilys.ebi.gatling.jenkins.chart.Graph.java
public String getSeriesJSON() { String json = null;/* w w w.j a v a 2s. com*/ try { json = mapper.writeValueAsString(series.values()); } catch (IOException e) { LOGGER.log(Level.INFO, e.getMessage(), e); } return json; }
From source file:org.ow2.play.metadata.service.MetadataServiceImpl.java
@Override @WebMethod/*from w ww. j a va 2 s.c om*/ public void addMetadata(Resource resource, Metadata metadata) throws MetadataException { if (logger.isLoggable(Level.INFO)) logger.info(String.format("Adding metdata %s to resource %s", metadata, resource)); if (resource == null || resource.getName() == null || resource.getUrl() == null) { throw new MetadataException("Null resource"); } if (metadata == null || metadata.getData() == null || metadata.getName() == null) { throw new MetadataException("Null metadata"); } Update update = new Update(); update.addToSet("metadata", metadata); mongoTemplate.updateFirst( query(where("resource.name").is(resource.getName()).and("resource.url").is(resource.getUrl())), update, org.ow2.play.metadata.service.document.MetaResource.class); }