Coder Social home page Coder Social logo

rabbitmq-functionapp's Introduction

Prerequisites

Although, the versions listed below are not strict requirements, if in case a particular command fails at your end, just make sure that your tool's version is not far off.

> docker --version
Docker version 20.10.12, build e91ed57

> dotnet --version
6.0.101

> func version
4.0.3971

Test Instructions

  1. Run RabbitMQ Docker container (Reference: https://www.rabbitmq.com/download.html).

    > docker run --interactive --tty --rm --name rabbitmq --publish 5672:5672 --publish 15672:15672 rabbitmq:3-management
  2. Login to http://localhost:15672. with guest/guest as username/password.

  3. Open page http://localhost:15672/#/queues. Add queues inputQueue and outputQueue. Use default options.

  4. In another console, start this Function App locally.

    > func start
  5. Open page http://localhost:15672/#/queues/%2F/inputQueue and publish message World to queue.

  6. Verify that the event shows up in the Function App logs.

    [2022-01-28T11:13:24.838Z] Executing 'RabbitMqExample' (Reason='RabbitMQ message detected from queue: inputQueue at 2022-01-28 16:43:24', Id=de09cdcf-4c14-4fba-9cfa-fb0c6f6316df)
    [2022-01-28T11:13:24.850Z] Message received: World.
    [2022-01-28T11:13:24.875Z] Executed 'RabbitMqExample' (Succeeded, Id=de09cdcf-4c14-4fba-9cfa-fb0c6f6316df, Duration=73ms)
    
  7. Open page http://localhost:15672/#/queues/%2F/outputQueue and get the message from queue. The payload should be Hello, World..

  8. Stop the function app and stop/remove the Docker container by pressing Ctrl+C in both console windows.

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.