activemq-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Gary Tully (JIRA)" <j...@apache.org>
Subject [jira] Commented: (AMQ-1978) ActiveMQTextMessage toString() method to call getText()
Date Wed, 15 Oct 2008 09:39:52 GMT

    [ https://issues.apache.org/activemq/browse/AMQ-1978?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=46468#action_46468
] 

Gary Tully commented on AMQ-1978:
---------------------------------

A hard limit of 60 could be good, better may be something of the form "abc....xyz" so the
beginning and the end of the text are visible.

need for a limit seems to be reflected in the tests, I see a bunch TextMessage related failures
like :

-------------------------------------------------------------------------------
Test set: org.apache.activemq.openwire.v1.ActiveMQTextMessageTest
-------------------------------------------------------------------------------
Tests run: 1, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 0.046 sec <<< FAILURE!
testGenerateAndReParsingIsTheSame(org.apache.activemq.openwire.v1.ActiveMQTextMessageTest)
 Time elapsed: 0.02 sec  <<< ERROR!
java.lang.OutOfMemoryError: Requested array size exceeds VM limit
        at java.lang.AbstractStringBuilder.<init>(AbstractStringBuilder.java:44)
        at java.lang.StringBuffer.<init>(StringBuffer.java:92)
        at org.apache.activemq.util.MarshallingSupport.readUTF8(MarshallingSupport.java:320)
        at org.apache.activemq.command.ActiveMQTextMessage.getText(ActiveMQTextMessage.java:85)
        at org.apache.activemq.command.ActiveMQTextMessage.toString(ActiveMQTextMessage.java:152)
        at java.lang.String.valueOf(String.java:2615)
        at java.lang.StringBuilder.append(StringBuilder.java:116)
        at org.apache.activemq.openwire.DataFileGeneratorTestSupport.testGenerateAndReParsingIsTheSame(DataFileGeneratorTestSupport.java:97)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:585)
        at junit.framework.TestCase.runTest(TestCase.java:154)
        at junit.framework.TestCase.runBare(TestCase.java:127)
        at junit.framework.TestResult$1.protect(TestResult.java:106)
        at junit.framework.TestResult.runProtected(TestResult.java:124)
        at junit.framework.TestResult.run(TestResult.java:109)
        at junit.framework.TestCase.run(TestCase.java:118)
        at junit.framework.TestSuite.runTest(TestSuite.java:208)
        at junit.framework.TestSuite.run(TestSuite.java:203)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:585)
        at org.apache.maven.surefire.junit.JUnitTestSet.execute(JUnitTestSet.java:210)
        at org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.executeTestSet(AbstractDirectoryTestSuite.java:135)
        at org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.execute(AbstractDirectoryTestSuite.java:160)
        at org.apache.maven.surefire.Surefire.run(Surefire.java:81)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:585)


> ActiveMQTextMessage toString() method to call getText()
> -------------------------------------------------------
>
>                 Key: AMQ-1978
>                 URL: https://issues.apache.org/activemq/browse/AMQ-1978
>             Project: ActiveMQ
>          Issue Type: Improvement
>          Components: Broker
>    Affects Versions: 5.2.0
>            Reporter: Dejan Bosanac
>            Assignee: Dejan Bosanac
>            Priority: Minor
>             Fix For: 5.3.0
>
>
> Currently toString on newly consumed message shows text field has the null value, because
getText is never called.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message