Ignore:
Timestamp:
07/04/13 16:45:14 (11 years ago)
Author:
stoda
Message:

ParameterQueues? changed, added some properties to modify the queues

Location:
trunk/src/main/java/omq/client/proxy
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/main/java/omq/client/proxy/MultiProxymq.java

    r75 r77  
    4141                replyQueueName = env.getProperty(ParameterQueue.RPC_REPLY_QUEUE);
    4242                exchange = multi + uid;
    43                 serializerType = env.getProperty(ParameterQueue.SERIALIZER_NAME, Serializer.JAVA);
     43                serializerType = env.getProperty(ParameterQueue.PROXY_SERIALIZER, Serializer.JAVA);
    4444        }
    4545
  • trunk/src/main/java/omq/client/proxy/Proxymq.java

    r76 r77  
    5151        private transient Serializer serializer;
    5252        private transient Properties env;
     53        private transient Integer deliveryMode = null;
    5354        private transient Map<String, byte[]> results;
    5455
     
    9495
    9596                // set the serializer type
    96                 serializerType = env.getProperty(ParameterQueue.SERIALIZER_NAME, Serializer.JAVA);
     97                serializerType = env.getProperty(ParameterQueue.PROXY_SERIALIZER, Serializer.JAVA);
     98                if (env.getProperty(ParameterQueue.DELIVERY_MODE) != null) {
     99                        deliveryMode = Integer.parseInt(env.getProperty(ParameterQueue.DELIVERY_MODE));
     100                }
    97101
    98102                // Create a new hashmap and registry it in rListener
     
    143147
    144148                // Add the correlation ID and create a replyTo property
    145                 BasicProperties props = new BasicProperties.Builder().appId(uid).correlationId(corrId).replyTo(replyQueueName).type(serializerType).build();
     149                BasicProperties props = new BasicProperties.Builder().appId(uid).correlationId(corrId).replyTo(replyQueueName).type(serializerType)
     150                                .deliveryMode(deliveryMode).build();
    146151
    147152                // Publish the message
    148153                byte[] bytesRequest = serializer.serialize(serializerType, request);
    149154                broker.getChannel().basicPublish(exchange, routingkey, props, bytesRequest);
    150                 logger.debug("Proxymq: " + uid + " invokes " + request.getMethod() + ", corrID" + corrId + ", exchange: " + exchange + ", replyQueue: "
    151                                 + replyQueueName + ", serializerType: " + serializerType + ", multi call: " + request.isMulti() + ", async call: " + request.isAsync());
     155                logger.debug("Proxymq: " + uid + " invokes '" + request.getMethod() + "' , corrID: " + corrId + ", exchange: " + exchange + ", replyQueue: "
     156                                + replyQueueName + ", serializerType: " + serializerType + ", multi call: " + request.isMulti() + ", async call: " + request.isAsync()
     157                                + ", delivery mode: " + deliveryMode);
    152158        }
    153159
Note: See TracChangeset for help on using the changeset viewer.