<?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>BasePatterns.org &#187; Java</title>
	<atom:link href="http://basepatterns.org/category/java/feed/" rel="self" type="application/rss+xml" />
	<link>http://basepatterns.org</link>
	<description>Trends in software design</description>
	<lastBuildDate>Thu, 05 Apr 2012 00:13:31 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>Service Selector</title>
		<link>http://basepatterns.org/2009/11/service-selector/</link>
		<comments>http://basepatterns.org/2009/11/service-selector/#comments</comments>
		<pubDate>Mon, 02 Nov 2009 03:43:24 +0000</pubDate>
		<dc:creator>fortuna</dc:creator>
				<category><![CDATA[Java]]></category>
		<category><![CDATA[patterns]]></category>
		<category><![CDATA[proxy]]></category>

		<guid isPermaLink="false">http://basepatterns.org/?p=115</guid>
		<description><![CDATA[Sometimes we may have more than one implementation and/or instance of a service to which we need to route requests. Routing may be controlled by a number of different factors, such as the request type, request arguments, runtime configuration, etc.

An implementation of such routing might look something like this:

[java]
public interface SomeService {
  void someMethod();
}

public class RoutingSomeService implements SomeService {

  private Map<String, SomeService> delegates = ...

  private String activeDelegateId = ...

  public void someMethod() {
    SomeService delegate = delegates.get(activeDelegateId);
    if (delegate != null) {
      delegate.someMethod();
    }
    else {
      // XXX: throw runtime exception???
    }
  }
}
[/java]]]></description>
		<wfw:commentRss>http://basepatterns.org/2009/11/service-selector/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Uniform Caching</title>
		<link>http://basepatterns.org/2009/10/uniform-caching/</link>
		<comments>http://basepatterns.org/2009/10/uniform-caching/#comments</comments>
		<pubDate>Tue, 13 Oct 2009 01:14:42 +0000</pubDate>
		<dc:creator>fortuna</dc:creator>
				<category><![CDATA[Java]]></category>
		<category><![CDATA[adapter]]></category>
		<category><![CDATA[caching]]></category>
		<category><![CDATA[patterns]]></category>

		<guid isPermaLink="false">http://basepatterns.org/?p=101</guid>
		<description><![CDATA[Typically object caching in Java is managed by the container or framework in use. Occasionally however there is a need to manually cache domain-specific objects, whereby a java.util.Map implementation will not suffice. Using the popular ehcache framework as an example, the following pattern is typically observed: The common aspects of this pattern are as follows: [...]]]></description>
		<wfw:commentRss>http://basepatterns.org/2009/10/uniform-caching/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Whiteboard Registry</title>
		<link>http://basepatterns.org/2009/10/whiteboard-registry/</link>
		<comments>http://basepatterns.org/2009/10/whiteboard-registry/#comments</comments>
		<pubDate>Thu, 08 Oct 2009 06:59:44 +0000</pubDate>
		<dc:creator>fortuna</dc:creator>
				<category><![CDATA[Java]]></category>
		<category><![CDATA[osgi]]></category>
		<category><![CDATA[patterns]]></category>
		<category><![CDATA[registry]]></category>
		<category><![CDATA[whiteboard]]></category>

		<guid isPermaLink="false">http://basepatterns.org/?p=86</guid>
		<description><![CDATA[In OSGi using a publisher/subscriber design can be somewhat more complicated that traditional Java environments: To overcome these hurdles the Whiteboard Pattern prescribes registering listeners in the service registry as opposed to services, whereby services can publish events to available listeners at the time of the event. The problem with the Whiteboard Pattern is that [...]]]></description>
		<wfw:commentRss>http://basepatterns.org/2009/10/whiteboard-registry/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>OSGi Service Locator</title>
		<link>http://basepatterns.org/2009/09/osgi-service-locator/</link>
		<comments>http://basepatterns.org/2009/09/osgi-service-locator/#comments</comments>
		<pubDate>Wed, 30 Sep 2009 01:27:10 +0000</pubDate>
		<dc:creator>fortuna</dc:creator>
				<category><![CDATA[Java]]></category>
		<category><![CDATA[osgi]]></category>
		<category><![CDATA[patterns]]></category>
		<category><![CDATA[service locator]]></category>

		<guid isPermaLink="false">http://basepatterns.org/?p=74</guid>
		<description><![CDATA[The Service Locator pattern is a well-established mechanism for accessing local and remote services in a consistent manner: Using a structured service name interface we can improve uniformity and reduce the potential for typos: In an OSGi environment, the recommended approach for retrieving services is via the org.osgi.util.tracker.ServiceTracker class: We can combine these two patterns [...]]]></description>
		<wfw:commentRss>http://basepatterns.org/2009/09/osgi-service-locator/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Uniform Logging</title>
		<link>http://basepatterns.org/2009/09/uniform-logging/</link>
		<comments>http://basepatterns.org/2009/09/uniform-logging/#comments</comments>
		<pubDate>Fri, 25 Sep 2009 02:37:46 +0000</pubDate>
		<dc:creator>fortuna</dc:creator>
				<category><![CDATA[Java]]></category>
		<category><![CDATA[adapter]]></category>
		<category><![CDATA[logging]]></category>
		<category><![CDATA[patterns]]></category>

		<guid isPermaLink="false">http://basepatterns.org/?p=45</guid>
		<description><![CDATA[Application logging always seems to become one of those code smells, typically regarding duplication of code, or conversely, non-uniform log messages. There are many different ways to log a message in Java, but variations on the following pattern are common: The following information can be extracted from this pattern: Category &#8211; classification for log entries [...]]]></description>
		<wfw:commentRss>http://basepatterns.org/2009/09/uniform-logging/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

