Adams Bros Blog


Spring Building a RESTful Web Service – revisited

Posted by Trenton

I do frequently find that Spring documentation reads more like a novel than it does technical documentation. I find you can sometimes take many minutes, or even hours, just wading through stuff to find out how to do something that should have taken 5-10 minutes. Spring's REST framework is relatively straight forward to use, but there doesn't seem to be a good quick start on it's use.

So, we endeavour to have you up and running with their "Building a RESTful Web Service" tutorial in under 5 minutes, assuming you have a basic java development environment going, meeting their requirements. Please quickly review the first two "What you'll build" and the "What you'll need" sections at "Building a RESTful Web Service", then come back here.

We have one additional requirement. It's assumed you're able to develop from a Linux command line. If you're not using Linux as a development platform, you really should be.

We won't be using gradle, as I personally think it's a really bad tool.

Filed under: Spring Continue reading


Posted by Trenton

I was recently asked the question about the conditions under which I would choose SOAP vs REST for writing a Web Service.  I was thoroughly intrigued by the question, because I was curious in which way the discussion would go, as that would tell me a lot about the other developer.


Git Recover Deleted or Staged Files

Posted by Trenton

I ran into a situation where I accidentally staged a file I didn't want to stage, and when I ran "git reset --hard" it was wiped out. After a simple google search (git recover staged files), recovering the file was simple.  I've put together a loop, which will check each commit, and look for a string "responsive", which I know is in the file.

Filed under: git Continue reading

Tora Install on Linux Mint 17

Posted by Trenton

We need to start by installing the oracle client appropriate for your architecture.  Grab the oracle instant client rpms from oracle's site.  Then run...

sudo alien --to-deb oracle-instantclient11.2-*.rpm

Java Script Quick Start Tips and Best Practises

Posted by Trenton

When not specified, much of this knowledge comes from Java Script Patterns by Stoyan Stefanov, and the JavaScript Pocket Reference (3rd Edition) by David Flanagan.  I personally found the JavaScript Pocket Reference to be the most valuable of the two.

This is by no means a comprehensive java script language overview, but it does provide a good bit of technical information for a beginner in the language.  It mostly just covers some key concepts that can help improve code quality, and some gotchas of the language.  It is recommended you have used Javascript a little bit prior to reading this.

I may update this from time to time.


Git Setup with SSH

Posted by Trenton

This is just a simple rundown of how to setup git properly for SSH use. SSH specific information about how to connect using SSH keys, and things of that nature, are not within the scope of this post. I will update this as I go.

Filed under: git, Linux Continue reading

git Commit Email Notification

Posted by Trenton

I couldn't really find anything that could get me up and running really quickly with git commit emails. In this blog post we provide a git post-receive-email example.  In our case, our server is CentOS.

Filed under: git, Linux Continue reading

OpenJPA Standalone Application Quick Start

Posted by Trenton

Finding a decent OpenJPA standalone example is very difficult. The one I've created on github does not provide any sort of complex example, but it at least shows how to get started with a standalone Open JPA application, with a maven build.

Filed under: Java Continue reading

Derby Command Line Quick Start

Posted by Trenton

While you can find this information on the derby website, in a grossly large Derby Basics document, isn't it nicer to just copy and paste? I just don't understand why developers like to write documents that make you take so much time to get started.

Filed under: Java Continue reading

apache tomcat 7 rpm

Posted by Trenton

So, I decided to get an apache tomcat 7 rpm going.  I ended up finding someone who had created one, and then made it work a little bit better.  I had one guy that used to be a fedora RPM contributor help out a bit as well.  The result is a repository on github.

If you want to help contribute, and make it better, by all means fork it and work away. 😀

Filed under: Java, Linux No Comments