<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Coffee &#38; Code</title>
	<atom:link href="http://kevin.mudrick.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://kevin.mudrick.com</link>
	<description>Ramblings &#38; Adventures in Software Development</description>
	<lastBuildDate>Fri, 19 Feb 2010 13:33:29 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.2.1</generator>
		<item>
		<title>Useful Apps for Jailbroken iPhones</title>
		<link>http://kevin.mudrick.com/2009/12/06/useful-apps-for-jailbroken-iphones/</link>
		<comments>http://kevin.mudrick.com/2009/12/06/useful-apps-for-jailbroken-iphones/#comments</comments>
		<pubDate>Sun, 06 Dec 2009 06:25:33 +0000</pubDate>
		<dc:creator>kevin</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[iphone]]></category>
		<category><![CDATA[jailbreak]]></category>

		<guid isPermaLink="false">http://kevin.mudrick.com/?p=47</guid>
		<description><![CDATA[A few months back I decided to jailbreak my iPhone.  It is a powerful device and iPhone OS is rather snazzy, but lack of backgrounding non-Apple apps grew to be pretty frustrating. I won&#8217;t dive in to how to go about jailbreaking (I used Pwnage Tool to do the deed), since there are tons of [...]]]></description>
			<content:encoded><![CDATA[<p>A few months back I decided to jailbreak my iPhone.  It is a powerful device and iPhone OS is rather snazzy, but lack of backgrounding non-Apple apps grew to be pretty frustrating.  I won&#8217;t dive in to how to go about jailbreaking (I used <a href="http://blog.iphone-dev.org/post/211802082/pwnage-pie" onclick="javascript:pageTracker._trackPageview('/outbound/article/blog.iphone-dev.org');">Pwnage Tool</a> to do the deed), since there are tons of tutorials already out there.  I do, however, wish to list the apps/tweaks I have found rather useful since opening this up.  All of these apps can be installed via an out-of-the-box <a href="http://cydia.saurik.com" onclick="javascript:pageTracker._trackPageview('/outbound/article/cydia.saurik.com');">Cydia</a> which is an app &amp; software repository for jailbroken devices.</p>
<h3>Backgrounder</h3>
<p><a href="http://code.google.com/p/iphone-backgrounder" onclick="javascript:pageTracker._trackPageview('/outbound/article/code.google.com');">Backgrounder</a> is an extension that lets you run apps in the background.  This was originally my only intent with jailbreaking.  I often use <a href="http://www.normsoft.com/products/iphone/pockettunes/" onclick="javascript:pageTracker._trackPageview('/outbound/article/www.normsoft.com');">Pocket Tunes Deluxe</a> to stream local sports stations or Sirius radio, but having to quit the app every time I wanted to reply to an SMS message or check the twitters was pretty annoying.</p>
<h3>Cycorder</h3>
<p>Since I only an iPhone 3G, not the 3GS, I cannot record video on my device via the camera.  That is, until I installed <a href="http://cydia.saurik.com/info/cycorder/" onclick="javascript:pageTracker._trackPageview('/outbound/article/cydia.saurik.com');">this nifty app</a>.  The quality of the video it records is pretty nice.  Makes me wonder why Apple could not have extended this feature to those of us with our ancient year-old phones.</p>
<h3>SBSettings</h3>
<p>Invaluable method for quickly toggling all sorts of system properties with a simple screen swipe from anywhere.  Lets you toggle Wifi, 3G, Bluetooth, view/kill processes, see available memory and disk space, etc.   Awesomeness.</p>
<h3>Rotation Inhibitor</h3>
<p>This lets me toggle auto-rotation from SBSettings.  Personally, I find the rotation on this device to be mostly an annoyance.  I&#8217;m used to the regular keyboard layout, and sometimes when I am ever laying down on my side or walking, the auto-rotation tends to get wonky.  Presto, I can now turn it off (which I do.)</p>
<h3>ScreenSplitr</h3>
<p><a href="http://plutinosoft.com/screensplitr/" onclick="javascript:pageTracker._trackPageview('/outbound/article/plutinosoft.com');">ScreenSplitr</a> actually has come in rather handy at work.  This app will mirror your device screen onto a tv via a tv-out cable, or to a computer over wifi using an app called <a href="http://www.plutinosoft.com/blog/projects/demogod/" onclick="javascript:pageTracker._trackPageview('/outbound/article/www.plutinosoft.com');">DemoGod</a>.  This is not really meant for, say, watching video on a big screen, but it is perfect for doing application demos to a larger audience.</p>
<h3>SMS Helper</h3>
<p><a href="http://thebigboss.org/2009/10/08/sms-helper-is-released/" onclick="javascript:pageTracker._trackPageview('/outbound/article/thebigboss.org');">SMS Helper</a> modifies the default SMS app to count characters when composing a new message.  This is very helpful if you would rather not have your text split into multiple messages on the recipient&#8217;s end, or for texting to twitter.</p>
<h3>Mobile Terminal</h3>
<p>Want to drop into a shell on your iPhone?  Enter <a href="http://code.google.com/p/mobileterminal/" onclick="javascript:pageTracker._trackPageview('/outbound/article/code.google.com');">Mobile Terminal</a>.  Very useful if you ever need console access, especially considering things like wget, vim, etc have been ported to this platform.</p>
]]></content:encoded>
			<wfw:commentRss>http://kevin.mudrick.com/2009/12/06/useful-apps-for-jailbroken-iphones/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Getting JBossWS working with JDK 6</title>
		<link>http://kevin.mudrick.com/2009/11/23/getting-jbossws-working-with-jdk-6/</link>
		<comments>http://kevin.mudrick.com/2009/11/23/getting-jbossws-working-with-jdk-6/#comments</comments>
		<pubDate>Mon, 23 Nov 2009 21:57:44 +0000</pubDate>
		<dc:creator>kevin</dc:creator>
				<category><![CDATA[Things I Learned Today]]></category>
		<category><![CDATA[java6]]></category>
		<category><![CDATA[jax-ws]]></category>
		<category><![CDATA[jboss]]></category>
		<category><![CDATA[webservice]]></category>
		<category><![CDATA[wsdl]]></category>

		<guid isPermaLink="false">http://kevin.mudrick.com/?p=39</guid>
		<description><![CDATA[See https://jira.jboss.org/jira/browse/JBWS-1439 for more details, but essentially, there are some classpath issues with an out of the box JBoss 4.2.x and jdk6 when trying to use JBossWS (Implementation of JAX-WS stack in JBoss Application Server.) If you run into these problems, there is a simple fix. Copy the conflicting jars into the endorsed directory: cp [...]]]></description>
			<content:encoded><![CDATA[<p>See <a title="https://jira.jboss.org/jira/browse/JBWS-1439" rel="nofollow" href="https://jira.jboss.org/jira/browse/JBWS-1439" onclick="javascript:pageTracker._trackPageview('/outbound/article/jira.jboss.org');" target="_blank">https://jira.jboss.org/jira/browse/JBWS-1439</a> for more details, but essentially, there are some classpath issues with an out of the box JBoss 4.2.x and jdk6 when trying to use JBossWS (Implementation of JAX-WS stack in JBoss Application Server.)</p>
<p>If you run into these problems, there is a simple fix. Copy the conflicting jars into the endorsed directory:</p>
<pre>cp -t $JBOSS_HOME/lib/endorsed $JBOSS_HOME/server/all/lib/jboss-jaxrpc.jar \
  $JBOSS_HOME/server/all/lib/jboss-saaj.jar</pre>
<h2>Fixing the wsdl soap address brokenness</h2>
<p>Another problem you might run into is that the default wsdl generated will end up using whatever hostname JBoss thinks it is.  This is <strong>not</strong> necessarily the hostname that is accessible remotely.</p>
<p>To get around this, modify:</p>
<pre>$JBOSS_HOME/server/$instanceName/deploy/jbossws.sar/jbossws.beans/META-INF/jboss-beans.xml</pre>
<p>By commenting out the <em>webServiceHost</em> property in <em>WSServerConfig</em></p>
]]></content:encoded>
			<wfw:commentRss>http://kevin.mudrick.com/2009/11/23/getting-jbossws-working-with-jdk-6/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Ajax loading, sorting, and paginating of Displaytag tables</title>
		<link>http://kevin.mudrick.com/2009/11/23/ajax-loading-sorting-and-paginating-of-displaytag-tables/</link>
		<comments>http://kevin.mudrick.com/2009/11/23/ajax-loading-sorting-and-paginating-of-displaytag-tables/#comments</comments>
		<pubDate>Mon, 23 Nov 2009 17:19:54 +0000</pubDate>
		<dc:creator>kevin</dc:creator>
				<category><![CDATA[Quick How-To]]></category>
		<category><![CDATA[ajax]]></category>
		<category><![CDATA[displaytag]]></category>
		<category><![CDATA[jquery]]></category>
		<category><![CDATA[jsp]]></category>

		<guid isPermaLink="false">http://kevin.mudrick.com/?p=19</guid>
		<description><![CDATA[In a lot of my Java based web apps, I tend to make use of the wonderful Display Tag Library for rendering display tables.  It is pretty powerful and easy to do sorting, paging, decoration, etc with very little code.  I also tend to make use of jQuery as my preferred javascript library. It makes [...]]]></description>
			<content:encoded><![CDATA[<p>In a lot of my Java based web apps, I tend to make use of the wonderful <a href="http://displaytag.sourceforge.net" onclick="javascript:pageTracker._trackPageview('/outbound/article/displaytag.sourceforge.net');">Display Tag Library</a> for rendering display tables.  It is pretty powerful and easy to do sorting, paging, decoration, etc with very little code.  I also tend to make use of <a href="http://jquery.com" onclick="javascript:pageTracker._trackPageview('/outbound/article/jquery.com');">jQuery</a> as my preferred javascript library.  It makes doing DOM manipulation, ajax operations, styling, etc a breeze.</p>
<p>jQuery&#8217;s <a href="http://docs.jquery.com/Ajax/load" onclick="javascript:pageTracker._trackPageview('/outbound/article/docs.jquery.com');">Ajax/load</a> request allows you load external html from a remote source and inject it into the DOM.  This means you can keep your javascript and my page layout completely separate. Combining the use of displaytag and ajax/load is a snap, and allowing the sorting &amp; pagination to be ajax-driven rather than forcing page reloads is great.</p>
<p>In your jsp that renders the table (assuming you have an appropriately-scoped object called people available):</p>
<pre>&lt;s:url id="thisUrl"/&gt;
&lt;display:table class="people" id="peopleTable" name="${people}" requestURI="${thisUrl}" pagesize="5" sort="list"&gt;
  &lt;display:column property="name" title="Name" class="name" sortable="true"/&gt;
  &lt;display:column property="birthday" title="Birthday" class="birthday"/&gt;
&lt;/display:table&gt;</pre>
<p>And in your display page, from which you want to dynamically load this table and inject:</p>
<pre>&lt;script type="text/javascript"&gt;

  if (!com) var com = {};
  com.mudrick = {

    onPeopleTableLoad: function() {

      // Gets called when the data loads
      $("table#peopleTable th.sortable").each(function() {
        // Iterate over each column header containing the sortable class, so
        // we can setup overriding click handlers to load via ajax, rather than
        // allowing the browser to follow a normal link
        $(this).click(function() {
          // "this" is scoped as the sortable th element
          var link = $(this).find("a").attr("href");
          $("div#peopleData").load(link, {}, com.mudrick.onPeopleTableLoad);
          // Stop event propagation, i.e. tell browser not to follow the clicked link
          return false;
        });
      });

      $("div#peopleData .pagelinks a").each(function() {
        // Iterate over the pagination-generated links to override also
        $(this).click(function() {
          var link = $(this).attr("href");
          $("div#peopleData").load(link, {}, com.mudrick.onPeopleTableLoad);
          return false;
        });
      });
    }
  };

  $(document).ready(function() {
    // Load the initial rendering when the dom is ready.  Assuming you are injecting into a div
    // with id "peopleData" that exists in the page.
    $("div#peopleData").load("/remote/path/to/whatever/generates/table/above", {}, com.mudrick.onPeopleTableLoad);
  });

&lt;/script&gt;</pre>
<p>Presto!  Pagination + sorting in an ajaxy way using displaytag out of the box with some simple jQuery code.</p>
]]></content:encoded>
			<wfw:commentRss>http://kevin.mudrick.com/2009/11/23/ajax-loading-sorting-and-paginating-of-displaytag-tables/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Tracing uncaught exceptions in xcode</title>
		<link>http://kevin.mudrick.com/2009/10/30/tracing-uncaught-exceptions-in-xcode/</link>
		<comments>http://kevin.mudrick.com/2009/10/30/tracing-uncaught-exceptions-in-xcode/#comments</comments>
		<pubDate>Fri, 30 Oct 2009 16:51:46 +0000</pubDate>
		<dc:creator>kevin</dc:creator>
				<category><![CDATA[Things I Learned Today]]></category>
		<category><![CDATA[cocoa]]></category>
		<category><![CDATA[iphone]]></category>
		<category><![CDATA[objective-c]]></category>
		<category><![CDATA[xcode]]></category>

		<guid isPermaLink="false">http://kevin.mudrick.com/?p=17</guid>
		<description><![CDATA[One of the annoyances I had with doing iPhone development in Xcode, besides for the fact that it is not eclipse, or that editing multiple source files means having windows strewn about (as opposed to a nice tabbed interface), was that whenever I introduced a bug that caused an Uncaught Exception (i.e. TERMINATING_DUE_TO_UNCAUGHT_EXCEPTION) to be [...]]]></description>
			<content:encoded><![CDATA[<p>One of the annoyances I had with doing iPhone development in Xcode, besides for the fact that it is not eclipse, or that editing multiple source files means <a href="http://warpspire.com/tipsresources/programming/do-people-really-like-the-window-management-in-xcode/" onclick="javascript:pageTracker._trackPageview('/outbound/article/warpspire.com');">having windows strewn about</a> (as opposed to a nice tabbed interface), was that whenever I introduced a bug that caused an Uncaught Exception (i.e. <strong>TERMINATING_DUE_TO_UNCAUGHT_EXCEPTION</strong>) to be thrown, I&#8217;d be lost trying to trace its origin.  Java stacktraces have line numbers and all, which in Eclipse, takes me directly to the offending location.  Easy.</p>
<p><a href="http://www.catamount.com/blog/?p=547" onclick="javascript:pageTracker._trackPageview('/outbound/article/www.catamount.com');">This guy figured out how to get similar behavior in Xcode</a>.</p>
<p>In the event that the referenced blog entry ever goes away&#8230; You need to add <em>an objc_exception_throw</em> breakpoint to your global breakpoints.</p>
<p>Why this isn&#8217;t configured as such out of the box, I don&#8217;t know.</p>
]]></content:encoded>
			<wfw:commentRss>http://kevin.mudrick.com/2009/10/30/tracing-uncaught-exceptions-in-xcode/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Re-configuring JBoss RewriteValve without restarting</title>
		<link>http://kevin.mudrick.com/2009/09/30/re-configuring-jboss-rewritevalve-without-restarting/</link>
		<comments>http://kevin.mudrick.com/2009/09/30/re-configuring-jboss-rewritevalve-without-restarting/#comments</comments>
		<pubDate>Wed, 30 Sep 2009 21:44:54 +0000</pubDate>
		<dc:creator>kevin</dc:creator>
				<category><![CDATA[Things I Learned Today]]></category>
		<category><![CDATA[jboss]]></category>

		<guid isPermaLink="false">http://kevin.mudrick.com/?p=5</guid>
		<description><![CDATA[At my company, I often make use of the wonderful Rewrite Valve that comes with JBoss Web.  This is very similar to mod_rewrite that you&#8217;d use with Apache Httpd, but instead applicable to your JBoss/Tomcat install.  I find it very handy for rewriting short urls outside of your app&#8217;s context root. For instance, how else [...]]]></description>
			<content:encoded><![CDATA[<p>At my company, I often make use of the wonderful <a href="http://labs.jboss.com/jbossweb/modules/rewrite/index.html" onclick="javascript:pageTracker._trackPageview('/outbound/article/labs.jboss.com');">Rewrite Valve</a> that comes with JBoss Web.  This is very similar to mod_rewrite that you&#8217;d use with Apache Httpd, but instead applicable to your JBoss/Tomcat install.  I find it very handy for rewriting short urls outside of your app&#8217;s context root.</p>
<p>For instance, how else would I have <strong>http://host/a123</strong> really be processed by <strong>http://host/MyApp/Processor.action?id=123</strong>?  I won&#8217;t get into the specifics of configuring tomcat valves or, in particular, this one, but I will briefly touch on something I previously thought was not possible:  Making changes to a running configuration without incurring the downtime of performing a jboss restart.</p>
<p>Assuming that your rewrite valve is configured in your jboss.web engine&#8217;s default hostname (i.e. the valve is configured in /Server/Engine/Host/ in $JBOSS_HOME/server/$INSTANCE/deploy/jboss-web.deployer/server.xml) you&#8217;d do the following.  I&#8217;m using JBoss 4.2.3GA btw.</p>
<pre>$JBOSS_HOME/bin/twiddle.sh -s localhost:$JMX_PORT \
  set 'jboss.web:host=$ENGINE_HOST,name=RewriteValve,type=Valve' configuration \
  "$(cat $JBOSS_HOME/server/$INSTANCE/conf/jboss.web/$ENGINE_HOST/rewrite.properties)"</pre>
<p>My variables:</p>
<pre>JMX_PORT=1099
INSTANCE=default
ENGINE_HOST=localhost</pre>
<p>You should then see the configuration print to <em>STDOUT</em>, and the changes will be active.</p>
<p>It would be great if you could do this from the JMX console.  Unfortunately, browsers hose the newlines in your rewrite rules (pretty important) and there&#8217;s a <a href="https://jira.jboss.org/jira/browse/JBWEB-147" onclick="javascript:pageTracker._trackPageview('/outbound/article/jira.jboss.org');">bug in the getter implementation of the RewriteValve</a> that might mess things up.</p>
]]></content:encoded>
			<wfw:commentRss>http://kevin.mudrick.com/2009/09/30/re-configuring-jboss-rewritevalve-without-restarting/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

