I truly do not understand all I know about this, but I’ve been tripped up by this several times now.
After working on a java servlet in Eclipse on a home machine (which happens to be Windows in this case), when I’m ready to deploy I export a WAR file and upload it to Tarragon, the Fedora box that serves this site. I copy the WAR file into /usr/share/tomcat6/webapps, and tomcat redeploys it. Then I have to fix the context.xml to change the datasources from the test database to the real database. Naturally I do this in /usr/share/tomcat6/webapps/<app>/META-INF/context.xml. Then I fire it up, and it fails. Continue reading Deploying Tomcat from Eclipse
Monthly Archives: June 2012
Flying the Rockies
In an earlier post I mentioned that my early flight education inculcated me with a healthy fear of flying in the mountains, and that I’m trying to build up my confidence. I’m “stretching” myself, pushing myself. Two weeks ago I flew to Steamboat Springs, a charming little town in Northern Colorado. Yesterday I flew to Glenwood Springs on the other side of the Rockies. In both cases this means flying through the mountains. Glenwood Springs is quite a challenging little airport, nestled down in a valley with mountains all around. To get down to pattern altitude (7000 feet) I was descending in a valley southeast where the airport was out of sight, and then flying around this little ridge to finally get into the pattern. The final comes over a little river which creates some little downdraft. And of course this is only a 3100 foot runway. Plenty of runway I suppose, unless you are as inexperienced as I am. I’m landing the twin at blue line, which is 120mph, so if I don’t get it down pretty quick I’ll run out of runway, and the other end of this runway is not very accommodating to running over. Experience pilots would laugh at me. Bush pilots put bigger planes down in much smaller runways. But I’m still pleased. I’m pushing myself, and I’m learning.
Standalone java apps vs JNDI datasources
This is another post as a memory jogger for me.
Whenever I switch back to java I have trouble remembering the evolving history of setting up mysql connections. Back in the dark ages, you used to do this with Class.forName. But by the time I started writing servlets initially, it was being done instead with DriverManager. Then along came DataSources which could be set up in JNDI. A much more elegant solurtion, as long as you have a container to offer the JNDI service. Most of the active java I have is servlets running in Tomcat, and these are happily set up to use DataSource objects, and the DataSources are all described in the context and picked off from there. Continue reading Standalone java apps vs JNDI datasources
Starting Services
There is no great insight in this post, it is only to help me remember how to start services in Fedora and Ubuntu as I have both. I used Fedora long enough to get used to the old chkconfig stuff, but now thats gone. Ubuntu never did that anyway. They are different, and I get confused about which new syntax to use on which system.
If somebody other than me ever reads this, be careful to check dates and versions before you believe anything I write. It will probably change. This is as of Fedora 16 and Ubuntu 12.04. Continue reading Starting Services