Giter Site home page Giter Site logo

conduit's Introduction

Conduit

Discover why functional languages, such as Elixir, are ideally suited to building applications following the command query responsibility segregation and event sourcing (CQRS/ES) pattern.

Conduit is a blogging platform, an exemplary Medium.com clone, built as a Phoenix web application.

This is the full source code to accompany the "Building Conduit" eBook.

This book is for anyone who has an interest in CQRS/ES and Elixir. It demonstrates step-by-step how to build an Elixir application implementing the CQRS/ES pattern using the Commanded open source library.


MIT License

Build Status


Getting started

Conduit is an Elixir application using Phoenix 1.4 and PostgreSQL for persistence.

Prerequisites

You must install the following dependencies before starting:

Configuring Conduit

  1. Clone the Git repo from GitHub:

    $ git clone https://github.com/slashdotdash/conduit.git
  2. Install mix dependencies:

    $ cd conduit
    $ mix deps.get
  3. Create the event store database:

    $ mix do event_store.create, event_store.init
  4. Create the read model store database:

    $ mix do ecto.create, ecto.migrate
  5. Run the Phoenix server:

    $ mix phx.server

This will start the web server on localhost, port 4000: http://0.0.0.0:4000

This application only includes the API back-end, serving JSON requests.

You need to choose a front-end from those listed in the RealWorld repo. Follow the installation instructions for the front-end you select. The most popular implementations are listed below.

Any of these front-ends should integrate with the Conduit back-end due to their common API.

Running the tests

MIX_ENV=test mix event_store.create
MIX_ENV=test mix event_store.init
MIX_ENV=test mix ecto.create
MIX_ENV=test mix ecto.migrate
mix test

Need help?

Please submit an issue if you encounter a problem, or need support.

conduit's People

Contributors

barbariccorgi avatar gordalina avatar gregjohnsonsaltaire avatar slashdotdash avatar tt 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.