Posted by: TomS on April 15, 2012 @ 8:58 pm
In Part 1 of this post, I covered performing a basic installation of Nexus in a Tomcat servlet container on Ubuntu 11.10. Now I’m going to cover the details of configuring Nexus.
Nexus is a repository that can be used with tools such as Maven to index and store artifacts for dependency management across projects. I like to use the Nexus/Maven combo for three main reasons:
- Storing Versions of My Own Artifacts – I try to do all my Java builds in Maven these days. This means that all my projects always have a standard lifecycle and release procedures. I can commit my code to SVN, but its also nice to have a repository to store my compiled artifacts. Nexus fills this job, allowing me to deploy all versioned projects to the central repository, accessible from all of my machines. Additionally, the repository makes all these versioned artifacts available as dependencies for any of the other projects I work with.
- Proxying Other Repositories – When you work with Java Maven projects, you’ll get pretty used to Maven “downloading the internet” the first time you build a particular project on a machine. This is Maven getting all the dependencies and transitive dependencies required to build your project. It might take a little while, but its far better than trying to manage all those dependencies yourself. This step is often dependent on external repositories outside of my control, however. The external repositories may gone down (but rarely), and it is common for these repositories to eventually remove old versions of artifacts or reorganize their repositories. Proxying a repository means that my Maven builds will always fetch artifacts from my Nexus repository first. If Nexus can’t find the artifact, it will download it from the external repository, but it will store it locally so future requests do not depend on the external repository. This means that the artifacts I use never go away, and the process is much faster since I only need to retrieve artifacts from my own repository in most cases.
- Hosting 3rd Party Artifacts – There are times when I use a jar, but the jar isn’t readily available in a Maven repository somewhere. I try to avoid just adding those jars to SVN. Instead, I’ll upload the artifacts to Nexus and I can access them as needed via standard Maven builds.
(more…)
Posted by: TomS on April 15, 2012 @ 1:13 pm
I just need to do some final proof-reading on Part 2 of the Nexus/Maven post, but in the man time, here’s another place my cat shouldn’t be. In the rafters of the family room this time.

Izzy in the Rafters
Posted by: TomS on April 10, 2012 @ 7:37 am
I’ve used Maven and Nexus at work quite extensively, and since I’ve become familiar with the tooling, I’ll never go back. When using a mature language like Java that has an expansive ecosystem, dependency management is a must. Maven has its rough edges, but it does get the job done, and I’ve always been pleasantly surprised with how easy it is to use Nexus and how little maintenance it really requires.
I’m planning on doing a bit more Java development at home, and I’d like to have my own Nexus repository hosted on my internal network. Part 2 of this article will cover configuring Nexus and the benefits of using it. In this part of the article, I’ll walk through the steps for setting up and configuring Nexus from a base Ubuntu 11.10 Server installation.
For my purposes, I would like the end result of my installation to be that I can go to nexus.my.home (a DNS name on my internal network) and be able to interact with Nexus, so I’ll be doing some additional configuration with Apache Web Server to make this happen.
(more…)
Posted by: TomS on July 8, 2011 @ 1:22 pm
My wife and I have a cat, Izzy, and since adopting her from the SPCA, we’ve been continuously amazed/surprised/horrified at the various places and situations we find her getting into. I’ve had the idea for a while to add a section to this blog called Places My Cat Shouldn’t Be, documenting some of the more humorous moments we actually managed to catch on camera. My wife made a few pillows recently and put this gallery together (along with captions), showing just how helpful Izzy can be be. I decided to share it as the first entry in Places My Cat Shouldn’t Be. Enjoy!

I like to help make pillows! My favorite part is cutting the fabric.

