30 March 2010

10 Questions to Ask Your New Manager | Javalobby

10 Questions to Ask Your New Manager | Javalobby
# What do know about management? What models do you use?
# What books and blogs do you read? Which managers are your source of inspiration?
# Are your teams self-organizing? How? And how do you add value?
# Can you give examples of your teams being happy about what you've done for them?
# How have you motivated your team members?
# What kind of direction, rules and constraints do you impose on teams?
# What kinds of impediments have you removed lately?
# How do you develop competence and craftsmanship in the teams?

The Obix Framework: Software Configuration Made Easy

The Obix Framework: Software Configuration Made Easy
"The Obix Framework simplifies software configuration by providing a standard means, of encoding configuration data in XML, and of loading such data into an application so that the data can be accessed using basic Java™ objects. It provides a host of powerful, yet simple, features that simplify the representation, and use of configuration information. These features, to name but a few, include: the ability to represent complex configuration data (file) trees, by providing links between configuration documents; modularization of configuration data; automatic change detection and auto-reload of configuration data; simple integration into Java™ applications using little or no custom code; support for enterprise scale (J2EE™) applications; configuration event listeners; a flat learning curve; and extensibility."

22 March 2010

Codehaus: GreenMail

Codehaus: GreenMail
GreenMail is an embedable, lightweight and sandboxed email server for testing and developing purposes.

* Features: – supports SMTP, POP3, IMAP with SSL – provides a JBoss GreenMail Service extension for running a sandboxed mail server – contains examples for mail integration tests

21 March 2010

HtmlUnit 2.4, a headless java browser, released - TheServerSide.com

HtmlUnit 2.4, a headless java browser, released - TheServerSide.com
A new release of the pure GUI-Less browser is available, which allows high-level manipulation of web pages, such as filling forms, clicking links, accessing attributes and values of specific elements within the pages, you do not have to create lower-level requests of TCP/IP or HTTP, but just getPage(url), find a hyperlink, click() and you have all the HTML, JavaScript, and Ajax are automatically processed.

The most common use of HtmlUnit is test automation of web pages (even with complex JavaScript libraries, like jQuery and Google Web Toolkit), but sometimes it can be used for web scraping, or downloading website content.

20 March 2010

How to Use Symlinks in Windows - Symlinks - Lifehacker

How to Use Symlinks in Windows - Symlinks - Lifehacker
mklink /j "c:\users\Will\Music\iTunes\iTunes Music" d:\Music\ - This line makes a symlink that redirects from the folder c:\users\Will\Music\iTunes\iTunes Music to the Music folder on my second hard drive. This type of use is especially handy if you have a small main hard drive and a larger secondary drive.

How do I use all my cores? | Architects Zone

Didn't really agree with this article as a general approach to concurrency by using unix pipes but there was a "bang-on" comment included below:

This is a classic hammer nail kind of thing where pipes and filters are a particularly old hammer and map reduce is about the same age but recently re-discovered. Neither will solve all your problems.

Yes, concurrency is hard, especially if you have no background in computer science, i.e. if you lack basic understanding of the abstractions that can make your life easier. If you do have such a background, the next step is understanding the different patterns that exist in this space. Producer consumer, semaphores, message queues, callbacks, functions without side effects, threads, blocking/non blocking IO, etc.

Still with me? Now the good news. Your needs are probably quite modest and well covered by some existing framework. Using the java.concurrent api is not exactly easy but if use properly will allow you to dodge synchronization issues.

A few useful tricks that you should practice regardless of whether you are going to run with multiple threads:

- Don't use global variables.

- Don't share object state with mutable objects.

