You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@activemq.apache.org by "Wolfgang.Klein (JIRA)" <ji...@apache.org> on 2008/06/04 11:45:00 UTC

[jira] Created: (AMQCPP-180) Segmentation fault after removing derivation from runnable

Segmentation fault after removing derivation from runnable
----------------------------------------------------------

                 Key: AMQCPP-180
                 URL: https://issues.apache.org/activemq/browse/AMQCPP-180
             Project: ActiveMQ C++ Client
          Issue Type: Bug
          Components: Example Code
    Affects Versions: 2.1.3
         Environment: #CentOS release 5 (Final)
redhat-4
Linux orion 2.6.18-53.el5 #1 SMP Mon Nov 12 02:14:55 EST 2007 x86_64 x86_64 x86_64 GNU/Linux

            Reporter: Wolfgang.Klein
            Assignee: Nathan Mittler
            Priority: Minor


I have unstalled ActiveMQ 5.1.0 and activemq-cpp-2.1.3.
I have used simple_producer and simple_async_consumer successful.
Then i have started several times simple_producer without starting a consumer. Which (clearly) results in an exception:

[wok@orion] ~/src 679$ /opt/apache-activemq-5.1.0/bin/simple_producer
=====================================================
Starting the example:
-----------------------------------------------------
Sent message #1 from thread -1420801584
No valid response received for command: (null), check broker.
        FILE: activemq/transport/filters/ResponseCorrelator.cpp, LINE: 146
        FILE: activemq/transport/filters/ResponseCorrelator.cpp, LINE: 154
        FILE: activemq/connector/openwire/OpenWireFormatNegotiator.cpp, LINE: 105
        FILE: activemq/connector/openwire/OpenWireConnector.cpp, LINE: 1371
        FILE: activemq/connector/openwire/OpenWireConnector.cpp, LINE: 848
        FILE: activemq/core/ActiveMQSession.cpp, LINE: 675
        FILE: activemq/core/ActiveMQProducer.cpp, LINE: 194
        FILE: activemq/core/ActiveMQProducer.cpp, LINE: 149
        FILE: activemq/core/ActiveMQProducer.cpp, LINE: 108
-----------------------------------------------------
Finished with the example.
=====================================================

That's all ok. 

