From activemq-commits-return-537-apmail-geronimo-activemq-commits-archive=geronimo.apache.org@geronimo.apache.org Thu Feb 02 21:13:10 2006 Return-Path: Delivered-To: apmail-geronimo-activemq-commits-archive@www.apache.org Received: (qmail 14985 invoked from network); 2 Feb 2006 21:13:07 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 2 Feb 2006 21:13:07 -0000 Received: (qmail 31786 invoked by uid 500); 2 Feb 2006 21:12:57 -0000 Delivered-To: apmail-geronimo-activemq-commits-archive@geronimo.apache.org Received: (qmail 31673 invoked by uid 500); 2 Feb 2006 21:12:56 -0000 Mailing-List: contact activemq-commits-help@geronimo.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: activemq-dev@geronimo.apache.org Delivered-To: mailing list activemq-commits@geronimo.apache.org Received: (qmail 31249 invoked by uid 99); 2 Feb 2006 21:12:52 -0000 Received: from asf.osuosl.org (HELO asf.osuosl.org) (140.211.166.49) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 02 Feb 2006 13:12:52 -0800 X-ASF-Spam-Status: No, hits=-9.4 required=10.0 tests=ALL_TRUSTED,NO_REAL_NAME X-Spam-Check-By: apache.org Received: from [209.237.227.194] (HELO minotaur.apache.org) (209.237.227.194) by apache.org (qpsmtpd/0.29) with SMTP; Thu, 02 Feb 2006 13:12:45 -0800 Received: (qmail 13902 invoked by uid 65534); 2 Feb 2006 21:12:25 -0000 Message-ID: <20060202211224.13899.qmail@minotaur.apache.org> Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r374503 [2/8] - /incubator/activemq/site/ Date: Thu, 02 Feb 2006 21:11:36 -0000 To: activemq-commits@geronimo.apache.org From: chirino@apache.org X-Mailer: svnmailer-1.0.5 X-Virus-Checked: Checked by ClamAV on apache.org X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N Modified: incubator/activemq/site/ActiveMQ+4.0 URL: http://svn.apache.org/viewcvs/incubator/activemq/site/ActiveMQ%2B4.0?rev=374503&r1=374502&r2=374503&view=diff ============================================================================== --- incubator/activemq/site/ActiveMQ+4.0 (original) +++ incubator/activemq/site/ActiveMQ+4.0 Thu Feb 2 13:10:25 2006 @@ -1,4 +1,4 @@ - + @@ -18,7 +18,10 @@ - + + + + @@ -155,7 +158,7 @@
  • Test Source XRef
  • XSD
  • -

    Tools we use

    +

    Tools we use

    Feeds

    @@ -199,7 +202,7 @@ -

    Please feel free to take it for a spin!

    +

    Please feel free to take it for a spin!

    This section of the site contains the development notes and features for the forthcoming major release

    • Design Documents
    • Modified: incubator/activemq/site/ActiveMQ+Command+Line+Tools+Reference URL: http://svn.apache.org/viewcvs/incubator/activemq/site/ActiveMQ%2BCommand%2BLine%2BTools%2BReference?rev=374503&r1=374502&r2=374503&view=diff ============================================================================== --- incubator/activemq/site/ActiveMQ+Command+Line+Tools+Reference (original) +++ incubator/activemq/site/ActiveMQ+Command+Line+Tools+Reference Thu Feb 2 13:10:25 2006 @@ -1,4 +1,4 @@ - + @@ -18,7 +18,10 @@ - +
    + + +
    @@ -155,7 +158,7 @@
  • Test Source XRef
  • XSD
  • -

    Tools we use

    +

    Tools we use

    Feeds

    Modified: incubator/activemq/site/Advisory+Message URL: http://svn.apache.org/viewcvs/incubator/activemq/site/Advisory%2BMessage?rev=374503&r1=374502&r2=374503&view=diff ============================================================================== --- incubator/activemq/site/Advisory+Message (original) +++ incubator/activemq/site/Advisory+Message Thu Feb 2 13:10:25 2006 @@ -1,4 +1,4 @@ - + @@ -18,7 +18,10 @@ - +
    + + +
    @@ -155,7 +158,7 @@
  • Test Source XRef
  • XSD
  • -

    Tools we use

    +

    Tools we use

    Feeds

    @@ -201,12 +204,12 @@

    Methods to get the advisory destnation objects are available in AdvisorySupport

    -
    AdvisorySupport.getConsumerAdvisoryTopic()
    -AdvisorySupport.getProducerAdvisoryTopic()
    -AdvisorySupport.getExpiredTopicMessageAdvisoryTopic()
    -AdvisorySupport.getExpiredQueueMessageAdvisoryTopic()
    -AdvisorySupport.getNoTopicConsumersAdvisoryTopic()
    -AdvisorySupport.getNoQueueConsumersAdvisoryTopic()
    +        
    AdvisorySupport.getConsumerAdvisoryTopic()
    +AdvisorySupport.getProducerAdvisoryTopic()
    +AdvisorySupport.getExpiredTopicMessageAdvisoryTopic()
    +AdvisorySupport.getExpiredQueueMessageAdvisoryTopic()
    +AdvisorySupport.getNoTopicConsumersAdvisoryTopic()
    +AdvisorySupport.getNoQueueConsumersAdvisoryTopic()
     AdvisorySupport.getDestinationAdvisoryTopic()

    @@ -214,21 +217,21 @@

    For example:

    -
    ...
    -  
    -    Destination advisoryDestination = AdvisorySupport.getProducerAdvisoryTopic(destination)
    -    MessageConsumer consumer = session.createConsumer(advisoryDestination);
    -    consumer.setMessageListener(this);
    -....
    -public void onMessage(Message msg){
    -    if (msg instanceof ActiveMQMessage){
    -        try {
    -             ActiveMQMessage aMsg =  (ActiveMQMessage)msg;
    -             ProducerInfo prod = (ProducerInfo) aMsg.getDataStructure();
    -        } catch (JMSException e) {
    -            log.error("Failed to process message: " + msg);
    -        }
    -    }
    +        
    ...
    +  
    +    Destination advisoryDestination = AdvisorySupport.getProducerAdvisoryTopic(destination)
    +    MessageConsumer consumer = session.createConsumer(advisoryDestination);
    +    consumer.setMessageListener(this);
    +....
    +public void onMessage(Message msg){
    +    if (msg instanceof ActiveMQMessage){
    +        try {
    +             ActiveMQMessage aMsg =  (ActiveMQMessage)msg;
    +             ProducerInfo prod = (ProducerInfo) aMsg.getDataStructure();
    +        } catch (JMSException e) {
    +            log.error("Failed to process message: " + msg);
    +        }
    +    }
     }

    @@ -236,9 +239,9 @@

    The destination string constants are available in ActiveMQDestination

    -
    ActiveMQDestination.CONSUMER_ADVISORY_PREFIX
    -ActiveMQDestination.PRODUCER_ADVISORY_PREFIX
    -ActiveMQDestination.CONNECTION_ADVISORY_PREFIX
    +        
    ActiveMQDestination.CONSUMER_ADVISORY_PREFIX
    +ActiveMQDestination.PRODUCER_ADVISORY_PREFIX
    +ActiveMQDestination.CONNECTION_ADVISORY_PREFIX
     ActiveMQDestination.TEMP_DESTINATION_ADVISORY_PREFIX

    @@ -246,20 +249,20 @@

    For example:

    -
    ...
    -    String advisoryName = ActiveMQDestination.PRODUCER_ADVISORY_PREFIX + destination.getPhysicalName();
    -    Destination advisoryDestination = ActiveMQDestination.createDestination(destination.getDestinationType(), advisoryName);
    -    MessageConsumer consumer = session.createConsumer(advisoryDestination);
    -    consumer.setMessageListener(this);
    -....
    -public void onMessage(Message msg){
    -    if (msg instanceof ObjectMessage){
    -        try {
    -            ProducerInfo info = (ProducerInfo)((ObjectMessage)msg).getObject();
    -        } catch (JMSException e) {
    -            log.error("Failed to process message: " + msg);
    -        }
    -    }
    +        
    ...
    +    String advisoryName = ActiveMQDestination.PRODUCER_ADVISORY_PREFIX + destination.getPhysicalName();
    +    Destination advisoryDestination = ActiveMQDestination.createDestination(destination.getDestinationType(), advisoryName);
    +    MessageConsumer consumer = session.createConsumer(advisoryDestination);
    +    consumer.setMessageListener(this);
    +....
    +public void onMessage(Message msg){
    +    if (msg instanceof ObjectMessage){
    +        try {
    +            ProducerInfo info = (ProducerInfo)((ObjectMessage)msg).getObject();
    +        } catch (JMSException e) {
    +            log.error("Failed to process message: " + msg);
    +        }
    +    }
     }

    Modified: incubator/activemq/site/Ajax URL: http://svn.apache.org/viewcvs/incubator/activemq/site/Ajax?rev=374503&r1=374502&r2=374503&view=diff ============================================================================== --- incubator/activemq/site/Ajax (original) +++ incubator/activemq/site/Ajax Thu Feb 2 13:10:25 2006 @@ -1,4 +1,4 @@ - + @@ -18,7 +18,10 @@ - +
    + + +
    @@ -155,7 +158,7 @@
  • Test Source XRef
  • XSD
  • -

    Tools we use

    +

    Tools we use

    Feeds

    Modified: incubator/activemq/site/Are+destinations+case+sensitive URL: http://svn.apache.org/viewcvs/incubator/activemq/site/Are%2Bdestinations%2Bcase%2Bsensitive?rev=374503&r1=374502&r2=374503&view=diff ============================================================================== --- incubator/activemq/site/Are+destinations+case+sensitive (original) +++ incubator/activemq/site/Are+destinations+case+sensitive Thu Feb 2 13:10:25 2006 @@ -1,4 +1,4 @@ - + @@ -18,7 +18,10 @@ - +
    + + +
    @@ -155,7 +158,7 @@
  • Test Source XRef
  • XSD
  • -

    Tools we use

    +

    Tools we use

    Feeds

    Modified: incubator/activemq/site/Are+messages+read+directly+from+the+journal URL: http://svn.apache.org/viewcvs/incubator/activemq/site/Are%2Bmessages%2Bread%2Bdirectly%2Bfrom%2Bthe%2Bjournal?rev=374503&r1=374502&r2=374503&view=diff ============================================================================== --- incubator/activemq/site/Are+messages+read+directly+from+the+journal (original) +++ incubator/activemq/site/Are+messages+read+directly+from+the+journal Thu Feb 2 13:10:25 2006 @@ -1,4 +1,4 @@ - + @@ -155,7 +155,7 @@
  • Test Source XRef
  • XSD
  • -

    Tools we use

    +

    Tools we use

    Feeds

    Modified: incubator/activemq/site/Articles URL: http://svn.apache.org/viewcvs/incubator/activemq/site/Articles?rev=374503&r1=374502&r2=374503&view=diff ============================================================================== --- incubator/activemq/site/Articles (original) +++ incubator/activemq/site/Articles Thu Feb 2 13:10:25 2006 @@ -1,4 +1,4 @@ - + @@ -18,7 +18,10 @@ - +
    + + +
    @@ -155,7 +158,7 @@
  • Test Source XRef
  • XSD
  • -

    Tools we use

    +

    Tools we use

    Feeds

    Modified: incubator/activemq/site/Axis+Support URL: http://svn.apache.org/viewcvs/incubator/activemq/site/Axis%2BSupport?rev=374503&r1=374502&r2=374503&view=diff ============================================================================== --- incubator/activemq/site/Axis+Support (original) +++ incubator/activemq/site/Axis+Support Thu Feb 2 13:10:25 2006 @@ -1,4 +1,4 @@ - + @@ -18,7 +18,10 @@ - +
    + + +
    @@ -155,7 +158,7 @@
  • Test Source XRef
  • XSD
  • -

    Tools we use

    +

    Tools we use

    Feeds

    Modified: incubator/activemq/site/Becoming+a+committer URL: http://svn.apache.org/viewcvs/incubator/activemq/site/Becoming%2Ba%2Bcommitter?rev=374503&r1=374502&r2=374503&view=diff ============================================================================== --- incubator/activemq/site/Becoming+a+committer (original) +++ incubator/activemq/site/Becoming+a+committer Thu Feb 2 13:10:25 2006 @@ -1,4 +1,4 @@ - + @@ -18,7 +18,10 @@ - +
    + + +
    @@ -155,7 +158,7 @@
  • Test Source XRef
  • XSD
  • -

    Tools we use

    +

    Tools we use

    Feeds

    @@ -200,7 +203,7 @@

    Once you're contributing and your work is good, one of our Team might invite you to be a committer (after we've called a vote). When that happens, if you accept, the following process kicks into place...

    Becoming a committer steps

      -
    • Download and print the Apache Contributor License Agreement from here. You need to sign it and fax it to Apache. In the past I've found its often faster to also post it via snail mail
    • +
    • Download and print the Apache Contributor License Agreement from here. You need to sign it and fax it to Apache. In the past I've found its often faster to also post it via snail mail
    • wait for your name to appear on the list of received CLAs
    • once thats done let us know and we can apply to Apache Infrastructure to have your account created; we'll also need to know
      • your full name
      • Modified: incubator/activemq/site/Benchmark+Tests URL: http://svn.apache.org/viewcvs/incubator/activemq/site/Benchmark%2BTests?rev=374503&r1=374502&r2=374503&view=diff ============================================================================== --- incubator/activemq/site/Benchmark+Tests (original) +++ incubator/activemq/site/Benchmark+Tests Thu Feb 2 13:10:25 2006 @@ -1,4 +1,4 @@ - + @@ -18,7 +18,10 @@ - +
    + + +
    @@ -155,7 +158,7 @@
  • Test Source XRef
  • XSD
  • -

    Tools we use

    +

    Tools we use

    Feeds

    Modified: incubator/activemq/site/Broker+Configuration+URI URL: http://svn.apache.org/viewcvs/incubator/activemq/site/Broker%2BConfiguration%2BURI?rev=374503&r1=374502&r2=374503&view=diff ============================================================================== --- incubator/activemq/site/Broker+Configuration+URI (original) +++ incubator/activemq/site/Broker+Configuration+URI Thu Feb 2 13:10:25 2006 @@ -1,4 +1,4 @@ - + @@ -18,7 +18,10 @@ - +
    + + +
    @@ -155,7 +158,7 @@
  • Test Source XRef
  • XSD
  • -

    Tools we use

    +

    Tools we use

    Feeds

    @@ -247,7 +250,7 @@

    The following example starts up a broker accepting connections on port 61616, and establishes a network connection to remotehost:61616 and disables persistence.

    -
    broker:(tcp://localhost:61616,network:static:tcp://remotehost:61616)?persistent=false&useJmx=true
    +        
    broker:(tcp://localhost:61616,network:static:tcp://remotehost:61616)?persistent=false&useJmx=true
     

    Modified: incubator/activemq/site/Building URL: http://svn.apache.org/viewcvs/incubator/activemq/site/Building?rev=374503&r1=374502&r2=374503&view=diff ============================================================================== --- incubator/activemq/site/Building (original) +++ incubator/activemq/site/Building Thu Feb 2 13:10:25 2006 @@ -1,4 +1,4 @@ - + @@ -18,7 +18,10 @@ - +
    + + +
    @@ -155,7 +158,7 @@
  • Test Source XRef
  • XSD
  • -

    Tools we use

    +

    Tools we use

    Feeds

    Modified: incubator/activemq/site/C+Integration URL: http://svn.apache.org/viewcvs/incubator/activemq/site/C%2BIntegration?rev=374503&r1=374502&r2=374503&view=diff ============================================================================== --- incubator/activemq/site/C+Integration (original) +++ incubator/activemq/site/C+Integration Thu Feb 2 13:10:25 2006 @@ -1,4 +1,4 @@ - + @@ -18,7 +18,10 @@ - +
    + + +
    @@ -155,7 +158,7 @@
  • Test Source XRef
  • XSD
  • -

    Tools we use

    +

    Tools we use

    Feeds

    Modified: incubator/activemq/site/Can+I+send+really+large+files+over+ActiveMQ URL: http://svn.apache.org/viewcvs/incubator/activemq/site/Can%2BI%2Bsend%2Breally%2Blarge%2Bfiles%2Bover%2BActiveMQ?rev=374503&r1=374502&r2=374503&view=diff ============================================================================== --- incubator/activemq/site/Can+I+send+really+large+files+over+ActiveMQ (original) +++ incubator/activemq/site/Can+I+send+really+large+files+over+ActiveMQ Thu Feb 2 13:10:25 2006 @@ -1,4 +1,4 @@ - + @@ -18,7 +18,10 @@ - +
    + + +
    @@ -155,7 +158,7 @@
  • Test Source XRef
  • XSD
  • -

    Tools we use

    +

    Tools we use

    Feeds

    Modified: incubator/activemq/site/Can+you+browse+a+topic URL: http://svn.apache.org/viewcvs/incubator/activemq/site/Can%2Byou%2Bbrowse%2Ba%2Btopic?rev=374503&r1=374502&r2=374503&view=diff ============================================================================== --- incubator/activemq/site/Can+you+browse+a+topic (original) +++ incubator/activemq/site/Can+you+browse+a+topic Thu Feb 2 13:10:25 2006 @@ -1,4 +1,4 @@ - + @@ -18,7 +18,10 @@ - +
    + + +
    @@ -155,7 +158,7 @@
  • Test Source XRef
  • XSD
  • -

    Tools we use

    +

    Tools we use

    Feeds

    Modified: incubator/activemq/site/Changes+in+4.0 URL: http://svn.apache.org/viewcvs/incubator/activemq/site/Changes%2Bin%2B4.0?rev=374503&r1=374502&r2=374503&view=diff ============================================================================== --- incubator/activemq/site/Changes+in+4.0 (original) +++ incubator/activemq/site/Changes+in+4.0 Thu Feb 2 13:10:25 2006 @@ -1,4 +1,4 @@ - + @@ -18,7 +18,10 @@ - +
    + + +
    @@ -155,7 +158,7 @@
  • Test Source XRef
  • XSD
  • -

    Tools we use

    +

    Tools we use

    Feeds

    Modified: incubator/activemq/site/Clustering URL: http://svn.apache.org/viewcvs/incubator/activemq/site/Clustering?rev=374503&r1=374502&r2=374503&view=diff ============================================================================== --- incubator/activemq/site/Clustering (original) +++ incubator/activemq/site/Clustering Thu Feb 2 13:10:25 2006 @@ -1,4 +1,4 @@ - + @@ -18,7 +18,10 @@ - +
    + + +
    @@ -155,7 +158,7 @@
  • Test Source XRef
  • XSD
  • -

    Tools we use

    +

    Tools we use

    Feeds

    Modified: incubator/activemq/site/Code+Overview URL: http://svn.apache.org/viewcvs/incubator/activemq/site/Code%2BOverview?rev=374503&r1=374502&r2=374503&view=diff ============================================================================== --- incubator/activemq/site/Code+Overview (original) +++ incubator/activemq/site/Code+Overview Thu Feb 2 13:10:25 2006 @@ -1,4 +1,4 @@ - + @@ -18,7 +18,10 @@ - +
    + + +
    @@ -155,7 +158,7 @@
  • Test Source XRef
  • XSD
  • -

    Tools we use

    +

    Tools we use

    Feeds

    Modified: incubator/activemq/site/Compile+ActiveMQ+with+GCJ URL: http://svn.apache.org/viewcvs/incubator/activemq/site/Compile%2BActiveMQ%2Bwith%2BGCJ?rev=374503&r1=374502&r2=374503&view=diff ============================================================================== --- incubator/activemq/site/Compile+ActiveMQ+with+GCJ (original) +++ incubator/activemq/site/Compile+ActiveMQ+with+GCJ Thu Feb 2 13:10:25 2006 @@ -1,4 +1,4 @@ - + @@ -18,7 +18,10 @@ - +
    + + +
    @@ -155,7 +158,7 @@
  • Test Source XRef
  • XSD
  • -

    Tools we use

    +

    Tools we use

    Feeds

    @@ -203,38 +206,38 @@

    If you don't already have GCC 4.0.2 installed you need to download and build it. See GCC manuals for complete instructions on how to build GCC but below is a short descriptions of the steps involved. The GCC build steps assumes that you already have an older GCC compiler installed.

    • Unpack GCC into an arbitrary directory, for example /opt/gccbuild, and then create a separate output directory. Your directory structure should look similar to this;
      -
              /opt/gccbuild/gcc-4.0.2
      -        /opt/gccbuild/output
      +          
              /opt/gccbuild/gcc-4.0.2
      +        /opt/gccbuild/output
       
    • Go to the output directory and run configure.
      -
              cd /opt/gccbuild/output
      -        ../gcc-4.0.2/configure --prefix=/opt/gcc402
      -                               --enable-shared
      -                               --enable-threads=posix
      -                               --enable-languages=c,c++,java
      +          
              cd /opt/gccbuild/output
      +        ../gcc-4.0.2/configure --prefix=/opt/gcc402
      +                               --enable-shared
      +                               --enable-threads=posix
      +                               --enable-languages=c,c++,java
       
    • Run make.
      -
              make bootstrap
      -        make install
      +          
              make bootstrap
      +        make install
       
    • Download ActiveMQ and copy the JARs to a new empty directory /opt/app, including
      -
              activeio-1.1.jar
      -        activemq-core-3.2.jar
      -        commons-logging-1.0.3.jar
      -        concurrent-1.3.4.jar
      -        geronimo-spec-j2ee-jacc-1.0-rc4.jar
      -        geronimo-spec-j2ee-management-1.0-rc4.jar
      -        geronimo-spec-jms-1.1-rc4.jar
      -        geronimo-spec-jta-1.0.1B-rc4.jar
      -        log4j-1.2.8.jar
      +          
              activeio-1.1.jar
      +        activemq-core-3.2.jar
      +        commons-logging-1.0.3.jar
      +        concurrent-1.3.4.jar
      +        geronimo-spec-j2ee-jacc-1.0-rc4.jar
      +        geronimo-spec-j2ee-management-1.0-rc4.jar
      +        geronimo-spec-jms-1.1-rc4.jar
      +        geronimo-spec-jta-1.0.1B-rc4.jar
      +        log4j-1.2.8.jar
       
    • @@ -245,136 +248,136 @@
      Bootstrap.cpp

      -
      #include <gcj/cni.h>
      -#include <iostream>
      -#include <java/lang/System.h>
      -#include <java/lang/Throwable.h>
      -#include <java/io/PrintStream.h>
      -#include "MQAdapter.h"
      -
      -using namespace std;
      -
      -int main(int argc, char* argv[])
      -{
      -    cout << "Entering main" << endl;
      -    using namespace java::lang;
      -
      -    try
      -    {
      -        // Create and startup Java VM
      -        JvCreateJavaVM(NULL) ;
      -        JvAttachCurrentThread(NULL, NULL) ;
      -
      -        System::out->println(JvNewStringLatin1("Java println")) ;
      -
      -        // Start ActiveMQ
      -        MQAdapter* pAdapter = new MQAdapter() ;
      -        pAdapter->start() ;
      -
      -        // Send a message
      -        pAdapter->send(JvNewStringLatin1("Hello World!")) ;
      -
      -        // Shutdown ActiveMQ
      -        pAdapter->stop() ;
      -     
      -        JvDetachCurrentThread() ;
      -    }
      -    catch( Throwable *t )
      -    {
      -        System::err->println(JvNewStringLatin1("Exception")) ;
      -        t->printStackTrace() ;
      -    }
      -}
      +        
      #include <gcj/cni.h>
      +#include <iostream>
      +#include <java/lang/System.h>
      +#include <java/lang/Throwable.h>
      +#include <java/io/PrintStream.h>
      +#include "MQAdapter.h"
      +
      +using namespace std;
      +
      +int main(int argc, char* argv[])
      +{
      +    cout << "Entering main" << endl;
      +    using namespace java::lang;
      +
      +    try
      +    {
      +        // Create and startup Java VM
      +        JvCreateJavaVM(NULL) ;
      +        JvAttachCurrentThread(NULL, NULL) ;
      +
      +        System::out->println(JvNewStringLatin1("Java println")) ;
      +
      +        // Start ActiveMQ
      +        MQAdapter* pAdapter = new MQAdapter() ;
      +        pAdapter->start() ;
      +
      +        // Send a message
      +        pAdapter->send(JvNewStringLatin1("Hello World!")) ;
      +
      +        // Shutdown ActiveMQ
      +        pAdapter->stop() ;
      +     
      +        JvDetachCurrentThread() ;
      +    }
      +    catch( Throwable *t )
      +    {
      +        System::err->println(JvNewStringLatin1("Exception")) ;
      +        t->printStackTrace() ;
      +    }
      +}
       

      MQAdapter.java

      -
      import org.activemq.*;
      -import java.util.Hashtable ;
      -import javax.jms.*;
      -import javax.naming.*;
      -
      -public class MQAdapter
      -{
      -    private InitialContext         jndiContext ;
      -    private QueueConnectionFactory factory ;
      -    private QueueConnection        connection ;
      -    private QueueSession           session ;
      -    private QueueSender            sender ;
      -    private Queue                  queue ;
      -
      -    public MQAdapter()
      -    {
      -    }
      -
      -    public void start()
      -    {
      -        try
      -        {
      -            Hashtable props = new Hashtable() ;
      -            props.put(Context.INITIAL_CONTEXT_FACTORY, "org.activemq.jndi.ActiveMQInitialContextFactory") ;
      -            props.put(Context.PROVIDER_URL, "tcp://localhost:61616") ;
      -            props.put("queue.MyQueue", "example.MyQueue") ;
      -
      -            jndiContext = new InitialContext(props) ;
      -        
      -            // Create and configure JMS connection factory
      -            factory = (QueueConnectionFactory)jndiContext.lookup("ConnectionFactory") ;
      -
      -            // Lookup Queue
      -            queue = (Queue)jndiContext.lookup("MyQueue") ;
      -
      -            // Create a JMS connection
      -            connection = (QueueConnection)factory.createQueueConnection() ;
      -            System.out.println("Created connection: " + connection) ;
      -
      -            // Create a JMS session
      -            session = connection.createQueueSession(false, Session.AUTO_ACKNOWLEDGE) ;
      -            System.out.println("Created session: " + session) ;
      -
      -            // Create JMS sender
      -            sender  = session.createSender(queue) ;
      -        }
      -        catch( Exception e )
      -        {
      -            e.printStackTrace() ;
      -
      -            try
      -            {
      -                if( connection != null )
      -                    connection.close() ;
      -            } catch( JMSException jmse )
      -            { /* ignore */ }
      -        }
      -    }
      -
      -    public void stop()
      -    {
      -        try
      -        {
      -            if( connection != null )
      -                connection.close() ;
      -        } catch( JMSException e )
      -        { /* ignore */ }
      -    }
      -
      -    public void send(String msg)
      -    {
      -        TextMessage message ;
      -
      -        try
      -        {
      -            message = session.createTextMessage(msg) ;
      -            sender.send(message) ;
      -        }
      -        catch( JMSException e )
      -        {
      -            e.printStackTrace() ;
      -        }
      -    }
      -}
      +        
      import org.activemq.*;
      +import java.util.Hashtable ;
      +import javax.jms.*;
      +import javax.naming.*;
      +
      +public class MQAdapter
      +{
      +    private InitialContext         jndiContext ;
      +    private QueueConnectionFactory factory ;
      +    private QueueConnection        connection ;
      +    private QueueSession           session ;
      +    private QueueSender            sender ;
      +    private Queue                  queue ;
      +
      +    public MQAdapter()
      +    {
      +    }
      +
      +    public void start()
      +    {
      +        try
      +        {
      +            Hashtable props = new Hashtable() ;
      +            props.put(Context.INITIAL_CONTEXT_FACTORY, "org.activemq.jndi.ActiveMQInitialContextFactory") ;
      +            props.put(Context.PROVIDER_URL, "tcp://localhost:61616") ;
      +            props.put("queue.MyQueue", "example.MyQueue") ;
      +
      +            jndiContext = new InitialContext(props) ;
      +        
      +            // Create and configure JMS connection factory
      +            factory = (QueueConnectionFactory)jndiContext.lookup("ConnectionFactory") ;
      +
      +            // Lookup Queue
      +            queue = (Queue)jndiContext.lookup("MyQueue") ;
      +
      +            // Create a JMS connection
      +            connection = (QueueConnection)factory.createQueueConnection() ;
      +            System.out.println("Created connection: " + connection) ;
      +
      +            // Create a JMS session
      +            session = connection.createQueueSession(false, Session.AUTO_ACKNOWLEDGE) ;
      +            System.out.println("Created session: " + session) ;
      +
      +            // Create JMS sender
      +            sender  = session.createSender(queue) ;
      +        }
      +        catch( Exception e )
      +        {
      +            e.printStackTrace() ;
      +
      +            try
      +            {
      +                if( connection != null )
      +                    connection.close() ;
      +            } catch( JMSException jmse )
      +            { /* ignore */ }
      +        }
      +    }
      +
      +    public void stop()
      +    {
      +        try
      +        {
      +            if( connection != null )
      +                connection.close() ;
      +        } catch( JMSException e )
      +        { /* ignore */ }
      +    }
      +
      +    public void send(String msg)
      +    {
      +        TextMessage message ;
      +
      +        try
      +        {
      +            message = session.createTextMessage(msg) ;
      +            sender.send(message) ;
      +        }
      +        catch( JMSException e )
      +        {
      +            e.printStackTrace() ;
      +        }
      +    }
      +}
       

      @@ -387,80 +390,80 @@
    - +
    Note

    Using -Bsymbolic does not seem to work, use -symbolic instead.

    -
        compile.sh:
    -
    -    #!/bin/sh
    -
    -    # Create new classmap database
    -    gcj-dbtool -n classmap.db
    -
    -    for JAR_FILE in `find -iname "*.jar"`
    -    do
    -        echo "Compiling ${JAR_FILE} to native"
    -        gcj -shared -findirect-dispatch -fjni -fPIC -Wl,-symbolic -o ${JAR_FILE}.so ${JAR_FILE}
    -        gcj-dbtool -a classmap.db ${JAR_FILE} ${JAR_FILE}.so
    -    done
    +        
        compile.sh:
    +
    +    #!/bin/sh
    +
    +    # Create new classmap database
    +    gcj-dbtool -n classmap.db
    +
    +    for JAR_FILE in `find -iname "*.jar"`
    +    do
    +        echo "Compiling ${JAR_FILE} to native"
    +        gcj -shared -findirect-dispatch -fjni -fPIC -Wl,-symbolic -o ${JAR_FILE}.so ${JAR_FILE}
    +        gcj-dbtool -a classmap.db ${JAR_FILE} ${JAR_FILE}.so
    +    done
     

    • Run the above script and set environment property GCJ_PROPERTIES.
      -
                 ./compile.sh
      -           export GCJ_PROPERTIES="gnu.gcj.precompiled.db.path=/opt/app/classmap.db"
      +          
                 ./compile.sh
      +           export GCJ_PROPERTIES="gnu.gcj.precompiled.db.path=/opt/app/classmap.db"
       
    • Java compile MQAdapter.java
      -
                 gcj --classpath=./geronimo-spec-jms-1.1-rc4.jar:./activemq-core-3.2.jar -C MQAdapter.java
      +          
                 gcj --classpath=./geronimo-spec-jms-1.1-rc4.jar:./activemq-core-3.2.jar -C MQAdapter.java
       
    • Generate CNI header for MQAdapter.class
      -
                 gcjh MQAdapter
      +          
                 gcjh MQAdapter
       
    • JAR the Java glue code
      -
                 fastjar cf MQAdapter.jar MQAdapter.class
      +          
                 fastjar cf MQAdapter.jar MQAdapter.class
       
    • Native compile the Java JAR into a shared library, add output directory to LD_LIBRARY_PATH.
      -
                 gcj -shared -findirect-dispatch -fjni -fPIC -Wl,-symbolic -o MQAdapter.so MQAdapter.jar
      -           export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/opt/app
      -
      +          
                 gcj -shared -findirect-dispatch -fjni -fPIC -Wl,-symbolic -o MQAdapter.so MQAdapter.jar
      +           export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/opt/app
      +
       
    • Compile the C++ code
      -
                 g++ -c Bootstrap.cpp
      +          
                 g++ -c Bootstrap.cpp
       
    • Link Bootstrap with the Java code
      -
                 gcj -o Bootstrap Bootstrap.o -L /opt/app -lgcj -lstdc++ activeio-1.1.jar.so activemq-core-3.2.jar.so
      -               commons-logging-1.0.3.jar.so concurrent-1.3.4.jar.so geronimo-spec-jms-1.1-rc4.jar.so
      -               geronimo-spec-j2ee-management-1.0-rc4.jar.so geronimo-spec-j2ee-jacc-1.0-rc4.jar.so
      -               geronimo-spec-jta-1.0.1B-rc4.jar.so log4j-1.2.8.jar.so MQAdapter.so
      +          
                 gcj -o Bootstrap Bootstrap.o -L /opt/app -lgcj -lstdc++ activeio-1.1.jar.so activemq-core-3.2.jar.so
      +               commons-logging-1.0.3.jar.so concurrent-1.3.4.jar.so geronimo-spec-jms-1.1-rc4.jar.so
      +               geronimo-spec-j2ee-management-1.0-rc4.jar.so geronimo-spec-j2ee-jacc-1.0-rc4.jar.so
      +               geronimo-spec-jta-1.0.1B-rc4.jar.so log4j-1.2.8.jar.so MQAdapter.so
       
    • Modified: incubator/activemq/site/Composite+Destinations URL: http://svn.apache.org/viewcvs/incubator/activemq/site/Composite%2BDestinations?rev=374503&r1=374502&r2=374503&view=diff ============================================================================== --- incubator/activemq/site/Composite+Destinations (original) +++ incubator/activemq/site/Composite+Destinations Thu Feb 2 13:10:25 2006 @@ -1,4 +1,4 @@ - + @@ -18,7 +18,10 @@ - + + + + @@ -155,7 +158,7 @@
    • Test Source XRef
    • XSD
    -

    Tools we use

    +

    Tools we use

    Feeds

    Modified: incubator/activemq/site/Configuration URL: http://svn.apache.org/viewcvs/incubator/activemq/site/Configuration?rev=374503&r1=374502&r2=374503&view=diff ============================================================================== --- incubator/activemq/site/Configuration (original) +++ incubator/activemq/site/Configuration Thu Feb 2 13:10:25 2006 @@ -1,4 +1,4 @@ - + @@ -18,7 +18,10 @@ - +
    + + +
    @@ -155,7 +158,7 @@
  • Test Source XRef
  • XSD
  • -

    Tools we use

    +

    Tools we use

    Feeds

    Modified: incubator/activemq/site/Configuring+Brokers URL: http://svn.apache.org/viewcvs/incubator/activemq/site/Configuring%2BBrokers?rev=374503&r1=374502&r2=374503&view=diff ============================================================================== --- incubator/activemq/site/Configuring+Brokers (original) +++ incubator/activemq/site/Configuring+Brokers Thu Feb 2 13:10:25 2006 @@ -1,4 +1,4 @@ - + @@ -18,7 +18,10 @@ - +
    + + +
    @@ -155,7 +158,7 @@
  • Test Source XRef
  • XSD
  • -

    Tools we use

    +

    Tools we use

    Feeds

    @@ -205,24 +208,24 @@

    Example

    -
    <beans xmlns="http://activemq.org/config/1.0">
    -
    -  <broker useJmx="true">
    -  
    -    <persistenceAdapter>
    -      <journaledJDBC journalLogFiles="5" dataDirectory="../data"/>
    -    </persistenceAdapter>
    -  
    -    <transportConnectors>
    -      <transportConnector uri="discovery:tcp://localhost:61616"/>
    -    </transportConnectors>
    -    
    -    <networkConnectors>
    -      <networkConnector uri="multicast"/>
    -    </networkConnectors>
    -    
    -  </broker>
    -  
    +        
    <beans xmlns="http://activemq.org/config/1.0">
    +
    +  <broker useJmx="true">
    +  
    +    <persistenceAdapter>
    +      <journaledJDBC journalLogFiles="5" dataDirectory="../data"/>
    +    </persistenceAdapter>
    +  
    +    <transportConnectors>
    +      <transportConnector uri="discovery:tcp://localhost:61616"/>
    +    </transportConnectors>
    +    
    +    <networkConnectors>
    +      <networkConnector uri="multicast"/>
    +    </networkConnectors>
    +    
    +  </broker>
    +  
     </beans>

    Modified: incubator/activemq/site/Configuring+Transports URL: http://svn.apache.org/viewcvs/incubator/activemq/site/Configuring%2BTransports?rev=374503&r1=374502&r2=374503&view=diff ============================================================================== --- incubator/activemq/site/Configuring+Transports (original) +++ incubator/activemq/site/Configuring+Transports Thu Feb 2 13:10:25 2006 @@ -1,4 +1,4 @@ - + @@ -18,7 +18,10 @@ - +
    + + +
    @@ -155,7 +158,7 @@
  • Test Source XRef
  • XSD
  • -

    Tools we use

    +

    Tools we use

    Feeds

    Modified: incubator/activemq/site/Connection+Factory+Properties URL: http://svn.apache.org/viewcvs/incubator/activemq/site/Connection%2BFactory%2BProperties?rev=374503&r1=374502&r2=374503&view=diff ============================================================================== --- incubator/activemq/site/Connection+Factory+Properties (original) +++ incubator/activemq/site/Connection+Factory+Properties Thu Feb 2 13:10:25 2006 @@ -1,4 +1,4 @@ - + @@ -155,7 +155,7 @@
  • Test Source XRef
  • XSD
  • -

    Tools we use

    +

    Tools we use

    Feeds

    Modified: incubator/activemq/site/Consumer+Priority URL: http://svn.apache.org/viewcvs/incubator/activemq/site/Consumer%2BPriority?rev=374503&r1=374502&r2=374503&view=diff ============================================================================== --- incubator/activemq/site/Consumer+Priority (original) +++ incubator/activemq/site/Consumer+Priority Thu Feb 2 13:10:25 2006 @@ -1,4 +1,4 @@ - + @@ -155,7 +155,7 @@
  • Test Source XRef
  • XSD
  • -

    Tools we use

    +

    Tools we use

    Feeds

    Modified: incubator/activemq/site/Contributing URL: http://svn.apache.org/viewcvs/incubator/activemq/site/Contributing?rev=374503&r1=374502&r2=374503&view=diff ============================================================================== --- incubator/activemq/site/Contributing (original) +++ incubator/activemq/site/Contributing Thu Feb 2 13:10:25 2006 @@ -1,4 +1,4 @@ - + @@ -18,7 +18,10 @@ - +
    + + +
    @@ -155,7 +158,7 @@
  • Test Source XRef
  • XSD
  • -

    Tools we use

    +

    Tools we use

    Feeds

    Modified: incubator/activemq/site/DR URL: http://svn.apache.org/viewcvs/incubator/activemq/site/DR?rev=374503&r1=374502&r2=374503&view=diff ============================================================================== --- incubator/activemq/site/DR (original) +++ incubator/activemq/site/DR Thu Feb 2 13:10:25 2006 @@ -1,4 +1,4 @@ - + @@ -155,7 +155,7 @@
  • Test Source XRef
  • XSD
  • -

    Tools we use

    +

    Tools we use

    Feeds

    Modified: incubator/activemq/site/Design+Documents URL: http://svn.apache.org/viewcvs/incubator/activemq/site/Design%2BDocuments?rev=374503&r1=374502&r2=374503&view=diff ============================================================================== --- incubator/activemq/site/Design+Documents (original) +++ incubator/activemq/site/Design+Documents Thu Feb 2 13:10:25 2006 @@ -1,4 +1,4 @@ - + @@ -155,7 +155,7 @@
  • Test Source XRef
  • XSD
  • -

    Tools we use

    +

    Tools we use

    Feeds

    Modified: incubator/activemq/site/Discovery URL: http://svn.apache.org/viewcvs/incubator/activemq/site/Discovery?rev=374503&r1=374502&r2=374503&view=diff ============================================================================== --- incubator/activemq/site/Discovery (original) +++ incubator/activemq/site/Discovery Thu Feb 2 13:10:25 2006 @@ -1,4 +1,4 @@ - + @@ -18,7 +18,10 @@ - +
    + + +
    @@ -155,7 +158,7 @@
  • Test Source XRef
  • XSD
  • -

    Tools we use

    +

    Tools we use

    Feeds

    Modified: incubator/activemq/site/Discovery+Transport+Reference URL: http://svn.apache.org/viewcvs/incubator/activemq/site/Discovery%2BTransport%2BReference?rev=374503&r1=374502&r2=374503&view=diff ============================================================================== --- incubator/activemq/site/Discovery+Transport+Reference (original) +++ incubator/activemq/site/Discovery+Transport+Reference Thu Feb 2 13:10:25 2006 @@ -1,4 +1,4 @@ - + @@ -155,7 +155,7 @@
  • Test Source XRef
  • XSD
  • -

    Tools we use

    +

    Tools we use

    Feeds

    @@ -239,7 +239,7 @@
    Example URI

    -
    discovery:(multicast://default)?initialReconnectDelay=100
    +        
    discovery:(multicast://default)?initialReconnectDelay=100