Shaun Abram
Java and Technology weblog
Maven archetypes to create your project folder structure
Although gradle is my preferred build tool these days, the maven archetypes are still useful for creating a folder structure to start with.
(more…)
Tags: devops, gradle, Maven, mvn
Software Quality via Unit Testing
The following post is based on a talk I gave at Desert Code Camp 2013. See also the associated slide deck.
Software quality is critical to consistently and continually delivering new features to our users. This articles covers the importance of software quality and how to deliver it via unit testing, Test Driven Development and clean code in general.
Read more
Tags: cleancode, codecamp, dcc13, desertcodecamp, JUnit, martinfowler, talks, tdd, Testing, unittesting
Cloudbees
I’ve been using CloudBees a lot recently for deploying to ‘the cloud’.
There are a couple of things that attract me to CloudBees…
Read more
Tags: cloud, cloudbees, continuousdeployment, continuousintegration, jenkins, Maven
Handsontable ‘Spreadsheet’ talking to SpringMVC
Handsontable is an Excel-like data grid utilizing JQuery. For example, it provides the ability to copy and paste directly to & from Excel. Handsontable itself if very easy to setup. The part I struggled with was passing the data to SpringMVC. So, this post shows how to send data from a Handsontable data grid on the client to a SpringMVC server.
Tags: excel, handsontable, JavaScript, jQuery, jsp, spreadsheet, spring, springmvc
SpringMVC file download
This post shows how to download a file using Spring MVC. For example, you have a SpringMVC web app and you want to include a link on a page that downloads a file to be opened on the user’s machine (e.g. a Microsoft Excel).
Read more
MyMoney – A simple SpringMVC app
I created a small, open source web app called MyMoney for entering and tracking spending details. It allows you to create accounts (for example Cash or Checking) and enter transactions associated with those accounts.
The app is running at http://mymoney.shaunabram.cloudbees.net and the sourecode is available via GitHub.
Read more
Tags: Hibernate, spring, springmvc
Certified ScrumMaster
I became a Certified ScrumMaster today via the Scrum Alliance. I know certifications are worth very little, but the training and exam prep was definitely very useful and, more importantly, I’m implementing Scrum techniques on the new project I’m working on: Planning the sprint ahead, daily scrums, sprint reviews and trying to remove obstacles for the team.
Tags: agile, Certification, scrum
415 ‘Unsupported Media Type’ error when submitting JSON from a JSP
I’ve been experimenting with submitting JSON data from a JSP to a Spring MVC Controller, using the Spring MVC Ajax example as my guide.
But after setting everything up, I continually ran into this error:
NetworkError: 415 Unsupported Media Type
The server refused this request because the request entity is in a format not supported by the requested resource for the requested method().
After much googling, I found a plethora of solutions, none of which worked for me. In the end, I found it was because I had omitted this line from my JSP:
<script type="text/javascript" src="<c:url value="/resources/json.min.js" /> "></script>
Hope that helps someone else…
Tags: json, jsp, spring, springmvc
Spring MVC Hello World with Continuous Deployment
Oh dear, yet another ‘Hello World!’. But although the functionality is trivial, this little SpringMVC project is complete enough for me to use as a template to bootstrap more complex projects. It consists of:
- HTML/JSP client
- SpringMVC server using a Controller/Service/DAO design
- Maven for build and dependency management
This is an updated version of an older project I created, with the following enhancements:
- Added a full suite of automated tests (unit, integration and browser based)
- Added placeholders for JavaScript and images (both can be a little tricky to put in the correct place with SpringMVC)
- Incorporated into a continuous deployment environment
More details below, but you can find the full source code on this GitHub repository and the deployed app at http://springmvc.shaunabram.cloudbees.net.
Read more
Tags: cloud, cloudbees, continuousdeployment, continuousintegration, easymock, fest, helloworld, jenkins, spring, springmvc, Testing, unittesting
Running Jenkins jobs sequentially
I am a huge fan of the Jenkins continuous integration tool, using it not just for continuous integration, but also continuous delivery, server monitoring and performance testing.
Although using Jenkins is normally a breeze, I recently had a need to run several Jenkins jobs sequentially and it proved a little trickier than expected, so I thought worth posting about.
Basically, I wanted to call a database backup job before calling the deploy build job, which obviously shouldn’t be done in parallel. After a bit of research, I found a number of ways to have Jenkins run jobs sequentially.
Read more
Tags: agile, ci, continuousintegration, devops, hudson, jenkins
Subscribe to RSS Feed