Posts tagged 'java'

Social Roller

We demonstrated the Project SocialSite widgets in Roller at JavaOne, but we didn't show much other than just the basic widgets. We modified a Roller front-page theme to include a people directory, added a profile page for each user and slapped the widgets on the page. It was pretty rough, as you can see on the right, like our other SocialSite demo vehicles.

This week, I'm working to put together a much better demonstration, something useful enough to deploy to our internal blog site at Sun. Since I have limited time and I really need to get back to working on the SocialSite widgets and web services, I've been thinking about minimum set of features needed to add some value. Here's what I think we need:

  • Landing page: shows activities of your friends and groups, your inbox of social requests and place for you to update your status. This could be added to Roller's Main Menu page or to pages of the Front Page blog, which is my preferred option.
  • Personal profile page: shows your mugshot and the subset of your profile information that the viewer is allowed to see. Shows your activities and the OpenSocial gadgets you have installed. This could be done in the pages of each user's blog, which would give folks complete control of profile layout via page templates. Or I could be done in the pages of the Front Page blog.
  • Activity per entry or comment: whenever you publish a weblog post, or comment on one, an entry will be added to your activity feed so that your friends can see what you're doing. This will be implemented as a feature of a Roller-specific OpenSocial Gadget.
  • Protected entries: ability to publish blog entries that are visible only to your friends via the Roller Gadget.

Most of the above items should be pretty easy with the SocialSite widgets, but I'm sure I'll run into a snag or two at least. I always do. I'll post again next week and let you know how far I got.

RESTful JSF in the works?

JSF spec lead Ed Burns just pointed out that some of my Sun-internal comments about JSF have made it outside the firewall and into an issue on the JSF specification project:

On Wed, 19 Mar 2008, David M Johnson said:

I think the goal should be to make JSF applications RESTful by default, with proper use of GET and POST, i.e. only use POST when application data is changing, not for component state. Another goal should be clean, book-markable URLs that only carry path-info and parameters needed by the application logic.

That's easy and the default situation with Rails, Grails, Struts, etc. How hard would it be to redesign JSF along those lines? Would it require EJB2 -> EJB3 level changes to JSF?

I suspect work on JSF 2.0 is too far along for this kind of change now, but it's nice to hear that the idea of a truly RESTful JSF is at least under consideration.

Latest Links

LinkedIn: 99% Pure Java

Nick Lothian tweeted about this JavaOne presentation on LinkedIn because it mentions the ROME RSS/Atom feed parser. I'm really sorry I missed it at JavaOne. What's particularly interesting to me are the diagrams that explain how the LinkedIn architecture has evolved to scale up to 22 million users. Here's an example:

LinkedIn architecture diagram

Struts 2 in Action

stack of struts 2 books at the JavaOne bookstore

Struts 2 is my favorite Java web framework these days; it's REST-friendly, simple, easy to use, very flexible and the only thing it has with its creaky old Struts 1.x parent is the fact that it's an action framework rather than a component framework like JSF. As most of my readers probably already know, Struts 2 is based on WebWork/XWork the framework that powers JIRA and Confluence, two of the coolest Java webapps around.

Apparently, I'm not alone in this thinking -- I keep on running into folks at JavaOne who feel the same way. But unfortunately, Struts 2 docs are lacking, so I was very happy to see two new books on Struts 2 at the JavaOne bookstore. There's Struts 2 in Action, a rewrite of the classic Manning book, and Practical Apache Struts 2 Web 2.0 Projects from Apress.

I picked up a copy of Struts 2 in Action on Monday and it looks great so far, but I've only skimmed it. I'll let you know what I think once I dig-in on the flight home.

If you're at JavaOne, check out TS-5739 - Hands-on Struts2 by Ian Roughley (author of the Apress book) today at 10:50 AM in Esplanade 307/310.

Social Software at JavaOne 2008

There are quite a number of Social Software related talks at JavaOne and CommunityOne this year. You can learn about everything from building Social Networks with the Liferay portal and federated relationships with OpenSSO to creating 3D virtual works and implementing OpenSocial with Java. And, I'll finally be able to talk about what I've been working on for the past couple of months -- more about that later. [Read More]

Latest Links: open source, social networking and etc.

Latest Links: JSF vs. REST

I've been very happy with the choice of Struts 2 for Roller, but I still follow JSF because it's the Java standard. A couple of articles by Ryan Lubke about what's coming in JSF 2.0 got me thinking about JSF again.

One of my problems with JSF is REST. REST fans say JSF is inherently RESTless because every JSF request is a POST. JSF advocates say JSF can do GET and bookmarkable URLs if necessary and that's good enough.

Fortunately, the plans for JSF 2.0 indicate that REST improvements are coming:

Unfortunately, it sounds like all they're planning to do is make it easier to create bookmarkable URLs and add some support for the JSF-311 REST API. Why can't the goal be to make JSF applications RESTful by default? Why can't JSF ensure that POST is only used when required by the application (not the framework) and JSF URLs are simple, clean and always bookmarkable.

Latest Links: Feb. 16, 2008

