Inside Paulo Abrantes' head
[ start | index | login or register ]
start > 2006-10-23 > 1

Work: What I have been up to

Created by pabrantes. Last edited by pabrantes, one year and 301 days ago. Viewed 915 times. #6
[diff] [history] [edit] [rdf]
labels
attachments

Work: What I have been up to

Well as you probably have noticed lately I've not been posting as much as I used to. I've been busy with work and when I get home most of the time I'm not in the mood to write stuff.

But here I am again, to bring you news of what I've been working on.

Besides patching bugs and adding new request features to the vigilancy system that is now in production, I'm working on a tool to convert our Moin Moin Wiki content to the our new Snipsnap wiki.
Besides that I'm also working on another part of the FenixEDU domain, the Research Domain. The main goal is to implement >>CERIF model within Fenix system. This is not a work from scratch since a few FenixEDU members (and former members) already have worked in it. You can read about CERIF within Fenix system at >>CERIF's @ Fenix wiki page. On a long term there's also the idea to develop an eclipse plugin to be able to visualise our domain through our DML (Domain Modelling Language) specification.

Right now, I wanted to discuss a bit about the converter I've been developing. I have just refactored it and I think it has a decent design. Let's give a look then. Here it is the converter system:

Seems a fairly simple design, but what is each class? And what is it responsible for?

Let's give a quick look!

Spider

This is the class where it all starts. The Spider class is responsible to instantiate the correct AbstractPageConnector (this is done by looking up a property file) and also to instantiate the converter and start it.

Converter

Not much to say Converter as the name indicates is responsibile to convert from Moin Moin Wiki syntax to SnipSnap syntax. Although a first direct conversion is made within the PageConnector due to the filter chain (we will get there later).

SnipSnapConnector

The SnipSnapConnector is the class responsibile to access Snipsnap's wiki context and interact with it, this means this class is able to create and store pages and also files that might be attached to wiki pages.

AbstractPageConnector

The AbstractPageConnector is responsible to fetch pages from the Moin Moin wiki and give them to the Converter. There are two different kinds of Page Connectors, one is the HttpConnector which acts like a web spider and crawls by the webpage, the other one is a file system connector, which starts harvesting everything in the Moin Moin file system directory and converting.

Before the page content is given to the Converter to be parsed character by character trying to find convertible blocks (things like code segments, tables, camel case, etc) it first goes through a filter engine that does a few simple conversions.

Indexer

The class Indexer is responsibile to keep an index of pages yes to visit and already visited pages. So the Page connector always know where it is and where it's gonna go next.

FilterEngine

The FilterEngine is a simple class that uses a >>Strategy Design Pattern to filter content in each line that is read by the Page Connector.

AbstractFilter


(not all filters are displayed in the UML so it doesn't get too crowded)

The filters are responsible to convert simple matching textlike, for example the [[Include]], [[Calendar]] moin moin macros, along with text formatting like bullets or headers. Each one of these filters extends RegexFilter and has a known interface that allows the RenderEngine to handle them all without actually knowing what real filter it's handling.

Currently this tool is not yet available since I'm still finishing it's development, but when I finish it I'll might put it available in this blog.

Along with this tool snipsnap macros have been developed to support, includes, moin moin calendar's, moin moin tables and table of contents. This last one also originated a small change in the radeox rendering engine. But those stories will be left for another post!

Why have I showed you the design? Well maybe you find it interesting, maybe you learn something with it… But what I'm really hoping is to ear some suggestions on how it could be improved.

Any questions related with this tool or anything else feel free to post!

2 comments (by anonymous, pabrantes) | post comment
Who am I?
paulo-roca2My name is Paulo Abrantes AKA pabrantes and I'm a software developer. I'm currently employed at >>CIIST working as a Java developer in >>FenixEDU.

This blog is mostly about Java programming, domain driven design and snipsnap bliki developing. Everything written in this blog is my personal opinion and it may not reflect the opinions of my employer and co-workers.


Blog subscription
subscribe by rss subscribe by email

Links
>> Home
>> Paulo's Profile
>> Post History
>> Add to Technorati Favorites
>> Paulo's Photo Gallery
>> WishList
>> Posting without Login

Search Blog
Fellow Bloggers

Recent Posts

Java Programming: Bytecode Injection
Intermission: Sorry For Downtime
Software Developing: Studying The Bliki Domain Model
SnipSnap Developing: Trying to settle a roadmap
System Administration: Load Balancing with Apache
Blogging: Two years have passed
Software Developing: The SnipSnap Saga
Java Programming: Getting your code spicy with Groovy
Software Developing: Fluent Interfaces
Software Developing: Implementing a ShoutBox on SnipsSnip
Software Developing: SnipSnap, SnipIt and SnipSnip
Java Programming: Proxies and Access Control
Java Programming: Proxies and References
Java Programming: References' Package
YALM: Yet Another Layout Modification

For older posts, please refer to post-history for a complete Post History

Logged in Users: (0)
… and 4 Guests.
This is a modified version of snipsnap.org created by >>Paulo Abrantes