Re: ActiveMQ-CPP 3.4.2 memory leaks?

2012-05-18 Thread Ivan Pechorin
2012/5/14 > > I'm wondering whether or not you've been able to find out anything using > BoundsChecker or when you might have time to test it? I have access to > another tool which is not as good as what you have; it will probably take > me a couple of days before I have something I'm comfortabl

Re: ActiveMQ-CPP 3.4.2 memory leaks?

2012-05-13 Thread Ivan Pechorin
2012/5/13 richardm > > My tools are not that good, though I'll spend some time later today or > tomorrow to better understanding what I'm seeing. All I know is that the > most basic dump of leaked memory indicates quite a few problems in the > Visual Studio environment. I'm guessing this to be

Re: one queue per request

2012-04-22 Thread Ivan Pechorin
2012/4/22 Mohit Anchlia > Thanks, but then I would like to know how do people design such a system > where request comes in goes on the queue and waits on the outgoing queue. > If responses from different requests go to only one queue then this model > wouldn't work unless there is some other com

Re: Set JMSType using activeMQCPP

2012-04-04 Thread Ivan Pechorin
On 04.04.2012, at 21:02, JRR wrote: > Hello, > > I think I know how to do this but I want to confirm with the crowd. > > We're using AMQ as the MOM between my group, which use ActiveMQ-CPP, and > another group which I believe is using camel. They've requested that the > header's "type" field

Re: ActiveMQ CPP: Getting text from a Text Message without making temporary

