Posted in java, spring-framework, web at 3:50 pm by Josh Peters
For some time now, I’ve been working with Spring MVC and Spring Web Flow to build web applications. One option that Spring MVC (and Web Flow by extension) offer is a view resolver that allows you to hide your JSP files behind the magical WEB-INF folder. The excellent Spring MVC tutorial started me on the practice of configuring my view resolver to stash JSPs behind the wall of WEB-INF.
The downside to this approach is that it becomes very difficult to compile those JSP files without walking through one’s application.
Read the rest of this entry »
Permalink
Posted in apple/mac/ipod, best-practices, programming at 1:55 pm by Josh Peters
As we all know, Apple recently introduced iPad to the world. Regardless of what you think about the device, I find myself really interested in the brief glimpses it offers about how Apple has been running its business.
Read the rest of this entry »
Permalink
Posted in music at 5:02 pm by Josh Peters
On the way home from work today I was listening to WGLT and a great cover of The Cure came on. A gal named Kat Edmonson sings “Just Like Heaven” on her debut album
“Take To The Sky”
. It’s a slow and sultry cover of a decent pop song by one of my favorite bands. Perhaps surprisingly, I really like it.
Permalink
Posted in Uncategorized at 11:11 pm by Josh Peters
Well, Danielle and I exchanged gifts tonight: I got the complete Farscape
! Oh yes. John Criton and space puppets are in my near future.
Read the rest of this entry »
Permalink
Posted in web at 12:34 pm by Josh Peters
So Google Chrome for the Mac is out. I’ve pretty much switched to it from Safari and Firefox for my home browsing.
Only one issue I’ve really seen: Gmail frequently lags and threatens with the wait screen. Seriously? Chrome is a kick-ass browser otherwise.
Permalink
Posted in programming, technology at 7:45 pm by Josh Peters
Today I watched the Google Chrome OS demonstration (11 minutes) video on YouTube®. Here is what I thought of it.
Read the rest of this entry »
Permalink
Posted in customer-relations, flamebait, health, identity, politics/government, privacy/secrecy/security at 12:57 pm by Josh Peters
According to a University of Rochester report, plastic chemicals “feminize boys.” If I ask how long before a rumor of a global conspiracy against Western boys is mentioned, does that count as a mention?
Seriously though, if I could at all believe in an overarching, long-term strategy to weaken an enemy, this would be a doozy of one. (please note, I do not endorse any arguments about women being a “weaker gender” by the previous statement, I only imply that a potential enemy of the West could)
Permalink
Posted in java, maven, work at 1:29 pm by Josh Peters
Apache Maven has become my build tool of choice at work. It seems that nearly every week I learn how to do something new with Maven (part of this is my inexperience, part is the plethora of awesome plug-ins).
I’ve been working on a project lately that is a pretty simple management application that uses JPA in the data layer. One of the goals of this project is to provide a nightly process for parsing input files. I could have tackled this in a variety of ways. My first hope was to create an executable JAR file, but I quickly found that I couldn’t get very far due to a limitation/feature of JARs: one cannot modify the classpath via the command line interface. My project uses some platform-specific files, so I could not easily include them in the final package. My second attempt ended up working well: create a JAR file within my WAR and execute a class inside that particular JAR.
This project has quite a lot of dependencies: Spring MVC, Hibernate, JPA, Javamail, SQL Server, etc. If I were to create a command-line call to the java executable it would quickly fill up many, many lines in an editor. Fortunately, it’s easy to include the classpath inside the JAR manifest during the Maven package:
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-war-plugin</artifactId>
<configuration>
<archiveClasses>true</archiveClasses>
<archive>
<manifest>
<addClasspath>true</addClasspath>
<mainClass>…</mainClass>
</manifest>
</archive>
</configuration>
</plugin>
The <addClassPath> bit tells Maven to include all of the other dependencies in the manifest file. This is a big deal, as it accomplishes two things: it takes care of me having to write a script to generate the classpath dynamically and it allows me to have a very reasonable length command line statement.
Thanks to letting Maven create a JAR file with its manifest managing the classpath, my resulting java command looks like this: java -cp MyProject.jar:… MyProjectRunner (where MyProjectRunner is a class that I want to execute).
Permalink
Posted in politics/government at 12:28 pm by Josh Peters
An increasing part of me is in disbelief that we’re still having a national conversation about torture. Andrew Sullivan makes a great point about how labels really don’t change the morality of something.
One of the reasons I voted for Obama was so that our nation would stop justifying torture (and hopefully to prosecute those sorry souls that sullied my country’s reputation by doing so). I have great hope in Eric Holder’s prerogatives regarding the latter.
Permalink