Skip to content

Commit

Permalink
[2.6] Fix shields & other links (playframework#21)
Browse files Browse the repository at this point in the history
[2.6] Fix shields & other links
  • Loading branch information
octonato authored Jun 3, 2019
2 parents e918cdf + 4c2fa10 commit e43e8b7
Show file tree
Hide file tree
Showing 28 changed files with 39 additions and 76 deletions.
5 changes: 5 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
# Play samples

[![Build Status](https://travis-ci.com/playframework/play-samples.svg?branch=2.6.x)](https://travis-ci.com/playframework/play-samples)
[![GitHub issues](https://img.shields.io/github/issues/playframework/play-samples.svg?style=flat)](https://github.com/playframework/play-samples/issues)
[![GitHub forks](https://img.shields.io/github/forks/playframework/play-samples.svg?style=flat)](https://github.com/playframework/play-samples/network)
[![GitHub stars](https://img.shields.io/github/stars/playframework/play-samples.svg?style=flat)](https://github.com/playframework/play-samples/stargazers)

#### License

<sup>
Expand Down
2 changes: 0 additions & 2 deletions play-java-chatroom-example/README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
# play-java-chatroom-example

[<img src="https://img.shields.io/travis/playframework/play-java-chatroom-example.svg"/>](https://travis-ci.org/playframework/play-java-chatroom-example)

This is a simple chatroom using Play and Websockets with the Java API.

This project makes use of [dynamic streams](http://doc.akka.io/docs/akka/current/java/stream/stream-dynamic.html) from Akka Streams, notably `BroadcastHub` and `MergeHub`. By [combining MergeHub and BroadcastHub](http://doc.akka.io/docs/akka/current/java/stream/stream-dynamic.html#Dynamic_fan-in_and_fan-out_with_MergeHub_and_BroadcastHub), you can get publish/subscribe functionality.
Expand Down
5 changes: 2 additions & 3 deletions play-java-compile-di-example/README.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,11 @@
# play-java-compile-di-example

[<img src="https://img.shields.io/travis/playframework/play-java-compile-di-example.svg"/>](https://travis-ci.org/playframework/play-java-compile-di-example)

This is a Play project using the Java API and compile time dependency injection.

It is intentionally very simple and basic to show how compile time DI works in Play with the Java API.

There is also an [example](https://github.com/playframework/play-java-dagger2-example) using Java compile time DI with [Dagger 2](https://google.github.io/dagger/).
There is also an example using Java compile time DI with [Dagger 2](https://google.github.io/dagger/):
the "play-java-dagger2-example" in the [play-samples](https://github.com/playframework/play-samples) repo.

## Running

Expand Down
4 changes: 1 addition & 3 deletions play-java-dagger2-example/README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
[<img src="https://img.shields.io/travis/playframework/play-java-dagger2-example.svg"/>](https://travis-ci.org/playframework/play-java-dagger2-example)

# play-java-dagger2-example

This project shows how to use Play Java with [Dagger 2](https://google.github.io/dagger/).
Expand Down Expand Up @@ -87,4 +85,4 @@ public class MyComponentsFromContext {
return simpleInjector;
}
}
```
```
6 changes: 2 additions & 4 deletions play-java-ebean-example/README.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,10 @@
[<img src="https://img.shields.io/travis/playframework/play-java-ebean-example.svg"/>](https://travis-ci.org/playframework/play-java-ebean-example)

# play-java-ebean-example

This is an example Play application that uses Java, and communicates with an in memory database using EBean.

The Github location for this project is:
The GitHub location for this project is inside:

[https://github.com/playframework/play-java-ebean-example](https://github.com/playframework/play-java-ebean-example)
<https://github.com/playframework/play-samples>

## Play

Expand Down
2 changes: 0 additions & 2 deletions play-java-fileupload-example/README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
# Play File Upload using a custom BodyParser

[![Build Status](https://travis-ci.org/playframework/play-java-fileupload-example.svg?branch=2.6.x)](https://travis-ci.org/playframework/play-java-fileupload-example)

This is a sample project that shows how to upload a file through Akka Streams using a custom BodyParser using Akka Streams using the Java API.

## Default MultipartFormData Body Parser
Expand Down
4 changes: 1 addition & 3 deletions play-java-forms-example/README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
# play-java-forms-example

[<img src="https://img.shields.io/travis/playframework/play-java-forms-example.svg"/>](https://travis-ci.org/playframework/play-java-forms-example)

This example shows form processing and form helper handling in Play.

## How to run
Expand All @@ -16,4 +14,4 @@ And open <http://localhost:9000/>

## Documentation

Please see <https://playframework.com/documentation/latest/JavaForms>.
Please see <https://playframework.com/documentation/latest/JavaForms>.
2 changes: 0 additions & 2 deletions play-java-jpa-example/README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
[<img src="https://img.shields.io/travis/playframework/play-java-jpa-example.svg"/>](https://travis-ci.org/playframework/play-java-jpa-example)

# play-java-jpa-example

This project demonstrates how to create a simple database application with Play, using JPA.
Expand Down
4 changes: 1 addition & 3 deletions play-java-rest-api-example/README.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,10 @@
# play-java-rest-api-example

[<img src="https://img.shields.io/travis/playframework/play-java-rest-api-example.svg"/>](https://travis-ci.org/playframework/play-java-rest-api-example)

A REST API showing Play with a JPA backend. For the Scala version, please see <https://github.com/playframework/play-scala-rest-api-example>.

## Best Practices for Blocking API

If you look at the controller: <https://github.com/playframework/play-java-rest-api-example/blob/2.6.x/app/v1/post/PostController.java>
If you look at the controller: [PostController](app/v1/post/PostController.java)
then you can see that when calling out to a blocking API like JDBC, you should put it behind an asynchronous boundary -- in practice, this means using the CompletionStage API to make sure that you're not blocking the rendering thread while the database call is going on in the background.

```java
Expand Down
2 changes: 0 additions & 2 deletions play-java-starter-example/README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
[<img src="https://img.shields.io/travis/playframework/play-java-starter-example.svg"/>](https://travis-ci.org/playframework/play-java-starter-example)

# play-java-starter-example

This is a starter application that shows how Play works. Please see the documentation at https://www.playframework.com/documentation/latest/Home for more details.
Expand Down
2 changes: 0 additions & 2 deletions play-java-streaming-example/README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
# play-java-streaming-example

[<img src="https://img.shields.io/travis/playframework/play-java-streaming-example.svg"/>](https://travis-ci.org/playframework/play-java-streaming-example)

This is an example Play template that demonstrates Streaming with Server Sent Events or Comet, using Akka Streams.

Please see the documentation at:
Expand Down
2 changes: 0 additions & 2 deletions play-java-websocket-example/README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
# play-websocket-java-example

[![Build Status](https://travis-ci.org/playframework/play-java-websocket-example.svg?branch=2.6.x)](https://travis-ci.org/playframework/play-java-websocket-example) [![GitHub issues](https://img.shields.io/github/issues/playframework/play-websocket-java.svg?style=flat)](https://github.com/playframework/play-websocket-java/issues) [![GitHub forks](https://img.shields.io/github/forks/playframework/play-websocket-java.svg?style=flat)](https://github.com/playframework/play-websocket-java/network) [![GitHub stars](https://img.shields.io/github/stars/playframework/play-websocket-java.svg?style=flat)](https://github.com/playframework/play-websocket-java/stargazers)

This is an example Play application that shows how to use Play's Websocket API in Java, by showing a series of stock tickers updated using WebSocket.

The Websocket API is built on Akka Streams, and so is async, non-blocking, and backpressure aware. Using Akka Streams also means that interacting with Akka Actors is simple.
Expand Down
2 changes: 0 additions & 2 deletions play-scala-anorm-example/README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
# play-scala-anorm-example

[<img src="https://img.shields.io/travis/playframework/play-scala-anorm-example.svg"/>](https://travis-ci.org/playframework/play-scala-anorm-example)

This is an example Play application that uses Scala on the front end, and communicates with an in memory database using Anorm.

## Play
Expand Down
2 changes: 0 additions & 2 deletions play-scala-chatroom-example/README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
# play-scala-chatroom-example

[<img src="https://img.shields.io/travis/playframework/play-scala-chatroom-example.svg"/>](https://travis-ci.org/playframework/play-scala-chatroom-example)

This is a simple chatroom using Play and Websockets with the Scala API.

This project makes use of [dynamic streams](http://doc.akka.io/docs/akka/current/scala/stream/stream-dynamic.html) from Akka Streams, notably `BroadcastHub` and `MergeHub`. By [combining MergeHub and BroadcastHub](http://doc.akka.io/docs/akka/current/scala/stream/stream-dynamic.html#Dynamic_fan-in_and_fan-out_with_MergeHub_and_BroadcastHub), you can get publish/subscribe functionality.
Expand Down
2 changes: 0 additions & 2 deletions play-scala-compile-di-example/README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
# play-scala-compile-di-example

[<img src="https://img.shields.io/travis/playframework/play-scala-compile-di-example.svg"/>](https://travis-ci.org/playframework/play-scala-compile-di-example)

This is an example of Play using the Scala API with manually wired compile time dependency injection.

The application loader here is `MyApplicationLoader` which uses `MyComponents` to wire together an injector.
Expand Down
2 changes: 0 additions & 2 deletions play-scala-forms-example/README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
# play-scala-forms-example

[![Build Status](https://travis-ci.org/playframework/play-scala-forms-example.svg?branch=2.6.x)](https://travis-ci.org/playframework/play-scala-forms-example)

This example shows form processing and form helper handling under Play 2.6.x.

## How to run
Expand Down
2 changes: 0 additions & 2 deletions play-scala-isolated-slick-example/README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
# Play with Slick 3.1

[![Build Status](https://travis-ci.org/playframework/play-scala-isolated-slick-example.svg?branch=2.6.x)](https://travis-ci.org/playframework/play-scala-isolated-slick-example)

This project shows Play working with Slick.

This project is configured to keep all the modules self-contained.
Expand Down
2 changes: 0 additions & 2 deletions play-scala-log4j2-example/README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
# Play using Log4j 2

[![Build Status](https://travis-ci.org/playframework/play-scala-log4j2-example.svg?branch=2.6.x)](https://travis-ci.org/playframework/play-scala-log4j2-example)

This is an example project showing a sample Play application that use Log4J 2 instead of using Logback.

Please see [Using a custom logging framework](https://www.playframework.com/documentation/2.6.x/SettingsLogger#Using-a-Custom-Logging-Framework) in the Play documentation for more details.
Expand Down
4 changes: 1 addition & 3 deletions play-scala-macwire-di-example/README.md
Original file line number Diff line number Diff line change
@@ -1,11 +1,9 @@
# play-scala-macwire-di-example

[<img src="https://img.shields.io/travis/playframework/play-scala-macwire-di-example.svg"/>](https://travis-ci.org/playframework/play-scala-macwire-di-example)

This is an example project for setting up Play with Macwire compile time dependency injection.

For further details, please see:

* <https://www.playframework.com/documentation/latest/ScalaCompileTimeDependencyInjection>
* <https://github.com/adamw/macwire/blob/master/README.md>
* <https://di-in-scala.github.io/>
* <https://di-in-scala.github.io/>
2 changes: 0 additions & 2 deletions play-scala-rest-api-example/README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
# Play REST API

[![Build Status](https://travis-ci.org/playframework/play-scala-rest-api-example.svg?branch=2.6.x)](https://travis-ci.org/playframework/play-scala-rest-api-example)

This is the example project for [Making a REST API in Play](http://developer.lightbend.com/guides/play-rest-api/index.html).

## Appendix
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ You will need to have [git](https://git-scm.com/) installed.

## Downloading

You can clone the example project from Github:
You can clone the example project from GitHub:

```bash
git clone https://github.com/playframework/play-scala-rest-api-example.git
Expand Down
16 changes: 9 additions & 7 deletions play-scala-rest-api-example/docs/src/main/paradox/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ We’ll demonstrate with a "best practices" REST API. You can get source code f

## From Lightbend Tech Hub

Download a pre-packaged bundle with this link [https://example.lightbend.com/v1/download/play-scala-rest-api-example](https://example.lightbend.com/v1/download/play-scala-rest-api-example)
Download a pre-packaged bundle with this link: <https://example.lightbend.com/v1/download/play-scala-rest-api-example>.

**Linux/Mac:**

Expand All @@ -25,14 +25,16 @@ cd play-scala-rest-api-example
sbt.bat
```

## [From Github](https://github.com/playframework/play-scala-rest-api-example/tree/2.6.x):
## [From GitHub](https://github.com/playframework/play-samples):

```bash
git clone https://github.com/playframework/play-scala-rest-api-example.git
git checkout 2.6.x
git clone https://github.com/playframework/play-samples.git
cd play-scala-rest-api-example
```

This example is in Scala, but Play also has a [Java API](https://www.playframework.com/documentation/latest/JavaHome) which looks and acts just like the [Scala API](https://www.playframework.com/documentation/latest/ScalaHome), and has a corresponding [play-java-rest-api-example](https://github.com/playframework/play-java-rest-api-example) project. For instructions on running and using the project, please see the [[appendix]]. This project also comes with an integrated [Gatling](http://gatling.io/) load test -- again, instructions are in the appendix.
Make sure you're using the right Play version branch.

This example is in Scala, but Play also has a [Java API](https://www.playframework.com/documentation/latest/JavaHome) which looks and acts just like the [Scala API](https://www.playframework.com/documentation/latest/ScalaHome), and has a corresponding play-java-rest-api-example project in the [play-samples](https://github.com/playframework/play-samples) repo. For instructions on running and using the project, please see the [[appendix]]. This project also comes with an integrated [Gatling](http://gatling.io/) load test -- again, instructions are in the appendix.

Note that there’s more involved in a REST API -- monitoring, representation, and managing access to back end resources -- that we'll cover in subsequent posts. But first, let's address why Play is so effective as a REST API.

Expand All @@ -52,11 +54,11 @@ Play provides an easy to use MVC paradigm, including hot-reloading without any J

Play combines this with a **reactive programming API** that lets you write async, non-blocking code in a straightforward fashion without worrying about complex and confusing "callback hell." In both Java or Scala, Play works on the same principle: leverage the asynchronous computation API that the language provides to you. In Play, you work with [`java.util.concurrent.CompletionStage`](https://docs.oracle.com/javase/8/docs/technotes/guides/concurrency/changes8.html) or [`scala.concurrent.Future`](http://docs.scala-lang.org/overviews/core/futures.html) API directly, and Play passes that asynchronous computation back through the framework.

Finally, Play is modular and extensible. Play works with multiple runtime and compile time dependency injection frameworks like [Guice](https://www.playframework.com/documentation/latest/ScalaDependencyInjection), [Macwire](https://di-in-scala.github.io/), [Dagger](https://github.com/playframework/play-java-dagger2-example), and leverages DI principles to integrate authentication and authorization frameworks built on top of Play.
Finally, Play is modular and extensible. Play works with multiple runtime and compile time dependency injection frameworks like [Guice](https://www.playframework.com/documentation/latest/ScalaDependencyInjection), [Macwire](https://di-in-scala.github.io/), [Dagger](https://google.github.io/dagger/), and leverages DI principles to integrate authentication and authorization frameworks built on top of Play.

## Community

To learn more about Play, check out the [Play tutorials](https://playframework.com/documentation/latest/Tutorials) and see more examples and blog posts about Play, including streaming [Server Side Events](https://github.com/playframework/play-streaming-scala) and first class [WebSocket support](https://github.com/playframework/play-websocket-scala).
To learn more about Play, check out the [Play tutorials](https://playframework.com/documentation/latest/Tutorials) and see more examples and blog posts about Play, including streaming server-side events ("play-scala-streaming-example") and first class WebSocket support ("play-scala-websocket-example") in the [Play Samples](https://github.com/playframework/play-samples).

To get more involved and if you have questions, join the [forums](https://discuss.playframework.com) at and follow [PlayFramework on Twitter](https://twitter.com/playframework).

Expand Down
Loading

0 comments on commit e43e8b7

Please sign in to comment.