michaelahlers / michaelahlers-playful

Odds and ends for developers using Lightbend's Play Framework.

GitHub

Playful Build Status Discuss

Odds and ends for developers using Lightbend's Play Framework.

About

Playful offers features its author wishes were part of APIs included with Play Framework. It's starting small and will expand incrementally, focusing first on augmenting the iteratee and JSON libraries.

Everything you'll find here will be tested and considered production-ready (despite the low version number). What's not clear is whether this library will receive maintenance in the long term. (It may turn out to be redundant as Lightbend expands their offerings and adds features.) In the meantime, interested users might consider simply copying and pasting source code directly into their own projects. (Although updates will be published to public repositories.)

Installation

Release binaries are by Sonatype. If not already present, add these resolvers to your SBT project configuration:

resolvers += "Sonatype OSS (releases)" at "https://oss.sonatype.org/content/repositories/releases"
resolvers += "Sonatype OSS (snapshots)" at "https://oss.sonatype.org/content/repositories/snapshots"

And add Playful to your dependencies:

libraryDependencies += "com.github.michaelahlers" %% "playful" % "0.1.1-SNAPSHOT"

Development

All contributions—advice, criticism, and assistance—are welcomed and strongly encouraged.

Setup

Apart from requiring Oracle's Java SE Development Kit 8 (JDK 8), this project is “batteries included.” Simply start Lightbend Activator from the project's root to get started (installing SBT is optional). It's recommended to use one of the following resources to obtain Java.

Tests

From an SBT shell, the unit test suite is run with:

test

Specific tests with:

test-only ahlers.michael.playful.iteratee.EnumerateeOpsSpec

Test code coverage reports may be generated with:

;coverage;clean;test;coverageReport

Visit target/scala-2.11/scoverage-report/index.html (from the project's root) in your browser to see results.

Benchmarks

There's currently a beginner's attempt at writing meaningful performance tests using ScalaMeter in src/bench. Benchmarks can be run with:

bench:test

Visit target/benchmarks/report/index.html (from the project's root) in your browser to see results.

Documentation

API documentation is available with copious developer notes is included. From an SBT shell, generate it with:

doc

Visit target/scala-2.11/api/index.html (from the project's root) in your browser to see results.

Resources

Play Iteratees

A reactive API for handling high volume streams.

Play JSON

An outstanding API for working with JSON in Scala.

ScalaMeter

A benchmarking framework used to test performance of this library.