But then i haved change the SimpleProducer in line 43 and 110 to be closer to our integration:
   < class SimpleProducer /*: public Runnable*/ {
   string threadIdStr;   // = Integer::toString( Thread::getId() );

I repeated the test and got a Segmentation fault (wihout a core file).

=====================================================
Starting the example:
-----------------------------------------------------
Sent message #1 from thread
Segmentation fault

WHY ???????????????


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


[jira] Commented: (AMQCPP-180) Segmentation fault after removing derivation from runnable

Posted by "Wolfgang.Klein (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/activemq/browse/AMQCPP-180?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=44051#action_44051 ] 

Wolfgang.Klein commented on AMQCPP-180:
---------------------------------------

The example code is your standard example code 
  apache-activemq-5.1.0/activemq-cpp-2.1.3-src/src/examples/main.cpp
with 2 lines changed as described above. I thought it is available for you. 

But the problem disappears after changing the binding, so i accept the close. Probably the error occurs also without changes in the source code..


> Segmentation fault after removing derivation from runnable
> ----------------------------------------------------------
>
>                 Key: AMQCPP-180
>                 URL: https://issues.apache.org/activemq/browse/AMQCPP-180
>             Project: ActiveMQ C++ Client
>          Issue Type: Bug
>          Components: Example Code
>    Affects Versions: 2.1.3
>         Environment: #CentOS release 5 (Final)
> redhat-4
> Linux orion 2.6.18-53.el5 #1 SMP Mon Nov 12 02:14:55 EST 2007 x86_64 x86_64 x86_64 GNU/Linux
>            Reporter: Wolfgang.Klein
>            Assignee: Timothy Bish
>            Priority: Minor
>
> I have unstalled ActiveMQ 5.1.0 and activemq-cpp-2.1.3.
> I have used simple_producer and simple_async_consumer successful.
> Then i have started several times simple_producer without starting a consumer. Which (clearly) results in an exception:
> [wok@orion] ~/src 679$ /opt/apache-activemq-5.1.0/bin/simple_producer
> =====================================================
> Starting the example:
> -----------------------------------------------------
> Sent message #1 from thread -1420801584
> No valid response received for command: (null), check broker.
>         FILE: activemq/transport/filters/ResponseCorrelator.cpp, LINE: 146
>         FILE: activemq/transport/filters/ResponseCorrelator.cpp, LINE: 154
>         FILE: activemq/connector/openwire/OpenWireFormatNegotiator.cpp, LINE: 105
>         FILE: activemq/connector/openwire/OpenWireConnector.cpp, LINE: 1371
>         FILE: activemq/connector/openwire/OpenWireConnector.cpp, LINE: 848
>         FILE: activemq/core/ActiveMQSession.cpp, LINE: 675
>         FILE: activemq/core/ActiveMQProducer.cpp, LINE: 194
>         FILE: activemq/core/ActiveMQProducer.cpp, LINE: 149
>         FILE: activemq/core/ActiveMQProducer.cpp, LINE: 108
> -----------------------------------------------------
> Finished with the example.
> =====================================================
> That's all ok. 
> But then i haved change the SimpleProducer in line 43 and 110 to be closer to our integration:
>    < class SimpleProducer /*: public Runnable*/ {
>    string threadIdStr;   // = Integer::toString( Thread::getId() );
> I repeated the test and got a Segmentation fault (wihout a core file).
> =====================================================
> Starting the example:
> -----------------------------------------------------
> Sent message #1 from thread
> Segmentation fault
> WHY ???????????????

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


[jira] Closed: (AMQCPP-180) Segmentation fault after removing derivation from runnable

Posted by "Timothy Bish (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/activemq/browse/AMQCPP-180?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Timothy Bish closed AMQCPP-180.
-------------------------------

      Assignee: Timothy Bish  (was: Nathan Mittler)
    Resolution: Cannot Reproduce

No example code given, can't reproduce this one.

> Segmentation fault after removing derivation from runnable
> ----------------------------------------------------------
>
>                 Key: AMQCPP-180
>                 URL: https://issues.apache.org/activemq/browse/AMQCPP-180
>             Project: ActiveMQ C++ Client
>          Issue Type: Bug
>          Components: Example Code
>    Affects Versions: 2.1.3
>         Environment: #CentOS release 5 (Final)
> redhat-4
> Linux orion 2.6.18-53.el5 #1 SMP Mon Nov 12 02:14:55 EST 2007 x86_64 x86_64 x86_64 GNU/Linux
>            Reporter: Wolfgang.Klein
>            Assignee: Timothy Bish
>            Priority: Minor
>
> I have unstalled ActiveMQ 5.1.0 and activemq-cpp-2.1.3.
> I have used simple_producer and simple_async_consumer successful.
> Then i have started several times simple_producer without starting a consumer. Which (clearly) results in an exception:
> [wok@orion] ~/src 679$ /opt/apache-activemq-5.1.0/bin/simple_producer
> =====================================================
> Starting the example:
> -----------------------------------------------------
> Sent message #1 from thread -1420801584
> No valid response received for command: (null), check broker.
>         FILE: activemq/transport/filters/ResponseCorrelator.cpp, LINE: 146
>         FILE: activemq/transport/filters/ResponseCorrelator.cpp, LINE: 154
>         FILE: activemq/connector/openwire/OpenWireFormatNegotiator.cpp, LINE: 105
>         FILE: activemq/connector/openwire/OpenWireConnector.cpp, LINE: 1371
>         FILE: activemq/connector/openwire/OpenWireConnector.cpp, LINE: 848
>         FILE: activemq/core/ActiveMQSession.cpp, LINE: 675
>         FILE: activemq/core/ActiveMQProducer.cpp, LINE: 194
>         FILE: activemq/core/ActiveMQProducer.cpp, LINE: 149
>         FILE: activemq/core/ActiveMQProducer.cpp, LINE: 108
> -----------------------------------------------------
> Finished with the example.
> =====================================================
> That's all ok. 
> But then i haved change the SimpleProducer in line 43 and 110 to be closer to our integration:
>    < class SimpleProducer /*: public Runnable*/ {
>    string threadIdStr;   // = Integer::toString( Thread::getId() );
> I repeated the test and got a Segmentation fault (wihout a core file).
> =====================================================
> Starting the example:
> -----------------------------------------------------
> Sent message #1 from thread
> Segmentation fault
> WHY ???????????????

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


[jira] Commented: (AMQCPP-180) Segmentation fault after removing derivation from runnable

Posted by "Timothy Bish (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/activemq/browse/AMQCPP-180?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=43226#action_43226 ] 

Timothy Bish commented on AMQCPP-180:
-------------------------------------

You could also try and use the ActiveMQ-CPP 2.2 Release candidate which you can get from here:
http://activemq.apache.org/cms/activemq-cpp-22-release.html

You will most likely still get the error from the response correlator because we don't support producer flow control at the moment so once you fill the brokers memory with messages it will stop responding.  But it might solve the seg fault issue you are seeing.

> Segmentation fault after removing derivation from runnable
> ----------------------------------------------------------
>
>                 Key: AMQCPP-180
>                 URL: https://issues.apache.org/activemq/browse/AMQCPP-180
>             Project: ActiveMQ C++ Client
>          Issue Type: Bug
>          Components: Example Code
>    Affects Versions: 2.1.3
>         Environment: #CentOS release 5 (Final)
> redhat-4
> Linux orion 2.6.18-53.el5 #1 SMP Mon Nov 12 02:14:55 EST 2007 x86_64 x86_64 x86_64 GNU/Linux
>            Reporter: Wolfgang.Klein
>            Assignee: Nathan Mittler
>            Priority: Minor
>
> I have unstalled ActiveMQ 5.1.0 and activemq-cpp-2.1.3.
> I have used simple_producer and simple_async_consumer successful.
> Then i have started several times simple_producer without starting a consumer. Which (clearly) results in an exception:
> [wok@orion] ~/src 679$ /opt/apache-activemq-5.1.0/bin/simple_producer
> =====================================================
> Starting the example:
> -----------------------------------------------------
> Sent message #1 from thread -1420801584
> No valid response received for command: (null), check broker.
>         FILE: activemq/transport/filters/ResponseCorrelator.cpp, LINE: 146
>         FILE: activemq/transport/filters/ResponseCorrelator.cpp, LINE: 154
>         FILE: activemq/connector/openwire/OpenWireFormatNegotiator.cpp, LINE: 105
>         FILE: activemq/connector/openwire/OpenWireConnector.cpp, LINE: 1371
>         FILE: activemq/connector/openwire/OpenWireConnector.cpp, LINE: 848
>         FILE: activemq/core/ActiveMQSession.cpp, LINE: 675
>         FILE: activemq/core/ActiveMQProducer.cpp, LINE: 194
>         FILE: activemq/core/ActiveMQProducer.cpp, LINE: 149
>         FILE: activemq/core/ActiveMQProducer.cpp, LINE: 108
> -----------------------------------------------------
> Finished with the example.
> =====================================================
> That's all ok. 
> But then i haved change the SimpleProducer in line 43 and 110 to be closer to our integration:
>    < class SimpleProducer /*: public Runnable*/ {
>    string threadIdStr;   // = Integer::toString( Thread::getId() );
> I repeated the test and got a Segmentation fault (wihout a core file).
> =====================================================
> Starting the example:
> -----------------------------------------------------
> Sent message #1 from thread
> Segmentation fault
> WHY ???????????????

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


[jira] Commented: (AMQCPP-180) Segmentation fault after removing derivation from runnable

Posted by "Timothy Bish (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/activemq/browse/AMQCPP-180?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=43223#action_43223 ] 

Timothy Bish commented on AMQCPP-180:
-------------------------------------

You are welcome to attach a sample app that demonstrates the problem you are seeing and we can take a look at it.  Without seeing the code mods you've made its hard to say what the issue could be.

> Segmentation fault after removing derivation from runnable
> ----------------------------------------------------------
>
>                 Key: AMQCPP-180
>                 URL: https://issues.apache.org/activemq/browse/AMQCPP-180
>             Project: ActiveMQ C++ Client
>          Issue Type: Bug
>          Components: Example Code
>    Affects Versions: 2.1.3
>         Environment: #CentOS release 5 (Final)
> redhat-4
> Linux orion 2.6.18-53.el5 #1 SMP Mon Nov 12 02:14:55 EST 2007 x86_64 x86_64 x86_64 GNU/Linux
>            Reporter: Wolfgang.Klein
>            Assignee: Nathan Mittler
>            Priority: Minor
>
> I have unstalled ActiveMQ 5.1.0 and activemq-cpp-2.1.3.
> I have used simple_producer and simple_async_consumer successful.
> Then i have started several times simple_producer without starting a consumer. Which (clearly) results in an exception:
> [wok@orion] ~/src 679$ /opt/apache-activemq-5.1.0/bin/simple_producer
> =====================================================
> Starting the example:
> -----------------------------------------------------
> Sent message #1 from thread -1420801584
> No valid response received for command: (null), check broker.
>         FILE: activemq/transport/filters/ResponseCorrelator.cpp, LINE: 146
>         FILE: activemq/transport/filters/ResponseCorrelator.cpp, LINE: 154
>         FILE: activemq/connector/openwire/OpenWireFormatNegotiator.cpp, LINE: 105
>         FILE: activemq/connector/openwire/OpenWireConnector.cpp, LINE: 1371
>         FILE: activemq/connector/openwire/OpenWireConnector.cpp, LINE: 848
>         FILE: activemq/core/ActiveMQSession.cpp, LINE: 675
>         FILE: activemq/core/ActiveMQProducer.cpp, LINE: 194
>         FILE: activemq/core/ActiveMQProducer.cpp, LINE: 149
>         FILE: activemq/core/ActiveMQProducer.cpp, LINE: 108
> -----------------------------------------------------
> Finished with the example.
> =====================================================
> That's all ok. 
> But then i haved change the SimpleProducer in line 43 and 110 to be closer to our integration:
>    < class SimpleProducer /*: public Runnable*/ {
>    string threadIdStr;   // = Integer::toString( Thread::getId() );
> I repeated the test and got a Segmentation fault (wihout a core file).
> =====================================================
> Starting the example:
> -----------------------------------------------------
> Sent message #1 from thread
> Segmentation fault
> WHY ???????????????

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


[jira] Commented: (AMQCPP-180) Segmentation fault after removing derivation from runnable

Posted by "Wolfgang.Klein (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/activemq/browse/AMQCPP-180?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=43218#action_43218 ] 

Wolfgang.Klein commented on AMQCPP-180:
---------------------------------------

i haved changed the example program again, removing the older changes (derivation from runnable) and introduced other minor changes. The program cores again.

Then i have changed the link step using -Wl,--rpath -Wl,/opt/gcc-4.0.2/lib64 as in the make of ActiveMQ. Now i get the same Exception Print as in the delivered test program.

The difference is:
/opt/gcc-4.0.2/lib64/libstdc++.so.6.0.6
/usr/lib64/libstdc++.so.6.0.8

What should i do?

> Segmentation fault after removing derivation from runnable
> ----------------------------------------------------------
>
>                 Key: AMQCPP-180
>                 URL: https://issues.apache.org/activemq/browse/AMQCPP-180
>             Project: ActiveMQ C++ Client
>          Issue Type: Bug
>          Components: Example Code
>    Affects Versions: 2.1.3
>         Environment: #CentOS release 5 (Final)
> redhat-4
> Linux orion 2.6.18-53.el5 #1 SMP Mon Nov 12 02:14:55 EST 2007 x86_64 x86_64 x86_64 GNU/Linux
>            Reporter: Wolfgang.Klein
>            Assignee: Nathan Mittler
>            Priority: Minor
>
> I have unstalled ActiveMQ 5.1.0 and activemq-cpp-2.1.3.
> I have used simple_producer and simple_async_consumer successful.
> Then i have started several times simple_producer without starting a consumer. Which (clearly) results in an exception:
> [wok@orion] ~/src 679$ /opt/apache-activemq-5.1.0/bin/simple_producer
> =====================================================
> Starting the example:
> -----------------------------------------------------
> Sent message #1 from thread -1420801584
> No valid response received for command: (null), check broker.
>         FILE: activemq/transport/filters/ResponseCorrelator.cpp, LINE: 146
>         FILE: activemq/transport/filters/ResponseCorrelator.cpp, LINE: 154
>         FILE: activemq/connector/openwire/OpenWireFormatNegotiator.cpp, LINE: 105
>         FILE: activemq/connector/openwire/OpenWireConnector.cpp, LINE: 1371
>         FILE: activemq/connector/openwire/OpenWireConnector.cpp, LINE: 848
>         FILE: activemq/core/ActiveMQSession.cpp, LINE: 675
>         FILE: activemq/core/ActiveMQProducer.cpp, LINE: 194
>         FILE: activemq/core/ActiveMQProducer.cpp, LINE: 149
>         FILE: activemq/core/ActiveMQProducer.cpp, LINE: 108
> -----------------------------------------------------
> Finished with the example.
> =====================================================
> That's all ok. 
> But then i haved change the SimpleProducer in line 43 and 110 to be closer to our integration:
>    < class SimpleProducer /*: public Runnable*/ {
>    string threadIdStr;   // = Integer::toString( Thread::getId() );
> I repeated the test and got a Segmentation fault (wihout a core file).
> =====================================================
> Starting the example:
> -----------------------------------------------------
> Sent message #1 from thread
> Segmentation fault
> WHY ???????????????

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