<?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>Weneck.com</title>
	<atom:link href="http://weneck.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://weneck.com</link>
	<description>Rusty Weneck&#039;s little corner of the interweb.</description>
	<lastBuildDate>Thu, 15 Apr 2010 22:57:50 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Copy to Excel from Flex</title>
		<link>http://weneck.com/2010/04/15/copy-to-excel-from-flex/</link>
		<comments>http://weneck.com/2010/04/15/copy-to-excel-from-flex/#comments</comments>
		<pubDate>Thu, 15 Apr 2010 22:51:19 +0000</pubDate>
		<dc:creator>Rusty Weneck</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[Computer Science]]></category>
		<category><![CDATA[Excel]]></category>
		<category><![CDATA[Flash]]></category>
		<category><![CDATA[Flex]]></category>

		<guid isPermaLink="false">http://weneck.com/?p=342</guid>
		<description><![CDATA[]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve promIsed my next article would be on Spring 3, as part 3 in my series on the web application. However, I&#8217;m going to take a little segway to a neat solution I&#8217;ve come up with for a common requirement that is a little tricky to solve. Copying data out of a data grid and being able to paste that data into Microsoft&#8217;s Excel. </p>
<p>Flex is often used for displaying and calculating many different metrics. Sometimes a new metric, or a one off request will come in to see the data in a slightly different way or with an additional calculation. A lot of times the one off requests don&#8217;t illicit a development investment to get the new analytic. Others might be too much of an immediate need and a development cycle would take too long. For this the ability to export the data to a less than friendly(IMHO), but standard and well know tool is a huge plus. Enter stage left&#8230;. <a href="http://weneck.com/wp-content/uploads/2010/04/copyToExcel/FlexDataGridCopyToExcel.html">Copy to Excel</a>.</p>
<p>Copy the entire contents of the grids (both AdvancedDataGrid and DataGrid are supported, I wish these implemented a common interface) by not selecting any rows, or just the selected rows by selecting them (use shift or ctrl with click to multi select/deselect). This will call a static method in a util class (source available) that takes a single parameter, the grid itself. All data conversion from its dataProvider is handled, along with a header row with the headerText and if any of the fields use a labelFunction, that too is called to formate the data.</p>
<p>This is released under the <a href="http://www.opensource.org/licenses/mit-license.php">MIT License</a>, and is free for anyone to use/modify/distribute as they see fit. Just give props back here somewhere in the source.</p>
]]></content:encoded>
			<wfw:commentRss>http://weneck.com/2010/04/15/copy-to-excel-from-flex/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Hibernate</title>
		<link>http://weneck.com/2010/02/25/hibernate/</link>
		<comments>http://weneck.com/2010/02/25/hibernate/#comments</comments>
		<pubDate>Thu, 25 Feb 2010 21:03:14 +0000</pubDate>
		<dc:creator>Rusty Weneck</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[Computer Science]]></category>
		<category><![CDATA[Hibernate]]></category>
		<category><![CDATA[Java]]></category>
		<category><![CDATA[Maven]]></category>
		<category><![CDATA[Web Application]]></category>

		<guid isPermaLink="false">http://weneck.com/?p=325</guid>
		<description><![CDATA[
So this has been a long time coming. I&#8217;ve put it off time and time again because there was just so much area I wanted to cover. (see previous post) So finally I&#8217;ve decided to cut a bunch of scope and just get this done.
This article is part 2 in a series of 3, which [...]]]></description>
			<content:encoded><![CDATA[<p><a href="https://www.hibernate.org/" target="_blank"><img class="alignnone size-full wp-image-330" title="hibernateLogo" src="http://weneck.com/wp-content/uploads/2010/02/hibernateLogo.png" alt="hibernate logo" width="228" height="38" /></a><br />
So this has been a long time coming. I&#8217;ve put it off time and time again because there was just so much area I wanted to cover. (see <a href="http://weneck.com/2009/11/09/maven/" target="_blank">previous post</a>) So finally I&#8217;ve decided to cut a bunch of scope and just get this done.</p>
<p>This article is part 2 in a series of 3, which I started way back in November. The project herein is a continuation of that project and the updated project files are included <a href="http://weneck.com/wp-content/uploads/2010/02/WebApplication.zip" target="_blank">here</a>. I won’t be covering the additional Maven issues in hopes that the first article brought you (the reader) up to speed on those. I will say there are some additional dependencies, so it would be best to use the new files and update your eclipse project files by running the eclipse:eclipse target with Maven.</p>
<h2><strong><a href="https://www.hibernate.org/" target="_blank">Hibernate</a></strong></h2>
<p>Hibernate is a great tool. It makes my life easier, and that is good. It started out as a Java only technology.  After checking the <a href="https://www.hibernate.org/" target="_blank">website</a> it appears they have a .NET version too. Hibernate is a persistence manager. Well you say, “Whatever does that mean?” Well it means that I can map my objects to a set of tables and Hibernate will manage their persistence. Hibernate is language agnostic. For the most part you just tell it what database dialect to use and unless you are using some special features not supported by other databases you can pick a code base up and move it from one DB to another with no change. Another great thing about hibernate is its ability to load an entire object graph, eagerly or lazily, just from querying a single object. For instance let’s say you have a person object, and that person has an address object on it (or even several). Issuing a query for that person will automatically load the address. (For lazy loading it will actually proxy the object and then retrieve the address when the getter is called but that is beyond the scope of the project, yet again, so I won’t go there.) And the last big plus Hibernate brings you, all of this being in my opinion, is updating and keeping object references the same for objects which should be the same and are loaded in 2 different places. Imagine doing all of this in straight JDBC, yuck, I don&#8217;t even want to think about that.</p>
<h2><strong>Let’s get started!</strong></h2>
<p>First things first, download and install <a href="http://dev.mysql.com/downloads/mysql/" target="_blank">MySql</a>, my favorite database. Once you have it all installed, create a user, you can name it whatever you like but I choose test, with a password of&#8230; password. If you stray from these values you&#8217;ll want to change the configuration that we&#8217;ll talk about later. For administrating MySql, if you&#8217;re not comfortable with the command line, which I admit can be a bit daunting with a DBMS, then I suggest you also install the <a href="http://dev.mysql.com/downloads/gui-tools/5.0.html" target="_blank">MySql GUI tools</a>, they are great and work for Windows, Mac, and Linux. After creating the user, also create a database, again I would call it test, and give the user permissions to access it. I had hoped to do this all using an in memory DB like Derby or Hypersonic, but again out of scope.</p>
<p>The next thing you want to do is to execute the DDL I&#8217;ve prepared which is in the application&#8217;s src/main/resources/ directory. Creatively enough it’s titled DDL.sql. It’s important for me to note that Hibernate can create this file for you based on either your mapping files or your annotations (more on these later), but again it was out of the scope so I went ahead and prepared one for you.</p>
<h2><strong>Down to the nitty gritty.</strong></h2>
<p>Now our database is set up and we are ready to get going.  First thing’s first, we need to tell spring where our data source is and where does our database server live.  It won’t always be localhost, in fact most of the time it shouldn&#8217;t be. So we are going to create a datasource bean using spring, which we will later provide to our DAO&#8217;s for use with Hibernate. For defining our data source we have several options.  I hopefully have chosen the simplest one, which is to declare an instance of spring&#8217;s <a href="http://static.springsource.org/spring/docs/2.5.6/api/org/springframework/jdbc/datasource/DriverManagerDataSource.html" target="_blank">DriverManagerDataSource</a> bean in the spring-web-config.xml file like so&#8230;</p>
<p><code>&lt;bean id="dataSource" class="org.springframework.jdbc.datasource.DriverManagerDataSource"&gt;<br />
	&lt;property name="driverClassName"&gt;&lt;value&gt;com.mysql.jdbc.Driver&lt;/value&gt;&lt;/property&gt;<br />
	&lt;property name="url"&gt;&lt;value&gt;jdbc:mysql://localhost:3306/test&lt;/value&gt;&lt;/property&gt;<br />
	&lt;property name="username"&gt;&lt;value&gt;test&lt;/value&gt;&lt;/property&gt;<br />
	&lt;property name="password"&gt;&lt;value&gt;password&lt;/value&gt;&lt;/property&gt;<br />
&lt;/bean&gt;</code></p>
<p>This is the code block you will want to pay attention to if you have used a different username/password than I did. So what is this doing for us? Well this is telling spring to instantiate an object that is a DriverManagerDataSource. On that object it is setting 4 parameters; the JDBC driver to use, the location of the database, the username, and of course the password. Later we will use this bean in our DAO&#8217;s so that they can connect to the database. Alternatively we could have used JNDI to locate a defined data source which lives most likely in a server config out there somewhere, but this is out of the scope for what I want to accomplish.</p>
<p>The next thing we need to do is to set up the session factory in our DAO config. We are going to configure our DAO using a file called spring-dao.xml.  We load this file in the web.xml file in the context config section.</p>
<p><code>	&lt;bean id="sessionFactory"<br />
		class="org.springframework.orm.hibernate3.annotation.AnnotationSessionFactoryBean"&gt;<br />
		&lt;property name="hibernateProperties"&gt;<br />
			&lt;props&gt;<br />
				&lt;prop key="hibernate.dialect"&gt;org.hibernate.dialect.MySQLDialect&lt;/prop&gt;<br />
				&lt;prop key="batch_size"&gt;15&lt;/prop&gt;<br />
				&lt;prop key="fetch_size"&gt;30&lt;/prop&gt;<br />
				&lt;prop key="hbm2ddl.auto"&gt;false&lt;/prop&gt;<br />
				&lt;prop key="hibernate.show_sql"&gt;false&lt;/prop&gt;<br />
			&lt;/props&gt;<br />
		&lt;/property&gt;</p>
<p>		&lt;property name="dataSource"&gt;<br />
			&lt;ref bean="dataSource" /&gt;<br />
		&lt;/property&gt;</p>
<p>		&lt;property name="annotatedClasses"&gt;<br />
			&lt;list&gt;<br />
				&lt;value&gt;com.weneck.webapplication.domain.Game&lt;/value&gt;<br />
			&lt;/list&gt;<br />
		&lt;/property&gt;<br />
	&lt;/bean&gt;</p>
<p>	&lt;bean id="transactionManager"<br />
		class="org.springframework.orm.hibernate3.HibernateTransactionManager"&gt;<br />
		&lt;property name="sessionFactory"&gt;<br />
			&lt;ref bean="sessionFactory" /&gt;<br />
		&lt;/property&gt;<br />
	&lt;/bean&gt;</code></p>
<p>This does a few things for us. First are the Hibernate properties. We tell Hibernate what dialect to use, some parameters on how to batch queries, and if it should show the SQL being used. After all, Hibernate does still use SQL to communicate with the DB and these statements can be a great way to debug or just learn. Next, we provide the datasource. Remember that datasource bean we just defined, her is where we are using it. Additionally we have a transaction manager, and the location of our annotated classes. For now we only have 1 annotated class in hopes at keeping this simple. Finally we are going to want to set up our JDBC template for our JDBC counterpart. I&#8217;ve included a duplicate DAO which uses JDBC instead of hibernate to illustrate the differences.</p>
<h2><strong>Domain what?</strong></h2>
<p>Lets model our domain. I&#8217;m sure by now, especially after applying the DDL you have guessed our domain is a simple object representing a video game. Now we need to model our object in the java world. Take a look at Game.java. At its heart Game has 4 attributes; id, title, platform, and description. What isn’t as clear, perhaps are the annotations marking up the class everywhere. These are JPA standard annotations, which are compatible with Hibernate and tells hibernate what to do with these objects. Let’s take a closer look.</p>
<ul>
<li>@Entity  &#8211;  this tells hibernate that this class should be considered an entity. Easy enough right?</li>
<li>@Table(name=&#8217;games&#8217;) &#8211; this tells hibernate what table in the database this entity maps too, still easy.</li>
<li>@Id &#8211; This tells hibernate that this column/attribute should be considered the primary key of the entity. For composite primary keys you should take a look at the documentation for @EmbeddedId and @Embeddable.</li>
<li>@GeneratedValue(strategy=GenerationType.IDENTITY) &#8211; this is perhaps a more vague annotations, in our case MySql supports auto_increment, this is a good thing, it means that objects inserted will automatically receive the next value for their id column. Other languages (*cough* I’m looking at you Oracle) do not support this, in that case you need to define a sequence, and tell Hibernate to use the sequence with @SequenceGenerator and a different strategy for the @GeneratedValue annotation. Man, I need to stay on topic.</li>
<li>@Column(name=&#8221;id&#8221;) &#8211; this is hopefully the easiest one to understand, what column in the table does this attribute map to.</li>
</ul>
<p>There are a ton of other useful annotations, including adding constraints @NotNull, where clauses that are ever present @Where, and mapping @OneToOne, @ManyToOne, @OneToMany, and @ManyToMany relationships.</p>
<h2><strong>The DAO Layer</strong></h2>
<p>Next we need to write our DAO&#8217;s. As a general rule and a good practice, DAO&#8217;s should not contain any logic, but merely manage objects persistence to and from the database. This isn&#8217;t always possible, but something to think about when writing your DAOs. I&#8217;ve started by creating a GameDao.java interface. We want to be able to list all of our games, search our games, and save a game. So these are the 3 methods I&#8217;ve defined in my DAO. There is a JDBC implementation of this DAO in GameDaoJDBCImpl.java and a Hibernate implementation at GameDaoImpl.java. Once these are written we need to define them in the spring-dao.xml file, and provide them with the data source or the session factory depending on their implementation. Notice each DAO extends a different spring helper class for providing common functionality.</p>
<p>For the hibernate side there are a few important built in methods for managing your domain. Load and Get are good ones, simply call getHibernateTemplate().load(Class.class, Id); or getHibernateTemplate().get(Class.class, Id); specifying the class you want to load along with the primary key you specified with the @Id or @EmbeddedId anotations in the model class. That’s it, the object will come back, properly typed and everything. The loadAll method is similar but you need not specify an id and you get all the objects of the type Class.class. Save is pretty simple, though in my opinion should not be used. It takes an object and saves it. Easy! But it&#8217;s my preference to instead use saveOrUpdate, since this will save a new object or as the name suggest update an existing one, thusly killing two birds with one stone. Update, well, if you read that last sentence you know how I feel about update. Delete, pretty easy this one, it deletes the object.</p>
<p>Now we are getting to some of the fun methods. Find will return a typed list of object that meet the criteria supplied in the HQL statement. Whoah, HQL, what’s that? Well it’s nearly identical to SQL, only you can use the java entity name and attribute name of those entities instead of having to reference the column names directly. This includes automatically joining the attributes that might be joined into the entity using some of the @OneToOne etc&#8230; anotations. Last there is Execute. It again does as it says, will execute a statement, usually a ddl statement tough it doesn&#8217;t have to be.</p>
<h2><strong>Spring Services</strong></h2>
<p>Normally here is where I would tell you to create your services, configure them in the spring-service.xml file, and put any logic in these classes. In this simple example however, we aren&#8217;t really coding any logic, so we&#8217;ll bypass this important layer of the web application.</p>
<h2><strong>The Results</strong></h2>
<p>Fire up that server and open a browser to <a href="http://localhost:8080/WebApplication/test/" target="_blank">http://localhost:8080/WebApplication/test/</a></p>
<p>Just for funzies I&#8217;ve included a JDBC implementation for comparison. If you look in the TestServlet.init() method on line 28, you can toggle the comment to use this implementation instead. Such a contrite example it doesn&#8217;t showcase all the greatness that Hibernate is, but with a little imagination I bet you can see your way through to the possibilities.</p>
<p>Next up…the whole reason for starting this series, Spring 3 MVC. It’s gonna be a good&#8217;un.</p>
]]></content:encoded>
			<wfw:commentRss>http://weneck.com/2010/02/25/hibernate/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Where is episode 2</title>
		<link>http://weneck.com/2010/01/13/where-is-episode-2/</link>
		<comments>http://weneck.com/2010/01/13/where-is-episode-2/#comments</comments>
		<pubDate>Wed, 13 Jan 2010 22:03:24 +0000</pubDate>
		<dc:creator>Rusty Weneck</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://weneck.com/2010/01/13/where-is-episode-2/</guid>
		<description><![CDATA[So, anyone who might be following this blog (read: no-one), might be wondering where the follow up to the three part series on the spring maven web app is. Well get off my back, I&#8217;ve been busy, and perhaps a little over zealouse. I started to write/develope the second part to the series, but scope [...]]]></description>
			<content:encoded><![CDATA[<p>So, anyone who might be following this blog (read: no-one), might be wondering where the follow up to the three part series on the spring maven web app is. Well get off my back, I&#8217;ve been busy, and perhaps a little over zealouse. I started to write/develope the second part to the series, but scope creep really impeded my progress. I got to thinking, well I can&#8217;t just set them up with hibernate, I need to explain unitils, testing automation, data scripts&#8230; oh wait, they need a db, I don&#8217;t wantto require them to download and install mySQL, Oracle, or God forbid MsSQL. better research Hypersonic, or should I use Derby? Oh how do I automate db creation so the user only needs to run a simple maven command? As you can see I was wandering off into the weeds and now am trying to pull in the reigns of the scope. After all, the main reason for writing this series was to showcase Spring 3 (which is release quality now !) So look back here in the coming weeks (read: months) for the next part when I can finally catch up with my ambitions</p>
]]></content:encoded>
			<wfw:commentRss>http://weneck.com/2010/01/13/where-is-episode-2/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Prototype image flip</title>
		<link>http://weneck.com/2009/12/22/prototype-image-flip/</link>
		<comments>http://weneck.com/2009/12/22/prototype-image-flip/#comments</comments>
		<pubDate>Tue, 22 Dec 2009 15:34:31 +0000</pubDate>
		<dc:creator>Rusty Weneck</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[Computer Science]]></category>
		<category><![CDATA[HTML]]></category>
		<category><![CDATA[Javascript]]></category>

		<guid isPermaLink="false">http://weneck.com/?p=320</guid>
		<description><![CDATA[I found a great Javascript image flip function over at Webmuch and wanted to use it, problem was it was only implemented in JQuery. I was using Prototype and script.aculo.us, so I ported it over. I ended up not using it, but for future reference I&#8217;ll preserve it here. Enjoy.
//adapted from a jQuery flip function [...]]]></description>
			<content:encoded><![CDATA[<p>I found a great Javascript image flip function over at <a href="http://webmuch.com/image-flip-using-jquery/">Webmuch</a> and wanted to use it, problem was it was only implemented in <a href="http://jquery.com/">JQuery</a>. I was using <a href ="http://www.prototypejs.org/">Prototype</a> and <a href="http://script.aculo.us/">script.aculo.us</a>, so I ported it over. I ended up not using it, but for future reference I&#8217;ll preserve it here. Enjoy.<br />
<code>//adapted from a jQuery flip function found here.<br />
//http://webmuch.com/image-flip-using-jquery/<br />
var tweenDuration = 0.5;</p>
<p>//get the image elements.<br />
var image1 = $('theFirstImage');<br />
var image2 = $('theSecondImage');</p>
<p>//set up the flip function<br />
image1.observe( 'click', function(event){<br />
        //set the heights so that the images do-not scale with the widths (if not explicitly set)<br />
        image1.height = image1.height;<br />
        image2.height = image2.height;</p>
<p>        var halfWidth = image1.width/2;</p>
<p>        image2.setStyle({marginLeft: halfWidth});<br />
        image2.width = 0;</p>
<p>        new Effect.Tween(image1, 250, 0, {duration: tweenDuration}, 'width');<br />
        new Effect.Tween(image1, 0, halfWidth, {duration: tweenDuration}, function(p){image1.setStyle({marginLeft: p})});<br />
        window.setTimeout(<br />
                function(){<br />
                    new Effect.Tween(image2, 0, 250, {duration: tweenDuration}, 'width');<br />
                    new Effect.Tween(image2, halfWidth, 0, {duration: tweenDuration}, function(p){image2.setStyle({marginLeft: p})});<br />
                }<br />
                , tweenDuration*1000);<br />
    }<br />
);<br />
image2.observe( 'click', function(event){<br />
        image2.height = image2.height;<br />
        image1.height = image1.height;</p>
<p>        var halfWidth = image2.width/2;</p>
<p>        image1.setStyle({marginLeft: halfWidth});<br />
        image1.width = 0;</p>
<p>        new Effect.Tween(image2, 250, 0, {duration: tweenDuration}, 'width');<br />
        new Effect.Tween(image2, 0, halfWidth, {duration: tweenDuration}, function(p){image2.setStyle({marginLeft: p})});<br />
        window.setTimeout(<br />
                function(){<br />
                    new Effect.Tween(image1, 0, 250, {duration: tweenDuration}, 'width');<br />
                    new Effect.Tween(image1, halfWidth, 0, {duration: tweenDuration}, function(p){image1.setStyle({marginLeft: p})});<br />
                }<br />
                , tweenDuration*1000);<br />
    }<br />
);</code></p>
]]></content:encoded>
			<wfw:commentRss>http://weneck.com/2009/12/22/prototype-image-flip/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Revision 3 ads</title>
		<link>http://weneck.com/2009/11/27/revision-3-ads/</link>
		<comments>http://weneck.com/2009/11/27/revision-3-ads/#comments</comments>
		<pubDate>Fri, 27 Nov 2009 08:36:53 +0000</pubDate>
		<dc:creator>Rusty Weneck</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[Revision3]]></category>

		<guid isPermaLink="false">http://weneck.com/2009/11/27/revision-3-ads/</guid>
		<description><![CDATA[So it&#8217;s dark o&#8217;thirty in the morning and I&#8217;m standing in a rediciously long line at one of those Friday after thanksgiving sales. What a better way to pass the time than listening to one of my favorite revision 3 shows, since episode 1, Diggnation. I gotta say, I do enjoy those guys, their shenanigans [...]]]></description>
			<content:encoded><![CDATA[<p>So it&#8217;s dark o&#8217;thirty in the morning and I&#8217;m standing in a rediciously long line at one of those Friday after thanksgiving sales. What a better way to pass the time than listening to one of my favorite revision 3 shows, since episode 1, Diggnation. I gotta say, I do enjoy those guys, their shenanigans and whatnot, and they do deserve a buck, but when the adds in the show start approaching half the content has it gone too far? They do a good job at making them entertaining, but all grouped togethor at the end gets to be a bit long of an intermission for me. Will it change my viewing habits? Maybe, I&#8217;ll continue to support them for now, this whole iptv thing is new and revision 3 is definatley blazing the path, but users are going to start to lose interest if these continue to grow.<br />
Remember when I said it was dark o&#8217;thirty? Did anything I just say make sence? Well that&#8217;s the kind of soap box rants you&#8217;re gona get around here when I&#8217;m sleepy.</p>
]]></content:encoded>
			<wfw:commentRss>http://weneck.com/2009/11/27/revision-3-ads/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Maven</title>
		<link>http://weneck.com/2009/11/09/maven/</link>
		<comments>http://weneck.com/2009/11/09/maven/#comments</comments>
		<pubDate>Tue, 10 Nov 2009 01:04:04 +0000</pubDate>
		<dc:creator>Rusty Weneck</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[Computer Science]]></category>
		<category><![CDATA[Java]]></category>
		<category><![CDATA[Maven]]></category>
		<category><![CDATA[Web Application]]></category>

		<guid isPermaLink="false">http://weneck.com/?p=307</guid>
		<description><![CDATA[Maven
What it is and what it isn&#8217;t
Maven is first and probably most agreed on by developers a dependency manager. Public repositories all over the net house project dependencies, as well as files called poms which contain descriptors of other files that the dependency is dependent on. As a dev this can be quite a time [...]]]></description>
			<content:encoded><![CDATA[<h1><a href="http://maven.apache.org/index.html" target="_blank">Maven</a></h1>
<h2><strong>What it is and what it isn&#8217;t</strong></h2>
<p>Maven is first and probably most agreed on by developers a dependency manager. Public repositories all over the net house project dependencies, as well as files called poms which contain descriptors of other files that the dependency is dependent on. As a dev this can be quite a time saver so that all dependencies are downloaded and placed on the class path instead of manually downloading 1, finding out what jars its missing, then downloading those&#8230; so on and so forth.<br />
Secondly maven is a build framework. Maven aims to be a constant for building any java project across all java projects. With a standard life cycle developers can become familiar with the framework and aim for a smoother build process. In order to do this Maven needs to be extend-able. Good thing it is. Maven has oodles of plug-ins for near any task for the build process. Plug-ins can (obviously) build java code, run ant tasks, run automated testing, run sql code, run code coverage reports, deploy artifacts (to a repository or a server), exec os code, pretty much the sky is the limit.</p>
<h2><strong>Installation.</strong></h2>
<p>Installing maven is not a complicated process but many get confused with it, mostly because of setting the proper environmental variables. First make sure you have java properly installed and the JAVA_HOME environmental variables properly set. Then download the latest version of Maven from http://maven.apache.org/download.html and unzip it wherever you please. From here you need to add a few environmental variables and add maven to the system path.</p>
<h3>For Windows</h3>
<p><code>Control Panel &gt; System &gt; Advanced &gt; Environmental Variables</code><br />
Under the system variables list add a new variable<br />
<code>MAVEN_HOME = C:\... (maven install location)</code><br />
and append this to your path<br />
<code>;%MAVEN_HOME%bin\</code></p>
<h3>For *nix</h3>
<p><code>export M2_HOME=(Maven install location)<br />
export M2=$M2_HOME/bin<br />
PATH=$PATH:$M2</code><br />
now at the command line you should be able to type<br />
<code>mvn --version</code><br />
and get some kind of output like this&#8230;<br />
<code>Maven version: 2.0.9<br />
Java version: 1.6.0_11<br />
OS name: "windows xp" version: "5.1" arch: "x86" Family: "windows"</code></p>
<h2>How it works.</h2>
<p>Maven uses a file called the POM (http://en.wikipedia.org/wiki/Project_Object_Model#Project_Object_Model), short for project object model. This is an XML file that describes your project. Here you can list what the name of your project is, what is its version, how it is packaged, how it is built, repositories for any dependencies, and last but not least its dependencies. There are many advanced configurations such as specifying profiles that are beyond the scope and necessity of this entry to go into.<br />
Lets dig in shall we?</p>
<p><code>&lt;?xml version="1.0" encoding="utf-8"?&gt;<br />
&lt;project xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd"<br />
	xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"&gt;<br />
	&lt;modelVersion&gt;4.0.0&lt;/modelVersion&gt;<br />
	&lt;groupId&gt;com.weneck.webapplication&lt;/groupId&gt;<br />
	&lt;artifactId&gt;WebApplication&lt;/artifactId&gt;<br />
	&lt;packaging&gt;war&lt;/packaging&gt;<br />
	&lt;version&gt;1.0&lt;/version&gt;<br />
	&lt;name&gt;Sample Maven Webapp&lt;/name&gt;<br />
	&lt;url&gt;http://maven.apache.org&lt;/url&gt;<br />
...</code></p>
<p>The pom starts out simple enough, you have your XML encoding and versioning information, project declaration and schema information. The modelVersion declared what version of the POM we are using, in this case 4.0.0, not to be confused with the version of your project. Next is the group id of your organization, the name of your artifact (artifactId), how your artifact should be packaged, in this case a WAR file (http://en.wikipedia.org/wiki/WAR_%28Sun_file_format%29). Finally a name and a version number of your artifact should be declared. Simple enough eh?</p>
<p><code>&lt;repositories&gt;<br />
	&lt;repository&gt;<br />
		&lt;id&gt;springsource maven repo&lt;/id&gt;<br />
		&lt;url&gt;http://maven.springframework.org/milestone&lt;/url&gt;<br />
	&lt;/repository&gt;<br />
&lt;/repositories&gt;</code></p>
<p>The next section defines your repositories. Kinda like how it reads. In this case we are specifying springsource&#8217;s milestone repository so we can grab the Spring 3 RC artifacts (important for the final segment in this piece). You can also specify these in your settings.xml file locates in the maven home directory. This is usually ~/.m2/ or %USER_HOME%/.m2 depending on your OS.</p>
<p><code>&lt;build&gt;<br />
	&lt;finalName&gt;WebApplication&lt;/finalName&gt;<br />
	&lt;plugins&gt;<br />
		&lt;plugin&gt;<br />
....</code></p>
<p>The build section is next, here we define the plugins we are going to user, most commonly the compiler plugin, a properties file plugin if needed, and if you&#8217;re using eclipse (you should be) the maven-eclipse plugin. (fear not, full source attached at the end of my rant.</p>
<p><code>&lt;dependencies&gt;<br />
	&lt;dependency&gt;<br />
		&lt;groupId&gt;javax.servlet&lt;/groupId&gt;<br />
		&lt;artifactId&gt;jstl&lt;/artifactId&gt;<br />
		&lt;version&gt;1.1.2&lt;/version&gt;<br />
&lt;/dependency&gt;<br />
...</code></p>
<p>And finally the dependencies section. Here we define each of the dependencies our project is&#8230; well&#8230; dependent on. Easy peasy huh?</p>
<p>Now the cool part, putting it all together. So there is a common file structure maven expects, as well as few file we need to put in place for this thing to get off the groung. They are all included in the source, but I&#8217;ll gloss over them here. Maven expects a src folder with 2 folders within it, main and test. It&#8217;s not rocket science, as the names suggest you source code goes here. Inside the main folder goes your main files, and inside the test folder all files associated with your testing process/procedures. (you are testing your code right?) Inside main you have java, resources, and webapp. Inside java is your java code, resources is your resources, and webapp are the files needed for a webapp. Am I sounding redundant here? I also stuck in a nearly blank jsp for good measure. Hey, when its all done we want to see something other than a 404, amiright?</p>
<h2>Using Maven</h2>
<p>You can use maven from within eclipse, which used to work really well, but last time I tried was kinda buggy and bothersome. So I prefer the command line. First things first we need to configure eclipse to use all these wonderful dependencies that maven is managing for you.<br />
<code>mvn eclipse:eclipse</code><br />
This line will download all your dependencies into that .m2 folder I referenced earlier. It will also write a .project and .classpath file for eclipse&#8217;s benefit. This  will point java&#8217;s build path within eclipse to those dependencies which are not being stored within your project. Be sure to refresh the workspace after performing this command as eclipse does not activley monitor those files and will continue to complain about missing dependencies untill you do so.<br />
<code>mvn clean</code><br />
This wonderful command performs a clean on your project, simple.<br />
<code>mvn install</code><br />
Here&#8217;s our meat and potatoes. This command does what we really came here for. It creates the target directory structure, builds our code, and packages it all into our pre-defined package structure. In our case the war file. It also puts all the structure in place for eclipse&#8217;s WTP so if you have a java server configured in eclipse you can now add the project to the servers hosted projects. (Once added to the web server you dont need to continually build with maven, you can build with eclipse and WTP will pick up the changes and replace the necessary files in the web-server or prompt you for a restart.)<br />
You can also chain these command together.<br />
<code>mvn clean install</code><br />
That about wraps it up for Maven, but stay tuned for the next segment, Hibernate.</p>
<p>As promised <strong><a href='http://weneck.com/wp-content/uploads/2009/11/WebApplication.zip'>Source</a></strong></p>
]]></content:encoded>
			<wfw:commentRss>http://weneck.com/2009/11/09/maven/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Bastardizing the CNAME record</title>
		<link>http://weneck.com/2009/11/09/bastardizing-the-cname-record/</link>
		<comments>http://weneck.com/2009/11/09/bastardizing-the-cname-record/#comments</comments>
		<pubDate>Mon, 09 Nov 2009 05:46:06 +0000</pubDate>
		<dc:creator>Rusty Weneck</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[CNAME]]></category>
		<category><![CDATA[Computer Science]]></category>
		<category><![CDATA[DNS]]></category>

		<guid isPermaLink="false">http://weneck.com/?p=303</guid>
		<description><![CDATA[So I was just now tossing and turning thinking about a new series I want to write on web applications when I thought to check my blog, after all it has been too long. Lo-and behold my server was up, but my redirect was down. For a while now I have been taking advantage of [...]]]></description>
			<content:encoded><![CDATA[<p>So I was just now tossing and turning thinking about a new series I want to write on web applications when I thought to check my blog, after all it has been too long. Lo-and behold my server was up, but my redirect was down. For a while now I have been taking advantage of <a href="https://www.no-ip.com" target="_blank">no-ip.org</a>&#8217;s free dynamic ip resolving DNS service. Circumstances has forced me to move my server to a residential connection to the nets with a dynamic ip. Bad news for trying to be in touch with home. So I transferred all my domains to a new registrar, mainly <a href="http://name.com" target="_blank">name.com</a>, because they include DNS in your registration fee, which at the time was 10$, not bad considering I was previously paying 7$. (per year mind you, so affordable on anyone&#8217;s income.) This took care of my Google apps ( &lt;3 ) and the like but still did not take care of my dynamic ip problem.</p>
<p>Solution, the CNAME record. A CNAME record in my opinion is far too often overlooked by administrators as a valuable tool. First things first, administrators out there I&#8217;m talking to you, your customers should not have to distinguish between www.youdomain.com and yourdomain.com unless there is a very good reason for doing so. CNAME records should be in place for your www name to redirect to the A records for your domain. VIOLA! Instant karma with your patrons. Secondly, and more important to my little rant here is that CNAME records can point to those unsightly domain names that the free dynamic DNS services provide you. For instance I CNAME www.weneck.com to weneck.com (which would normally be my A record) and then CNAME weneck.com to weneck.no-ip.com. BAM! Instant dynamic ip resolution while keeping my pretty domain name. Gotta love that.</p>
<p>Long short, I&#8217;m back up and in business, and maybe soon I can get cracking on my 3 part web application rant.</p>
]]></content:encoded>
			<wfw:commentRss>http://weneck.com/2009/11/09/bastardizing-the-cname-record/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Getting Started with Google App Engine</title>
		<link>http://weneck.com/2009/06/12/getting-started-with-google-app-engine/</link>
		<comments>http://weneck.com/2009/06/12/getting-started-with-google-app-engine/#comments</comments>
		<pubDate>Fri, 12 Jun 2009 23:49:41 +0000</pubDate>
		<dc:creator>Rusty Weneck</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[Computer Science]]></category>
		<category><![CDATA[Eclipse]]></category>
		<category><![CDATA[Google]]></category>
		<category><![CDATA[Google App Engine]]></category>
		<category><![CDATA[GWT]]></category>

		<guid isPermaLink="false">http://weneck.com/?p=274</guid>
		<description><![CDATA[So getting started with Google&#8217;s App Engine is a breese, so easy this is probably pointless, but I want to document it none the less.
Getting Started
First things first, if you&#8217;re a java developer, get Eclipse. Next install the Google App Engine plugin. This can be done by going to the software updates screen and adding [...]]]></description>
			<content:encoded><![CDATA[<p>So getting started with Google&#8217;s App Engine is a breese, so easy this is probably pointless, but I want to document it none the less.<br />
<strong>Getting Started</strong><br />
First things first, if you&#8217;re a java developer, get <a href="http://www.eclipse.org/downloads/" target="_blank">Eclipse</a>. Next install the Google App Engine plugin. This can be done by going to the software updates screen and adding the plugin update site location, either <code>http://dl.google.com/eclipse/plugin/3.4</code> for Ganymede or <code>http://dl.google.com/eclipse/plugin/3.3</code> for Europa. Check the boxes to install the plugin and the SDK&#8217;s, click the install button in the upper right, then the obligatory next, next, next, accept, next, finnish process we are all familiar with and we are done (except maybe a restart of Eclipse). Images below to help those in need of some visual queues.</p>
<p align="center"><a href="http://weneck.com/wp-content/uploads/2009/06/eclipsesoftwareupdates.png"><img class="size-medium wp-image-276 alignnone" title="eclipsesoftwareupdates" src="http://weneck.com/wp-content/uploads/2009/06/eclipsesoftwareupdates-300x187.png" alt="eclipsesoftwareupdates" width="210" height="131" /></a><a href="http://weneck.com/wp-content/uploads/2009/06/eclipsesoftwareupdatesavailable.png"><img class="alignnone size-medium wp-image-277" title="eclipsesoftwareupdatesavailable" src="http://weneck.com/wp-content/uploads/2009/06/eclipsesoftwareupdatesavailable-300x211.png" alt="eclipsesoftwareupdatesavailable" width="210" height="148" /></a><a href="http://weneck.com/wp-content/uploads/2009/06/eclipsesoftwareupdatesavailableadd.png"><img class="alignnone size-medium wp-image-278" title="eclipsesoftwareupdatesavailableadd" src="http://weneck.com/wp-content/uploads/2009/06/eclipsesoftwareupdatesavailableadd-300x211.png" alt="eclipsesoftwareupdatesavailableadd" width="210" height="148" /></a><a href="http://weneck.com/wp-content/uploads/2009/06/eclipsesoftwareupdatesavailableadded.png"><img class="alignnone size-medium wp-image-275" title="eclipsesoftwareupdatesavailableadded" src="http://weneck.com/wp-content/uploads/2009/06/eclipsesoftwareupdatesavailableadded-300x211.png" alt="eclipsesoftwareupdatesavailableadded" width="210" height="148" /></a></p>
<p><strong>Creating a new Project</strong></p>
<p>Now the fun part, we get to create a new project.</p>
<ol>
<li>Click File &gt; New &gt; Web Application Project.</li>
<li>Enter a project name, and give it a default package, here I&#8217;ve used com.weneck.gaetest.</li>
<li>Click finish</li>
</ol>
<p align="center"><a href="http://weneck.com/wp-content/uploads/2009/06/eclipsenewproject.png"><img class="size-medium wp-image-286 alignnone" title="eclipsenewproject" src="http://weneck.com/wp-content/uploads/2009/06/eclipsenewproject-300x187.png" alt="eclipsenewproject" width="300" height="187" /></a><a href="http://weneck.com/wp-content/uploads/2009/06/eclipsenewprojectdialogue.png"><img class="size-medium wp-image-285 alignnone" title="eclipsenewprojectdialogue" src="http://weneck.com/wp-content/uploads/2009/06/eclipsenewprojectdialogue-300x187.png" alt="eclipsenewprojectdialogue" width="300" height="187" /></a></p>
<p>You&#8217;ll find the sample GWT project is allready set up for you. Simply clicking the run button will launch a modified jetty application server and a custom browser and you can view the application.</p>
<p align="center"><a href="http://weneck.com/wp-content/uploads/2009/06/projectrun.png"><img class="alignnone size-medium wp-image-288" title="projectrun" src="http://weneck.com/wp-content/uploads/2009/06/projectrun-300x187.png" alt="projectrun" width="300" height="187" /></a></p>
<p><strong>Deploying</strong></p>
<p>This is probably the coolest part about the process, deployment is simple as clicking a button. Well it will be once you have registered for an<a href="appengine.google.com/" target="_blank"> App Engine account</a>. Create your account, sign in, then click the <code>Create an Application</code> button. I&#8217;ve entered <code>wenecktest</code> as my application id, and will use this value through the rest of the tutorial.</p>
<p align="center"><a href="http://weneck.com/wp-content/uploads/2009/06/appenginecreate.png"><img class="alignnone size-medium wp-image-289" title="appenginecreate" src="http://weneck.com/wp-content/uploads/2009/06/appenginecreate-300x202.png" alt="appenginecreate" width="300" height="202" /></a></p>
<p>Back in Eclipse, click the <code>Deploy App Engine Project</code> button, located on the toolbar at the top.</p>
<p align="center"><a href="http://weneck.com/wp-content/uploads/2009/06/deploybutton.png"><img class="alignnone size-full wp-image-290" title="deploybutton" src="http://weneck.com/wp-content/uploads/2009/06/deploybutton.png" alt="deploybutton" width="251" height="75" /></a></p>
<p>You will be asked for your email address (the one you registered for the app engine account with) and your password. you will also be asked for an application ID for the project, the one we just created, so click the <code>App Engine project settings...</code> link and enter your value.</p>
<p align="center"><a href="http://weneck.com/wp-content/uploads/2009/06/appenginedeploy.png"><img class="alignnone size-medium wp-image-292" title="appenginedeploy" src="http://weneck.com/wp-content/uploads/2009/06/appenginedeploy-300x191.png" alt="appenginedeploy" width="210" height="134" /></a><a href="http://weneck.com/wp-content/uploads/2009/06/appenginedeployid.png"><img class="alignnone size-medium wp-image-291" title="appenginedeployid" src="http://weneck.com/wp-content/uploads/2009/06/appenginedeployid-300x259.png" alt="appenginedeployid" width="210" height="181" /></a></p>
<p>The application will be compiled, uploaded and deployed, as easy as that(watch the console output). Mine can be viewed at <a href="http://wenecktest.appspot.com/" target="_blank">http://wenecktest.appspot.com</a> (disclaimer: I will be using this application id for testing purposes, so some clicks in the future might have a different application parked there.)</p>
<p>Well that is all good and dandy, but what if you have your own domain where you want this application hosted? Well Google has thought of that too. Through the magic of Google Apps, and a CNAME dns record you can access this at any domain you own. In the App Engine console you can click on the versions link in the left nav and then click the <code>Add Domain...</code> button. The rest of the process includes either signing up for Google Apps (which I&#8217;ve allready highly reccomended) or signing into Google Apps to prove you own the domain name. Then you have to add a CNAME record to your DNS server to point to <code>ghs.google.com</code> the rest is magic.  For those wondering the CNAME record for that looks like<br />
•   <code>googleappengine.weneck.com.     IN      CNAME   ghs.google.com.</code><br />
to deploy to <a href="http://googleappengine.weneck.com" target="_blank">http://googleappengine.weneck.com</a> . (same disclaimer applies)</p>
<p>Well, that it, it really is that easy. Now the only thing left to do is to actually write some effective code. I&#8217;m going to be looking into persistance using JPA annotations, so stay tuned for that adventure.</p>
]]></content:encoded>
			<wfw:commentRss>http://weneck.com/2009/06/12/getting-started-with-google-app-engine/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>The only advice I can give</title>
		<link>http://weneck.com/2009/05/31/the-only-advice-i-can-give/</link>
		<comments>http://weneck.com/2009/05/31/the-only-advice-i-can-give/#comments</comments>
		<pubDate>Mon, 01 Jun 2009 00:12:44 +0000</pubDate>
		<dc:creator>Rusty Weneck</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://weneck.com/2009/05/31/the-only-advice-i-can-give/</guid>
		<description><![CDATA[I&#8217;ve been getting a lot of advice latley so I thought I&#8217;d give my shot at giving some.

 Earn every dollar you make, but make sure to make every dollay you earn.
 Love your work so much that if it called for it you would do it for free.
 Find a passion in your work [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve been getting a lot of advice latley so I thought I&#8217;d give my shot at giving some.</p>
<ul>
<li> Earn every dollar you make, but make sure to make every dollay you earn.</li>
<li> Love your work so much that if it called for it you would do it for free.</li>
<li> Find a passion in your work so that you&#8217;re not worried about how much you are making and others will notice, it&#8217;s then that the money will come because of the quality of your work.</li>
<li> Play.</li>
<li> Be content with what you have and be thankful when you achieve more.</li>
<li> Learn from your elders, or anyone with more experience for that matter, they have a lot of wisedom that books and bullshit won&#8217;t teach you.</li>
</ul>
<p>I don&#8217;t have all the answers but I wholly believe these few tidbits, in entirety or in part, can lead to happiness.</p>
]]></content:encoded>
			<wfw:commentRss>http://weneck.com/2009/05/31/the-only-advice-i-can-give/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Flex Heat Map</title>
		<link>http://weneck.com/2009/05/27/flex-heat-map/</link>
		<comments>http://weneck.com/2009/05/27/flex-heat-map/#comments</comments>
		<pubDate>Thu, 28 May 2009 00:06:44 +0000</pubDate>
		<dc:creator>Rusty Weneck</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[Computer Science]]></category>
		<category><![CDATA[Flex]]></category>
		<category><![CDATA[Google]]></category>
		<category><![CDATA[HeatMap]]></category>

		<guid isPermaLink="false">http://weneck.com/?p=260</guid>
		<description><![CDATA[**UPDATE**
So I realized I overlooked a few datails on the heat map. First, I hardcoded into the component the starting location and zoom of the map. Second, I did not expose any of the awesome geo-locating code that allowed adding markers to the map from a standard U.S. Address (or most others for that matter). [...]]]></description>
			<content:encoded><![CDATA[<p>**UPDATE**</p>
<p>So I realized I overlooked a few datails on the heat map. First, I hardcoded into the component the starting location and zoom of the map. Second, I did not expose any of the awesome geo-locating code that allowed adding markers to the map from a standard U.S. Address (or most others for that matter). So I added those features, as well as clearing up the add points by click button by changing it to a checkbox. Below is a picture of the newer version with Cincinnati&#8217;s City Hall marked on the map and some example data, pretend its sales in the Cincinnati area or something.</p>
<p><a href="http://weneck.com/wp-content/uploads/2009/05/heatmap2.png"><img class="aligncenter size-medium wp-image-272 shutterset" title="heatmap2" src="http://weneck.com/wp-content/uploads/2009/05/heatmap2-300x124.png" alt="heatmap2" width="300" height="124" /></a></p>
<p>So one of my interest is data visualization. Good thing I happen to be proficient in one of the best technologies for displaying data sets in new an interesting way. I first ran across a heat map in the package I use to track statistics on this very site. <a href="http://www.phpmyvisites.us/" target="_blank">http://www.phpmyvisites.us/</a> What they did is take a picture of your page and track user clicks, which can be infinitely useful for someone who is trying to optimize how users navigate their site. (not that I do too much of that here.) Essentially it shows you where many clicks amass, causing certain areas of the site to &#8220;heat up&#8221;.</p>
<p>I used Google maps, both because this could be used for just a map api wrapper, and because I&#8217;m a bit of a cheerleader for Google. Let me know what you think, It&#8217;s not the prettiest, but its been a fun little project. Binarys to come&#8230;</p>
<p><a href="/wp-content/uploads/2009/05/heatmap.png"><img class="aligncenter size-thumbnail wp-image-158 shutterset" title="heatMap" src="/wp-content/uploads/2009/05/heatmap-300x130.png" alt="" width="300" height="130" /></a></p>
<p>Source <a href="/wp-content/uploads/2009/05/heatMap/srcview/" target="_blank">here</a>.</p>
<p>Example <a href="/wp-content/uploads/2009/05/heatMap/Main.html" target="_blank">here</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://weneck.com/2009/05/27/flex-heat-map/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
