Examples of QmfData


Examples of org.apache.qpid.qmf2.common.QmfData

            MethodCallWorkItem item = (MethodCallWorkItem)wi;
            MethodCallParams methodCallParams = item.getMethodCallParams();
            String methodName = methodCallParams.getName();
            ObjectId objectId = methodCallParams.getObjectId();

            QmfData inArgs = methodCallParams.getArgs();
            ObjectId controlAddress = _control.getObjectId();

            if (objectId.equals(controlAddress))
            {
                if (methodName.equals("processPayload"))
                {
                    System.out.println("Invoked processPayload method");

                    byte[] parameter = inArgs.getValue("parameter");
                    System.out.println("payload size = " + parameter.length);

                    QmfData outArgs = new QmfData();
                    outArgs.setValue("return", parameter);
                    _agent.methodResponse(methodName, item.getHandle(), outArgs, null);
                }
            }
        }
    }
View Full Code Here

Examples of org.apache.qpid.qmf2.common.QmfData

                System.out.println("No broker QmfConsoleData returned");
                System.exit(1);
            }

            QmfConsoleData broker = brokers.get(0);
            QmfData arguments = new QmfData();
            arguments.setValue("type", "queue");

            for (int i = 0; i < 300; i++)
            {
                arguments.setValue("name", "test " + i);

                try
                {
                    broker.invokeMethod("create", arguments);
                }
View Full Code Here

Examples of org.apache.qpid.qmf2.common.QmfData

        if (_altExchange != null)
        {
            properties.put("alternate-exchange", _altExchange);
        }

        QmfData arguments = new QmfData();
        arguments.setValue("type", "exchange");
        arguments.setValue("name", args[1]);
        arguments.setValue("properties", properties);

        try
        {
            _broker.invokeMethod("create", arguments);
        }
View Full Code Here

Examples of org.apache.qpid.qmf2.common.QmfData

        if (_flowResumeCount > 0)
        {
            properties.put(FLOW_RESUME_COUNT, _flowResumeCount);
        }

        QmfData arguments = new QmfData();
        arguments.setValue("type", "queue");
        arguments.setValue("name", args[0]);
        arguments.setValue("properties", properties);

        try
        {
            _broker.invokeMethod("create", arguments);
        }
View Full Code Here

Examples of org.apache.qpid.qmf2.common.QmfData

            {
                QmfConsoleData control = controls.get(0);

                // ********** Invoke processPayload nethod **********
                System.out.println("Testing invokeMethod(processPayload, args)");
                QmfData inArgs = new QmfData();
                inArgs.setValue("parameter", new byte[150000000]);

                MethodResult results = control.invokeMethod("processPayload", inArgs);
                if (!results.succeeded())
                {
                    System.out.println("processPayload returned an exception object");
View Full Code Here

Examples of org.apache.qpid.qmf2.common.QmfData

        if (args.length < 1)
        {
            usage();
        }

        QmfData arguments = new QmfData();
        arguments.setValue("type", "exchange");
        arguments.setValue("name", args[0]);

        try
        {
            _broker.invokeMethod("delete", arguments);
        }
View Full Code Here

Examples of org.apache.qpid.qmf2.common.QmfData

                    }
                }
            }
        }

        QmfData arguments = new QmfData();
        arguments.setValue("type", "queue");
        arguments.setValue("name", args[0]);

        try
        {
            _broker.invokeMethod("delete", arguments);
        }
View Full Code Here

Examples of org.apache.qpid.qmf2.common.QmfData

            response.setStringProperty("method", "response");
            response.setStringProperty("qmf.opcode", "_exception");
            response.setStringProperty("qmf.agent", _name);
            response.setStringProperty("qpid.subject", handle.getRoutingKey());

            QmfData exception = new QmfData();
            exception.setValue("error_text", message);
            response.setObject("_values", exception.mapEncode());
            sendResponse(handle, response);
        }
        catch (JMSException jmse)
        {
            _log.info("JMSException {} caught in handleLocateRequest()", jmse.getMessage());
View Full Code Here

Examples of org.apache.qpid.qmf2.common.QmfData

        if (args.length > 2)
        {
            bindingIdentifier = bindingIdentifier + "/" + args[2];
        }

        QmfData arguments = new QmfData();
        arguments.setValue("type", "binding");
        arguments.setValue("name", bindingIdentifier);
        arguments.setValue("properties", properties);

        try
        {
            _broker.invokeMethod("create", arguments);
        }
View Full Code Here

Examples of org.apache.qpid.qmf2.common.QmfData

            }
            else if (opcode.equals("_subscribe_cancel_indication"))
            {
                if (AMQPMessage.isAMQPMap(message))
                {
                    QmfData qmfSubscribe = new QmfData(AMQPMessage.getMap(message));
                    String subscriptionId = qmfSubscribe.getStringValue("_subscription_id");
                    if (this instanceof AgentExternal)
                    {
                        _eventListener.onEvent(new UnsubscribeRequestWorkItem(subscriptionId));
                    }
                    else
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.