Package org.apache.qpid.server.model

Examples of org.apache.qpid.server.model.LifetimePolicy


        attributes = new HashMap<String, Object>(attributes);

        String         name     = MapValueConverter.getStringAttribute(Exchange.NAME, attributes, null);
        State          state    = MapValueConverter.getEnumAttribute(State.class, Exchange.STATE, attributes, State.ACTIVE);
        boolean        durable  = MapValueConverter.getBooleanAttribute(Exchange.DURABLE, attributes, false);
        LifetimePolicy lifetime = MapValueConverter.getEnumAttribute(LifetimePolicy.class, Exchange.LIFETIME_POLICY, attributes, LifetimePolicy.PERMANENT);
        String         type     = MapValueConverter.getStringAttribute(Exchange.TYPE, attributes, null);
        long           ttl      = MapValueConverter.getLongAttribute(Exchange.TIME_TO_LIVE, attributes, 0l);

        attributes.remove(Exchange.NAME);
        attributes.remove(Exchange.STATE);
View Full Code Here


        }

        String         name     = MapValueConverter.getStringAttribute(Queue.NAME, attributes, null);
        State          state    = MapValueConverter.getEnumAttribute(State.class, Queue.STATE, attributes, State.ACTIVE);
        boolean        durable  = MapValueConverter.getBooleanAttribute(Queue.DURABLE, attributes, false);
        LifetimePolicy lifetime = MapValueConverter.getEnumAttribute(LifetimePolicy.class, Queue.LIFETIME_POLICY, attributes, LifetimePolicy.PERMANENT);
        long           ttl      = MapValueConverter.getLongAttribute(Queue.TIME_TO_LIVE, attributes, 0l);
        boolean        exclusive= MapValueConverter.getBooleanAttribute(Queue.EXCLUSIVE, attributes, false);

        attributes.remove(Queue.NAME);
        attributes.remove(Queue.STATE);
View Full Code Here

        // In the Java Broker LifetimePolicy may be PERMANENT, DELETE_ON_CONNECTION_CLOSE,
        // DELETE_ON_SESSION_END, DELETE_ON_NO_OUTBOUND_LINKS, DELETE_ON_NO_LINKS, IN_USE
        // We map these to a boolean value to be consistent with the C++ Broker QMF value.
        // TODO The C++ and Java Brokers should really return consistent information.
        LifetimePolicy lifetimePolicy = (LifetimePolicy)_exchange.getAttribute("lifetimePolicy");
        boolean autoDelete = (lifetimePolicy != LifetimePolicy.PERMANENT) ? true : false;

        // TODO vhostRef - currently just use its name to try and get things working with standard command line tools.

        setValue("name", _name);
View Full Code Here

        // In the Java Broker LifetimePolicy may be PERMANENT, DELETE_ON_CONNECTION_CLOSE,
        // DELETE_ON_SESSION_END, DELETE_ON_NO_OUTBOUND_LINKS, DELETE_ON_NO_LINKS, IN_USE
        // We map these to a boolean value to be consistent with the C++ Broker QMF value.
        // TODO The C++ and Java Brokers should really return consistent information.
        LifetimePolicy lifetimePolicy = (LifetimePolicy)_queue.getAttribute("lifetimePolicy");
        boolean autoDelete = (lifetimePolicy != LifetimePolicy.PERMANENT) ? true : false;

        // In the Java Broker exclusivity may be NONE, SESSION, CONNECTION, CONTAINER, PRINCIPAL, LINK
        // We map these to a boolean value to be consistent with the C++ Broker QMF value.
        // TODO The C++ and Java Brokers should really return consistent information.
View Full Code Here

        attributes = new HashMap<String, Object>(attributes);

        String         name     = MapValueConverter.getStringAttribute(Exchange.NAME, attributes, null);
        State          state    = MapValueConverter.getEnumAttribute(State.class, Exchange.STATE, attributes, State.ACTIVE);
        boolean        durable  = MapValueConverter.getBooleanAttribute(Exchange.DURABLE, attributes, false);
        LifetimePolicy lifetime = MapValueConverter.getEnumAttribute(LifetimePolicy.class, Exchange.LIFETIME_POLICY, attributes, LifetimePolicy.PERMANENT);
        String         type     = MapValueConverter.getStringAttribute(Exchange.TYPE, attributes, null);
        long           ttl      = MapValueConverter.getLongAttribute(Exchange.TIME_TO_LIVE, attributes, 0l);

        attributes.remove(Exchange.NAME);
        attributes.remove(Exchange.STATE);
View Full Code Here

        }

        String         name     = MapValueConverter.getStringAttribute(Queue.NAME, attributes, null);
        State          state    = MapValueConverter.getEnumAttribute(State.class, Queue.STATE, attributes, State.ACTIVE);
        boolean        durable  = MapValueConverter.getBooleanAttribute(Queue.DURABLE, attributes, false);
        LifetimePolicy lifetime = MapValueConverter.getEnumAttribute(LifetimePolicy.class, Queue.LIFETIME_POLICY, attributes, LifetimePolicy.PERMANENT);
        long           ttl      = MapValueConverter.getLongAttribute(Queue.TIME_TO_LIVE, attributes, 0l);
        boolean        exclusive= MapValueConverter.getBooleanAttribute(Queue.EXCLUSIVE, attributes, false);

        attributes.remove(Queue.NAME);
        attributes.remove(Queue.STATE);
View Full Code Here

                final UUID id = UUIDGenerator.generateQueueUUID(queueName, virtualHost.getName());

                arguments.put(Queue.ID, id);
                arguments.put(Queue.NAME, queueName);

                LifetimePolicy lifetime;
                if(autoDelete)
                {
                    lifetime = exclusive ? LifetimePolicy.DELETE_ON_SESSION_END
                            : LifetimePolicy.DELETE_ON_NO_OUTBOUND_LINKS;
                }
View Full Code Here

                final UUID id = UUID.randomUUID();

                arguments.put(Queue.ID, id);
                arguments.put(Queue.NAME, queueName);

                LifetimePolicy lifetime;
                if(autoDelete)
                {
                    lifetime = exclusive ? LifetimePolicy.DELETE_ON_SESSION_END
                            : LifetimePolicy.DELETE_ON_NO_OUTBOUND_LINKS;
                }
View Full Code Here

        final String queueNameString = AMQShortString.toString(queueName);
        attributes.put(Queue.NAME, queueNameString);
        attributes.put(Queue.ID, UUIDGenerator.generateQueueUUID(queueNameString, virtualHost.getName()));
        attributes.put(Queue.DURABLE, durable);

        LifetimePolicy lifetimePolicy;
        ExclusivityPolicy exclusivityPolicy;

        if(exclusive)
        {
            lifetimePolicy = autoDelete
View Full Code Here

        final String queueNameString = AMQShortString.toString(queueName);
        attributes.put(Queue.NAME, queueNameString);
        attributes.put(Queue.ID, UUID.randomUUID());
        attributes.put(Queue.DURABLE, durable);

        LifetimePolicy lifetimePolicy;
        ExclusivityPolicy exclusivityPolicy;

        if(exclusive)
        {
            lifetimePolicy = autoDelete
View Full Code Here

TOP

Related Classes of org.apache.qpid.server.model.LifetimePolicy

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.