Skip to main content

Posts

Pursuing Your Dream - beware the awful advice people will give you

DivineCaroline.com  wrote this inspiring article. Simply put, your life starts now, every day is a new chance to change it into what you want it to be - thanks caroline! Unfortunately, just before you take your first step on the righteous journey to pursue your dreams, people around you, even the ones who deeply care for you, will give you awful advice. It’s not because they have evil intentions. It’s because they don’t understand the big picture—what your dreams, passions, and life goals mean to you. They don’t understand that, to you, the reward is worth the risk. So they try to protect you by shielding you from the possibility of failure, which, in effect, also shields you from the possibility of making your dreams a reality. As the late Steve Jobs says: “Your time is limited, so don’t waste it living someone else’s life. Don’t be trapped by dogma, which is living with the results of other people’s thinking. Don’t let the noise of others’ opinions drown out your own...
Recent posts

“The Google+ Platform is a Pathetic Afterthought”

I saw this headline and had to read it. Steve’s Google Platforms Rant was great. I don't think I like Amazon much now, knowing what goes on behind the scenes (supposedly) - a bit like those sweat shops in Thailand for Nike, instead its teams of programmers cowering under the "do it or get fired" mantra. If true, it sounds like a crap place to work. You can read it here:  http://siliconfilter.com/google-engineer-google-is-a-prime-example-of-our-complete-failure-to-understand-platforms/

Spring enabled code co-existing with the legacy code

Today I needed to build a bridge and found this code to do exactly what I needed. My rationale for introducing Spring into the application I am working on also is that maintenance and enhancement are very difficult and time-consuming with the existing architecture. However, the conversion is not going to happen overnight, and neither can we mandate that all new development should stop as we move to the new architecture. It is also not possible to build and deploy the new functionality in separate web applications, because we don't have the resources to handle the deployment issues that such an approach would require. So our new Spring enabled code co-exists with the legacy code in the same web application. One by-product of this setup is that we often end up developing non-GUI components using Spring, which need to be hooked into existing legacy code so we can reuse the legacy request flow. There are three ways we could do this: Build the Spring bean manually in our legacy co...

Top Ten Things to Build a Bridge and Get Over

Found this list by Mary Rosendale (a life coach) and had to shamelessly steal it and put it here seeing that its what I named this blog after, enjoy... 1. Nobody knows why anybody does anything. Imagine the time this one will free up. You don’t need to figure out what happened to Aunt Bertha as a child to make her so mean and crabby; why your s.o. dumped you; why your neighbor ignores you. We humans are a product of our upbringing; environment, genetics and hormones. We do what we do when we do it. Let it go. Don’t take it personally. 2. Nobody owes you a thing. When you think about all the time, love and attention it took to get where you are today you’ll see that you can never repay the debt. Your mother and father who raised you; your teachers who pushed and believed in you; your friends who supported you; your community which nurtures you. Question is : what have you given back in return? 3. You’ll be balanced when you’re dead. Not a moment sooner. Balance schmalanace. We chase it ...

classpath*: vs. classpath

I had this problem Today, googled and again found a solution. Google is great. Using classpath*: vs. classpath: when loading Spring resources. I recently resolved a build problem nestled deep within the esoterica of spring resource loading. The behavior of classpath: URLs is explained at length in the Spring documentation, but, sadly, this is probably the last place a developer of my disposition would look. The problem (which I describe in more detail beyond the fold) was that we were unable to load hibernate mapping files from our Spring configured integration tests even though they gave us no trouble in our web application. The solution was to replace the "classpath:" prefix of our mappingLocation URI with "classpath*:". In this project, we are storing our Hibernate mapping files as separate files located in the package of the class they map (i.e. "Foo.hbm.xml" stored in "src/main/java/com/example/"). We inherited the persisted classes and Hib...

JdbcTemplate with Autocommit

I am currently converting a straight jdbc codebase into a spring based jdbc template codebase and saw that part of the code used a method called getAutoCommitConnection() which did a conn.setAutoCommit(true); This lead me to ask the question of whether springs' jdbcTemplate.update() does autocommit the transaction. Appartently it does according to this post http://saloon.javaranch.com/cgi-bin/ubb/ultimatebb.cgi?ubb=get_topic&f=83&t=001006 However, this guy had another situation where updating then immediately trying to read rows failed. http://sujitpal.blogspot.com/2006/12/spring-jdbctemplate-with-autocommit.html I am a about to find out for myself with my own tests, however apparently it comes down to the transaction isolation level set at the Database. If its DEFAULT isolation level is READCOMMITTED, and you're working with a spring datasource which is connection pooled (as in my case) then you'll get this problem. By default, SQL Server operates at READ COMMITTED...