Git Product home page Git Product logo

amqprotocol's People

Contributors

bimawa avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

amqprotocol's Issues

Queue bindToExchange Throwing Error

I am getting the following error when the Queue's bindToExchange is executed:

2013-02-28 09:24:06.782 RabbitMQTest[9819:c07] AMQPException: Failed to bind queue to exchange: No such file or directory

I have an example application that runs perfectly that uses the straight C API and appears to call the same methods with the same parameters as AMQP classes. As you can see by the code, I am using a durable queue & exchange that does not get autodeleted.

Here's my code fragment:

NSError *error;
AMQPConnection *connection = [[AMQPConnection alloc] init];

[connection connectToHost:_host.text onPort:[_port.text integerValue] error:&error];
if (error.code != 0)
{
    _output.text = [NSString stringWithFormat:@"%@\n%@", _output.text, error.localizedDescription];
    return;
}

[connection loginAsUser:@"guest" withPasswort:@"guest" onVHost:VIRTUAL_HOST error:&error];

AMQPChannel *channel = [connection openChannel];

if (channel)
{
    AMQPExchange *exchange = [[AMQPExchange alloc] initDirectExchangeWithName:EXCHANGE_NAME onChannel:channel isPassive:NO isDurable:YES getsAutoDeleted:NO error:&error];
    AMQPQueue *queue = [[AMQPQueue alloc] initWithName:QUEUE_NAME onChannel:channel isPassive:NO isExclusive:NO isDurable:YES getsAutoDeleted:NO error:&error];

    [queue bindToExchange:exchange withKey:BINDING_KEY error:&error];

error "Failed to login on server."

AMQPConnection _connection = [[AMQPConnection alloc] init];
NSError *error,_error1;
[connection connectToHost:server onPort:port error:&error];
[connection loginAsUser:login withPasswort:password onVHost:@"/" error:&error1];
if (error1) {
NSLog(@"%@", error1);
}
2014-06-30 13:14:11.438 AZApp[62979:60b] Error Domain=AMQPConnection Code=-3 "Failed to login on server." UserInfo=0x99bb0e0 {NSLocalizedDescription=Failed to login on server.}
sending:
00000000: 01 00 01 00 00 00 05 00 : 14 00 0A 00 CE .............
0000000D:

I've checked server, port, login and password. They are OK and working on android device. Why does it shows "Failed to login on server."?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.