ActiveMQ
ActiveMQ is part of our fundraising architecture. It stands between civicrm and our operational cluster running the Donation Gateway extension providing a new payment gateway.
It's currently living on silicon, a member of frack.eqiad.wmnet.
Software
Currently we're running ActiveMQ 5.9.0 for our installation. The software needs to be puppetized but in the interim is located in /usr/local/apache-activemq, symlinked to the current version. The configuration is located in /etc/activemq.conf.
Configuration
Config files
There are two important config files for ActiveMQ:
- /usr/local/apache-activemq/conf/actibemq.xml - This contains the specific conncetion information for activemq (eg defining transportConncetors). This gets loaded by activemq by default when activemq is invoked.
- /etc/activemq.conf - This contains some environment variables for activemq
Connectors
<transportConnector name="stomp" uri="stomp://0.0.0.0:61613?transport.closeAsync=false"/>
Start/Stop
/etc/init.d/activemq {start|stop}
note: if stop doesn't work then just killall java
Escalation
Activity
Check /var/log/activemq.log for what's going on.
or to view in a web browser:
Log in to tellurium. ex
ssh khorn@tellurium.wikimedia.org -L 4000:silicon.frack.eqiad.wmnet:8161
Login with your default terminal username
ssh tellurium.wikimedia.org -L 4000:silicon.frack.eqiad.wmnet:8161
Connect to ActiveMQ
http://localhost:4000/admin/queues.jsp
Testing donation consumption
- Follow the steps above to pull up the web interface.
- Under the "Operations" column click "Send to" for the "test_donations" queue.
- Insert a test message and click send. (The message body will consist of a JSON string. You can check the logs to see examples.)
- ssh to aluminium (or wherever civicrm-dev is running from).
- cd to the /srv/org.wikimedia.civicrm-dev directory
- run "drush qc" to consume the queue
- If there are no errors, log into https://civicrm-dev.wikimedia.org/civicrm/ and look for the donation.