2012-02-13 Thread Ivan Pechorin
2012/2/13 stephenju > Is there a way to access the text bytes without creating a temporary > std::string? I am dealing with some large text messages and try not to > allocate memory when making copies. For example, when I get the message: > > std::string reply = myMessage->getText(); > > getText(

Re: Producer Hung up after some time.

2012-01-14 Thread Ivan Pechorin
2012/1/14 Ganuke Perera : > I am using a topic name MarketData. I have set the time to live to 5 > minutes in the producer. Also I am using the default configuration for > ActiveMQ. I am adding messages with the rate of 200 messages per second. > And there is one subscriber to the topic and at the

Re: emulate synchronous response, need suggestion

2012-01-08 Thread Ivan Pechorin
2012/1/8 beep02 : > How can I release the request thread and in the same time keep user in wait > without response? > Is there some way to achieve that? Yes, either use Servlet 3.0 container such as Tomcat 7 (just google for AsyncContext [1] and ServletRequest.startAsync [2]). Or (for older versio

Re: _ITERATOR_DEBUG_LEVEL error when linking with libactivemq-cpp.lib

2011-12-29 Thread Ivan Pechorin
2011/12/29 Bill Moo : > I have build myself a libactivemq-cpp.lib file (525MB) from source using > Visual Studio 2010 (x64) and the Release-SSL configuration and I now want > to make use of it in my test program. I am trying to build a test > application using Qt with the MSVC 10.0 (amd64) toolchai

Re: Problem using ActiveMQ-CPP interfaces where std::string are used as parameters

2011-12-14 Thread Ivan Pechorin
2011/12/14 mikmela : > I'm having a lot of issues passing std::strings into ActiveMQ-CPP interfaces, > i.e. Connection, Session, Message and etc. > Even though I'm using MS VS2010 to build both activemq-cpp dll and my > application with the same version of multithreaded c-runtime dll > MSVCP100.dll

Re: How can a producer/consumer tell if its connection is still good?

2011-12-10 Thread Ivan Pechorin
2011/12/10 JRR : > I am using the Active MQ CPP 3.4.0 client. > > We have a multi-threaded application that has multiple producers, and they > share a single connection. These connections are */not/* fail over > connections, nor can they be. > > I'm trying to find the fastest, most efficient way to

Re: Is shutdownLibrary() really needed?

2011-12-06 Thread Ivan Pechorin
2011/12/6 JRR : > My question is more along the lines of what would happen if shutdownLibray() > was **not** invoked when a process exits? I believe, this is really important only when you want to use something like valgrind.

Re: ActiveMQ CMS core dump

2011-12-01 Thread Ivan Pechorin
2011/12/2 Timothy Bish : > If you are using a mac then you need to get the 3.4. SNAPSHOT code from the > link on the v3.4.1 download page. The same issue (https://issues.apache.org/jira/browse/AMQCPP-369) is applicable to Solaris too. So, it's not Mac-specific at all, and I suggest to try 3.4.1 on

Re: ActiveMQ CMS core dump

2011-12-01 Thread Ivan Pechorin
2011/12/2 stretch_kiwi : > [michael@blackbox test]$ ./activemq-test > Segmentation fault (core dumped) > I would appreciate any practical suggestions. Stack backtrace should be the first thing to look at: $ gdb activemq-test core > where

Re: ActiveMQ CPP : Same message being consumed by two consumers

2011-11-22 Thread Ivan Pechorin
2011/11/22 manua : > Each consumer is running in a different thread, though listening on the same > queue. > We dont see any concurrent access. Consumers always belong to some session; session is thread-specific (this is a generic principle of JMS, and as far as I know it's valid both for ActiveM

Re: ActiveMQ CPP : Same message being consumed by two consumers

2011-11-22 Thread Ivan Pechorin
2011/11/22 manua : > > We have used activemq cpp and created a session. The session is set in the > auto acknowledge mode. > Multiple threads have been launched from that code and each thread has a > consumer.All consumers are listening on the same queue, and sharing the same > session. Do you pro

Re: ActiveMQ CPP question -- crashing in destructor

2011-09-22 Thread Ivan Pechorin
> Just to make sure I am getting things right I do the following in the > cleanup: > >  delete destination; >  consumer.stop(); >  session.stop(); >  consumer.close(); >  delete consumer; >  delete session; > > Is this the correct order? Yes, it looks correct.

Re: ActiveMQ CPP question -- crashing in destructor

2011-09-21 Thread Ivan Pechorin
>>> The reason is that the ActiveMQConsumer object is crashing during its >>> destruction. >>> >>Stack traces and sample code that reproduces the issue are needed before >>any help here, this could result from a number of different scenarios. > > I am in the process of creating a standalone example

Re: Stack-like queue

2011-08-19 Thread Ivan Pechorin
It seems like you hit prefetch limit (the default prefetch size is 1000). Try setting prefetch size to something larger for the particular connection or consumer used by your 'queue sorter'. On 8/19/11, Matías García Isaía wrote: > Hi all... > > Another one here trying to implement kind-of-a-stac

Re: using activemq-cpp-library

2011-07-07 Thread Ivan Pechorin
2011/7/7 mahens : > i want to build activemq-cpp-library-3.4.0, using microsoft visual studio > 2010 i am trying to build activemq-cpp-library-3.4.0. > > Actually i want to test connection to activemq broker using c++ program. > Please suggest. What's you question?

occasional NullPointerExceptions in ActiveMQTextMessage.getSize()

2011-06-16 Thread Ivan Pechorin
Hello, Sometime we get NullPointerException when sending a text message. We use method send(destination, message) of interface javax.jms.MessageProducer. java.lang.NullPointerException at org.apache.activemq.command.ActiveMQTextMessage.getSize(ActiveMQTextMessage.java:148) at org.apache.activemq

Re: help needed: heap corruption when activemq-cpp routines called

2011-06-09 Thread Ivan Pechorin
2011/6/9 Ken Moore : >> >> Yes, that was definiately part of the problem. Also I had not used the >> correct macros for checked iterators in the STL, to be consistent with the >> rest of our build. It is all working now. Many thanks for your help >> > Can you tell me what macros you corrected to so

Re: Unicode support in C++ clients

2011-05-04 Thread Ivan Pechorin
2011/5/4 Suneel Papineni : > > I am getting problems in sending or receiving Unicode messages. Could > someone please tell me how can I implement this correctly. We use UTF-8 successfully in ActiveMQ's TextMessage since activemq-cpp-3.0.x. In particular, we UTF-8 between C++ and Java clients.

Re: ACTIVEMQ-CPP Error compiling with windows.h header included in the project

2011-01-25 Thread Ivan Pechorin
2011/1/25 Oscar Pernas : > Im using ActiveMQ-CPP in a dll using windows XP. When I was trying to > compile my library (that uses activemq-cpp), I was always having  error > C2059: syntax error : 'constant' in thread.h class of decaf/lang. > I was looking for a solution and I saw that the constant w

Re: Does resource adapter support session pooling in jboss

2010-10-17 Thread Ivan Pechorin
2010/10/14 Ed : > All the tests show that pool size > defined under affects connections pooling only. > > Is sessions pooling really done so strange way? > Sessions are pooled but no way to manage/configure that pooling from > outside? My understanding is that the resource adapter implements one

Re: ACTIVEMQ-CPP Compiling in Visual C 6

2010-10-15 Thread Ivan Pechorin
2010/10/15 Oscar Pernas : > Thanks ivan, but are you totally sure? I cant find any reference in the > webpage or in the readme files about it. Well, I'm quite sure, because when I tried to use ActiveMQ-C++ for the first time in June or July 2009, we used VC7.1 (2003) exclusively. I proposed small

Re: ACTIVEMQ-CPP Compiling in Visual C 6

2010-10-15 Thread Ivan Pechorin
2010/10/15 Oscar Pernas : > Only to know, has anyone compiled activemq-cpp in visual c 6? is supported? As far as I remember, even much newer Visual C++ 2003 (VC7.1) isn't supported. Hence VC6 is not supported too.

Re: ACTIVEMQ-CPP Error compiling activemq-cpp release SSL

2010-09-29 Thread Ivan Pechorin
2010/9/28 Oscar Pernas : > > ..\src\main\decaf\lang\System.cpp(389) : error C2664: 'strlen' : cannot > convert parameter  1 from 'LPTSTR' a 'const char *' > ..\src\main\decaf\lang\System.cpp(395) : error C2664: > 'std::vector<_Ty>::push_back' : cannot convert parameter  1 1 de 'LPTSTR' a > 'const s

Re: Installing Activemq-cpp (3.2.2) on Mac OS X

2010-09-08 Thread Ivan Pechorin
Hello > On Tue, 2010-08-03 at 12:33 -0700, Marc Luce wrote: >> My LD_LIBRARY_PATH=::/usr/lib:/usr/local/lib I wonder if APR 1.4.x is supported? README in branches/activemq-cpp-3.2.x still suggests APR >= 1.3*. Regards, Ivan

Re: correlation ID on synchronous message

2010-07-08 Thread Ivan Pechorin
> So it's fine without correlation ID because the producer waits for reply > message not on the static queue but on the temporary queue registered in the > JMSReplyTo header. It's fine without correlation ID as long as the requesting side (producer) waits for reply before sending next request. Cor

Re: Temporary queues and a WAN

2010-06-22 Thread Ivan Pechorin
2010/6/22 : > As per the advice at > http://activemq.apache.org/how-should-i-implement-request-response-with-jms.html > I am using temporary Qs for my replies. > ... > > Because of various technical obstacles that I wont go into here, I am only > able to run with ActiveMQ locally. ActiveMQ is fine

Re: Problems with lingering ActiveMQTempQueue objects

2010-06-03 Thread Ivan Pechorin
> I'm using temporary response queues as per the JMS spec and attaching these > to the message using setJMSReplyTo(responseQueue). The calling code then > sits and waits for the response or times out and then closes the connection. Sorry, did I understand correctly and you create a new temporary q

Re: Various problems using ActiveMQ from C#

2010-05-30 Thread Ivan Pechorin
On 2010/5/28 Frank Gynnild wrote: > How "cheap" is it to create local session, > producers and consumers for each thread vs using synchronization to create > thread safe sessions? There is no need to create local session, producers and consumers for EACH thread, you can utilize a thread-safe pool

Re: JBoss 4 and ActiveMQ standalone

2010-04-30 Thread Ivan Pechorin
> Why would I have an activemq-ra.rar in $JBOSS_HOME/server/all/deploy if I am > not embedding it? You need resource adapter in order to connect your MDBs to ActiveMQ broker. No matter whether you are embedding the broker, or not. By the way, if you need to connect your MDBs to more than one brok

Re: JBoss 4 and ActiveMQ standalone

2010-04-30 Thread Ivan Pechorin
2010/4/30 ed4becky : > > I would like to configure an MDB running in JBoss to access a JMS message > queue running in a standalone ActiveMQ instance. You should configure property "ServerUrl" of ActiveMQ Resource Adapter (RA) to connect to your standalone ActiveMQ instance. $JBOSS_HOME/server/all

Re: ActiveMQConnection leaks memory by caching ActiveMQTempQueue objects

2010-04-29 Thread Ivan Pechorin
> what I cannot understand is that why those ActiveMQTempQueue are always > there even I close the connection. Because the connection is not closed actually, it is just returned to the pool. If I understand correctly, the following kinds of ActiveMQ objects involve sync request to ActiveMQ broker

Re: ActiveMQConnection leaks memory by caching ActiveMQTempQueue objects

2010-04-29 Thread Ivan Pechorin
Hello, 2010/4/29 easyl : > AMQ 5.3 in Geronimo 2.2 > > I found ActiveMQConnection always hold the ActiveMQTempQueue and should lead > to memory leak, > especially using massive send/reply through temp queues. > > I create a ticket here https://issues.apache.org/activemq/browse/AMQ-2716 There is s

Re: ActiveMQ RA and client acknowledge in a message-driven bean

2010-04-26 Thread Ivan Pechorin
Hello 2010/4/21 Gary Tully : > Use a transacted delivery in your endpoint activation and throw an exception > from onMessage. if you have the source, take a peek at this test: > org.apache.activemq.ra.MDBTest.testMessageExceptionReDelivery Thanks a lot, it works like a charm now! Another thing

Re: a direct way to connect to activemq without tcp overhead ?

2010-04-20 Thread Ivan Pechorin
christoph_75 wrote: > > I am using the activemq-cpp-library-3.1.2 and activemq 5.3.1 > one possibility might maybe using the vm transport , but i don't see any > vmTransportfactory in the activemq-cpp-library-3.1.2 , > so i guess the vm transport isn't supported in this library , correct ? >

ActiveMQ RA and client acknowledge in a message-driven bean

2010-04-20 Thread Ivan Pechorin
Hello! I use JBoss, ActiveMQ resource adapter (RA), and a message-driven bean (MDB) with a persistent queue. I need to be able to leave a message in queue if something bad happened inside method onMessage() of my MDB. The question is how to achieve it? I looked into the source of ActiveMQ RA, and

ActiveMQ RA: how to make MDB with CLIENT_ACKNOWLEDGE?

2010-04-19 Thread Ivan Pechorin
Hello We have a message-driven bean in JBoss with ActiveMQ resource adapter (RA). It seems like ActiveMQ RA doesn't support CLIENT_ACKNOWLEDGE mode. It supports only DUPS_OK_ACKNOWLEDGE and AUTO_ACKNOWLEDGE modes. Basically, I need to be able to leave a message in queue if something bad happened

Re: ActiveMQ-CPP - why ResourceLifecycleManager is not synchronized?

2010-02-19 Thread Ivan Pechorin
Hi Tim, > Care to work up a patch for it and create an issue? Sure, I will do it soon. Best regards, IVan -- View this message in context: http://old.nabble.com/ActiveMQ-CPP---why-ResourceLifecycleManager-is-not-synchronized--tp27653021p27656486.html Sent from the ActiveMQ - User mailing li

ActiveMQ-CPP - why ResourceLifecycleManager is not synchronized?

2010-02-19 Thread Ivan Pechorin
Hi! We use ActiveMQ C++ 3.1.0 client in a multi-threaded application. We use activemq::cmsutil::SessionPool and activemq::cmsutil::PooledSession. Today the application crashed because methods createCachedProducer and createCachedConsumer do not synchronize access to their shared ResourceLifecyc

ActiveMQ-CPP - how to purge a queue?

2010-02-12 Thread Ivan Pechorin
Hi! Is there any way to purge a queue from a C++ application that uses ActiveMQ-CPP client? Best regards, Ivan -- View this message in context: http://old.nabble.com/ActiveMQ-CPP---how-to-purge-a-queue--tp27562975p27562975.html Sent from the ActiveMQ - User mailing list archive at Nabble.com.

Re: ActiveMQ C++: warning "deletion of pointer to incomplete type"

2010-01-26 Thread Ivan Pechorin
> Its possible it could cause an issue. You are welcome to open a new > Jira issue and submit a patch to fix the problem. Thanks, Tim. I'll try to fix it. Just wanted to check if anybody else already done that :) -- View this message in context: http://old.nabble.com/ActiveMQ-C%2B%2B%3A-warni

Re: ActiveMQ C++: warning "deletion of pointer to incomplete type"

2010-01-26 Thread Ivan Pechorin
By the way, is it the right place for such questions, or is it better to open JIRA issue? -- View this message in context: http://old.nabble.com/ActiveMQ-C%2B%2B%3A-warning-%22deletion-of-pointer-to-incomplete-type%22-tp27323723p27323921.html Sent from the ActiveMQ - User mailing list archive at

Re: Installing Activemq-cpp in HP-UX

2010-01-26 Thread Ivan Pechorin
One of possible reasons of crash in __pthread_startup could be "-mt" flag missing in LDFLAGS... I've seen this few months ago on HP-UX 11i v2 (11.23) on IA64 platform with latest version of HP aCC compiler. Not sure if it is applicable to GCC build. -- View this message in context: http://old.na

ActiveMQ C++: warning "deletion of pointer to incomplete type"

2010-01-26 Thread Ivan Pechorin
Hello The latest version of ActiveMQ C++ client (3.1.0) gives the following warning (multiple times) when compiling it with Visual C++ 2008 SP1 on Win32: 1>SimpleLogger.cpp 1>c:\dev_vc9\activemq\activemq-cpp\src\main\decaf/lang/Pointer.h(357) : warning C4150: deletion of pointer to incomplete ty

Re: ActiveMQ-CPP: how to send to temp queue?

2009-07-16 Thread Ivan Pechorin
> Actually its not nearly as hard as all that. Each of the Destination > classes in CMS extends from cms::Destination which defines a clone > method. When you receive a message that has a replyTo destination you > can simply clone the destination and use the new instance you created to > create

ActiveMQ-CPP: how to send to temp queue?

2009-07-16 Thread Ivan Pechorin
Hello I'm trying to implement Request-Response pattern with: - ActiveMQ broker, - NMS (C#) on the client (requestor) side, - CMS (ActiveMQ-CPP) on the server (responder) side. This pattern is described very clearly - for JMS: http://remark.wordpress.com/articles/implementing-request-respons