Return-Path: X-Original-To: apmail-activemq-commits-archive@www.apache.org Delivered-To: apmail-activemq-commits-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 996466280 for ; Thu, 26 May 2011 19:37:39 +0000 (UTC) Received: (qmail 54524 invoked by uid 500); 26 May 2011 19:37:39 -0000 Delivered-To: apmail-activemq-commits-archive@activemq.apache.org Received: (qmail 54498 invoked by uid 500); 26 May 2011 19:37:39 -0000 Mailing-List: contact commits-help@activemq.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@activemq.apache.org Delivered-To: mailing list commits@activemq.apache.org Received: (qmail 54491 invoked by uid 99); 26 May 2011 19:37:39 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 26 May 2011 19:37:39 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=5.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO eris.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 26 May 2011 19:37:35 +0000 Received: by eris.apache.org (Postfix, from userid 65534) id 60560238897F; Thu, 26 May 2011 19:37:13 +0000 (UTC) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r1128056 - in /activemq/activemq-apollo/trunk: apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/ apollo-dto/src/main/java/org/apache/activemq/apollo/dto/ apollo-dto/src/test/java/org/apache/activemq/apollo/dto/ apollo-dto/src/... Date: Thu, 26 May 2011 19:37:13 -0000 To: commits@activemq.apache.org From: chirino@apache.org X-Mailer: svnmailer-1.0.8 Message-Id: <20110526193713.60560238897F@eris.apache.org> X-Virus-Checked: Checked by ClamAV on apache.org Author: chirino Date: Thu May 26 19:37:12 2011 New Revision: 1128056 URL: http://svn.apache.org/viewvc?rev=1128056&view=rev Log: rename durable_subscription(s) and ds to dsub(s) fields to have more concise and consistent naming. Modified: activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/QueueBinding.scala activemq/activemq-apollo/trunk/apollo-dto/src/main/java/org/apache/activemq/apollo/dto/DurableSubscriptionDTO.java activemq/activemq-apollo/trunk/apollo-dto/src/main/java/org/apache/activemq/apollo/dto/DurableSubscriptionDestinationDTO.java activemq/activemq-apollo/trunk/apollo-dto/src/main/java/org/apache/activemq/apollo/dto/TopicStatusDTO.java activemq/activemq-apollo/trunk/apollo-dto/src/main/java/org/apache/activemq/apollo/dto/VirtualHostDTO.java activemq/activemq-apollo/trunk/apollo-dto/src/test/java/org/apache/activemq/apollo/dto/XmlCodecTest.java activemq/activemq-apollo/trunk/apollo-dto/src/test/resources/org/apache/activemq/apollo/dto/XmlCodecTest.xml activemq/activemq-apollo/trunk/apollo-web/src/main/scala/org/apache/activemq/apollo/web/resources/BrokerResource.scala activemq/activemq-apollo/trunk/apollo-web/src/main/webapp/WEB-INF/org/apache/activemq/apollo/dto/BrokerStatusDTO.jade activemq/activemq-apollo/trunk/apollo-web/src/main/webapp/WEB-INF/org/apache/activemq/apollo/dto/TopicStatusDTO.jade activemq/activemq-apollo/trunk/apollo-web/src/main/webapp/WEB-INF/org/apache/activemq/apollo/dto/VirtualHostStatusDTO.jade activemq/activemq-apollo/trunk/apollo-website/src/documentation/management-api.md activemq/activemq-apollo/trunk/apollo-website/src/documentation/user-manual.md Modified: activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/QueueBinding.scala URL: http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/QueueBinding.scala?rev=1128056&r1=1128055&r2=1128056&view=diff ============================================================================== --- activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/QueueBinding.scala (original) +++ activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/QueueBinding.scala Thu May 26 19:37:12 2011 @@ -240,7 +240,7 @@ class DurableSubscriptionQueueBinding(va } true } - host.config.durable_subscriptions.find(matches _).getOrElse(new DurableSubscriptionDTO) + host.config.dsubs.find(matches _).getOrElse(new DurableSubscriptionDTO) } } Modified: activemq/activemq-apollo/trunk/apollo-dto/src/main/java/org/apache/activemq/apollo/dto/DurableSubscriptionDTO.java URL: http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-dto/src/main/java/org/apache/activemq/apollo/dto/DurableSubscriptionDTO.java?rev=1128056&r1=1128055&r2=1128056&view=diff ============================================================================== --- activemq/activemq-apollo/trunk/apollo-dto/src/main/java/org/apache/activemq/apollo/dto/DurableSubscriptionDTO.java (original) +++ activemq/activemq-apollo/trunk/apollo-dto/src/main/java/org/apache/activemq/apollo/dto/DurableSubscriptionDTO.java Thu May 26 19:37:12 2011 @@ -23,7 +23,7 @@ import javax.xml.bind.annotation.*; /** * @author Hiram Chirino */ -@XmlRootElement(name = "ds") +@XmlRootElement(name = "dsub") @XmlAccessorType(XmlAccessType.FIELD) public class DurableSubscriptionDTO extends QueueDTO { Modified: activemq/activemq-apollo/trunk/apollo-dto/src/main/java/org/apache/activemq/apollo/dto/DurableSubscriptionDestinationDTO.java URL: http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-dto/src/main/java/org/apache/activemq/apollo/dto/DurableSubscriptionDestinationDTO.java?rev=1128056&r1=1128055&r2=1128056&view=diff ============================================================================== --- activemq/activemq-apollo/trunk/apollo-dto/src/main/java/org/apache/activemq/apollo/dto/DurableSubscriptionDestinationDTO.java (original) +++ activemq/activemq-apollo/trunk/apollo-dto/src/main/java/org/apache/activemq/apollo/dto/DurableSubscriptionDestinationDTO.java Thu May 26 19:37:12 2011 @@ -28,7 +28,7 @@ import java.util.List; * * @author Hiram Chirino */ -@XmlRootElement(name = "durable_subscription_destination") +@XmlRootElement(name = "dsub_destination") @XmlAccessorType(XmlAccessType.FIELD) public class DurableSubscriptionDestinationDTO extends TopicDestinationDTO { Modified: activemq/activemq-apollo/trunk/apollo-dto/src/main/java/org/apache/activemq/apollo/dto/TopicStatusDTO.java URL: http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-dto/src/main/java/org/apache/activemq/apollo/dto/TopicStatusDTO.java?rev=1128056&r1=1128055&r2=1128056&view=diff ============================================================================== --- activemq/activemq-apollo/trunk/apollo-dto/src/main/java/org/apache/activemq/apollo/dto/TopicStatusDTO.java (original) +++ activemq/activemq-apollo/trunk/apollo-dto/src/main/java/org/apache/activemq/apollo/dto/TopicStatusDTO.java Thu May 26 19:37:12 2011 @@ -48,6 +48,6 @@ public class TopicStatusDTO extends Stri /** * Ids of all queues that are associated with the destination */ - @XmlElement(name="durable_subscription") - public List durable_subscriptions = new ArrayList(); + @XmlElement(name="dsub") + public List dsubs = new ArrayList(); } \ No newline at end of file Modified: activemq/activemq-apollo/trunk/apollo-dto/src/main/java/org/apache/activemq/apollo/dto/VirtualHostDTO.java URL: http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-dto/src/main/java/org/apache/activemq/apollo/dto/VirtualHostDTO.java?rev=1128056&r1=1128055&r2=1128056&view=diff ============================================================================== --- activemq/activemq-apollo/trunk/apollo-dto/src/main/java/org/apache/activemq/apollo/dto/VirtualHostDTO.java (original) +++ activemq/activemq-apollo/trunk/apollo-dto/src/main/java/org/apache/activemq/apollo/dto/VirtualHostDTO.java Thu May 26 19:37:12 2011 @@ -61,8 +61,8 @@ public class VirtualHostDTO extends Serv /** * Holds the configuration for the queues. */ - @XmlElement(name="ds") - public ArrayList durable_subscriptions = new ArrayList(); + @XmlElement(name="dsub") + public ArrayList dsubs = new ArrayList(); /** * Should connections get regroups so they get serviced by the same thread? Modified: activemq/activemq-apollo/trunk/apollo-dto/src/test/java/org/apache/activemq/apollo/dto/XmlCodecTest.java URL: http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-dto/src/test/java/org/apache/activemq/apollo/dto/XmlCodecTest.java?rev=1128056&r1=1128055&r2=1128056&view=diff ============================================================================== --- activemq/activemq-apollo/trunk/apollo-dto/src/test/java/org/apache/activemq/apollo/dto/XmlCodecTest.java (original) +++ activemq/activemq-apollo/trunk/apollo-dto/src/test/java/org/apache/activemq/apollo/dto/XmlCodecTest.java Thu May 26 19:37:12 2011 @@ -47,7 +47,7 @@ public class XmlCodecTest { assertEquals("queue1", host.queues.get(0).id); assertEquals("topic1", host.topics.get(0).id); - assertEquals("durable_subscription1", host.durable_subscriptions.get(0).id); + assertEquals("durable_subscription1", host.dsubs.get(0).id); assertNotNull(dto.acl); assertTrue(dto.acl.admins.contains(new PrincipalDTO("hiram"))); Modified: activemq/activemq-apollo/trunk/apollo-dto/src/test/resources/org/apache/activemq/apollo/dto/XmlCodecTest.xml URL: http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-dto/src/test/resources/org/apache/activemq/apollo/dto/XmlCodecTest.xml?rev=1128056&r1=1128055&r2=1128056&view=diff ============================================================================== --- activemq/activemq-apollo/trunk/apollo-dto/src/test/resources/org/apache/activemq/apollo/dto/XmlCodecTest.xml (original) +++ activemq/activemq-apollo/trunk/apollo-dto/src/test/resources/org/apache/activemq/apollo/dto/XmlCodecTest.xml Thu May 26 19:37:12 2011 @@ -30,7 +30,7 @@ - + Modified: activemq/activemq-apollo/trunk/apollo-web/src/main/scala/org/apache/activemq/apollo/web/resources/BrokerResource.scala URL: http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-web/src/main/scala/org/apache/activemq/apollo/web/resources/BrokerResource.scala?rev=1128056&r1=1128055&r2=1128056&view=diff ============================================================================== --- activemq/activemq-apollo/trunk/apollo-web/src/main/scala/org/apache/activemq/apollo/web/resources/BrokerResource.scala (original) +++ activemq/activemq-apollo/trunk/apollo-web/src/main/scala/org/apache/activemq/apollo/web/resources/BrokerResource.scala Thu May 26 19:37:12 2011 @@ -59,6 +59,7 @@ case class BrokerResource() extends Reso result.current_time = System.currentTimeMillis result.state = broker.service_state.toString result.state_since = broker.service_state.since + result.version = Broker.version broker.virtual_hosts.values.foreach{ host=> // TODO: may need to sync /w virtual host's dispatch queue @@ -239,7 +240,7 @@ case class BrokerResource() extends Reso } } - @GET @Path("virtual-hosts/{id}/ds/{name:.*}") + @GET @Path("virtual-hosts/{id}/dsubs/{name:.*}") def durable_subscription(@PathParam("id") id : String, @PathParam("name") name : String, @QueryParam("entries") entries:Boolean):QueueStatusDTO = { with_virtual_host(id) { host => val router:LocalRouter = host @@ -264,7 +265,7 @@ case class BrokerResource() extends Reso node.durable_subscriptions.foreach { q => - rc.durable_subscriptions.add(q.id) + rc.dsubs.add(q.id) } node.consumers.foreach { consumer => Modified: activemq/activemq-apollo/trunk/apollo-web/src/main/webapp/WEB-INF/org/apache/activemq/apollo/dto/BrokerStatusDTO.jade URL: http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-web/src/main/webapp/WEB-INF/org/apache/activemq/apollo/dto/BrokerStatusDTO.jade?rev=1128056&r1=1128055&r2=1128056&view=diff ============================================================================== --- activemq/activemq-apollo/trunk/apollo-web/src/main/webapp/WEB-INF/org/apache/activemq/apollo/dto/BrokerStatusDTO.jade (original) +++ activemq/activemq-apollo/trunk/apollo-web/src/main/webapp/WEB-INF/org/apache/activemq/apollo/dto/BrokerStatusDTO.jade Thu May 26 19:37:12 2011 @@ -17,8 +17,11 @@ - val helper = new org.apache.activemq.apollo.web.resources.ViewHelper - import helper._ +h1 Apache ActiveMQ Apollo #{version} + p state: #{state} #{ uptime(state_since) } ago + - if( state == "STARTED" ) form(method="post" action={path("action/shutdown")}) input(type="submit" value="shutdown") Modified: activemq/activemq-apollo/trunk/apollo-web/src/main/webapp/WEB-INF/org/apache/activemq/apollo/dto/TopicStatusDTO.jade URL: http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-web/src/main/webapp/WEB-INF/org/apache/activemq/apollo/dto/TopicStatusDTO.jade?rev=1128056&r1=1128055&r2=1128056&view=diff ============================================================================== --- activemq/activemq-apollo/trunk/apollo-web/src/main/webapp/WEB-INF/org/apache/activemq/apollo/dto/TopicStatusDTO.jade (original) +++ activemq/activemq-apollo/trunk/apollo-web/src/main/webapp/WEB-INF/org/apache/activemq/apollo/dto/TopicStatusDTO.jade Thu May 26 19:37:12 2011 @@ -47,6 +47,6 @@ ul h4 Durable Subscribers ul - - for( x <- durable_subscriptions ) + - for( x <- dsubs ) li a(href={ path("../../ds/"+x) }) #{x} Modified: activemq/activemq-apollo/trunk/apollo-web/src/main/webapp/WEB-INF/org/apache/activemq/apollo/dto/VirtualHostStatusDTO.jade URL: http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-web/src/main/webapp/WEB-INF/org/apache/activemq/apollo/dto/VirtualHostStatusDTO.jade?rev=1128056&r1=1128055&r2=1128056&view=diff ============================================================================== --- activemq/activemq-apollo/trunk/apollo-web/src/main/webapp/WEB-INF/org/apache/activemq/apollo/dto/VirtualHostStatusDTO.jade (original) +++ activemq/activemq-apollo/trunk/apollo-web/src/main/webapp/WEB-INF/org/apache/activemq/apollo/dto/VirtualHostStatusDTO.jade Thu May 26 19:37:12 2011 @@ -20,7 +20,7 @@ .breadcumbs a(href={strip_resolve("..")}) Back -h1 Virtual Host X: #{id} +h1 Virtual Host: #{id} p state: #{state} #{ uptime(state_since) } ago Modified: activemq/activemq-apollo/trunk/apollo-website/src/documentation/management-api.md URL: http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-website/src/documentation/management-api.md?rev=1128056&r1=1128055&r2=1128056&view=diff ============================================================================== --- activemq/activemq-apollo/trunk/apollo-website/src/documentation/management-api.md (original) +++ activemq/activemq-apollo/trunk/apollo-website/src/documentation/management-api.md Thu May 26 19:37:12 2011 @@ -331,7 +331,7 @@ Results in a [Topic Status](./api/apollo "label":"/127.0.0.1:52773" } ], - "durable_subscriptions":[ + "dsubs":[ "mysubname" ] } @@ -368,7 +368,7 @@ Results in a [Broker Configuration](./ap "purge_on_startup":null, "topics":[], "queues":[], - "durable_subscriptions":[], + "dsubs":[], "regroup_connections":null, "acl":{ "connects":[ Modified: activemq/activemq-apollo/trunk/apollo-website/src/documentation/user-manual.md URL: http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-website/src/documentation/user-manual.md?rev=1128056&r1=1128055&r2=1128056&view=diff ============================================================================== --- activemq/activemq-apollo/trunk/apollo-website/src/documentation/user-manual.md (original) +++ activemq/activemq-apollo/trunk/apollo-website/src/documentation/user-manual.md Thu May 26 19:37:12 2011 @@ -184,7 +184,7 @@ A `virtual_host` element may be configur will be purged when the broker is started up. The `virtual_host` can also define multiple `topic`, `queue`, and -`durable_subscription` elements to secure or tune how message delivery works +`dsub` elements to secure or tune how message delivery works for different topics or queues. If none are defined, then sensible default settings are used which allows destinations to be auto created as they get accessed by applications. @@ -250,7 +250,7 @@ A `topic` element may be configured with ##### Durable Subscriptions When a new durable subscription is first created in the broker, it's -configuration will be determined by the first `durable_subscription` element +configuration will be determined by the first `dsub` element which matches the durable subscription being created. The attributes matched against are: @@ -260,7 +260,7 @@ against are: * `subscription_id` : This specify which subscription id this configuration should match. -A `durable_subscription` element may be configured with all the +A `dsub` element may be configured with all the attributes available on the `queue` element. ##### Unified Destinations @@ -542,7 +542,7 @@ Example of customizing the principal kin User authorization to broker resources is accomplished by configuring an access control list using an `acl` element on the `broker`, `connector`, -`virtual_host`, `topic`, `durable_subscription`, or `queue` resources. The +`virtual_host`, `topic`, `dsub`, or `queue` resources. The acl defines which principals are allowed or denied access to perform actions against the resources. An example of `acl` is shown below: @@ -656,19 +656,18 @@ The type of resource being secured deter can be secured by the acl rule entries. Here is listing of which actions can be secured on which resources: -* `broker`, `virtual_host`, `topic`, and `queue` +* `broker`, `virtual_host`, `topic`, `queue`, and `dsub` * `admin` : use of the administrative web interface * `monitor` : read only use of the administrative web interface * `connector` and `virtual_host` * `connect` : allows connections to the connector or virtual host -* `topic` and `queue` and `durable_subscription` +* `topic`, `queue` and `dsub` * `create` : allows creation * `destroy` : allows destruction -* `topic` and `queue` * `send` : allows the user to send to the destination * `receive` : allows the user to send to do non_destructive read from the destination -* `queue` +* `queue` and `dsub` * `consume` : allows the user to do destructive reads against the queue. #### Encrypting Passwords in the Configuration