Git Product home page Git Product logo

edson-a-soares / producer_consumer Goto Github PK

View Code? Open in Web Editor NEW
1.0 1.0 0.0 1.63 MB

The Consumer/Producer problem in a real application using Boost and Poco.

Home Page: https://bit.ly/3ifBcDr

License: Apache License 2.0

CMake 13.86% C++ 84.67% Shell 0.27% Dockerfile 1.05% C 0.15%
boost-libraries poco-libraries cpp-14 shared-memory bounded-buffer multiprocessor-programming producer-consumer modern-cpp dockerized-infrastructure architectural-patterns

producer_consumer's Introduction

Build Status codecov

Application dependencies

  • CMake 3.7 or newer
  • A C++14 compiler (GCC 6.3 or newer)
  • Boost 1.70.0
  • Poco C++ Libraries 1.9
  • Google Test
  • Google Mock
  • LCOV
  • GCOV
  • Doxygen

Application basic directory structure

The basic directory structure is as follows:


bin/                    all executables
lib/                    all libraries
data/                   all sort of application supporting files
    source/             source files that will be generated in runtime
    templates/          templates for the messages exchanged between the processes

scripts/                utility scripts for building
cmake/                  supporting files for CMake
docs/                   any additional documentation

Foundation/             project and make/build files for the Foundation module
    include/            all header files for the Foundation module
        Adapter/        all ConsumerDaemon module adapters
        Foundation/     all ConsumerDaemon module ports
    src/                source files for the Foundation module
    test/               project and make/build files for the Foundation testsuite
        Resources/      any supporting files for the tests
        Integration/    source files for the Foundation integration tests
        Unit/           source files for the Foundation unit tests

Consumer/               project and make/build files for the Consumer module
    include/            all header files for the Consumer module
        Adapter/        all Consumer module adapters
        Consumer/       all Consumer module ports
    src/                source files for the Consumer module
    test/               project and make/build files for the Consumer testsuite
        Resources/      any supporting files for the tests
        Integration/    source files for the Consumer integration tests
        Unit/           source files for the Consumer unit tests
        E2E/            source files for the Consumer end-to-end tests

ConsumerDaemon/         project and make/build files for the ConsumerDaemon module
    include/            all header files for the ConsumerDaemon module
        Adapter/        all ConsumerDaemon module adapters
        ConsumerDaemon/ all ConsumerDaemon module ports
    src/                source files for the ConsumerDaemon module
    test/               project and make/build files for the ConsumerDaemon testsuite
        Resources/      any supporting files for the tests
        Integration/    source files for the ConsumerDaemon integration tests
        Unit/           source files for the ConsumerDaemon unit tests
        E2E/            source files for the ConsumerDaemon end-to-end tests

Producer/               project and make/build files for the Producer module
    include/            all header files for the Producer module
        Adapter/        all Producer module adapters
        Producer/       all Producer module ports
    src/                source files for the Producer module
    test/               project and make/build files for the Producer testsuite
        Resources/      any supporting files for the tests
        Integration/    source files for the Producer integration tests
        Unit/           source files for the Producer unit tests
        E2E/            source files for the Producer end-to-end tests

Running with Docker

docker build . -t producer-consumer
docker run --name producer-consumer -p8080:80 -d producer-consumer
docker exec -it producer-consumer /bin/bash
docker stop producer-consumer

Testing

docker build . -t producer-consumer-test -f Test.Dockerfile
docker run producer-consumer-test /bin/bash -c "cd /tmp/producer_consumer; ./scripts/run-all-tests.sh"
Running coverage HTML report
./scripts/run-all-tests.sh
./scripts/run-coverage-html-report.sh

Useful links

producer_consumer's People

Contributors

edson-a-soares avatar

Stargazers

 avatar

Watchers

 avatar

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.