Skip to content

towczare/s02e03

Repository files navigation

Javafaktura s02e03 - Spring MVC - REST in peace

.images/javafaktura.png

How to read this repository?

This branch contains all implemented features.

Feel free to:

  • clone this repository 😃
  • fork this repository 👽
  • break things 😅
  • implement new features 😎
  • provide pull request to repository 😍

Let's choose baby name

Once Java Programmer was expecting to have baby, actually 2 babies.
He wrote a program to choose names for his newborns.
Unexpectedly triplets were born and they got the names:
Adam, Frank and... ArrayIndexOutOfBoundsException

This is simple program (or rather group of programs) is solving similar problem. We are going to draw name for a newborn. Data source is based on real data https://dane.gov.pl/dataset/219,imiona-nadawane-dzieciom-w-polsce .images/chooser.png We also present full statistics of most popular names given during first half of 2019. .images/all_names.png And plot a graph for names based on historical data. .images/graph.png

Code

Core

Code: child-core

This module contains no Spring dependencies. Just pure Java + library to read csv files.

What is best approach to test Spring projects?

Test them like there was no Spring at all. (:heart:)

Marcin Grzejszczak - Principal Software Engineer at Pivotal


Spring MVC

Code: child-webapp

  1. Draw a random name ✅
  2. Present all names split by gender ✅
  3. Draw a random name, taking parents preferences to gender and popularity ✅
  4. Allow to choose name from existing data - should increase occurrence counter ✅
  5. Allow to choose new name - should add new name with counter=1 ✅
  6. Show details of certain name using path variable ✅

Spring REST API

Module: child-api

  1. Serve all name stats ✅
  2. Serve random name stats ✅
  3. Serve certain name stats ✅
  4. Serve history of given name ✅
  5. Allow to insert existing name - should increase counter ✅
  6. Allow to insert new name - should add new name with counter=1 ✅

Spring REST API Client

Module: child-client

  1. Consume all name stats ✅
  2. Consume random name stats ✅
  3. Consume certain name stats ✅
  4. Consume history of given name and plot a graph ✅
  5. Allow to insert existing name using API - should increase counter ✅
  6. Allow to insert new name using API - should add new name with counter=1 ✅

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published