Code Monkey home page Code Monkey logo

gram's Introduction

Build Status

Note
This snapshot copy is captured from SpringOne 2GX 2015 in Washingon, D.C.

Spring-a-Gram is a demonstration of the Spring stack used to upload and view pictures.

Spring Data REST makes it incredibly simple to define and export data store entities. What does this mean? You declare the POJOs that are stored in your database. In this case, we are using a JPA, in-memory data store. (Spring Data REST supports other data stores as well). You then define a related repository interface. Spring Data REST takes it from there to create a hypermedia-driven, RESTful interface using Spring MVC that lets you create, read, update, and delete data.

This sample application demonstrations how declaring a backend aimed at storing image data can make it as simple as possible to upload pictures and then turn around and display them on a website. This opens the door to other front ends, like an iOS or Android app.

If you want to run it right now, you need:

To download and run:

  1. git clone [email protected]:gregturn/spring-a-gram.git to grab a local copy (or clone your own fork).

  2. bower install to pull down javascript libraries. If you get prompted about jQuery, accept the version specified in bower.json

  3. mvn clean spring-boot:run

Note
To deploy a copy to PWS, you need a Java 8 build pack. Execute cf push spring-a-gram -p target/spring-a-gram-0.1.0.jar -b https://github.com/spring-io/java-buildpack.git and you’ll be set.

This should get the app started courtesy of Spring Boot. Now you can traverse the app from different view points.

  • From the command line, interrogate the API with curl localhost:8080/api. Navigate to the other links.

  • From the desktop, visit http://localhost:8080 to see the Desktop version of the web experience.

  • From a mobile device, visit http://localhost:8080 and see a different flow, optimized for the smaller real estate.

gram's People

Contributors

gregturn avatar royclarkson avatar unscriptable avatar briancavalier 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.