diff options
author | gjoranv <gv@verizonmedia.com> | 2020-04-24 15:47:56 +0200 |
---|---|---|
committer | gjoranv <gv@verizonmedia.com> | 2020-04-25 02:24:37 +0200 |
commit | 545c7069fbf76932542f80a25aab44fdc972925a (patch) | |
tree | dd6aac41e9568cc68ba1f46c0c38609f0f7604bb /documentapi | |
parent | ee9e892838733da49d5ea2b74e456751c05c3f18 (diff) |
LogLevel.ERROR -> Level.SEVERE
Diffstat (limited to 'documentapi')
5 files changed, 17 insertions, 17 deletions
diff --git a/documentapi/src/main/java/com/yahoo/documentapi/messagebus/MessageBusVisitorSession.java b/documentapi/src/main/java/com/yahoo/documentapi/messagebus/MessageBusVisitorSession.java index b40da64df30..429c9bc0f51 100755 --- a/documentapi/src/main/java/com/yahoo/documentapi/messagebus/MessageBusVisitorSession.java +++ b/documentapi/src/main/java/com/yahoo/documentapi/messagebus/MessageBusVisitorSession.java @@ -726,7 +726,7 @@ public class MessageBusVisitorSession implements VisitorSession { } else { String msg = "Received reply we do not know how to handle: " + reply.getClass().getName(); - log.log(LogLevel.ERROR, msg); + log.log(Level.SEVERE, msg); transitionTo(new StateDescription(State.FAILED, msg)); } } catch (Exception e) { @@ -772,7 +772,7 @@ public class MessageBusVisitorSession implements VisitorSession { private void handleMessageProcessingException(Reply reply, Exception e, String what) { final String errorDesc = formatProcessingException(e, what); final String fullMsg = formatIdentifyingVisitorErrorString(errorDesc); - log.log(LogLevel.ERROR, fullMsg, e); + log.log(Level.SEVERE, fullMsg, e); int errorCode; synchronized (progress.getToken()) { if (!params.skipBucketsOnFatalErrors()) { @@ -841,7 +841,7 @@ public class MessageBusVisitorSession implements VisitorSession { msg.swapState(reply); if (params.getLocalDataHandler() == null) { - log.log(LogLevel.ERROR, sessionName + ": Got visitor data back to client with no local data destination."); + log.log(Level.SEVERE, sessionName + ": Got visitor data back to client with no local data destination."); reply.addError(new Error(ErrorCode.APP_FATAL_ERROR, "Visitor data with no local data destination")); receiver.reply(reply); return; @@ -1066,7 +1066,7 @@ public class MessageBusVisitorSession implements VisitorSession { progress.getIterator().setDistributionBitCount(stateBits); } } catch (Exception e) { - log.log(LogLevel.ERROR, "Failed to parse new system state string: " + log.log(Level.SEVERE, "Failed to parse new system state string: " + reply.getSystemState()); transitionTo(new StateDescription(State.FAILED, "Failed to parse cluster state '" + reply.getSystemState() + "'")); @@ -1170,7 +1170,7 @@ public class MessageBusVisitorSession implements VisitorSession { sender.destroy(); receiver.destroy(); } catch (Exception e) { - log.log(LogLevel.ERROR, "Caught exception destroying communication interfaces", e); + log.log(Level.SEVERE, "Caught exception destroying communication interfaces", e); } log.log(Level.FINE, sessionName + ": synchronous destroy() done"); } diff --git a/documentapi/src/main/java/com/yahoo/documentapi/messagebus/protocol/RoutableRepository.java b/documentapi/src/main/java/com/yahoo/documentapi/messagebus/protocol/RoutableRepository.java index c91db403cbd..7fc1ad8fc84 100755 --- a/documentapi/src/main/java/com/yahoo/documentapi/messagebus/protocol/RoutableRepository.java +++ b/documentapi/src/main/java/com/yahoo/documentapi/messagebus/protocol/RoutableRepository.java @@ -51,11 +51,11 @@ final class RoutableRepository { */ Routable decode(DocumentTypeManager docMan, Version version, byte[] data) { if (data == null || data.length == 0) { - log.log(LogLevel.ERROR, "Received empty byte array for deserialization."); + log.log(Level.SEVERE, "Received empty byte array for deserialization."); return null; } if (version.getMajor() < 5) { - log.log(LogLevel.ERROR,"Can not decode anything from (version " + version + "). Only major version 5 and up supported."); + log.log(Level.SEVERE,"Can not decode anything from (version " + version + "). Only major version 5 and up supported."); return null; } DocumentDeserializer in = DocumentDeserializerFactory.createHead(docMan, GrowableByteBuffer.wrap(data)); @@ -64,12 +64,12 @@ final class RoutableRepository { int type = in.getInt(null); RoutableFactory factory = getFactory(version, type); if (factory == null) { - log.log(LogLevel.ERROR,"No routable factory found for routable type " + type + " (version " + version + ")."); + log.log(Level.SEVERE,"No routable factory found for routable type " + type + " (version " + version + ")."); return null; } Routable ret = factory.decode(in, loadTypes); if (ret == null) { - log.log(LogLevel.ERROR,"Routable factory " + factory.getClass().getName() + " failed to deserialize " + + log.log(Level.SEVERE,"Routable factory " + factory.getClass().getName() + " failed to deserialize " + "routable of type " + type + " (version " + version + ").\nData = " + Arrays.toString(data)); return null; } @@ -90,18 +90,18 @@ final class RoutableRepository { int type = obj.getType(); RoutableFactory factory = getFactory(version, type); if (factory == null) { - log.log(LogLevel.ERROR,"No routable factory found for routable type " + type + " (version " + version + ")."); + log.log(Level.SEVERE,"No routable factory found for routable type " + type + " (version " + version + ")."); return new byte[0]; } if (version.getMajor() < 5) { - log.log(LogLevel.ERROR,"Can not encode routable type " + type + " (version " + version + "). Only major version 5 and up supported."); + log.log(Level.SEVERE,"Can not encode routable type " + type + " (version " + version + "). Only major version 5 and up supported."); return new byte[0]; } DocumentSerializer out= DocumentSerializerFactory.createHead(new GrowableByteBuffer(8192)); out.putInt(null, type); if (!factory.encode(obj, out)) { - log.log(LogLevel.ERROR, "Routable factory " + factory.getClass().getName() + " failed to serialize " + + log.log(Level.SEVERE, "Routable factory " + factory.getClass().getName() + " failed to serialize " + "routable of type " + type + " (version " + version + ")."); return new byte[0]; } diff --git a/documentapi/src/main/java/com/yahoo/documentapi/messagebus/protocol/RoutingPolicyRepository.java b/documentapi/src/main/java/com/yahoo/documentapi/messagebus/protocol/RoutingPolicyRepository.java index 0b9498d798a..c9e3488ecb9 100755 --- a/documentapi/src/main/java/com/yahoo/documentapi/messagebus/protocol/RoutingPolicyRepository.java +++ b/documentapi/src/main/java/com/yahoo/documentapi/messagebus/protocol/RoutingPolicyRepository.java @@ -49,13 +49,13 @@ class RoutingPolicyRepository { RoutingPolicy createPolicy(String name, String param) { RoutingPolicyFactory factory = getFactory(name); if (factory == null) { - log.log(LogLevel.ERROR, "No routing policy factory found for name '" + name + "'."); + log.log(Level.SEVERE, "No routing policy factory found for name '" + name + "'."); return null; } DocumentProtocolRoutingPolicy ret = factory.createPolicy(param); if (ret == null) { - log.log(LogLevel.ERROR, "Routing policy factory " + factory.getClass().getName() + " failed to create a " + + log.log(Level.SEVERE, "Routing policy factory " + factory.getClass().getName() + " failed to create a " + "routing policy for parameter '" + name + "'."); return null; } diff --git a/documentapi/src/main/java/com/yahoo/documentapi/messagebus/protocol/StoragePolicy.java b/documentapi/src/main/java/com/yahoo/documentapi/messagebus/protocol/StoragePolicy.java index 12dea1759c4..5594b9f9db4 100644 --- a/documentapi/src/main/java/com/yahoo/documentapi/messagebus/protocol/StoragePolicy.java +++ b/documentapi/src/main/java/com/yahoo/documentapi/messagebus/protocol/StoragePolicy.java @@ -282,7 +282,7 @@ public class StoragePolicy extends SlobrokPolicy { case DocumentProtocol.MESSAGE_CREATEVISITOR: return ((CreateVisitorMessage)msg).getBuckets().get(0); case DocumentProtocol.MESSAGE_REMOVELOCATION: return ((RemoveLocationMessage)msg).getBucketId(); default: - log.log(LogLevel.ERROR, "Message type '" + msg.getType() + "' not supported."); + log.log(Level.SEVERE, "Message type '" + msg.getType() + "' not supported."); return null; } } @@ -471,7 +471,7 @@ public class StoragePolicy extends SlobrokPolicy { if (context.usedState == null) { String msg = "Used state must be set as distributor is calculated. Bug."; reply.getTrace().trace(1, msg); - log.log(LogLevel.ERROR, msg); + log.log(Level.SEVERE, msg); } else if (newState.getVersion() == context.usedState.getVersion()) { String msg = "Message sent to distributor " + context.calculatedDistributor + " retrieved cluster state version " + newState.getVersion() + diff --git a/documentapi/src/main/java/com/yahoo/documentapi/messagebus/systemstate/rule/NodeState.java b/documentapi/src/main/java/com/yahoo/documentapi/messagebus/systemstate/rule/NodeState.java index 527c94a4d2a..d23a0e580a0 100755 --- a/documentapi/src/main/java/com/yahoo/documentapi/messagebus/systemstate/rule/NodeState.java +++ b/documentapi/src/main/java/com/yahoo/documentapi/messagebus/systemstate/rule/NodeState.java @@ -91,7 +91,7 @@ public class NodeState { } if (arr[0].equals(NODE_PARENT)) { if (parent == null) { - log.log(LogLevel.ERROR, "Location string '" + key + "' requests a parent above the top-most node, " + + log.log(Level.SEVERE, "Location string '" + key + "' requests a parent above the top-most node, " + "returning self to avoid crash."); } return parent.getChild(arr[1], force); |