- Use Dependency injection (i.e. don't initialize objects yourself). Keep the number of dependencies per class low.

- Separation of concerns. Make methods only one thing and keep your classes cohesive (i.e. don't dump random methods in one class).

If you do all this properly, your design will make a shared nothing approach a lot easier. Shared nothing is what you need to parallelize. Shared something means context switches and synchronization. These are the two things that make concurrent programming hard. If you can do shared nothing, concurrency is easy.

If you can't, work on how you share between processes/threads. Asynchronous is great here. Use call back mechanisms or some kind of queueing solution. Avoid manipulating semaphores and locks yourself, leave that to some off the shelf solution.

Unix pipelines are great if all processes in the pipe line are independent, don't contest the same resources, need to do about the same amount of work, and can work on partial results as they are streamed from the predecessor. If not, you've got a clogged pipe and a bunch of processes waiting for it to become unclogged.

Java plugin for Firefox on 64 bit linux

cd ~/.mozilla/plugins
ln -s ${JAVA_HOME}/jre/lib/amd64/libnpjp2.so

15 March 2010

Great Lies: "Design" vs. "Construction" | Architects Zone

Great Lies: "Design" vs. "Construction" | Architects Zone
In the building trades there are architects, engineers and construction crews. In manufacturing, there are engineers and factory labor. In these other areas, there's a clear distinction between design and construction. Software must be the same. Right?

The analogy is fatally flawed because there is no "construction" in the creation of software. Software only has design. Writing code is -- essentially -- design work.

13 March 2010

Design Patterns Uncovered: The Visitor Pattern | Javalobby

Design Patterns Uncovered: The Visitor Pattern | Javalobby
Design Patterns Uncovered: The Visitor Pattern

Jira Studio available for Google Apps

JIRA Studio has "Gone Google" - Atlassian News
The analog to Google Apps at Atlassian is JIRA Studio, our hosted software development suite. JIRA Studio (Studio for short) is our fastest growing product, which shouldn't be a surprise. In a single, hosted, just-turn-it-on-and-it-works product, Studio combines source control (Subversion), issue tracking (JIRA), agile planning (GreenHopper), enterprise wiki (Confluence), code browsing (FishEye), code reviews (Crucible) and continuous integration (Bamboo). All of that, beautifully integrated, and hosted as a single service. As a customer, you don't worry about managing or upgrading it - we take care of all that. Studio helps teams build great software, by giving them the tools they need to manage code and development projects, without the hassle of managing those tools.

VcsSurvey - MartinFowler.com

Dilbert CMMI




LOL

06 March 2010

BlueGreenDeployment - MartinFowler.com

MF Bliki: BlueGreenDeployment
One of the challenges with automating deployment is the cut-over itself, taking software from the final stage of testing to live production. You usually need to do this quickly in order to minimize downtime. The blue-green deployment approach does this by ensuring you have two production environments, as identical as possible. At any time one of them, let's say blue for the example, is live. As you prepare a new release of your software you do your final stage of testing in the green environment. Once the software is working in the green environment, you switch the router so that all incoming requests go to the green environment - the blue one is now idle.

Blue-green deployment also gives you a rapid way to rollback - if anything goes wrong you switch the router back to your blue environment.

What do you try to leave in your commit messages? | Java.net

What do you try to leave in your commit messages? | Java.net
# Bug ID. In fact, bug/commit association is so useful that often you use (or write) programs that analyze these relationship, so it's preferrable for this information to be machine readable.
# URL to the e-mail in the archive that prompted me to produce a change. In Hudson, often a conversation with users reveal an issue or an enhancement that results in a commit. This URL lets me retrieve the context of that change, and I find it tremendously useful.
# If the discussion of a change was in IM, not e-mail, I just paste the whole conversation log, as they don't have an URL. Ditto if the e-mail was sent to me privately.
# The input value and/or the environment that caused a misbehavior. In Hudson, I have this one method that needs to do some special casing for various application servers. When I later generalized it a bit more, commit messages that recorded the weird inputs from WebSphere, OC4J, and etc. turned out to be very useful.
# For a fix, a stack trace that indicates the failure. Sometimes I misdiagnose the problem, and later when I suspect I did, being able to see the original output really helps me.
# If I tried/considered some other approaches to the problem and abandoned them, record those and why. I sometimes look back my old change and go "why did I fix it this way — doing it that way would be a whole lot better!", only to discover later that "ah, because this won't work if I've done that!", and I knew I've gone through the same trail of thoughts before. If I'm in a middle of a big change and decide to abandon a considerable portion of it, I sometimes even commit that and roll it back, just so that I can revisit why I abandoned it later.
# If a change should have been logically a part of a previous change, just say so. If I happen to know the commit ID of the previous change, I definitely leave that, but if I don't remember it, I still try to point to where that previous change was, like roughly when it was made, which file it was made, who did it, etc, so that future myself can narrow down the search space if I need to find it.

What's new in iBATIS 3