Our base project is compiling and now we want to tackle our first User Story and implement the Kitchen Duty Planning page.
But before we start the implementation we drink another coffee and get our brain up to software-architecture-design-speed, because we need to make some design decisions now. Think of the following section as a little Story Workshop we do with our virtual Product Owner and the virtual Scrum Team to build a shared understanding on the work to be done.
Ok sounds like basic stuff we did a trillion times already in some other projects. But the question is, how do we do this the cool Atlassian way?
Most of you might know Bootstrap and use it to build sweet responsive websites. Atlassian also has such a Framework that drives their Applications. It is called Atlassian User Interface in short AUI.
Ok now we have selected the two frontend components we want to use and continue with server side components.
The caffeine kicks in now and our spacey software-engineering mind is fully operational to design the server components.
We could use a Servlet and simple MVC approach with lame JSP-style-pages and normal Request-Response-Cycle ...
But since that is just lame we will do it with REST Resources and a simple view that has a lot of (ugly) JavaScript code to interact with the REST Resources.
So after thinking about that a little we came up with the scheme on the right. (What is Webwork Action? We will learn about that soon.)
Component Overview
Kitchen Duty Planning Webwork Action is a basic “Servlet” that provides the actual Page to browse to and provides the HTML View and JavaScript.
User Search Resource JS Controller contains a bunch of JS-Code to interact between the HTML-View and the User REST Resource.
Kitchen Duty Planning Resource JS Controller contains a bunch of JS-Code to interact between the HTML-View and the Kitchen Duty REST Resource.
HTML View is our template that provides basic HTML components for the JavaScript Controller to hook into.
User Search REST Resource provides REST Resources for searching JIRA usernames via JAX-WS.
User Search Resource Model is our simple Pojo Model which we use to persist Data and also use as JSON representation in the JavaScript controller.
Kitchen Duty Planning REST Resource provides REST Resources for CRUD operations on the KitchenDutyPlanningModel via JAX-WS.
Kitchen Duty Planning Model is our simple Pojo Model which we use to persist Data and also use as JSON representation in the JavaScript controller.