Code Monkey home page Code Monkey logo

akka-persistence-jdbc-play's Introduction

#akka-persistence-jdbc-play A small example how to use the akka-persistence with the (Typesafe Play)[https://www.playframework.com/].

Please have the following installed:

Type the following on a console:

ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
brew update

(brew cask)[http://caskroom.io/]

Type the following on a console:

brew install caskroom/cask/brew-cask
brew tap caskroom/versions
brew cask install java
brew cask install java6
brew cask install java7
brew cask install boot2docker
brew cask install virtualbox

Sofware!

And more software, type the following:

brew install scala
brew install sbt
brew install typesafe-activator
brew install boot2docker
brew install docker-compose

Optionally

If you wish, some other tools I like:

brew install httpie
brew install mc

Upgrading packages

The nice thing about any package manager, and brew is just another package manager, is that you don't have to manage the versioning of the packages yourself. To update/upgrade, just type brew update and brew upgrade to have the package manager check the versions, the dependencies and do it all for you. How nice is that!

brew update
brew upgrade

Install the VirtualBox extensions pack

First install the (Virtualbox extension pack)[https://www.virtualbox.org/wiki/Downloads] from the downloads page, and just click on the download when finished. This will launch VirtualBox which will ask for your password to install it.

Initialize boot2docker

Side note, why not docker-machine? Let it ripe a bit more :-)

Initialize boot2docker. I like to tweak it a bit. For development I like more disk space, and more RAM:

boot2docker init --disksize=80000 --memory=8096

Make a small change to your ~/.bash_profile, add the following line:

$(boot2docker shellinit)

Reload the change to your active console:

source ~/.bash_profile

Make a small change to your /etc/hosts, add the following line, so you can use nice urls like: http://boot2docker:9000

192.168.59.103 boot2docker

Launch boot2docker

boot2docker up

How to use the example

The example uses boot2docker, docker, docker-compose and typesafe-activator.

To run the example, execute the run.sh script:

./run.sh

To restart the solution, because it uses akka-persistence, type:

docker-compose restart

To remove all containers type:

docker-compose rm --force

To view the log output type:

docker-compose logs

When the example has been started, point your browser to:

http://boot2docker:9000

Refresh the page a couple of times and see the counter state change.

Have fun!

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.