<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:clearspace="http://www.jivesoftware.com/xmlns/clearspace/rss" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:opensearch="http://a9.com/-/spec/opensearch/1.1/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>Blog Posts From Jivespace Community Blog Tagged With clearspace</title>
    <link>http://www.jivesoftware.com/jivespace/blogs/jivespace</link>
    <description>Jivespace Developer Community Blog</description>
    <pubDate>Fri, 07 Nov 2008 23:32:41 GMT</pubDate>
    <generator>Jive SBS 3.0.8 (http://jivesoftware.com/products/clearspace/)</generator>
    <dc:date>2008-11-07T23:32:41Z</dc:date>
    <item>
      <title>Finally, a Place to Trade Recipes</title>
      <link>http://www.jivesoftware.com/jivespace/blogs/jivespace/2008/11/07/finally-a-place-to-trade-recipes</link>
      <description>&lt;!-- [DocumentBodyStart:b5677701-e08a-4dce-a565-66e7b4842407] --&gt;&lt;div class='jive-rendered-content'&gt;&lt;p&gt;&lt;a class="jive-link-blog-small" href="http://www.jivesoftware.com/jivespace/blogs/jivespace/2008/10/31/a-whole-new-jivespace"&gt;A week ago Greg wrote&lt;/a&gt; about the changes we recently made to simplify Jive's communities. You'll now find four communities -- Support, Features, Developers, and Plugin Downloads -- under one community to collect them all: &lt;a class="jive-link-external-small" href="/index.jspa"&gt;&lt;span&gt;&lt;span&gt;Jivespace&lt;/span&gt;&lt;/span&gt;&lt;/a&gt;. I'm chiming in this week with details on changes to docs for developers building customizations to Clearspace.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;Here it is in a nutshell: The latest developer documentation will be in the &lt;a class="jive-link-community-small" href="http://www.jivesoftware.com/jivespace/community/developer"&gt;Developers&lt;/a&gt; community in Jivespace. That community is also the place to post your questions and comments. Other content, including developer content from previous versions, will be on &lt;a class="jive-link-external-small" href="http://www.jivesoftware.com/builds/docs/clearspace/latest/"&gt;&lt;span&gt;the site where docs have been&lt;/span&gt;&lt;/a&gt; for some time now.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;The best part, as I see it -- and really, I think this is fantastic -- is that it's not just docs. There's a lot more information: FAQs, how-tos, links to more information, and more. Internally, we started out calling it a "cookbook" (okay, Greg called it a cookbook and we humored him for a while). But while it wasn't really as procedural and example-driven as software cookbooks tend to be, it was obvious he was on to something. You (and we) really needed a single place to collect the knowledge we develop internally for extending and customizing Clearspace.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;If you've been to the Developers overview page, you might also have noticed that we've tried to make it easier to get to what you care about. The search box and "spotlight areas" are designed to help you find developer content without leaving the developers' stuff if you don't want to.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;By the way, there are no longer any Forums or older Clearspace docs on Jivespace. It had gotten to be kind of a mess (a "train wreck," as one of its admirers said). We're thinking it's better to have one version of developer content on the Developers community, and the rest of it where other docs live. See what you think.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;Here are the links of interest:&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;ul&gt;&lt;li&gt;&lt;a class="jive-link-community-small" href="http://www.jivesoftware.com/jivespace/community/developer"&gt;Developers -- current Clearspace developer content&amp;lt;br /&amp;gt;&lt;/a&gt;&lt;/li&gt;&lt;li&gt;&lt;a class="jive-link-external-small" href="http://www.jivesoftware.com/builds/docs/clearspace/latest/"&gt;&lt;span&gt;Latest archived Clearspace doc content&lt;/span&gt;&lt;/a&gt; (for earlier versions, replace "latest" in the URL with a version number -- such as "2.5.2")&lt;/li&gt;&lt;li&gt;&lt;a class="jive-link-external-small" href="http://www.jivesoftware.com/support/documentation"&gt;&lt;span&gt;Links to documentation for all Jive products&lt;/span&gt;&lt;/a&gt;&lt;br/&gt;&lt;/li&gt;&lt;/ul&gt;&lt;/div&gt;&lt;!-- [DocumentBodyEnd:b5677701-e08a-4dce-a565-66e7b4842407] --&gt;</description>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">jivespace</category>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">clearspace</category>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">developers</category>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">documentation</category>
      <pubDate>Fri, 07 Nov 2008 23:32:41 GMT</pubDate>
      <author>steve@jivesoftware.com</author>
      <guid>http://www.jivesoftware.com/jivespace/blogs/jivespace/2008/11/07/finally-a-place-to-trade-recipes</guid>
      <dc:date>2008-11-07T23:32:41Z</dc:date>
      <clearspace:dateToText>1 year, 5 hours ago</clearspace:dateToText>
      <clearspace:objectType>0</clearspace:objectType>
      <wfw:comment>http://www.jivesoftware.com/jivespace/blogs/jivespace/comment/finally-a-place-to-trade-recipes</wfw:comment>
      <wfw:commentRss>http://www.jivesoftware.com/jivespace/blogs/jivespace/feeds/comments?blogPost=1627</wfw:commentRss>
    </item>
    <item>
      <title>How Popularity Works in Clearspace</title>
      <link>http://www.jivesoftware.com/jivespace/blogs/jivespace/2008/09/04/how-popularity-works-in-clearspace</link>
      <description>&lt;!-- [DocumentBodyStart:2fdb08db-b4a3-435f-bd97-f8a3ff6d6852] --&gt;&lt;div class='jive-rendered-content'&gt;&lt;p&gt;I've heard this question a number of times here on Jivespace and I think even a couple times on our intranet (which is called Brewspace) but I've yet to see it documented anywhere, mostly because no one has ever taken the time to explain it to our awesome docs guy Steve (by the way, have you seen the new docs? &lt;a class="jive-link-external-small" href="http://www.jivesoftware.com/community/docs/"&gt;They're amazing&lt;/a&gt;!). I doubt any of you are losing sleep about it, but just in case, here's my simplified, albeit technical, take on things. If you've got a source build handy, I'd encourage you to follow along in your favorite IDE.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;PopularityDeterminationTask is the class that handles the majority of the work. It runs every 15 minutes (as configured in spring-taskContext.xml, which means you can change it via a plugin in 2.5 if you want) and works closely with &lt;a class="jive-link-external-small" href="http://www.jivesoftware.com/community/docs/ActivityManager.html"&gt;ActivityManager&lt;/a&gt;.&amp;nbsp; Every time it runs it does the following things:&lt;/p&gt;&lt;ul&gt;&lt;li type="ul"&gt;&lt;p&gt;iterates over the set of containers that exist in Clearspace (communities, projects, social groups and blogs)&lt;/p&gt;&lt;/li&gt;&lt;li type="ul"&gt;&lt;p&gt;calculates the popularity of each item in the in-memory copy of activities that activity manager maintains for the current day. The score (or popularity) of each item is calculated by adding together the score of each activity on an item, the scoring is as follows:&lt;/p&gt;&lt;/li&gt;&lt;ul&gt;&lt;li type="ul"&gt;&lt;p&gt;each comment (blogs and documents) or reply (thread) is given 5 points&lt;/p&gt;&lt;/li&gt;&lt;li type="ul"&gt;&lt;p&gt;each modification (documents only) is given 5 points&lt;/p&gt;&lt;/li&gt;&lt;li type="ul"&gt;&lt;p&gt;each view is given 1 point&lt;/p&gt;&lt;/li&gt;&lt;/ul&gt;&lt;li type="ul"&gt;&lt;p&gt;calculates the popularity of items in each container stored the database (a popularity score is computed for each item based on the activity that happened that day every night at midnight, this data is stored in the &lt;a class="jive-link-external-small" href="http://www.jivesoftware.com/community/docs/DatabaseSchemaGuide.html#jivePopularity"&gt;jivePopularity&lt;/a&gt; table) for the last seven days. The individual day score is adjusted for each day old that the score is recorded. We call this decay: the computation is done in SQL but if it were done in Java it would look something like this:&lt;/p&gt;&lt;/li&gt;&lt;/ul&gt;&lt;!--[CodeBlockStart:eb0a66b8-1322-4506-9dfb-9f4af8853ff6]--&gt;&lt;pre class="jive-pre"&gt;&lt;code class="jive-code"&gt;Calendar c = Calendar.getInstance();
c.add(Calendar.DATE, -daysAgo);
Date now = new Date();
Date nDaysAgo = c.getTime();
long dateDiff = now.getTime() - nDaysAgo.getTime();
long dateAdjustment = dateDiff / 86400000; 
long decayedScore = score / (1 + dateAdjustment);
&lt;/code&gt;&lt;/pre&gt;&lt;!--[CodeBlockEnd:eb0a66b8-1322-4506-9dfb-9f4af8853ff6]--&gt;&lt;ul&gt;&lt;li type="ul"&gt;&lt;p&gt;add the results of step 2 and step 3 together. So for example, let's say I published a blog post 2 months ago and through some sort of magic, it got 3 comments every day for the last 2 months (and it's already received 2 comments today that haven't been archived to the jivePopularity table). We only take into account the popularity score for the last seven days so the total score is going to be the sum of the following scores:&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;table style="width: 640px; height: 208px;"&gt;&lt;tbody&gt;&lt;tr&gt;&lt;th&gt;&lt;p&gt;Date&lt;/p&gt;&lt;/th&gt;&lt;th&gt;&lt;p&gt;Number of Comments&lt;/p&gt;&lt;/th&gt;&lt;th&gt;&lt;p&gt;Recorded Score&lt;/p&gt;&lt;/th&gt;&lt;th&gt;&lt;p&gt;Score With Decay&lt;/p&gt;&lt;/th&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;&lt;p&gt;6/5/2008 (today)&lt;/p&gt;&lt;/td&gt;&lt;td&gt;&lt;p&gt;3&lt;/p&gt;&lt;/td&gt;&lt;td&gt;&lt;p&gt;15&lt;/p&gt;&lt;/td&gt;&lt;td&gt;&lt;p&gt;15&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;&lt;p&gt;6/4/2008&lt;/p&gt;&lt;/td&gt;&lt;td&gt;&lt;p&gt;3&lt;/p&gt;&lt;/td&gt;&lt;td&gt;&lt;p&gt;15&lt;/p&gt;&lt;/td&gt;&lt;td&gt;&lt;p&gt;7&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;&lt;p&gt;6/3/2008&lt;/p&gt;&lt;/td&gt;&lt;td&gt;&lt;p&gt;3&lt;/p&gt;&lt;/td&gt;&lt;td&gt;&lt;p&gt;15&lt;/p&gt;&lt;/td&gt;&lt;td&gt;&lt;p&gt;5&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;&lt;p&gt;6/2/2008&lt;/p&gt;&lt;/td&gt;&lt;td&gt;&lt;p&gt;3&lt;/p&gt;&lt;/td&gt;&lt;td&gt;&lt;p&gt;15&lt;/p&gt;&lt;/td&gt;&lt;td&gt;&lt;p&gt;3&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;&lt;p&gt;6/1/2008&lt;/p&gt;&lt;/td&gt;&lt;td&gt;&lt;p&gt;3&lt;/p&gt;&lt;/td&gt;&lt;td&gt;&lt;p&gt;15&lt;/p&gt;&lt;/td&gt;&lt;td&gt;&lt;p&gt;3&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;&lt;p&gt;5/31/2008&lt;/p&gt;&lt;/td&gt;&lt;td&gt;&lt;p&gt;3&lt;/p&gt;&lt;/td&gt;&lt;td&gt;&lt;p&gt;15&lt;/p&gt;&lt;/td&gt;&lt;td&gt;&lt;p&gt;2&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;&lt;p&gt;5/30/2008&lt;/p&gt;&lt;/td&gt;&lt;td&gt;&lt;p&gt;3&lt;/p&gt;&lt;/td&gt;&lt;td&gt;&lt;p&gt;15&lt;/p&gt;&lt;/td&gt;&lt;td&gt;&lt;p&gt;2&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;&lt;p&gt;Total Score&lt;/p&gt;&lt;/td&gt;&lt;td&gt;&lt;/td&gt;&lt;td&gt;&lt;/td&gt;&lt;td&gt;&lt;p&gt;37&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;/li&gt;&lt;li type="ul"&gt;&lt;p&gt;Finally, each item is added to a SortedSet and then copied back to ActivityManager, where it lives until the next time popularity is calculated fifteen minutes later.&lt;/p&gt;&lt;/li&gt;&lt;/ul&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;So when you see a widget that shows the most popular items for a given community / space, project, social group or blog, you're getting the n items who have the highest combined score, which is a combination of comments, replies, edits and views, decayed over the last seven days. &amp;#191;Comprende?&lt;/p&gt;&lt;/div&gt;&lt;!-- [DocumentBodyEnd:2fdb08db-b4a3-435f-bd97-f8a3ff6d6852] --&gt;</description>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">clearspace</category>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">popularity</category>
      <pubDate>Thu, 04 Sep 2008 05:32:44 GMT</pubDate>
      <author>aaron@jivesoftware.com</author>
      <guid>http://www.jivesoftware.com/jivespace/blogs/jivespace/2008/09/04/how-popularity-works-in-clearspace</guid>
      <dc:date>2008-09-04T05:32:44Z</dc:date>
      <clearspace:dateToText>1 year, 2 months ago</clearspace:dateToText>
      <clearspace:replyCount>6</clearspace:replyCount>
      <clearspace:objectType>0</clearspace:objectType>
      <wfw:comment>http://www.jivesoftware.com/jivespace/blogs/jivespace/comment/how-popularity-works-in-clearspace</wfw:comment>
      <wfw:commentRss>http://www.jivesoftware.com/jivespace/blogs/jivespace/feeds/comments?blogPost=1587</wfw:commentRss>
    </item>
    <item>
      <title>Clearspace 2.5 Officially Announced</title>
      <link>http://www.jivesoftware.com/jivespace/blogs/jivespace/2008/08/19/clearspace-25-officially-announced</link>
      <description>&lt;!-- [DocumentBodyStart:6c1f8eab-9e35-4dcf-8777-11cf79178bc3] --&gt;&lt;div class='jive-rendered-content'&gt;&lt;p&gt;Thanks to everyone that's participated in the 2.5 beta -- we're finally ready to officially announce Clearspace 2.5! Check out the main &lt;a class="jive-link-external-small" href="http://www.jivesoftware.com/"&gt;Jive website&lt;/a&gt; for details. Sam's &lt;a class="jive-link-external-small" href="http://gobigalways.com/jive-launches-clearspace-25/"&gt;blog entry&lt;/a&gt; also has a great overview of what's new in the release. You'll also notice that we updated Jivespace to 2.5, so you can trythe release here. We're doing final testing and will have the release bits available in the near future.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;There's a lot in this release that's aimed at the developer crowd including many improvements to the plugin framework and a new theme &lt;a class="jive-link-external-small" href="http://tinyurl.com/54wg6n"&gt;resource kit&lt;/a&gt; for making easier changes to the UI. Check out the many new sections for developers in the &lt;a class="jive-link-external-small" href="http://www.jivesoftware.com/community/docs/"&gt;Clearspace documentation&lt;/a&gt;. Also significant in the 2.5 release are big improvements to performance. Over the past several months, we've built out a performance test environment that's let us measure the many improvements we've been making to the code -- from a 15% improvement in some areas to over 700% in others. Overall, Clearspace 2.5 is at least a 200% faster than 2.0.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;The Clearspace dev team is thrilled with the new release and we hope you'll be too. We're looking forward to your feedback!&lt;/p&gt;&lt;/div&gt;&lt;!-- [DocumentBodyEnd:6c1f8eab-9e35-4dcf-8777-11cf79178bc3] --&gt;</description>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">clearspace</category>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">release</category>
      <pubDate>Tue, 19 Aug 2008 04:59:09 GMT</pubDate>
      <author>matt@jivesoftware.com</author>
      <guid>http://www.jivesoftware.com/jivespace/blogs/jivespace/2008/08/19/clearspace-25-officially-announced</guid>
      <dc:date>2008-08-19T04:59:09Z</dc:date>
      <clearspace:dateToText>1 year, 2 months ago</clearspace:dateToText>
      <clearspace:replyCount>4</clearspace:replyCount>
      <clearspace:objectType>0</clearspace:objectType>
      <wfw:comment>http://www.jivesoftware.com/jivespace/blogs/jivespace/comment/clearspace-25-officially-announced</wfw:comment>
      <wfw:commentRss>http://www.jivesoftware.com/jivespace/blogs/jivespace/feeds/comments?blogPost=1573</wfw:commentRss>
    </item>
    <item>
      <title>Beta Program Launched</title>
      <link>http://www.jivesoftware.com/jivespace/blogs/jivespace/2008/08/07/beta-program-launched</link>
      <description>&lt;!-- [DocumentBodyStart:beb68085-cca0-430b-9cad-89b101524ba7] --&gt;&lt;div class='jive-rendered-content'&gt;&lt;p&gt;We've just launched the public beta program for the next release of Clearspace. We'd love your help in making sure the code is as polished and bug-free as possible before the general release. This release is the third beta (after two private betas) of the 2.5 series. There are two ways to get involved: first, you can &lt;/p&gt;&lt;p&gt;&lt;a class="jive-link-external-small" href="http://www.jivesoftware.com/dev/downloads/index.jsp"&gt;download&lt;/a&gt; the release and install it on your own servers. You can also visit the &lt;a class="jive-link-external-small" href="http://eval2.jivesoftware.com/beta/login.jspa"&gt;beta sandbox site&lt;/a&gt; and create an account to test out a live instance and provide feedback. We're looking forward to hearing what you think!&lt;/p&gt;&lt;/div&gt;&lt;!-- [DocumentBodyEnd:beb68085-cca0-430b-9cad-89b101524ba7] --&gt;</description>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">clearspace</category>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">beta</category>
      <pubDate>Thu, 07 Aug 2008 05:28:34 GMT</pubDate>
      <author>matt@jivesoftware.com</author>
      <guid>http://www.jivesoftware.com/jivespace/blogs/jivespace/2008/08/07/beta-program-launched</guid>
      <dc:date>2008-08-07T05:28:34Z</dc:date>
      <clearspace:dateToText>1 year, 3 months ago</clearspace:dateToText>
      <clearspace:replyCount>6</clearspace:replyCount>
      <clearspace:objectType>0</clearspace:objectType>
      <wfw:comment>http://www.jivesoftware.com/jivespace/blogs/jivespace/comment/beta-program-launched</wfw:comment>
      <wfw:commentRss>http://www.jivesoftware.com/jivespace/blogs/jivespace/feeds/comments?blogPost=1566</wfw:commentRss>
    </item>
    <item>
      <title>Web Service operation UserService deleteUser going away.</title>
      <link>http://www.jivesoftware.com/jivespace/blogs/jivespace/2008/07/28/web-service-operation-userservice-deleteuser-going-away</link>
      <description>&lt;!-- [DocumentBodyStart:10a6cc46-1c8c-4652-8a50-c25a5ad51d88] --&gt;&lt;div class='jive-rendered-content'&gt;&lt;p&gt;In 2.0.6 and 2.5.0 the UserService deleteUser method is going away. This is due to a transaction issue in the core UserManager#deleteUser method. The UserManager#deleteUser method is also disabled in these versions because of this.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;In the web service we opted to remove the method, rather than have the WSDL reflect a method that would only throw an Exception. &lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;The method will once again return in a future version. In the meantime we recommend using the UserService disableUser operation instead as this will prevent the user from contributing any new content.&lt;/p&gt;&lt;/div&gt;&lt;!-- [DocumentBodyEnd:10a6cc46-1c8c-4652-8a50-c25a5ad51d88] --&gt;</description>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">clearspacex</category>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">clearspace</category>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">web-services</category>
      <pubDate>Mon, 28 Jul 2008 17:05:44 GMT</pubDate>
      <author>communities@jivesoftware.com</author>
      <guid>http://www.jivesoftware.com/jivespace/blogs/jivespace/2008/07/28/web-service-operation-userservice-deleteuser-going-away</guid>
      <dc:date>2008-07-28T17:05:44Z</dc:date>
      <clearspace:dateToText>1 year, 3 months ago</clearspace:dateToText>
      <clearspace:objectType>0</clearspace:objectType>
      <wfw:comment>http://www.jivesoftware.com/jivespace/blogs/jivespace/comment/web-service-operation-userservice-deleteuser-going-away</wfw:comment>
      <wfw:commentRss>http://www.jivesoftware.com/jivespace/blogs/jivespace/feeds/comments?blogPost=1563</wfw:commentRss>
    </item>
    <item>
      <title>Customization Part 7: Using the Clearspace API</title>
      <link>http://www.jivesoftware.com/jivespace/blogs/jivespace/2008/07/16/customization-part-7-using-the-clearspace-api</link>
      <description>&lt;!-- [DocumentBodyStart:5a0fb207-d8ba-470e-8b2e-82792811c2fd] --&gt;&lt;div class='jive-rendered-content'&gt;&lt;p&gt;This post is the seventh and final post in a series of blog posts about customizing for Clearspace 2.x. The previous posts covered:&lt;/p&gt;&lt;ol&gt;&lt;li level="1" type="ol"&gt;&lt;p&gt;&lt;a class="jive-link-external-small" href="http://www.jivesoftware.com/community/blogs/clearspace/2008/06/24/customizations-in-clearspace-2x-part-one/"&gt;Customizations in Clearspace 2.x&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ol"&gt;&lt;p&gt;&lt;a class="jive-link-external-small" href="http://www.jivesoftware.com/community/blogs/clearspace/2008/06/26/customization-part-2-upgrading-themes-and-ftl-files/"&gt;Upgrading Themes and FTL Files&lt;/a&gt;. &lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ol"&gt;&lt;p&gt;&lt;a class="jive-link-external-small" href="http://www.jivesoftware.com/community/blogs/clearspace/2008/06/30/customization-part-3-widgets"&gt;Widgets in Clearspace 2.x&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ol"&gt;&lt;p&gt;&lt;a class="jive-link-external-small" href="http://www.jivesoftware.com/community/blogs/clearspace/2008/07/03/customization-part-4-macros"&gt;Macros for Clearspace 2.0&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ol"&gt;&lt;p&gt;&lt;a class="jive-link-external-small" href="http://www.jivesoftware.com/community/blogs/clearspace/2008/07/07/customization-part-5-web-services"&gt;Web Services&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ol"&gt;&lt;p&gt;&lt;a class="jive-link-external-small" href="http://www.jivesoftware.com/community/blogs/clearspace/2008/07/11/customization-part-6-custom-authentication-and-user-data-providers"&gt;Custom Authentication and User Data Providers&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;&lt;/ol&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;Some of the most important changes in version 2 of Clearspace required that the underlying API be changed. To get things working on version 2, you'll need to change not only references to these in your Java classes, but also references to them in your FreeMarker templates.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;The following describes the most significant changes.&lt;/p&gt;&lt;ul&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;Inject Dependencies with Spring &lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;Work with Containers for Projects and Spaces/Communities &lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;Use Transaction Support When Updating Multiple Tables &lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;Use Manager Interfaces to Work with Managed Things &lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;Handle Content As XML &lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;Other API Changes &lt;/p&gt;&lt;/li&gt;&lt;/ul&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;h3&gt;&lt;span&gt;Inject Dependencies With Spring&lt;/span&gt;&lt;/h3&gt;&lt;p&gt;For version 2, the Clearspace codebase was refactored to support &lt;a class="jive-link-external-small" href="http://en.wikipedia.org/wiki/Spring_Framework"&gt;Spring&lt;/a&gt;, a framework with modules for inversion of control, transaction management, authentication, and more. This has potentially the biggest impact on your code because components that extend Clearspace must use the same conventions in order to interact reliably with Clearspace. For example, as described below, dependency injection replaces version 1 conventions for using JiveContext and factory classes to get manager instances.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;&lt;a class="jive-link-external-small" href="http://en.wikipedia.org/wiki/Dependency_Injection"&gt;Dependency injection&lt;/a&gt; is a way to obtain a dependency, such as an object on which your code relies, by having the instance "injected" at run time&amp;nbsp; -- that is, the instance is set with a JavaBeans-style accessor method. In Clearspace code, manager class instances are generally now injected rather than obtained via a context or factory class method.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;A class that supports injection includes a class-level ++ variable for holding the instance it depends on and provides a set* accessor method through which Spring can inject the instance (in other words, your code provides a property of the interface's type). Your setter implementation assigns the injected instance to the variable, which your code can then use to access the instance. By specifying the &lt;em&gt;interface&lt;/em&gt; on which your code depends&amp;nbsp; -- rather than an implementation of the interface&amp;nbsp; -- you have a loosely-coupled dependency. This lets you avoid breakage that might occur if the implementation changes.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;blockquote class="jive-quote" level="1"&gt;&lt;p&gt;&lt;strong&gt;Note:&lt;/strong&gt; You can ensure that the setter you provide actually has a configured type associated with it by &lt;a class="jive-link-external-small" href="http://static.springframework.org/spring/docs/2.5.x/reference/metadata.html#metadata-annotations-required"&gt;annotating the setter method with @org.springframework.beans.factory.annotation.Required&lt;/a&gt;. If the injected type is not known to Spring configuration, then the Spring container will throw an exception at run time.&lt;/p&gt;&lt;/blockquote&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;The following example illustrates the basics of dependency injection with Spring: declare private class-level variables for manager instances and declare setter methods through which Spring will inject the instances. Code for version 1 techniques has been commented out in favor of the Spring conventions.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;!--[CodeBlockStart:00e1ed62-8f20-4c2c-b84c-928968f6843d]--&gt;&lt;pre class="jive-pre"&gt;&lt;code class="jive-code"&gt;// Variables to hold the manager instances.
private DocumentManager documentManager;
private FreemarkerManager freemarkerManager;


// Setters for injecting manager instances.
public void setDocumentManager(DocumentManager documentManager) {
&amp;nbsp;&amp;nbsp;&amp;nbsp; this.documentManager = documentManager;
}
public void setFreemarkerManager(FreemarkerManager freemarkerManager) {
&amp;nbsp;&amp;nbsp;&amp;nbsp; this.freemarkerManager = freemarkerManager;
}

private String getDocContent(String documentID)
{
&amp;nbsp;&amp;nbsp;&amp;nbsp; // ... Declare variables ... 
&amp;nbsp;&amp;nbsp;&amp;nbsp; 
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // Don't use JiveContext (from JiveApplication) to get a DocumentManager 
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // instance. The instance has been injected through the setter above.
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // DocumentManager documentManager = JiveApplication.getContext(AuthFactory
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; //&amp;nbsp;&amp;nbsp;&amp;nbsp; .getSystemAuthToken()).getDocumentManager();
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // Use the manager to get a document by its ID.
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; document = documentManager.getDocument(documentID);
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Map properties = new HashMap();
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // ... Set FreeMarker properties from the document, then apply 
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // a template with them ...
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; result = applyFreemarkerTemplate(properties, FREEMARKER_HTML_FILE);
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 
&amp;nbsp;&amp;nbsp;&amp;nbsp; // ... catch exceptions ...

&amp;nbsp;&amp;nbsp;&amp;nbsp; return result;
}

private String applyFreemarkerTemplate(Map properties,
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; String templateName) {
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 
&amp;nbsp;&amp;nbsp;&amp;nbsp; // ... Declare variables ... 
&amp;nbsp;&amp;nbsp;&amp;nbsp; 
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // Don't use getInstance to get the FreemarkerManager instance. It has 
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // been injected.
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // FreemarkerManager freemarkerManager = FreemarkerManager.getInstance();
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // ... Use the manager to set up FreeMarker configuration ...
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; config = freemarkerManager.getConfiguration(ServletActionContext.getServletContext());
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if (properties != null) {
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // Process the FreeMarker template and store the resulting HTML as a String
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; result = applyFreemarkerTemplate(config, properties, templateName);
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 
&amp;nbsp;&amp;nbsp;&amp;nbsp; // ... catch exceptions ...

&amp;nbsp;&amp;nbsp;&amp;nbsp; return result;
}&lt;/code&gt;&lt;/pre&gt;&lt;!--[CodeBlockEnd:00e1ed62-8f20-4c2c-b84c-928968f6843d]--&gt;&lt;p&gt;While you can optionally name the specific interface implementation you want to have injected, Spring in Clearspace supports a feature known as autowiring. In autowiring, you merely include the setter method (using JavaBeans naming conventions) with a single parameter of the interface's type. To optionally specify the implementation you want injected, you include a spring.xml file that associates the implementation class with your setter.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;&lt;strong&gt;Remove JiveContext uses that retrieve managers.&lt;/strong&gt; In version 1 the JiveContext interface was a popular convention to get instances of the various manager interfaces&amp;nbsp; -- CommunityManager, UserManager, DocumentManager, and so on. In version 2 this convention is, depending on the case, either unavailable or unreliable. For example, if you've written a plugin that has a static initializer that tries to bootstrap with call to JiveContext, Clearspace startup will likely fail.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;Instead, use dependency injection as described above. In fact, to stay out of trouble, the general rule in version 2 is "Don't use JiveContext."&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;&lt;strong&gt;Remove getInstance calls that retrieve managers.&lt;/strong&gt; This includes FreemarkerManager.getInstance, but also all of the *Factory.getInstance methods you might have used in version 1. In version 2 most of the factory classes have been removed. You should replace your calls to their getInstance methods with a property for setting the instance from Spring as described above. Here's a list of the removed classes:&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;ul&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;GroupManagerFactory &lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;UserManagerFactory &lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;AvatarManagerFactory &lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;BanManagerFactory &lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;PollManagerFactory &lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;SearchQueryLoggerFactory &lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;StatusLevelManagerFactory &lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;TagManagerFactory &lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;WidgetDAOFactory &lt;/p&gt;&lt;/li&gt;&lt;/ul&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;h3&gt;&lt;span&gt;Work with Containers for Projects and Spaces/Communities&lt;/span&gt;&lt;/h3&gt;&lt;p&gt;Version 2 introduces &lt;em&gt;projects&lt;/em&gt;, which, like spaces (known as communities in Clearspace Community), collect content such as documents, discussions, and blogs. Projects also add tasks as a content type. To organize the conceptually similar projects and spaces, the API was changed to introduce the idea of a &lt;em&gt;container&lt;/em&gt;. The interfaces that represent projects and spaces&amp;nbsp; -- Project and Community&amp;nbsp; -- now inherit from a common JiveContainer interface.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;In practical terms, this means that some methods taking an instance of the Community interface now take a JiveContainer instance instead. The following code works to get the latest document in either a project or space, for example, because they inherit from JiveContainer and both can contain documents. To see how your code might be affected, search the Javadoc index for occurrences of JiveContainer in method signatures and return types.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;!--[CodeBlockStart:88a17ff2-4fb3-49f9-802d-a9fd7c8f882d]--&gt;&lt;pre class="jive-pre"&gt;&lt;code class="jive-code"&gt;public Document getLatestDocument(JiveContainer container) {
&amp;nbsp;&amp;nbsp;&amp;nbsp; if (getDocumentCount(container) == 0) {
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; return null;
&amp;nbsp;&amp;nbsp;&amp;nbsp; }
&amp;nbsp;&amp;nbsp;&amp;nbsp; DocumentResultFilter filter = new DocumentResultFilter();
&amp;nbsp;&amp;nbsp;&amp;nbsp; filter.setSortOrder(DocumentResultFilter.DESCENDING);
&amp;nbsp;&amp;nbsp;&amp;nbsp; filter.setSortField(JiveConstants.MODIFICATION_DATE);

&amp;nbsp;&amp;nbsp;&amp;nbsp; // Round down the lower date boundary by 1 day.
&amp;nbsp;&amp;nbsp;&amp;nbsp; filter.setModificationDateRangeMin(ThreadResultFilter
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; .roundDate(container.getModificationDate(), 24 * 60 * 60));
&amp;nbsp;&amp;nbsp;&amp;nbsp; filter.setNumResults(10);
&amp;nbsp;&amp;nbsp;&amp;nbsp; Iterable&amp;lt;Document&amp;gt; documents = documentManager.getDocuments(container, filter);
&amp;nbsp;&amp;nbsp;&amp;nbsp; if (documents.iterator().hasNext()) {
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; return documents.iterator().next();
&amp;nbsp;&amp;nbsp;&amp;nbsp; }
&amp;nbsp;&amp;nbsp;&amp;nbsp; else {
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; return null;
&amp;nbsp;&amp;nbsp;&amp;nbsp; }
}&lt;/code&gt;&lt;/pre&gt;&lt;!--[CodeBlockEnd:88a17ff2-4fb3-49f9-802d-a9fd7c8f882d]--&gt;&lt;p&gt;By the way, this getLatestDocument method is now exposed by the DocumentManager interface; in version 1 this method was exposed by the Document interface. Methods such as this one were moved as part of a larger effort to migrate such functionality into managers.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;h3&gt;&lt;span&gt;Use Transaction Support When Updating Multiple Tables&lt;/span&gt;&lt;/h3&gt;&lt;p&gt;Version 2 supports &lt;a class="jive-link-external-small" href="http://static.springframework.org/spring/docs/1.2.x/reference/transaction.html#d0e5917"&gt;transaction management through Spring with the @Transactional annotation&lt;/a&gt;. When the work of your code results in updates (including deletes) to data in multiple database tables, supporting &lt;a class="jive-link-external-small" href="http://en.wikipedia.org/wiki/Database_transaction"&gt;transactional behavior&lt;/a&gt; can help to ensure that the updates are made consistently (that is, all of the effected tables are updated or none are).&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;If you're explicitly supporting transactions with @Transactional, you'll need to add an &lt;a class="jive-link-external-small" href="http://en.wikipedia.org/wiki/AspectJ"&gt;AspectJ&lt;/a&gt; compilation step. The AspectJ compiler weaves into your code the support needed to include at load time your transactional method calls in a transaction context.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;You'll want to add transaction support if your code updates multiple database tables as while executing a method. While the need to support transactions is fairly rare if you're doing all your work through the Clearspace API, keep in mind that your calls to API set* methods might result in database updates. If you're not sure whether your code's work results in database updates, it's not a bad idea probably to add the @Transactional annotation to the method.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;Adding support for transactions is pretty easy. Here's what you do:&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;ul&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;Add the @Transactional annotation to any methods whose execution might result in updates to multiple tables. The annotation is in the package &lt;a class="jive-link-external-small" href="http://static.springframework.org/spring/docs/2.0.x/api/org/springframework/transaction/annotation/Transactional.html"&gt;org.springframework.transaction.annotation&lt;/a&gt;.&lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;Compile your code with the &lt;a class="jive-link-external-small" href="http://www.eclipse.org/aspectj/doc/released/devguide/ajc-ref.html"&gt;AspectJ compiler&lt;/a&gt;. There are also &lt;a class="jive-link-external-small" href="http://www.eclipse.org/aspectj/doc/released/devguide/antTasks.html"&gt;Ant tasks&lt;/a&gt;.&lt;/p&gt;&lt;/li&gt;&lt;/ul&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;h3&gt;&lt;span&gt;Use Manager Interfaces to Work with Managed Things&lt;/span&gt;&lt;/h3&gt;&lt;p&gt;Much of the Clearspace code was rewritten to clarify (or create) relationships between instances of manager interfaces and instances of what they manage. The result is an API that's more intuitive, but it also might mean changes to your code.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;In general, methods designed to handle &lt;em&gt;types of things&lt;/em&gt;&amp;nbsp; -- documents, attachments, discussion messages, and so on&amp;nbsp; -- were moved from a "containing" type to a manager type. For example, in version 1 the method getAttachmentCount was exposed by the interfaces BlogPost, Document, and ForumMessage ; each of these could have attachments, and getAttachmentCount was how you got the count of them. In version 2, you get the count of attachments with the AttachmentManager.getAttachmentCount(AttachmentContentResource) method. The AttachmentContentResource is a marker interface extended by BlogPost, Document, ForumMessage, and other things that can have attachments.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;So in version 2 the rule of thumb, when looking for a way to manage types of things, is to look for a manager of those things.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;h3&gt;&lt;span&gt;Handle Content As XML&lt;/span&gt;&lt;/h3&gt;&lt;p&gt;Version 2 includes significant changes in the way Clearspace handles content. Improving the rich text editor (which blogs, documents, and discussions threads all use) included completely reworking the way that content is handled in conversions between plain text (wiki markup), rich text, and HTML (for previewed and published content).&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;In particular, content is set and received as XML. In version 1, the content-related accessors that get and set content body, subject and so on received and returned String instances. In version 2, these methods handle content as instances of org.w3c.dom.Document. Version 2 interfaces that used content accessor methods&amp;nbsp; -- including Document, PrivateMessage, ForumMessage, BlogPost, and others&amp;nbsp; -- still include methods such as getPlainBody for retrieving content without markup.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;For plugins that include actions, you can extend JiveActionSupport for several methods helpful in converting content from one format to another.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;While version 2 features a model for setting and getting content as XML, there's also an exception: the Macro interface render method still returns content as a String. It has to parse as well-formed XML, but it's still a string.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;h3&gt;&lt;span&gt;Other API Changes&lt;/span&gt;&lt;/h3&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;ul&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;In some cases, methods that took a JiveObject instance now take an instance of an interface that extends JiveObject. The marker interfaces CommentContentResource and AttachmentContentResource were created to indicate an object's support for comments or attachments. Look for these types in the Javadoc index to find out whether you need to update your own code.&lt;/p&gt;&lt;/li&gt;&lt;/ul&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;The information above along with more details can be found in the &lt;a class="jive-link-external-small" href="http://www.jivesoftware.com/community/docs/DOC-2060/"&gt;Upgrading Extensions to 2.0 documentation&lt;/a&gt;.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;/div&gt;&lt;!-- [DocumentBodyEnd:5a0fb207-d8ba-470e-8b2e-82792811c2fd] --&gt;</description>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">clearspace</category>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">freemarker</category>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">freemarker</category>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">java</category>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">xml</category>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">spring</category>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">2.0</category>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">api</category>
      <pubDate>Wed, 16 Jul 2008 21:46:18 GMT</pubDate>
      <author>communities@jivesoftware.com</author>
      <guid>http://www.jivesoftware.com/jivespace/blogs/jivespace/2008/07/16/customization-part-7-using-the-clearspace-api</guid>
      <dc:date>2008-07-16T21:46:18Z</dc:date>
      <clearspace:dateToText>1 year, 4 months ago</clearspace:dateToText>
      <clearspace:replyCount>1</clearspace:replyCount>
      <clearspace:objectType>0</clearspace:objectType>
      <wfw:comment>http://www.jivesoftware.com/jivespace/blogs/jivespace/comment/customization-part-7-using-the-clearspace-api</wfw:comment>
      <wfw:commentRss>http://www.jivesoftware.com/jivespace/blogs/jivespace/feeds/comments?blogPost=1551</wfw:commentRss>
    </item>
    <item>
      <title>Poll For Clearspace, What Customizations Do You Perform</title>
      <link>http://www.jivesoftware.com/jivespace/blogs/jivespace/2008/07/15/poll-for-clearspace-what-customizations-do-you-perform</link>
      <description>&lt;!-- [DocumentBodyStart:24579e60-6166-41a1-936d-ef519c4a8571] --&gt;&lt;div class='jive-rendered-content'&gt;&lt;p&gt;I created a quick, &lt;a class="jive-link-external-small" href="http://www.jivesoftware.com/community/poll.jspa?poll=1012"&gt;one-question poll&lt;/a&gt; on Jivespace to help understand what types of customizations are the most commonly performed. It would be great if you could take a few seconds to answer this one question for us. &lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;&lt;a href="http://www.jivesoftware.com/jivespace/servlet/JiveServlet/showImage/38-1554-3371/Picture+7.png"&gt;&lt;img alt="Picture 7.png" height="353" src="http://www.jivesoftware.com/jivespace/servlet/JiveServlet/downloadImage/38-1554-3371/234-353/Picture+7.png" width="234"/&gt;&lt;/a&gt; &lt;/p&gt;&lt;p&gt;&lt;a class="jive-link-external-small" href="http://www.jivesoftware.com/community/poll.jspa?poll=1012"&gt;Respond to the poll now.&lt;/a&gt;&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;We'll use this information to help decide what information would be the most helpful for this blog. I'm also happy to take suggestions here in the comments if you have anything that you would like to see us blog about here on Jivespace.&lt;/p&gt;&lt;/div&gt;&lt;!-- [DocumentBodyEnd:24579e60-6166-41a1-936d-ef519c4a8571] --&gt;</description>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">clearspace</category>
      <pubDate>Tue, 15 Jul 2008 15:16:56 GMT</pubDate>
      <author>communities@jivesoftware.com</author>
      <guid>http://www.jivesoftware.com/jivespace/blogs/jivespace/2008/07/15/poll-for-clearspace-what-customizations-do-you-perform</guid>
      <dc:date>2008-07-15T15:16:56Z</dc:date>
      <clearspace:dateToText>1 year, 3 months ago</clearspace:dateToText>
      <clearspace:objectType>0</clearspace:objectType>
      <wfw:comment>http://www.jivesoftware.com/jivespace/blogs/jivespace/comment/poll-for-clearspace-what-customizations-do-you-perform</wfw:comment>
      <wfw:commentRss>http://www.jivesoftware.com/jivespace/blogs/jivespace/feeds/comments?blogPost=1554</wfw:commentRss>
    </item>
    <item>
      <title>Customization Part 6: Custom Authentication and User Data Providers</title>
      <link>http://www.jivesoftware.com/jivespace/blogs/jivespace/2008/07/11/customization-part-6-custom-authentication-and-user-data-providers</link>
      <description>&lt;!-- [DocumentBodyStart:16a5678b-872f-4d65-b2e1-f0a1fdd6b003] --&gt;&lt;div class='jive-rendered-content'&gt;&lt;p&gt;This post is the sixth in a series of blog posts about customizing for Clearspace 2.x. The previous posts covered:&lt;/p&gt;&lt;ol&gt;&lt;li level="1" type="ol"&gt;&lt;p&gt;&lt;a class="jive-link-external-small" href="http://www.jivesoftware.com/community/blogs/clearspace/2008/06/24/customizations-in-clearspace-2x-part-one/"&gt;Customizations in Clearspace 2.x&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ol"&gt;&lt;p&gt;&lt;a class="jive-link-external-small" href="http://www.jivesoftware.com/community/blogs/clearspace/2008/06/26/customization-part-2-upgrading-themes-and-ftl-files/"&gt;Upgrading Themes and FTL Files&lt;/a&gt;. &lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ol"&gt;&lt;p&gt;&lt;a class="jive-link-external-small" href="http://www.jivesoftware.com/community/blogs/clearspace/2008/06/30/customization-part-3-widgets"&gt;Widgets in Clearspace 2.x&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ol"&gt;&lt;p&gt;&lt;a class="jive-link-external-small" href="http://www.jivesoftware.com/community/blogs/clearspace/2008/07/03/customization-part-4-macros"&gt;Macros for Clearspace 2.0&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ol"&gt;&lt;p&gt;&lt;a class="jive-link-external-small" href="http://www.jivesoftware.com/community/blogs/clearspace/2008/07/07/customization-part-5-web-services"&gt;Web Services&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;&lt;/ol&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;As in the Clearspace 1.x series, in Clearspace 2.x versions you can write your own components to manage user information and provide custom authentication. &lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;h3&gt;&lt;span&gt;Upgrading a User Data Provider&lt;/span&gt;&lt;/h3&gt;&lt;p&gt;In version 1 you created a custom user provider by implementing the com.jivesoftware.spi.user.UserProvider interface to interact with your user data source and implementing the com.jivesoftware.base.User interface to represent a user. In version 2, you implement UserProvider and User, but the interfaces have changed a bit. The version 2 model is more streamlined, removing the need to implement the lifecycle methods that the SPI framework requires. Here's a summary of the changes:&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;ul&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;Because you no longer implement the ServiceProvider interface, you don't implement support for its life cycle methods. Clearspace handles provider life cycle through Spring.&lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;The com.jivesoftware.base.User interface is read-only (lacks setters) in version 2. Your implementation now provides the interface and logic for updating user information and returning it to Clearspace.&lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;The User.authenticate method has been removed. Use an authentication provider to authenticate a user.&lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;The User interface includes several new methods for retrieving information about the user.&lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;You now connect your custom provider to Clearspace using Spring conventions rather than by setting a Jive property.&lt;/p&gt;&lt;/li&gt;&lt;/ul&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;Here's a high level view of the upgrade steps you'll need to consider.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;ul&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;Implement the User interface to support whatever setters it needs. You'll also want to implement the is*Supported methods that indicate to Clearspace which user data is supported for setting.&lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;For UserProvider methods in which your code receives and returns a User instance, you'll need to rewrite a bit to return your own User implementation. In version 1 the UserProvider instance received a UserTemplate with setters. Because you can no longer simply call setters on the User instance you receive (it might not have any), you'll instead copy data from the received instance into an instance of your own implementation and return your own (such as by constructing your instance from the User your code receives). The methods you'll need to change include create(User) and getUser(User).&lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;Implement UserProvider.supportsUpdate to return true if your data store supports creating or updating users from Clearspace. If you return false from this method, be sure to also throw an UnsupportedOperationException from the create and update methods.&lt;/p&gt;&lt;/li&gt;&lt;/ul&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;h3&gt;&lt;span&gt;Upgrading an Authentication Provider&lt;/span&gt;&lt;/h3&gt;&lt;p&gt;Authentication is substantially changed in version 2. For example, you no longer need to pass an AuthToken instance with method calls. Every request is guaranteed to have an authentication context. In version 2, Clearspace uses Acegi security, which is designed to fit well with the Spring framework. If you're implementing your own authentication provider, your components are based on Acegi; in some cases you might be able to use the classes included with Acegi, such as Authentication implementations.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;Be sure to read the &lt;a class="jive-link-external-small" href="http://www.acegisecurity.org/guide/springsecurity.html"&gt;Acegi documentation&lt;/a&gt;, which includes information you'll find useful.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;h4&gt;&lt;span&gt;What Your Implementation Should Include&lt;/span&gt;&lt;/h4&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;ul&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;Implement org.acegisecurity.AuthenticationProvider to provide the service that authenticates users for Clearspace. This interface includes two methods: authenticate(Authentication) and supports(Class). Your supports method is called by Clearspace to determine whether the Authentication approach is supported by your provider. You should return true if the Authentication class it receives is one your authenticate method supports.&lt;/p&gt;&lt;/li&gt;&lt;/ul&gt;&lt;!--[CodeBlockStart:96ee5b67-4387-46ad-b25d-72951a6663c2]--&gt;&lt;pre class="jive-pre"&gt;&lt;code class="jive-code"&gt;public boolean supports(Class authentication) {
&amp;nbsp;&amp;nbsp;&amp;nbsp; return authentication == UsernamePasswordAuthenticationToken.class;
}&lt;/code&gt;&lt;/pre&gt;&lt;!--[CodeBlockEnd:96ee5b67-4387-46ad-b25d-72951a6663c2]--&gt;&lt;p&gt;&lt;br/&gt; The authenticate method receives an Authentication instance containing information identifying the user. Your implementation knows how to authenticate the user and should return an Authentication instance that indicates whether the user is authenticated. Here's a simple authenticate method example in which the checkAuth method (not shown) communicates with the data source and returns true if the user is authentic: &lt;br/&gt; &lt;/p&gt;&lt;!--[CodeBlockStart:052bf3a2-ec10-4f90-96eb-74946125058f]--&gt;&lt;pre class="jive-pre"&gt;&lt;code class="jive-code"&gt;public Authentication authenticate(Authentication authentication) throws AuthenticationException {
&amp;nbsp;&amp;nbsp;&amp;nbsp; UsernamePasswordAuthenticationToken auth = (UsernamePasswordAuthenticationToken) authentication;
&amp;nbsp;&amp;nbsp;&amp;nbsp; String username = String.valueOf(auth.getPrincipal());
&amp;nbsp;&amp;nbsp;&amp;nbsp; String password = String.valueOf(auth.getCredentials());
&amp;nbsp;&amp;nbsp;&amp;nbsp; if(!checkAuth(username, password)){
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; throw new BadCredentialsException("Username:" + username + " was not authenticated");
&amp;nbsp;&amp;nbsp;&amp;nbsp; }
&amp;nbsp;&amp;nbsp;&amp;nbsp; return new UsernamePasswordAuthenticationToken(username, password, new GrantedAuthority[]{});
}&lt;/code&gt;&lt;/pre&gt;&lt;!--[CodeBlockEnd:052bf3a2-ec10-4f90-96eb-74946125058f]--&gt;&lt;p&gt;&lt;br/&gt; &lt;/p&gt;&lt;ul&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;Implement org.acegisecurity.Authentication to contain details of the authentication request (you can also use an existing class that implements Authentication ). An Authentication class represents the user in the context of a particular authentication approach -- such as basic authentication, LDAP, X.509 certificate, and so on. An instance includes details such as principal (something identifying the user, such as a username) and credentials (such as a password). Your isAuthenticated method should return true if the user is authentic. &lt;br/&gt;&amp;nbsp; &lt;br/&gt; The Authentication class includes a getAuthorities method that is not currently supported by Clearspace. Your implementation should return an empty array: &lt;br/&gt; &lt;/p&gt;&lt;/li&gt;&lt;/ul&gt;&lt;!--[CodeBlockStart:5a43fbfd-401a-45a6-936e-ff849c9c2d63]--&gt;&lt;pre class="jive-pre"&gt;&lt;code class="jive-code"&gt;public GrantedAuthority[] getAuthorities() {
&amp;nbsp;&amp;nbsp;&amp;nbsp; return new GrantedAuthority[0];
}]&lt;/code&gt;&lt;/pre&gt;&lt;!--[CodeBlockEnd:5a43fbfd-401a-45a6-936e-ff849c9c2d63]--&gt;&lt;p&gt;&lt;br/&gt; &lt;/p&gt;&lt;ul&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;Connect your authentication provider to Clearspace by adding a Spring configuration XML file to the jiveHome/etc directory.&lt;/p&gt;&lt;/li&gt;&lt;/ul&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;!--[CodeBlockStart:6da4fb35-a54f-4870-81f3-c5eb3c76368c]--&gt;&lt;pre class="jive-pre"&gt;&lt;code class="jive-code"&gt;&amp;lt;?xml version="1.0" encoding="UTF-8"?&amp;gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;beans xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.0.xsd"&amp;gt;
&amp;lt;bean id="filterChainProxy" class="org.acegisecurity.util.FilterChainProxy"&amp;gt;
&amp;lt;property name="filterInvocationDefinitionSource"&amp;gt;
&amp;lt;value&amp;gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; CONVERT_URL_TO_LOWERCASE_BEFORE_COMPARISON
&amp;nbsp;&amp;nbsp;&amp;nbsp; PATTERN_TYPE_APACHE_ANT
&amp;nbsp;&amp;nbsp;&amp;nbsp; /upgrade/**=httpSessionContextIntegrationFilter, upgradeAuthenticationFilter, upgradeExceptionTranslationFilter
&amp;nbsp;&amp;nbsp;&amp;nbsp; /post-upgrade/**=httpSessionContextIntegrationFilter, postUpgradeAuthenticationFilter, postUpgradeExceptionTranslationFilter
&amp;nbsp;&amp;nbsp;&amp;nbsp; /admin/**=httpSessionContextIntegrationFilter, adminAuthenticationFilter, adminExceptionTranslationFilter
&amp;nbsp;&amp;nbsp;&amp;nbsp; /rpc/xmlrpc=httpSessionContextIntegrationFilter, basicAuthenticationFilter, wsExceptionTranslator
&amp;nbsp;&amp;nbsp;&amp;nbsp; /rpc/rest/**=httpSessionContextIntegrationFilter, basicAuthenticationFilter, wsExceptionTranslator
&amp;nbsp;&amp;nbsp;&amp;nbsp; /**=httpSessionContextIntegrationFilter, formAuthenticationFilter, rememberMeProcessingFilter, anonymousProcessingFilter, exceptionTranslationFilter
&amp;nbsp;&amp;nbsp;&amp;nbsp; .... add your implementation ...
&amp;lt;/value&amp;gt;
&amp;lt;/property&amp;gt;
&amp;lt;/bean&amp;gt;&lt;/code&gt;&lt;/pre&gt;&lt;!--[CodeBlockEnd:6da4fb35-a54f-4870-81f3-c5eb3c76368c]--&gt;&lt;p&gt;The following stanza lists the authentication providers that Clearspace tries to use. When trying to authenticate a user, Clearspace tries with each in turn, top to bottom. Each of the beans listed here&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;!--[CodeBlockStart:d6595bc6-4642-4477-9cce-bd4ad7b09473]--&gt;&lt;pre class="jive-pre"&gt;&lt;code class="jive-code"&gt;&amp;lt;!-- A list of authentication sources that will be consulted when attempting to
&amp;nbsp;&amp;nbsp;&amp;nbsp; authenticate the user. Each is consulted in order until a provider does
&amp;nbsp;&amp;nbsp;&amp;nbsp; *not* return null. This chains multiple providers together
&amp;nbsp;&amp;nbsp;&amp;nbsp; until one decides it can handle the user. --&amp;gt;
&amp;lt;bean id="authenticationManager" 
&amp;nbsp;&amp;nbsp;&amp;nbsp; class="org.acegisecurity.providers.ProviderManager"&amp;gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;property name="providers"&amp;gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;list&amp;gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;ref bean="jiveLdapAuthenticationProvider"/&amp;gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;ref bean="jiveLegacyAuthenticationProvider"/&amp;gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;ref bean="daoAuthenticationProvider" /&amp;gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;ref bean="rememberMeAuthenticationProvider"/&amp;gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;ref bean="anonymousAuthenticationProvider"/&amp;gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/list&amp;gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/property&amp;gt;
&amp;lt;/bean&amp;gt;&lt;/code&gt;&lt;/pre&gt;&lt;!--[CodeBlockEnd:d6595bc6-4642-4477-9cce-bd4ad7b09473]--&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;The information above along with more details can be found in the &lt;a class="jive-link-external-small" href="http://www.jivesoftware.com/community/docs/DOC-2060/"&gt;Upgrading Extensions to 2.0 documentation&lt;/a&gt;.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;If you are working on authentication for SSO, you might also be interested in reading Fred's post about &lt;a class="jive-link-external-small" href="http://www.jivesoftware.com/community/blogs/clearspace/2008/07/01/quick-sso-on-clearspace-20/"&gt;Quick SSO on Clearspace 2.0&lt;/a&gt;&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;/div&gt;&lt;!-- [DocumentBodyEnd:16a5678b-872f-4d65-b2e1-f0a1fdd6b003] --&gt;</description>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">clearspace</category>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">sso</category>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">sso</category>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">authentication</category>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">acegi</category>
      <pubDate>Fri, 11 Jul 2008 21:37:43 GMT</pubDate>
      <author>communities@jivesoftware.com</author>
      <guid>http://www.jivesoftware.com/jivespace/blogs/jivespace/2008/07/11/customization-part-6-custom-authentication-and-user-data-providers</guid>
      <dc:date>2008-07-11T21:37:43Z</dc:date>
      <clearspace:dateToText>1 year, 4 months ago</clearspace:dateToText>
      <clearspace:replyCount>1</clearspace:replyCount>
      <clearspace:objectType>0</clearspace:objectType>
      <wfw:comment>http://www.jivesoftware.com/jivespace/blogs/jivespace/comment/customization-part-6-custom-authentication-and-user-data-providers</wfw:comment>
      <wfw:commentRss>http://www.jivesoftware.com/jivespace/blogs/jivespace/feeds/comments?blogPost=1550</wfw:commentRss>
    </item>
    <item>
      <title>Chats in spaces, projects and social groups</title>
      <link>http://www.jivesoftware.com/jivespace/blogs/jivespace/2008/07/07/chats-in-spaces-projects-and-social-groups</link>
      <description>&lt;!-- [DocumentBodyStart:54d05055-8edd-4965-9183-2041fdb09d2c] --&gt;&lt;div class='jive-rendered-content'&gt;&lt;p&gt;In my previous blog posts I talked about &lt;a class="jive-link-external-small" href="http://www.jivesoftware.com/community/blogs/clearspace/2008/05/15/connecting-a-chat-client-to-clearspace"&gt;Connecting a chat client to Clearspace&lt;/a&gt; and &lt;a class="jive-link-external-small" href="http://www.jivesoftware.com/community/blogs/clearspace/2008/06/03/scheduling-chats-in-clearspace"&gt;Scheduling chats in Clearspace&lt;/a&gt;. Today we are going to explain another usage of Chat inside of Clearspace. &lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;Lets say that we create a new social group that can be seen by anyone and anyone can join the group. As described in &lt;a class="jive-link-external-small" href="http://www.jivesoftware.com/community/blogs/clearspace/2008/05/15/connecting-a-chat-client-to-clearspace"&gt;Connecting a chat client to Clearspace&lt;/a&gt;, I can use my XMPP client to log into Openfire using my Clearspace credentials. I will then see in my roster (aka contacts list) the newly created social group and its members. From there I can easily tell if they are available, away, unavailable, etc. If I want I can start a one-to-one conversation or even send messages to offline users knowing that they will get them when they come back online.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;A room in Openfire was created when we created the social group in Clearspace. Rooms are also created when you create new spaces or projects. So what are these rooms? These rooms are defined by &lt;a class="jive-link-external-small" href="http://www.xmpp.org/extensions/xep-0045.html"&gt;XEP-0045: Multi-User Chat&lt;/a&gt; and will exist as long as the social group, space or project exists. When someone tries to join the room, Openfire will ask Clearspace if that user is allowed to join the room. Clearspace will check the user permissions on the social group, space or project to answer that question.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;Most XMPP clients allow you to browse rooms on the server. This is a very convenient way for users to discover rooms and join them. As we said, Clearspace has the ultimate control on who can join which room. Once in the room, everything that is said and information about users that join and left the room is stored in Clearspace. The chat transcript and presence information is updated every minute in Clearspace. It is also immediately available for searches.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;Besides being able to join from your XMPP client of choice you will also have the choice to join the room from the Clearspace site. When you go to the page of the social group, project or space you can customize it to have a widget that will show the room activity (without actually joining the room). Users can then click the join button to actually join the room and participate from the widget. Beside the widget option we also provide other ways to join the room from your site.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;Moreover, just like you can do in youtube.com it is also possible to copy some HTML instructions to embed the chat widget in your site outside of Clearspace. You can even pass the user/password from your site to the embedded widget so that the user does not need to log in again. However, if no user/password was passed then the widget will ask the user for his credentials before joining the room.&lt;/p&gt;&lt;/div&gt;&lt;!-- [DocumentBodyEnd:54d05055-8edd-4965-9183-2041fdb09d2c] --&gt;</description>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">clearspace</category>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">integration</category>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">rtc</category>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">openfire</category>
      <pubDate>Mon, 07 Jul 2008 22:56:13 GMT</pubDate>
      <author>gaston@jivesoftware.com</author>
      <guid>http://www.jivesoftware.com/jivespace/blogs/jivespace/2008/07/07/chats-in-spaces-projects-and-social-groups</guid>
      <dc:date>2008-07-07T22:56:13Z</dc:date>
      <clearspace:dateToText>1 year, 4 months ago</clearspace:dateToText>
      <clearspace:replyCount>14</clearspace:replyCount>
      <clearspace:objectType>0</clearspace:objectType>
      <wfw:comment>http://www.jivesoftware.com/jivespace/blogs/jivespace/comment/chats-in-spaces-projects-and-social-groups</wfw:comment>
      <wfw:commentRss>http://www.jivesoftware.com/jivespace/blogs/jivespace/feeds/comments?blogPost=1552</wfw:commentRss>
    </item>
    <item>
      <title>Customization Part 5: Web Services</title>
      <link>http://www.jivesoftware.com/jivespace/blogs/jivespace/2008/07/07/customization-part-5-web-services</link>
      <description>&lt;!-- [DocumentBodyStart:c5ad2f68-240b-45c8-a77e-b7577ba4c256] --&gt;&lt;div class='jive-rendered-content'&gt;&lt;p&gt;This post is the fifth in a series of blog posts about customizing for Clearspace 2.x. The previous posts covered:&lt;/p&gt;&lt;ol&gt;&lt;li level="1" type="ol"&gt;&lt;p&gt;&lt;a class="jive-link-external-small" href="http://www.jivesoftware.com/community/blogs/clearspace/2008/06/24/customizations-in-clearspace-2x-part-one/"&gt;Customizations in Clearspace 2.x&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ol"&gt;&lt;p&gt;&lt;a class="jive-link-external-small" href="http://www.jivesoftware.com/community/blogs/clearspace/2008/06/26/customization-part-2-upgrading-themes-and-ftl-files/"&gt;Upgrading Themes and FTL Files&lt;/a&gt;. &lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ol"&gt;&lt;p&gt;&lt;a class="jive-link-external-small" href="http://www.jivesoftware.com/community/blogs/clearspace/2008/06/30/customization-part-3-widgets"&gt;Widgets in Clearspace 2.x&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ol"&gt;&lt;p&gt;&lt;a class="jive-link-external-small" href="http://www.jivesoftware.com/community/blogs/clearspace/2008/07/03/customization-part-4-macros"&gt;Macros for Clearspace 2.0&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;&lt;/ol&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;Several changes were made in Clearspace 2.0 that could impact your web services code, whether the code is for a client or new service. Generally, these changes were made to make the API easier to use, to add functionality (such as support for REST, new in version 2), or to remove a little-used feature that couldn't be made to work well.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;ul&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;ln version 2 Clearspace web services are built on the &lt;a class="jive-link-external-small" href="http://incubator.apache.org/cxf/"&gt;CXF framework&lt;/a&gt;. CXF evolved from XFire, the framework on which Clearspace version 1 web services were built. When upgrading, be sure to update your classpath to replace the XFire JAR file with the CXF JAR.&lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;SOAP-based web services no longer support caching; references to caching have been removed from the web service client API. &lt;br/&gt; &lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;If you're using the Clearspace web service client API (for SOAP web services), you'll need to update your references to some classes. To clarify the difference between the standard and web service client APIs, some class names were prefixed with "WS". The &lt;a class="jive-link-external-small" href="http://www.jivesoftware.com/community/docs/DOC-2060/"&gt;Upgrading Extensions to Version 2&lt;/a&gt; documentation contains a list of the renamed classes; these are all in the com.jivesoftware.community.webservices package. Of course, this also means that signatures for some of the methods within the API itself have changed where these types were used. &lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;Update some API references where arrays were used so that collections are used instead.&lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;The .NET client API is no longer available. If you've got a .NET client, you'll need to rewrite it using another web service client library.&lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;If you've written web services that expose Clearspace functionality, note that the WSUtil.getJiveContext method has been removed. Instead, as noted in the description of API changes, you should use Spring properties to obtain manager references. &lt;br/&gt; &lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;Web services you've included in a plugin are no longer declared in the plugin.xml file. In version 2, when writing a web service for deployment in a plugin, you declare the web service in a spring.xml file included in your plugin. Use the &lt;a class="jive-link-external-small" href="http://cwiki.apache.org/CXF20DOC/ws-security.html"&gt;conventions described in the Apache CXF user's guide&lt;/a&gt;.Here's an example &lt;br/&gt; &lt;/p&gt;&lt;/li&gt;&lt;/ul&gt;&lt;!--[CodeBlockStart:c01e982d-bb94-4d83-8d60-dc9e45a221fa]--&gt;&lt;pre class="jive-pre"&gt;&lt;code class="jive-code"&gt;&amp;lt;bean id="echoServiceImpl" class="com.jivesoftware.clearspace.plugin.example.webservices.EchoServiceImpl /"&amp;gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; 
&amp;lt;bean id="saajInInterceptor" class="org.apache.cxf.binding.soap.saaj.SAAJInInterceptor" /&amp;gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;bean id="wss4jInInterceptor" class="org.apache.cxf.ws.security.wss4j.WSS4JInInterceptor"&amp;gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;constructor-arg&amp;gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;map&amp;gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;entry key="passwordCallbackClass"
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; value="com.jivesoftware.community.webservices.server.xfire.PasswordHandler" /&amp;gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;entry key="action" value="UsernameToken" /&amp;gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/map&amp;gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/constructor-arg&amp;gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/bean&amp;gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;bean id="validationCheckInterceptor"
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; class="com.jivesoftware.community.webservices.server.xfire.ValidationCheckInterceptor"&amp;gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;property name="jiveUserDetailsService" ref="jiveUserDetailsService" /&amp;gt;
&amp;lt;/bean&amp;gt;

&amp;lt;jaxws:endpoint id="echoService" address="/soap/EchoService"&amp;gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;jaxws:implementor&amp;gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;ref bean="echoServiceImpl" /&amp;gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/jaxws:implementor&amp;gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;jaxws:inInterceptors&amp;gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;ref bean="saajInInterceptor" /&amp;gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;ref bean="wss4jInInterceptor" /&amp;gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;ref bean="validationCheckInterceptor" /&amp;gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/jaxws:inInterceptors&amp;gt;
&amp;lt;/jaxws:endpoint&amp;gt;&lt;/code&gt;&lt;/pre&gt;&lt;!--[CodeBlockEnd:c01e982d-bb94-4d83-8d60-dc9e45a221fa]--&gt;&lt;p&gt;&lt;br/&gt; &lt;/p&gt;&lt;ul&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;In version 2 WSDL operation params have friendly names. You should get new version 2 WSDL.&lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;In version 1 accessing web services via XML-RPC used two extra parameters for username and password; version 2 uses basic auth instead.&lt;/p&gt;&lt;/li&gt;&lt;/ul&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;The information above along with more details can be found in the &lt;a class="jive-link-external-small" href="http://www.jivesoftware.com/community/docs/DOC-2060/"&gt;Upgrading Extensions to 2.0 documentation&lt;/a&gt;.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;We also have a &lt;a class="jive-link-external-small" href="http://www.jivesoftware.com/community/blogs/podcasts/2008/06/18/web-services-in-clearspace-20"&gt;video&lt;/a&gt; (with an attached presentation) that shows more about using web services to access your data in Clearspace 2.0 with Andrew Wright, Jive Software Engineer.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;/div&gt;&lt;!-- [DocumentBodyEnd:c5ad2f68-240b-45c8-a77e-b7577ba4c256] --&gt;</description>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">jivespace</category>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">jivespace</category>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">clearspace</category>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">webservices</category>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">api</category>
      <pubDate>Mon, 07 Jul 2008 16:20:46 GMT</pubDate>
      <author>communities@jivesoftware.com</author>
      <guid>http://www.jivesoftware.com/jivespace/blogs/jivespace/2008/07/07/customization-part-5-web-services</guid>
      <dc:date>2008-07-07T16:20:46Z</dc:date>
      <clearspace:dateToText>1 year, 4 months ago</clearspace:dateToText>
      <clearspace:objectType>0</clearspace:objectType>
      <wfw:comment>http://www.jivesoftware.com/jivespace/blogs/jivespace/comment/customization-part-5-web-services</wfw:comment>
      <wfw:commentRss>http://www.jivesoftware.com/jivespace/blogs/jivespace/feeds/comments?blogPost=1549</wfw:commentRss>
    </item>
    <item>
      <title>Customization Part 4: Macros</title>
      <link>http://www.jivesoftware.com/jivespace/blogs/jivespace/2008/07/04/customization-part-4-macros</link>
      <description>&lt;!-- [DocumentBodyStart:7b73d0a3-5e8e-47c2-abe6-4004080aa578] --&gt;&lt;div class='jive-rendered-content'&gt;&lt;p&gt;This post is the fourth in a series of blog posts about customizing for Clearspace 2.x. The previous posts covered:&lt;/p&gt;&lt;ol&gt;&lt;li level="1" type="ol"&gt;&lt;p&gt;General information about &lt;a class="jive-link-external-small" href="http://www.jivesoftware.com/community/blogs/clearspace/2008/06/24/customizations-in-clearspace-2x-part-one/"&gt;Customizations in Clearspace 2.x&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ol"&gt;&lt;p&gt;&lt;a class="jive-link-external-small" href="http://www.jivesoftware.com/community/blogs/clearspace/2008/06/26/customization-part-2-upgrading-themes-and-ftl-files/"&gt;Upgrading Themes and FTL Files&lt;/a&gt;. &lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ol"&gt;&lt;p&gt;&lt;a class="jive-link-external-small" href="http://www.jivesoftware.com/community/blogs/clearspace/2008/06/30/customization-part-3-widgets"&gt;Widgets in Clearspace 2.x&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;&lt;/ol&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;This post continues the series with more information about macros in Clearspace 2.0&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;Depending on what your macro does, it might need substantial upgrade changes or none at all. The main macro-specific difference arises from the fact that Clearspace content is now stored as XML, rather than plain text. At run time Clearspace renders plain text, rich text, or HTML from stored XML. This means that the HTML you return for display when the macro is previewed or published must qualify as well-formed XML.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;Note that unless your macro is extremely simple, you're likely to also need to keep in mind API changes and FreeMarker changes. The rest of macro development model&amp;nbsp; -- artifacts involved, how you deploy them, and so on&amp;nbsp; -- is unchanged from version 1.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;In version 1, you might have written your macro class in one of two ways: implementing the com.jivesoftware.base.Macro interface or extending the com.jivesoftware.base.BaseMacro class. Implementing the Macro interface was the relatively simple (and documented) way to write a macro class. If you extended the BaseMacro class you were probably doing so in order to support alternate content formats for targets other than HTML&amp;nbsp; -- including for email, the plain text editor, and so on. In version 2 Clearspace handles conversion to these other formats for you.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;The process for upgrading your macro class will differ depending on which approach you took. The following describes the two common version 1 ways to implement a macro class and describes what you can do to upgrade each.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;h3&gt;&lt;span&gt;Your Macro Class Implements the Macro Interface&lt;/span&gt;&lt;/h3&gt;&lt;p&gt;In version 1 the Macro interface has a single method: String render(String, Map, MacroContext). Your implementation received macro content and parameters (if any), along with information about the context in which it was being used, then simply returned the HTML that should be displayed in the published content.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;In version 2 this is still supported with one caveat: The HTML returned by your render method must now qualify as well-formed XML. That's because the return value is now inserted into the XML that represents the content it's being used in. Malformed XML returned by a macro won't be used by Clearspace.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;To upgrade your macro class, simply ensure that the HTML your render method implementation returns is well-formed XML.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;h3&gt;&lt;span&gt;Your Macro Class Extends the Version 1 BaseMacro Class&lt;/span&gt;&lt;/h3&gt;&lt;p&gt;In version 1 the BaseMacro class extended BaseFilter, which provided all of the methods a macro needed to return content to Clearspace, whether the content was being displayed in the Clearspace UI or in a notification email. You implemented each of these methods to handle the different targets. In version 2, Clearspace handles rendering for each of these targets so your code doesn't need to.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;In version 2 there's a BaseMacro class, but it no longer extends BaseFilter, implementing RenderMacro instead. In other words, macro classes extending the version 1 BaseMacro class won't compile on version 2. The version 2 BaseMacro class is for internal use and will almost surely change in future Clearspace releases.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;To upgrade your macro class, rewrite it so that it implements the Macro interface rather than extending BaseMacro. In most cases this will mean moving your BaseMacro.executeHtmlTarget method implementation (along with the logic that supports it) to your Macro.render method implementation. Both methods return HTML as a String. You can discard the code designed to support the other targets (methods executePlainTextTarget, executeWysiwygEditorTarget, and so on).&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;The information above along with more details can be found in the &lt;a class="jive-link-external-small" href="http://www.jivesoftware.com/community/docs/DOC-2060/"&gt;Upgrading Extensions to 2.0 documentation&lt;/a&gt;.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;/div&gt;&lt;!-- [DocumentBodyEnd:7b73d0a3-5e8e-47c2-abe6-4004080aa578] --&gt;</description>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">macros</category>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">clearspace</category>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">2.0</category>
      <pubDate>Fri, 04 Jul 2008 00:34:55 GMT</pubDate>
      <author>communities@jivesoftware.com</author>
      <guid>http://www.jivesoftware.com/jivespace/blogs/jivespace/2008/07/04/customization-part-4-macros</guid>
      <dc:date>2008-07-04T00:34:55Z</dc:date>
      <clearspace:dateToText>1 year, 4 months ago</clearspace:dateToText>
      <clearspace:objectType>0</clearspace:objectType>
      <wfw:comment>http://www.jivesoftware.com/jivespace/blogs/jivespace/comment/customization-part-4-macros</wfw:comment>
      <wfw:commentRss>http://www.jivesoftware.com/jivespace/blogs/jivespace/feeds/comments?blogPost=1546</wfw:commentRss>
    </item>
    <item>
      <title>Customization Part 3: Widgets</title>
      <link>http://www.jivesoftware.com/jivespace/blogs/jivespace/2008/06/30/customization-part-3-widgets</link>
      <description>&lt;!-- [DocumentBodyStart:ae64e489-7d6f-4d17-b834-04d353622c26] --&gt;&lt;div class='jive-rendered-content'&gt;&lt;p&gt;This post is the third in a series of blog posts about customizing for Clearspace 2.x. The previous posts covered general information about &lt;a class="jive-link-external-small" href="http://www.jivesoftware.com/community/blogs/clearspace/2008/06/24/customizations-in-clearspace-2x-part-one/"&gt;Customizations in Clearspace 2.x&lt;/a&gt; and &lt;a class="jive-link-external-small" href="http://www.jivesoftware.com/community/blogs/clearspace/2008/06/26/customization-part-2-upgrading-themes-and-ftl-files/"&gt;upgrading themes and FTL files&lt;/a&gt;. This post continues the series with more information about widgets.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;Widgets can be used much more broadly in version 2 than previously, so most of your widget-specific upgrade changes are related to this broader support. In version 1 a system or space administrator could use widgets only to assemble a space or community overview page. In version 2 both administrators and users can customize page layouts in several areas. Widgets can be used on the Clearspace instance home page (which has been rendered from main.ftl), a user's personal home page, a community/space overview page, a project overview page.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;Note that unless your widget is extremely simple, you're likely to also need to keep in mind API changes and FreeMarker changes. For example, version 2 requires that widgets acquire references to Clearspace manager beans using Spring. The rest of widget development model&amp;nbsp; -- artifacts involved, how you deploy them, and so on&amp;nbsp; -- is unchanged from version 1.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;When upgrading a widget (or developing a new one on version 2), you use the @WidgetTypeMarker annotation to specify which of the display contexts your widget is allowed in. Deciding which contexts to allow is an important part of your widget's design. For example, you might decide that a widget that takes a very individual-oriented set of property values (such as the Tag widget, which displays content associated with a particular tag) isn't useful in high-level contexts such as the instance or space home pages (where the broad set of people viewing might want views on a large variety of tags).&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;The @WidgetTypeMarker annotation supports values from the WidgetType enumeration. Here's an example that includes all of those values:&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;!--[CodeBlockStart:400ae138-2057-404c-b17b-d4196b1a6fca]--&gt;&lt;pre class="jive-pre"&gt;&lt;code class="jive-code"&gt;@WidgetTypeMarker({WidgetType.HOMEPAGE, WidgetType.PERSONALIZEDHOMEPAGE, 
&amp;nbsp;&amp;nbsp;&amp;nbsp; WidgetType.COMMUNITY, WidgetType.PROJECT})
@PropertyNames("myProperty")
public class MyWidget extends BaseWidget {
&amp;nbsp;&amp;nbsp;&amp;nbsp; // Implementation code omitted.
}&lt;/code&gt;&lt;/pre&gt;&lt;!--[CodeBlockEnd:400ae138-2057-404c-b17b-d4196b1a6fca]--&gt;&lt;p&gt;In order to reduce the tight coupling between the widget views (which are typically built using FreeMarker) and the rest of the Clearspace application, the widget context that was previously populated with a reference to the current context via a JiveContext instance has been modified so that the widget view no longer has access to that instance. That means that you'll need to provide everything that your widget view needs through the properties that the widget interface requires. Typically you'll create a widget class that extends BaseWidget and then you'll override this method:&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;!--[CodeBlockStart:3d55eae5-6ad0-4752-9792-6786471930eb]--&gt;&lt;pre class="jive-pre"&gt;&lt;code class="jive-code"&gt;protected Map&amp;lt;String, Object&amp;gt; loadProperties(WidgetContext widgetContext, ContainerSize size)
&lt;/code&gt;&lt;/pre&gt;&lt;!--[CodeBlockEnd:3d55eae5-6ad0-4752-9792-6786471930eb]--&gt;&lt;p&gt;So in the previous version of Clearspace, you might have had something like this in the FTL file that's your widget's view:&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;!--[CodeBlockStart:3cb3bc5d-3cd5-4b79-adc8-3547d3db53e3]--&gt;&lt;pre class="jive-pre"&gt;&lt;code class="jive-code"&gt;${widgetContext.jiveContext.communityManager.rootCommunity.ID?c}&lt;/code&gt;&lt;/pre&gt;&lt;!--[CodeBlockEnd:3cb3bc5d-3cd5-4b79-adc8-3547d3db53e3]--&gt;&lt;p&gt;Because the JiveContext instance has been removed from the WidgetContext class, you'll need to provide your view with the properties it needs explicitly in your widget. Here's an example:&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;!--[CodeBlockStart:c9eadd2e-5fa3-4a97-a058-0ecfa4f3a170]--&gt;&lt;pre class="jive-pre"&gt;&lt;code class="jive-code"&gt;public class MyWidget extends BaseWidget {

&amp;nbsp;&amp;nbsp;&amp;nbsp; // Declare a property variable and setter for injection by Spring.
&amp;nbsp;&amp;nbsp;&amp;nbsp; private CommunityManager communityManager;
&amp;nbsp;&amp;nbsp;&amp;nbsp; public void setCommunityManager(CommunityManager cm) {
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; this.communityManager = cm;
&amp;nbsp;&amp;nbsp;&amp;nbsp; }

&amp;nbsp;&amp;nbsp;&amp;nbsp; protected Map&amp;lt;String, Object&amp;gt; loadProperties(WidgetContext widgetContext, 
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ContainerSize size)
&amp;nbsp;&amp;nbsp;&amp;nbsp; {
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Map&amp;lt;String, Object&amp;gt; properties = super.loadProperties(widgetContext, size);
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // Implementation code omitted.
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; properties.put("rootCommunityID", communityManager.getRootCommunity().getID());
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; return properties;
&amp;nbsp;&amp;nbsp;&amp;nbsp; }
}&lt;/code&gt;&lt;/pre&gt;&lt;!--[CodeBlockEnd:c9eadd2e-5fa3-4a97-a058-0ecfa4f3a170]--&gt;&lt;p&gt;Finally, because you can create a widget that exists in multiple parts of the application (the homepage, a personalized homepage, a community, a project), you'll sometimes want to change the behavior of your widget based on where the widget is being rendered. You can determine the render context of your widget by checking the type of the WidgetContext class that you're given in the loadProperties method. Here's some example code that shows how you can determine what context the widget is in:&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;!--[CodeBlockStart:fd954682-eba6-45c4-b395-b09d77f7938d]--&gt;&lt;pre class="jive-pre"&gt;&lt;code class="jive-code"&gt;public class MyWidget extends BaseWidget {
&amp;nbsp;&amp;nbsp;&amp;nbsp; protected Map&amp;lt;String, Object&amp;gt; loadProperties(WidgetContext widgetContext, ContainerSize size) {
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Map&amp;lt;String, Object&amp;gt; properties = super.loadProperties(widgetContext, size);
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if (widgetContext.getWidgetType() == WidgetType.COMMUNITY) {
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; CommunityWidgetContext cwc = (CommunityWidgetContext)widgetContext;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // Do something specific for the community
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; else if (widgetContext.getWidgetType() == WidgetType.HOMEPAGE) {
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; HomepageWidgetContext hwc = (HomepageWidgetContext)widgetContext;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // Do something specific for the homepage
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; } 
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; else if (widgetContext.getWidgetType() == WidgetType.PERSONALIZEDHOMEPAGE) {
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; PersonalizedHomepageWidgetContext phwc = 
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; (PersonalizedHomepageWidgetContext)widgetContext;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // Do something specific for the personalized homepage&amp;nbsp;&amp;nbsp;&amp;nbsp; 
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; else if (widgetContext.getWidgetType() == WidgetType.PROJECT) {
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ProjectWidgetContext wwc = (ProjectWidgetContext)widgetContext;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // Do something specific for the project
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }
&amp;nbsp;&amp;nbsp;&amp;nbsp; 
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; properties.put("rootCommunityID", communityManager.getRootCommunity().getID());
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; return properties;
&amp;nbsp;&amp;nbsp;&amp;nbsp; }
}&lt;/code&gt;&lt;/pre&gt;&lt;!--[CodeBlockEnd:fd954682-eba6-45c4-b395-b09d77f7938d]--&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;The information above along with more details can be found in the &lt;a class="jive-link-external-small" href="http://www.jivesoftware.com/community/docs/DOC-2060/"&gt;Upgrading Extensions to 2.0 documentation&lt;/a&gt;.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;You can also &lt;a class="jive-link-external-small" href="http://www.jivesoftware.com/community/blogs/podcasts/2008/06/05/more-widget-development-in-clearspace-20"&gt;watch a video and download a presentation&lt;/a&gt; to learn more about how to write new widgets for Clearspace 2.0 from Aaron Johnson, Engineering Manager at Jive.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;/div&gt;&lt;!-- [DocumentBodyEnd:ae64e489-7d6f-4d17-b834-04d353622c26] --&gt;</description>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">clearspace</category>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">widget</category>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">widget</category>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">widgets</category>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">2.0</category>
      <pubDate>Mon, 30 Jun 2008 15:12:39 GMT</pubDate>
      <author>communities@jivesoftware.com</author>
      <guid>http://www.jivesoftware.com/jivespace/blogs/jivespace/2008/06/30/customization-part-3-widgets</guid>
      <dc:date>2008-06-30T15:12:39Z</dc:date>
      <clearspace:dateToText>1 year, 4 months ago</clearspace:dateToText>
      <clearspace:objectType>0</clearspace:objectType>
      <wfw:comment>http://www.jivesoftware.com/jivespace/blogs/jivespace/comment/customization-part-3-widgets</wfw:comment>
      <wfw:commentRss>http://www.jivesoftware.com/jivespace/blogs/jivespace/feeds/comments?blogPost=1545</wfw:commentRss>
    </item>
    <item>
      <title>Searching Clearspace from the Firefox Search Box</title>
      <link>http://www.jivesoftware.com/jivespace/blogs/jivespace/2008/06/27/searching-clearspace-from-the-firefox-search-box</link>
      <description>&lt;!-- [DocumentBodyStart:9555fb2a-a9d7-4ce3-af75-2f146ade3ddf] --&gt;&lt;div class='jive-rendered-content'&gt;&lt;p&gt;Did you know that you can add any Clearspace instance to the list of search engines available for quick searches from your Firefox or IE search box?&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;Since Clearspace is Opensearch enabled, Firefox will automatically recognize it and give you the option to add it to your drop down list of search engines.&amp;nbsp; This is made possible because we add an Opensearch descriptor to every page in Clearspace, which looks something like this:&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;!--[CodeBlockStart:8ce51ed0-07bf-4b81-a0ce-2f7773a68c3d]--&gt;&lt;pre class="jive-pre"&gt;&lt;code class="jive-code"&gt;
&amp;lt;link rel="search"
&amp;nbsp;&amp;nbsp;&amp;nbsp; href="/opensearch.xml"
&amp;nbsp;&amp;nbsp;&amp;nbsp; title="Jivespace"
&amp;nbsp;&amp;nbsp;&amp;nbsp; type="application/opensearchdescription+xml"/&amp;gt;
&lt;/code&gt;&lt;/pre&gt;&lt;!--[CodeBlockEnd:8ce51ed0-07bf-4b81-a0ce-2f7773a68c3d]--&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;This works just as well for internal instances of Clearspaces (assuming you are logged into your corporate network).&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;It is as easy as this:&lt;/p&gt;&lt;ul&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;Navigate to any page of any instance that has opensearch enabled&lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;Add that search engine from Firefox's drop down&lt;/p&gt;&lt;/li&gt;&lt;/ul&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;Opensearch is already enabled by default, so you should be able to add any Clearspace installation to your browser search box. More information about using OpenSearch in Clearspace can be found in the &lt;a class="jive-link-external-small" href="http://www.jivesoftware.com/builds/docs/clearspace/latest/ClearspaceAdminGuide.html"&gt;Clearspace System Administrator's Guide&lt;/a&gt;.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;/div&gt;&lt;!-- [DocumentBodyEnd:9555fb2a-a9d7-4ce3-af75-2f146ade3ddf] --&gt;</description>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">clearspace</category>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">search</category>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">firefox</category>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">firefox</category>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">opensearch</category>
      <pubDate>Fri, 27 Jun 2008 14:33:37 GMT</pubDate>
      <author>communities@jivesoftware.com</author>
      <guid>http://www.jivesoftware.com/jivespace/blogs/jivespace/2008/06/27/searching-clearspace-from-the-firefox-search-box</guid>
      <dc:date>2008-06-27T14:33:37Z</dc:date>
      <clearspace:dateToText>1 year, 4 months ago</clearspace:dateToText>
      <clearspace:replyCount>7</clearspace:replyCount>
      <clearspace:objectType>0</clearspace:objectType>
      <wfw:comment>http://www.jivesoftware.com/jivespace/blogs/jivespace/comment/searching-clearspace-from-the-firefox-search-box</wfw:comment>
      <wfw:commentRss>http://www.jivesoftware.com/jivespace/blogs/jivespace/feeds/comments?blogPost=1544</wfw:commentRss>
    </item>
    <item>
      <title>Customization Part 2: Upgrading Themes and FTL files</title>
      <link>http://www.jivesoftware.com/jivespace/blogs/jivespace/2008/06/27/customization-part-2-upgrading-themes-and-ftl-files</link>
      <description>&lt;!-- [DocumentBodyStart:9336aeec-e409-419c-aaab-943892b2d6c2] --&gt;&lt;div class='jive-rendered-content'&gt;&lt;p&gt;This post is the second in a series of blog posts about customizing for Clearspace 2.x. The first post covered general information about &lt;a class="jive-link-external-small" href="http://www.jivesoftware.com/community/blogs/clearspace/2008/06/24/customizations-in-clearspace-2x-part-one/"&gt;Customizations in Clearspace 2.x&lt;/a&gt;. This post continues the series with more information about upgrading themes and FreeMarker template (FTL) files.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;Each new version of Clearspace includes changes to FTL files and version 2 is no exception. Typically these changes are needed to support new or enhanced features. The FTL changelog included with a Clearspace release provides a list of the FTL files that were changed from the previous version. However, changes in version 2 have pretty much touched every template. In most cases these changes require a simple search-and-replace to fix. But some changes are more substantial.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;The information on upgrading themes suggests an incremental process for making your changes that could save you some aggravation.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;The following list suggests the tips and best practices for upgrading your templates.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;ul&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;When you've overridden existing Clearspace templates (as in a theme), start with new version 2 FTL files that correspond to the version 1 files in your theme. Then, working from your customized version of the version 1 template, transfer your changes to to the version 2 template. Updating the new templates might help you avoid accidentally transferring code from version 1 that no longer works on version 2. This is especially important given that FreeMarker errors are difficult to debug; errors don't show up until run time. Weaving your version 1 changes into the version 2 templates will make the process more systematic.As you copy your changes into the version 2 template, keep in mind the changed items described below. &lt;br/&gt; &lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;The version 1 pages whose templates were community.ftl and main.ftl -- community pages and the home page -- can be easily customized with widgets in version 2. Before you set out to upgrade these pages, take a look at how much of your customization work could be accomplished by using widgets on the version 2 templates. Using widgets might reduce the amount of customization you need to do and greatly reduce any work in future upgrades.&lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;If you've overridden community.ftl and want to upgrade it, note that the template has been split into multiple FTL files. This was done to divide logically what was a very large template.&lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;Replace WebWork directives with their Struts counterparts. Clearspace version 2 replaces WebWork conventions with Struts. This is pretty much just search-and-replace work to replace @ww. (for WebWork) with @s (for Struts) . The following example shows how to update the url directive. Notice that the updated code also omits the includeParams='none' attribute; in Struts 2, which Clearspace version 2 uses, none is the default value for includeParams.Version 1 (supporting WebWork): &lt;br/&gt; &lt;/p&gt;&lt;/li&gt;&lt;/ul&gt;&lt;!--[CodeBlockStart:a0457097-dcaf-4bb5-9787-1b2dc6948ed0]--&gt;&lt;pre class="jive-pre"&gt;&lt;code class="jive-code"&gt;&amp;lt;style type="text/css" media="screen"&amp;gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; @import "&amp;lt;@ww.url value='/styles/jive-blog.css' includeParams='none'/&amp;gt;";
&amp;lt;/style&amp;gt;&lt;/code&gt;&lt;/pre&gt;&lt;!--[CodeBlockEnd:a0457097-dcaf-4bb5-9787-1b2dc6948ed0]--&gt;&lt;p&gt;&lt;br/&gt; Version 2 (supporting Struts): &lt;br/&gt; &lt;/p&gt;&lt;!--[CodeBlockStart:052c1539-f0a9-4737-9cd2-010404d6d176]--&gt;&lt;pre class="jive-pre"&gt;&lt;code class="jive-code"&gt;&amp;lt;style type="text/css" media="screen"&amp;gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; @import "&amp;lt;@s.url value='/styles/jive-blog.css'/&amp;gt;";
&amp;lt;/style&amp;gt;&lt;/code&gt;&lt;/pre&gt;&lt;!--[CodeBlockEnd:052c1539-f0a9-4737-9cd2-010404d6d176]--&gt;&lt;p&gt;&lt;br/&gt; &lt;/p&gt;&lt;ul&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;Update calls to APIs that have been consolidated and simplified. Pay attention to the places in a template where code calls methods directly (although, as a best practice, you should avoid calling methods in FTL code and use actions instead). Here's an example in which you'd replace a call to a JiveGlobals methods with a call to JiveResourceResolver:Version 1 (using JiveGlobals ): &lt;br/&gt; &lt;/p&gt;&lt;/li&gt;&lt;/ul&gt;&lt;!--[CodeBlockStart:6086cfbf-5821-4d22-b4f3-5e217c0efb09]--&gt;&lt;pre class="jive-pre"&gt;&lt;code class="jive-code"&gt;&amp;lt;@ww.text name="doc.viewer.more_recent_ver.text"&amp;gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;@ww.param&amp;gt;&amp;lt;a href="&amp;lt;@ww.url value="${JiveGlobals.getJiveObjectURL(document)}" includeParams="none"/&amp;gt;"&amp;gt;&amp;lt;/@ww.param&amp;gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;@ww.param&amp;gt;&amp;lt;/a&amp;gt;&amp;lt;/@ww.param&amp;gt;
&amp;lt;/@ww.text&amp;gt;&lt;/code&gt;&lt;/pre&gt;&lt;!--[CodeBlockEnd:6086cfbf-5821-4d22-b4f3-5e217c0efb09]--&gt;&lt;p&gt;&lt;br/&gt; Version 2 (using JiveResourceResolver ): &lt;br/&gt; &lt;/p&gt;&lt;!--[CodeBlockStart:43d4b265-5bfc-49cd-ab83-f719ebe3b347]--&gt;&lt;pre class="jive-pre"&gt;&lt;code class="jive-code"&gt;&amp;lt;@s.text name="doc.viewer.more_recent_ver.text"&amp;gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;@s.param&amp;gt;&amp;lt;a href="&amp;lt;@s.url value="${JiveResourceResolver.getJiveObjectURL(document)}"/&amp;gt;"&amp;gt;&amp;lt;/@s.param&amp;gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;@s.param&amp;gt;&amp;lt;/a&amp;gt;&amp;lt;/@s.param&amp;gt;
&amp;lt;/@s.text&amp;gt;&lt;/code&gt;&lt;/pre&gt;&lt;!--[CodeBlockEnd:43d4b265-5bfc-49cd-ab83-f719ebe3b347]--&gt;&lt;p&gt;&lt;br/&gt; Here's another example where the change was from another class and method, but again to JiveResourceResolver: &lt;br/&gt; Version 1 (using CommunityUtils ): &lt;br/&gt; &lt;/p&gt;&lt;!--[CodeBlockStart:ef8d0fa9-6170-4ca5-8f66-83bf3e84e254]--&gt;&lt;pre class="jive-pre"&gt;&lt;code class="jive-code"&gt;&amp;lt;a href="&amp;lt;@ww.url value='${CommunityUtils.getCommunityURL(community)}'
&amp;nbsp;&amp;nbsp;&amp;nbsp; includeParams='none'/&amp;gt;?view=documents" 
&amp;nbsp;&amp;nbsp;&amp;nbsp; class="jive-link-more"&amp;gt;&amp;lt;@ww.text name="doc.main.brdcrmb.documents.link" /&amp;gt;&amp;lt;/a&amp;gt; &lt;/code&gt;&lt;/pre&gt;&lt;!--[CodeBlockEnd:ef8d0fa9-6170-4ca5-8f66-83bf3e84e254]--&gt;&lt;p&gt;&lt;br/&gt; Version 2 (using JiveResourceResolver ): &lt;br/&gt; &lt;/p&gt;&lt;!--[CodeBlockStart:c6b743cf-0f5d-472b-9f4f-c36ed2143c58]--&gt;&lt;pre class="jive-pre"&gt;&lt;code class="jive-code"&gt;&amp;lt;a href="&amp;lt;@s.url value='${JiveResourceResolver.getJiveObjectURL(container)}'/&amp;gt;?view=documents" 
&amp;nbsp;&amp;nbsp;&amp;nbsp; class="jive-link-more"&amp;gt;&amp;lt;@s.text name="doc.main.brdcrmb.documents.link" /&amp;gt;&amp;lt;/a&amp;gt; &lt;/code&gt;&lt;/pre&gt;&lt;!--[CodeBlockEnd:c6b743cf-0f5d-472b-9f4f-c36ed2143c58]--&gt;&lt;p&gt;&lt;br/&gt; &lt;/p&gt;&lt;ul&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;Update community references to container references. One twist on the API changes means that both projects and communities (also known as "spaces") are represented conceptually as containers. In the version 2 API, the Community and Project interfaces both inherit from JiveContainer. To disambiguate between the projects and communities, you'll need to pass a container &lt;em&gt;type&lt;/em&gt; with your action calls. The actual disambiguation is handled by Clearspace, however, when it intercepts the call before passing it to the action. The net effect is that the action itself receives only the container ID parameter, not the container type. Here's an FTL example:Version 1 (specifying a community by passing its community ID) &lt;br/&gt; &lt;/p&gt;&lt;/li&gt;&lt;/ul&gt;&lt;!--[CodeBlockStart:128d6bed-868e-4dfa-bbf0-63af451d9e88]--&gt;&lt;pre class="jive-pre"&gt;&lt;code class="jive-code"&gt;&amp;lt;@ww.action name="community-breadcrumb" executeResult="true" ignoreContextParams="true"&amp;gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;@ww.param name="communityID" value="${community.ID?c}" /&amp;gt;
&amp;lt;/@ww.action&amp;gt;
&lt;/code&gt;&lt;/pre&gt;&lt;!--[CodeBlockEnd:128d6bed-868e-4dfa-bbf0-63af451d9e88]--&gt;&lt;p&gt;&lt;br/&gt; Version 2 (specifying a community by passing both its type and its ID) &lt;br/&gt; &lt;/p&gt;&lt;!--[CodeBlockStart:6b1b3e40-d6d7-4aed-8538-09f0c2add8fa]--&gt;&lt;pre class="jive-pre"&gt;&lt;code class="jive-code"&gt;&amp;lt;@s.action name="community-breadcrumb" executeResult="true" ignoreContextParams="true"&amp;gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;@s.param name="containerType" value="${container.objectType?c}" /&amp;gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;@s.param name="container" value="${container.ID?c}" /&amp;gt;
&amp;lt;/@s.action&amp;gt;
&lt;/code&gt;&lt;/pre&gt;&lt;!--[CodeBlockEnd:6b1b3e40-d6d7-4aed-8538-09f0c2add8fa]--&gt;&lt;p&gt;&lt;br/&gt; &lt;/p&gt;&lt;ul&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;Update code that handles content. This includes code that gets content for display as wiki markup, HTML, and so on. Among the API changes were several designed to streamline and add structure to how you handle content. For example, in version 1, to get content as wiki markup you would have called methods of the message or document or comment itself. In version 2, you pass the content object to a method inherited from JiveActionSupport. These methods include renderToText, renderToHtml, renderSubjectToHtml, and so on. Here's an example using convertToWikiSyntax:Version 1 (using content object method) &lt;br/&gt; &lt;/p&gt;&lt;/li&gt;&lt;/ul&gt;&lt;!--[CodeBlockStart:737b7bda-104b-4203-9c4b-345dd8808bb4]--&gt;&lt;pre class="jive-pre"&gt;&lt;code class="jive-code"&gt;&amp;lt;textarea id="comment-body-edit-${comment.ID?c}" name="body" rows="10"
&amp;nbsp;&amp;nbsp;&amp;nbsp; style="width:100%;font-family:verdana,arial,helvetica,sans-serif;font-size:8pt;"
&amp;nbsp;&amp;nbsp;&amp;nbsp; class="jive-comment-textarea"&amp;gt;${comment.unfilteredBody!?html}&amp;lt;/textarea&amp;gt;&lt;/code&gt;&lt;/pre&gt;&lt;!--[CodeBlockEnd:737b7bda-104b-4203-9c4b-345dd8808bb4]--&gt;&lt;p&gt;&lt;br/&gt; Version 2 (using JiveActionSupport method) &lt;br/&gt; &lt;/p&gt;&lt;!--[CodeBlockStart:7c1e9474-423d-40e0-98d5-b862722a8208]--&gt;&lt;pre class="jive-pre"&gt;&lt;code class="jive-code"&gt;&amp;lt;textarea id="comment-body-edit-${comment.ID?c}" name="body" rows="10"
&amp;nbsp;&amp;nbsp;&amp;nbsp; style="width:100%;font-family:verdana,arial,helvetica,sans-serif;font-size:8pt;"
&amp;nbsp;&amp;nbsp;&amp;nbsp; class="jive-comment-textarea"&amp;gt;${action.convertToWikiSyntax(comment)!?html}&amp;lt;/textarea&amp;gt;&lt;/code&gt;&lt;/pre&gt;&lt;!--[CodeBlockEnd:7c1e9474-423d-40e0-98d5-b862722a8208]--&gt;&lt;p&gt;&lt;br/&gt; &lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;h3&gt;&lt;span&gt;Removed and Renamed FTL Files&lt;/span&gt;&lt;/h3&gt;&lt;table&gt;&lt;tr&gt;&lt;th&gt;&lt;p&gt;Version 1 FTL File&lt;/p&gt;&lt;/th&gt;&lt;th&gt;&lt;p&gt;Version 2 Change&lt;/p&gt;&lt;/th&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;&lt;p&gt;community-document-picker.ftl&lt;/p&gt;&lt;/td&gt;&lt;td&gt;&lt;p&gt;Renamed to container-document-picker.ftl&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;&lt;p&gt;community-thread-picker.ftl&lt;/p&gt;&lt;/td&gt;&lt;td&gt;&lt;p&gt;Renamed to container-thread-picker.ftl&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;&lt;p&gt;import-callback-communitynntp.ftl&lt;/p&gt;&lt;/td&gt;&lt;td&gt;&lt;p&gt;Removed.&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;&lt;p&gt;import-directory-error.ftl&lt;/p&gt;&lt;/td&gt;&lt;td&gt;&lt;p&gt;Removed.&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;&lt;p&gt;import-directory-updatetags.ftl&lt;/p&gt;&lt;/td&gt;&lt;td&gt;&lt;p&gt;Removed.&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;&lt;p&gt;import-directory.ftl&lt;/p&gt;&lt;/td&gt;&lt;td&gt;&lt;p&gt;Removed.&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td&gt;&lt;p&gt;datepicker.ftl&lt;/p&gt;&lt;/td&gt;&lt;td&gt;&lt;p&gt;Renamed to datetimepicker.ftl&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;&lt;h2&gt;&lt;span&gt;Upgrading Themes&lt;/span&gt;&lt;/h2&gt;&lt;p&gt;Nearly all of your work upgrading themes will focus on upgrading FreeMarker template (FTL) files. The way you build and deploy themes is unchanged from version 1.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;&lt;strong&gt;But wait -- there's more.&lt;/strong&gt; Having said that, the best practice recommendation in version 2 is to use widget-customized pages wherever possible as an alternative to custom FTLs. You can use widgets in more places than in version 1; check out the section on upgrading widgets for more.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;Here's why you should use widgets:&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;ul&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;You can do with widgets much of what you'd do with custom FTL markup. In addition, you can write logic in Java behind the your widget UI.&lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;Building widgets to support new features is a good deal tidier than adding new FTL files. While custom FTL files override default FTL files, widgets are encapsulated by the plugin deployment model -- essentially sandboxed.&lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;When it's time to upgrade Clearspace, the work needed to upgrade FTL files you've customized would likely be a good deal greater than what's needed to upgrade a widget.&lt;/p&gt;&lt;/li&gt;&lt;/ul&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;h3&gt;&lt;span&gt;Suggested Upgrade Process&lt;/span&gt;&lt;/h3&gt;&lt;p&gt;Use the following steps as a systematic way to upgrade your themes.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;ol&gt;&lt;li level="1" type="ol"&gt;&lt;p&gt;Consider which custom FTLs in your themes can be replaced by customizing the page with widgets.&lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ol"&gt;&lt;p&gt;Use jive.devMode Jive property for debugging. By default, Clearspace hides FreeMarker errors in themes. With dev mode on, you'll see them.&lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ol"&gt;&lt;p&gt;Disable themes while upgrading them.&lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ol"&gt;&lt;p&gt;Enable your custom FTL files one at a time. Debugging incrementally will make the process smoother.&lt;/p&gt;&lt;/li&gt;&lt;/ol&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;The information above along with more details can be found in the &lt;a class="jive-link-external-small" href="http://www.jivesoftware.com/community/docs/DOC-2060/"&gt;Upgrading Extensions to 2.0 documentation&lt;/a&gt;.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;/div&gt;&lt;!-- [DocumentBodyEnd:9336aeec-e409-419c-aaab-943892b2d6c2] --&gt;</description>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">clearspace</category>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">themes</category>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">freemarker</category>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">ftl</category>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">templates</category>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">templates</category>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">2.0</category>
      <pubDate>Fri, 27 Jun 2008 03:37:27 GMT</pubDate>
      <author>communities@jivesoftware.com</author>
      <guid>http://www.jivesoftware.com/jivespace/blogs/jivespace/2008/06/27/customization-part-2-upgrading-themes-and-ftl-files</guid>
      <dc:date>2008-06-27T03:37:27Z</dc:date>
      <clearspace:dateToText>1 year, 4 months ago</clearspace:dateToText>
      <clearspace:replyCount>1</clearspace:replyCount>
      <clearspace:objectType>0</clearspace:objectType>
      <wfw:comment>http://www.jivesoftware.com/jivespace/blogs/jivespace/comment/customization-part-2-upgrading-themes-and-ftl-files</wfw:comment>
      <wfw:commentRss>http://www.jivesoftware.com/jivespace/blogs/jivespace/feeds/comments?blogPost=1543</wfw:commentRss>
    </item>
    <item>
      <title>Customizations in Clearspace 2.x Part One</title>
      <link>http://www.jivesoftware.com/jivespace/blogs/jivespace/2008/06/24/customizations-in-clearspace-2x-part-one</link>
      <description>&lt;!-- [DocumentBodyStart:96adc7ac-9ceb-4eb1-b024-d690b153b2f7] --&gt;&lt;div class='jive-rendered-content'&gt;&lt;p&gt;We've been noticing more and more discussion on Jivespace about people migrating older customizations to the new Clearspace 2.x architecture along with quite a few people writing new customizations. I thought that now would be a good time for a refresher series of posts on customizing for Clearspace 2.x&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;Clearspace version 2 includes a few big changes to the conventions and frameworks on which Clearspace is built. Many of these changes were made to improve Clearspace extensibility by letting the application and extensions be more loosely coupled -- and so be more durable during upgrade. Other changes that impact customizations were simply feature improvements in which some change to code is required.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;Here's a high-level list of the changes that effect extension and customization code:&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;ul&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;Clearspace was &lt;strong&gt;migrated to the Spring framework&lt;/strong&gt;. This has both broad and deep effects on code written to run on Clearspace; such code must use the same conventions in order to integrate well. The changes include API refactoring to support dependency injection and integration of Spring modules (for security and transaction management, for example).&lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;Clearspace was &lt;strong&gt;migrated from WebWork2 to Struts2&lt;/strong&gt;. This has broad impact on plugins, but the changes are relatively small&amp;nbsp; -- primarily effecting syntax in FreeMarker templates and configuration files.&lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;&lt;strong&gt;Widgets were enhanced&lt;/strong&gt; to support use in multiple contexts, rather than just space overview pages. Changes to widget development support this new feature.&lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;The &lt;strong&gt;macro-related API was narrowed&lt;/strong&gt; to the area documented in version 1, essentially excluding an undocumented area that some people used. Also, macros must now return HTML that qualifies as well-formed XML.&lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;&lt;strong&gt;Web services support&lt;/strong&gt; is now provided through CXF, an evolution of XFire (the version 1 technology). A larger change results from the migration to Spring, which makes integrating new web services a bit more complex.&lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;&lt;strong&gt;Custom user data providers&lt;/strong&gt; are now based on a streamlined API. These must be rewritten, but the new model is much simpler.&lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;&lt;strong&gt;Custom authentication providers&lt;/strong&gt; are now based on Spring through Acegi. The change is pretty significant, including new API and configuration conventions.&lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;&lt;strong&gt;Myriad API changes&lt;/strong&gt; resulted from the migration to Spring and from an effort to streamline and modularize the Clearspace API. These include support for the projects feature, refactoring manager interfaces, content handling, and conventions such as dependency injection.&lt;/p&gt;&lt;/li&gt;&lt;/ul&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;For those extensions and customizations deployed as plugins (widgets, actions, macros, and web services), there are a few changes in version 2 with broad effect.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;ul&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;Migration from WebWork to Struts means replacing your xwork-plugin.xml with a struts.xml&lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;Migration to Spring means adding a spring.xml for certain kinds of Spring support.&lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;One benefit of the new model is that modifying your plugin.xml, struts.xml, or spring.xml will provoke Clearspace to reload your plugin. This can be handy for debugging.&lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;Support for a &amp;lt;maxserverversion&amp;gt; element was added. Similar to the &amp;lt;minserverversion&amp;gt; element, use the new one to specify that highest Clearspace version on which your plugin is supported. This can be useful when you want to ensure that upgrades to Clearspace prompt the plugin's users to upgrade the plugin also.&lt;/p&gt;&lt;/li&gt;&lt;li level="1" type="ul"&gt;&lt;p&gt;Plugin life cycle methods changed. If you used the version 1 com.jivesoftware.base.Plugin interface, you'll notice that its two methods have changed in order to support Spring. Semantics for the methods is unchanged. &lt;br/&gt; &lt;/p&gt;&lt;/li&gt;&lt;ul&gt;&lt;li level="2" type="ul"&gt;&lt;p&gt;Plugin.initialize(PluginManager, PluginMetaData) is now Plugin.init, a method without parameters. Use Spring dependency injection to receive a PluginManager instance; you can retrieve a PluginMetaData instance from the manager.&lt;/p&gt;&lt;/li&gt;&lt;li level="2" type="ul"&gt;&lt;p&gt;Plugin.destroyPlugin is now Plugin.destroy.&lt;/p&gt;&lt;/li&gt;&lt;/ul&gt;&lt;/ul&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;The information above along with more details can be found in the &lt;a class="jive-link-external-small" href="http://www.jivesoftware.com/community/docs/DOC-2060/"&gt;Upgrading Extensions to 2.0 documentation&lt;/a&gt;.&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;p style="min-height: 8pt; height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/p&gt;&lt;/div&gt;&lt;!-- [DocumentBodyEnd:96adc7ac-9ceb-4eb1-b024-d690b153b2f7] --&gt;</description>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">clearspace</category>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">plugins</category>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">webservices</category>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">spring</category>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">spring</category>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">2.0</category>
      <category domain="http://www.jivesoftware.com/jivespace/blogs/jivespace/tags">struts</category>
      <pubDate>Tue, 24 Jun 2008 20:00:29 GMT</pubDate>
      <author>communities@jivesoftware.com</author>
      <guid>http://www.jivesoftware.com/jivespace/blogs/jivespace/2008/06/24/customizations-in-clearspace-2x-part-one</guid>
      <dc:date>2008-06-24T20:00:29Z</dc:date>
      <clearspace:dateToText>1 year, 4 months ago</clearspace:dateToText>
      <clearspace:objectType>0</clearspace:objectType>
      <wfw:comment>http://www.jivesoftware.com/jivespace/blogs/jivespace/comment/customizations-in-clearspace-2x-part-one</wfw:comment>
      <wfw:commentRss>http://www.jivesoftware.com/jivespace/blogs/jivespace/feeds/comments?blogPost=1542</wfw:commentRss>
    </item>
  </channel>
</rss>