Yahoo Weather RSS module for ROME

Apparently, I spoke to soon about ROME being in maintenance mode. There's an all-new Yahoo Weather module for ROME from Robert "kerbernet" Cooper.

ROME vs. Abdera

For Java developers starting out with RSS and Atom, here are some notes to help you figure out the differences between the ROME and Apache Abdera (incubating) projects.

ROME is a set of Java tools for parsing, fetching and generating all forms of RSS and Atom feeds. The core ROME library is relatively small and depends only on the somewhat creaky old JDOM XML parser. Available separately are modules to support various feed extensions such as OpenSearch, iTunes, GeoRSS, etc. ROME was originally developed and open sourced by Sun Portal dev team members in 2004.

ROME Propono is a subproject of ROME that supports publishing/editing entries and files to blog servers and AtomPub servers. Propono is made up of three parts: 1) a Blog Client library can publish via either the old lagacy MetaWeblog API or the shiny new AtomPub protocol, 2) an AtomPub client that publishes only via AtomPub and 3) a framework for creating AtomPub servers. Propono was developed by Ramesh Mandava and Dave Johnson, based on code from RSS and Atom in Action and open sourced as part of the Sun Web Developer Pack in 2007.

Abdera is a set of Java tools for working with Atom feeds and AtomPub protocol. This includes a parser, writers, an AtomPub client and a framework for creating AtomPub servers. Abdera's Atom feed parser uses STAX, so it uses less memory and is faster than ROME. Abdera's Atom feed support is more comprehensive than ROME's and it supports signatures, encryption, Atom to JSON, extensions for Threading, Paging, GeoRSS, OpenSearch, GoogleLogin, etc. etc. Abdera was developed by IBM and contribued to Apache in 2006.

Now let's compare frameworks. The pros and cons of ROME are:

  • Pro: complete RSS support, all of the dozen various flavors
  • Pro: it's generally simple and small, depending only one jar (JDOM)
  • Pro: easy to understand and use the AtomPub server framework
  • Pro: MetaWeblog API support
  • Con: Atom feed support not as comprehensive as Abdera
  • Con: parser uses lots of memory, slower, JDOM based
  • Con: community not as active, seems to be in maintenance mode (See also Ohloh stats)