Tasty!
(more…)
Posted by: TomS on April 16, 2011 @ 4:05 pm
OpenID is an open standard for a distributed system that allows users to authenticate with a single identifier on sites across the internet. For a while now, OpenID has promised to become the tool that lets internet users login to all sites using a single account, and recently, with many of the big web comapnies (Google, AOL, Yahoo, MyOpenID) becoming OpenID providers, and many smaller sites starting to support OpenID authentication, OpenID is coming into its own. Yes, its still fragmented, yes there’s many sites that still don’t use it, but things are getting better, and for me, there’s enough value in it now, that I want to use my blog as my OpenID for my internet persona.
I have a couple unique requirements for what I’m trying to do, so let me set that up first. I have a public online persona that I use for this blog and other sites online related to running and technology. I have no illusions of privacy. I am sure anyone who is determined enough can find out plenty of personal information from my activity, but in general, most people that come to this site are looking for content about the information I post. I would rather not broadcast my personal information to all those people so I try and keep my public online accounts separate from my personal ones.
That being said, its a pain to manage multiple logins and passwords, log in and out of sites, and so on. OpenID can be really useful with this task, and that’s what I’m trying to do: use my WordPress blog at http://www.hackrunner.com as my digital identity for public web activity and convert as many accounts over to it as possible. BUT, I don’t always want to remember a second password for my public persona, so I’d still like to be able to login with my private personal OpenID, without broadcasting it to the world.
So here are my requirements:
- Set up my blog as an OpenID provider.
- When authenticating at my blog, be able to login using OpenID authentication from another provider (i.e the OpenID I use for my personal activity).
- I don’t necessarily want to do OpenID delegation here, since it will publicly broadcast my other OpenID.
- Be able to manage my user account settings on my blog, so I can switch between other OpenID providers I use to authenticate.
- This gives me portability in the future if I decide to switch OpenID providers.
As usual, WordPress already has all the tools I need available in its extensive plugin library. Here are the steps I followed to get this up and running.
(more…)
Posted by: TomS on February 6, 2011 @ 11:58 am
You may have seen a few commercials for it recently, but next week, from Feb. 14- Feb. 16, Jeopardy! will be airing a face-off pitting all-time greats Ken Jennings and Brad Rutter against a research computer built by IBM called Watson. I make no claim to be an expert, but from some brief exposure in college, I have a general feel for how hard it is for computers to perform natural language processing just to understand the human language. IBM is taking this one step farther by pairing advanced language processing with search algorithms to try and create the ultimate Jeopardy! champion. From some of the videos I’ve seen online, it’s pretty impressive, and the showdown next week should be fairly entertaining.
The Wall Street Journal has a good article giving a very simple explanation of how Watson actually works, and the forthcoming book will likely provide even more details on the story of Watson. I’ll be tuning into Jeopardy! next week to see how things go. My personal prediction is that Brad Rutter will take the win, but both Ken and Watson will put in good showings. Watson’s Achilles heel will likely be a few botched categories and questions that put him in hole, but its exciting to see how much progress IBM has made with technologies like these by taking up the IBM Jeopardy! challenge.
A practice round of Watson playing is available on YouTube and embedded below.
Posted by: TomS on January 28, 2011 @ 7:36 am
At lunch the other day, the conversation turned to Apple, and one of my co-workers posed the question, “Why hasn’t Apple released a video game system yet?” At the time, I was playing Angry Birds on another co-workers iPhone, and I waved the iPhone at him and responded “They have.” He of course responded that it isn’t really what he meant, but I thought a bit more about what Apple has done with its gaming strategy up till now, and they are actually positioned surprisingly well to pull in a huge chunk of the video game market over the next few years.
Before I dive into the details, most of my argument is based on Clayton Christensen’s ideas around disruptive innovation and low-end disruption. In a nutshell, Christensen theorizes that most disruptive innovation occurs when established firms neglect certain market segments because they offer too low of a margin to entice the incumbents. Innovators enter the low-end segments and the incumbents do not react, but overtime, the entrants overshoot the needs of the low-end markets and begin to pick up additional market segments. Left unchecked, the entrants eventually overtake the market, driving the incumbents out completely. Its a pattern that has repeated itself throughout history, and Apple may be repeating it again with the growing library of games it distributes on the App Store. (more…)
Posted by: TomS on January 9, 2011 @ 12:44 pm
It’s been a while since I’ve had to set up a new SVN repository on my home network, so now that its time, I figured I write a quick post documenting the steps along the way.
For those that may be unfamiliar with it, SVN is a commonly used version control system. It allows users to manage the changes to source code over time so that a user can quickly restore old versions, analyze change sets, and control how change sets are applied to a set of source code. SVN is likely the de facto open source centralized version control system. It grew up from the older CVS project, but it should be noted that it is a centralized version control system. There a number of distributed version control systems out there such as git, Mercurial, and Bazaar, which are gaining adoption very quickly and provide a number of benefits for projects with many users. For my home use, I’m the only user, and I’m familiar with the ins an outs of SVN, so I’ve stuck with it.
SVN is also one of the most well documented open source projects out there, primarily because of the excellent work that goes into the SVN Book. The online content is freely available, and its essentially the same content that is published in the O’Reilly reference. It is update often and is very comprehensive. If you have any questions about SVN, I’d start there.
Now that I’ve gotten that out of the way, on to the content. I want to set up an SVN Repository for a new project I’m working on. There are a number of ways in which you can choose to organize SVN, but I generally follow the 1 project per repo model. I use Apache and WebDav to connect to my SVN repos so that I can access them directly over http. Assuming you already have SVN and Apache installed, there are really three quick parts to the setup. Create the SVN Repo, Configure the WebDav connection, and Setup the SVN Repo.
Create the SVN Repo
To create the svn repo, you’ll make use of the svnadmin command line tool. It provides a number of SVN mainteance functions including the create repository functionality. I usually create the repository as root, and then after it is created update the permissions so that the web user is the owner and the group is the SVN group. This allows both Apache and SVN processes access to the files. The commands needed to set this up are below.
#create the new SVN repo
sudo svnadmin create /storage/svn/myNewRepo/
#change permissions on the new repo so that Apache and SVN can access it
sudo chown -R www-data.svn /storage/svn/myNewRepo/
Configure the WebDav Connection
Creating the WebDav interface is also just as easy. You’ll create a simple Location entry in your Apache configuration which defines the parameters needed for users and the SVN connection. For me, I put the configuration in the default website on my SVN server (on Ubuntu its /etc/apache2/sites-available/default), and I use the Apache AuthUserFile to control users of the repo. I have set up user accounts for other repos, so I’m just going to hook into the existing file.
The location information in my Apache file is shown below. I add it directly the default VirtualHost listing for the server.
<Location /svn/myNewRepo>
DAV svn
SVNPath /storage/svn/myNewRepo
AuthType Basic
AuthName "Subversion Repository"
AuthUserFile /etc/apache2/passwords
Require valid-user
</Location>
From there, its just a quick Apache restart with sudo /etc/init.d/apache2 restart and then you should be able to access the repository over HTTP in your browser by going /svn/myNewRepo on your server (i.e. http://server.my.home/svn/myNewRepo). You should see a simple page listing the repository information, version 0 as the version number, and an empty directory since we haven’t added any content yet.
Setup the SVN Repo
Your svn repository is now ready to use. Most repositories follow the general pattern of a trunk/branches/tags structure, so to make sure things are working, I’m going to create those directories using the svn command line client. Thereare a number of ways to do this, but I’m just going to create one directory at a time directly on the server. The commands look like this.
svn mkdir http://server.my.home/svn/myNewRepo/trunk --message "Creating the basic SVN structure for the project"
svn mkdir http://server.my.home/svn/myNewRepo/branches --message "Creating the basic SVN structure for the project"
svn mkdir http://server.my.home/svn/myNewRepo/tags --message "Creating the basic SVN structure for the project"
And that is all that’s needed. You can verify that it worked by going to the svn repo’s web address again and verifying that the list of folders has updated. Typically you would then check out the SVN trunk and then start checking in your code.
Posted by: TomS on December 16, 2010 @ 2:23 am
I’ve been toying around with some small ideas for websites, and I’ve been looking for some straightforward frameworks that would allow me to quickly prototype a site that could still be used, at least for moderate levels of traffic, in a production environment. I decided to check out Django, a Python based web framework that supports a lot of out-of-the-box functionality and is easily extensible.
This post outlines the steps I took to install Django on test web server, which is currently running Ubuntu 10.10 (Maverick Meerkat).
Overview
As is often the case, I like to configure my test system so that it is as close as possible to the production environment I eventually deploy to. In many cases, that means deviating from Ubuntu’s distribution repositories and installing some packages from source. In the case of Django, there is an appliance version of Ubuntu that supports Django, but nothing official in the repositories. So as usual, I’m back to installing my own version. Before I started, I laid out a few of the requirements I would like to achieve.
- Use the latest stable version of Django (1.2.3)
- Install Django in a shared location, but Django sites should be independent.
- Each Django site should be in its own Apache VirtualHost, so as not to disturb the other sites I have running on my test server.
- Each Django site should be easily maintained in source control and should not include any major artifacts from the Django library. This will make the application portable, and will be helpful when I move it to other servers, such as production.
I based most of my work on an article on jeffbaier.com, but made some adjustments along the way to suit my needs, so I’m posting my steps for anyone else that might be following the same path.
(more…)
Posted by: TomS on August 8, 2010 @ 8:57 pm

20in24 Lone Ranger Ultra Marathon
After several months of contemplating it, 1 semi-serious ankle injury, 6 solid weeks of mileage increases that took me far beyond anything I have ever been close to before, and a nice rewarding 2 week taper, the weekend of the Stroehmann Back on My Feet 20in24 Lone Ranger Ultra Marathon (hence force to be referred to as the 20in24 Lone Ranger run) finally came.
To break that name down a bit, Back on My Feet is a great charity that “promotes the self-sufficiency of homeless populations by engaging them in running as a means to build confidence, strength and self-esteem.” Each year, BOMF puts on the 20in24 series of races as a fund-raising event. The event consists of a number of relays and races in addition to the 24 Hour Lone Ranger Ultra Marathon. Stroehmann was the official sponsor this year. Here’s the recap of the event and how I did in the Lone Ranger Ultra Marathon.
(more…)