WICKET-6334 Fix a typo in class name

Improve error message by printing the passed object


Project: http://git-wip-us.apache.org/repos/asf/wicket/repo
Commit: http://git-wip-us.apache.org/repos/asf/wicket/commit/a08c112b
Tree: http://git-wip-us.apache.org/repos/asf/wicket/tree/a08c112b
Diff: http://git-wip-us.apache.org/repos/asf/wicket/diff/a08c112b

Branch: refs/heads/master
Commit: a08c112b364ac32a4b07f4bc85cacf92a1d6b34e
Parents: e248168
Author: Martin Tzvetanov Grigorov <[email protected]>
Authored: Mon Mar 13 23:06:10 2017 +0100
Committer: Martin Tzvetanov Grigorov <[email protected]>
Committed: Mon Mar 20 21:42:32 2017 +0100

----------------------------------------------------------------------
 .../util/instrument/InstrumentationObjectSizeOfStrategy.java | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/wicket/blob/a08c112b/wicket-objectsizeof-agent/src/main/java/org/apache/wicket/util/instrument/InstrumentationObjectSizeOfStrategy.java
----------------------------------------------------------------------
diff --git 
a/wicket-objectsizeof-agent/src/main/java/org/apache/wicket/util/instrument/InstrumentationObjectSizeOfStrategy.java
 
b/wicket-objectsizeof-agent/src/main/java/org/apache/wicket/util/instrument/InstrumentationObjectSizeOfStrategy.java
index a7355fa..03ab881 100644
--- 
a/wicket-objectsizeof-agent/src/main/java/org/apache/wicket/util/instrument/InstrumentationObjectSizeOfStrategy.java
+++ 
b/wicket-objectsizeof-agent/src/main/java/org/apache/wicket/util/instrument/InstrumentationObjectSizeOfStrategy.java
@@ -40,7 +40,7 @@ public class InstrumentationObjectSizeOfStrategy implements 
IObjectSizeOfStrateg
         * Records the size of an object and it's dependents as if they were 
serialized but using the
         * instrumentation API to calculate.
         */
-       private final class SizeRecodingOuputStream extends ObjectOutputStream
+       private final class SizeRecodingOutputStream extends ObjectOutputStream
        {
 
                private long totalSize = 0;
@@ -50,7 +50,7 @@ public class InstrumentationObjectSizeOfStrategy implements 
IObjectSizeOfStrateg
                 * 
                 * @throws IOException
                 */
-               public SizeRecodingOuputStream() throws IOException
+               public SizeRecodingOutputStream() throws IOException
                {
                        super(new OutputStream()
                        {
@@ -119,13 +119,13 @@ public class InstrumentationObjectSizeOfStrategy 
implements IObjectSizeOfStrateg
                }
                try
                {
-                       SizeRecodingOuputStream recorder = new 
SizeRecodingOuputStream();
+                       SizeRecodingOutputStream recorder = new 
SizeRecodingOutputStream();
                        recorder.writeObject(obj);
                        return recorder.getTotalSize();
                }
                catch (IOException e)
                {
-                       LOG.error("Error calculating size of object", e);
+                       LOG.error("An error occurred while calculating the size 
of object: " + obj, e);
                        return -1;
                }
 

Reply via email to