The pros and cons of Abdera are:

  • Pro: comprehensive Atom feed support, lots more Atom extensions
  • Pro: faster more efficient parser
  • Pro: In the Apache Incubator with active and growing community (See also Ohloh stats)
  • Con: lots of dependencies
  • Con: AtomPub server framework poorly documented, overly complex (rewrite coming soon)
  • Con: no RSS support (there is something in Abdera contrib, but it's incomplete).

There you have it. ROME and Abdera folks: think that's a fair comparison? Are you a ROME or Abdera user? How would you like to see these frameworks move forward?

Holiday project: JMaki for Roller

JMaki seal Over the holidays I avoided doing anything directly related to my current set of work tasks. Sun went quiet, which helped, and I ignored the messages that piled-up in the Roller user and dev lists. It was so quiet that I had time for a fun little project: a JMaki plugin for Roller.

JMaki makes it easy to use JavaScript widgets (Dojo, Google, YUI, etc.) from PHP, JSP, JSF and now Roller. To use a widget, all you have to do is call a method or include a tag and JMaki takes care of including the right JavaScript files and generating the right HTML for you. That's not all JMaki does, there's also a pub/sub facility to make it easy to wire widgets together via events, there's a proxy for fetching remote resources common table and tree data models. The theme is cool widgets with ease-of-development and that's what I'd like to see in Roller. You can read more about the JMaki value proposition on the Why Use JMaki page.

Here's an example. Below is a Roller page template that uses two JavaScript widgest, the Dojo Clock and the YUI Data Table. All it takes is a single line of template code to include each widget, and one widget is dynamic i.e. the table is populated via an RSS feed.

    <head><title>JMaki test page</title></head>

        <h1>JMaki test: dojo.clock</h1>

        <h1>JMaki test: yahoo.dataTable</h1>
        $jmaki.addWidget("yahoo.dataTable", "/roller/xhp?id=rss","","")


And here's what that page looks like when displayed by Roller:

JMaki Plugin for Roller w/Dojo and YUI

I'll write more about the plugin once I install it on this site. If you want some details about how the plugin was developed, you can read the email that I sent to the JMaki dev list: JMaki for Roller issues and suggestions. It links to the Java source code for the plugin.

Roller 4.0 released


OpenQabal: a social software platform w/Roller

I'm always happy to see Roller used in new sites, projects and products. Here's an interesting new example that I've been meaning to blog for a while now. Phillip Rhodes is working on building what he calls OpenQabal a "social software operating system." The project integrates a set of social software applications, including Roller and JavaBB, via Single Sign-On (SSO), a common look-and-feel and Semantically-Interlinked Online Communities (SIOC). He explains it all in an lengthy and informative blog post on the project's blog.

I'd never heard of SIOC before. Here's the executive summary:

Semantically-Interlinked Online Communities SIOC or is a framework aimed at connecting online community sites and internet-based discussions. Currently, online communities (boards, blogs, etc.) are like islands - they contain valuable information but are not well connected. SIOC allows us to interlink these sites, and enables the extraction of richer information from various discussion services.

Sounds like it could be pretty darn useful. But then again, I spent a little time exploring the list of SIOC enabled sites with the SIOC Firefox plugin and didn't really find any examples of interlinked communities or conversations. Am I missing something?

Sun open source project governance

Here's a sampling of governance docs from some of Sun's many open source projects. I've listed them in order of what I feel to be, the most progressive (i.e. community governance) to least progressive (i.e. corporate control). I've also listed a key quote from each doc and made a brief comment about each.

  • OpenSolaris governance: "The OpenSolaris Community has the authority and responsibility for all decisions" - seems to approach ASF style governance.

  • OpenJDK interim governance: "The [board] shall be comprised of [5 and ] shall conduct its affairs in accordance with democratic principles and shall represent the interests of the Community. Two [members] shall be employees of Sun" - not final, but looking good.

  • Netbeans governance: "In the case of an irresolvable dispute, there is a governance board of three people, who are appointed for six month terms." (2 appointed by community, 1 by Sun)." - sounds pretty good, but the doc seems a little vague.

  • SunGrid governance: "The Board positions include the Community Leader, the Community Site Manager, and four general members, two Sun members and from the independent developer Community." - sounds good, again doc seems a little vague.

  • Glassfish governance: "The GlassFish project has an overall Project Lead ... appointed by Sun" - Sun has final say.

  • OpenSSO governance (draft): "Project Managers make the final decision ... are appointed by Sun" - Sun has final say.

  • OpenDS governance: The OpenDS project has single, overall Project Lead [who is] appointed by Sun Microsystems." - Sun has final say.

  • Mobile and embedded: "Sun may change its appointed Governance Board members at any time" - Sun has final say.

Looks to me like the trend is towards community governance and the most important projects are the ones getting the most attention and the most progressive governance. That's good and I sincerely hope the trend continues.

Apache Shindig voting in progress and more OpenSocial details emerge

I wrote about Shindig before, it's a new open source project to implement the Google OpenSocial APIs. Well, now the official voting to accept the Shindig project into the Apache Incubator is in progress and some interesting details have emerged in the latest version of the proposal. First, as you can see by the initial list of committers in the proposal Google has joined the Shindig effort in force. Second, the proposal says that Shindig will be the reference implementation of the OpenSocial APIs. And third, Shindig will not only include the client-side JavaScript container but also a Java back-end. Brian McAllister has already made some "gnarly" initial client-side container code available, I can't wait to see the Google contribution.

Groovy support back in Netbeans

After going missing in NB 5.5, Groovy support is back in Netbeans. Basic Groovy support with syntax coloring and support for running scripts from the IDE is available in plugin form (download page) for Netbeans 6.0 (starting with RC2), read about it on Geertjan's blog.

Here's what's coming after Netbeans 6.0, Groovy project support: screenshot of Groovy NB project types

After Netbeans 6.0, the story gets better. Geertjan writes that a brand new Groovy plugin will be available in the post-6.0 builds that adds support for three types of Groovy projects: applications, class libraries and Grails webapps.

Roller Strong #11

I've got a couple of Roller related items to blog about, so why not just call it Roller Strong #11.

First, Lars Trieloff responds to some of the questions I raised about JCR and Roller in my ApacheCon wrap-up post. I left a comment on his blog in response. Personally, I think a JCR back-end is a very interesting idea and I wish I had some more time to explore it.

Manchi Leung AKA Thinkboy posted the code for a new Textile plugin to the Roller dev list, using Textile-J. Thinkboy says "it supports almost all of the Textile syntax. very much the same as Confluence wiki. Now I can easily sync or copy working notes from Confluence wiki to my personal Roller blog." Nice. Note to self: I need to fix up some of our existing entry plugins -- I think some of them (e.g. Ekit) still haven't been updated for Roller 3.1.

Arun Gupta blogged recently about Backing up your Roller entries and explained how to use the Grabber example (now known as BlogBackup in Blogapps 2) from the Blogapps project to backup your Roller blog. Backing-up your entries, but backing up your uploads is not. Hopefully, blogs.sun,com will turn on Atom protocol someday and that'll will make it easy for a tool like Grabber backup both entries and uploads.

roller logo

We're still waiting on Roller 4.0, but I sense our wait is soon over. Roller 4.0 RC10 was released one week ago with just a couple of bug fixes. And so far, no critical issues have been found. We've got only one +1 vote (thanks Anil!) so far so committers please test and vote.

And finally, I have to mention MarkMail because I've been using it throughout this blog post. MarkMail provides a slick interface and excellent facilities for mailing lists of all kinds. They're indexing all of the Apache mailing lists and providing statis and charts for each. Check the Roller page at MarkMail for example.

That's all I've got for this go-round. Keep on rollin'

Latest Links: Android, OpenSolaris and misc.

« Previous page | Main | Next page »