Skip to main content

a silhouette of a person's head and shoulders, used as a default avatar

Cave mouse






It was supposed to be a 10 km walk... well, some people can read maps, others can't..




It was more than obvious were we had to go..but they just don't listen to me.
At least I got some beer and Obazder after the hell of a walk.

And now there's this frog who accompanied them to the pub. The guy who brought the beer wanted to throw him away. But somehow in the very last second he figured out that this paper thingy was a frog.. they say he can jump.. the truth is he always lands with his feet sticking out and someone has to rescue him..what a nuisance..

the avatar of Flavio Castelli

Remember to commit

I have to admit that lately I have a really bad habit: I forget to commit my changes to Strigi. In this way I end-up performing multiple commits with different changes inside: from stupid to interesting one. This is a really bad behavior, so today I decided to perform some svn status and svn diff and I made some commits on Strigi trunk. Most of all are just code readability improvement == don’t exceed the 80 chars per line.

I think that Jos will be really happy to see them ;)

the avatar of Flavio Castelli

Work, work, work and... new house!

In my last message I promised to write some more contents on this site, in order to keep it more updated. As usual I disappointed this promise :) So, what I have been doing in these day? Just a simple answer: I’ve worked a lot. “Work” can be divided in the following categories:

  • office work
  • KDE & Strigi coding
  • Physical work

The most important of all is the last one. I’ve spent all my week-ends working in my new house. I’ve been fixing and improving it (wow… it seems I’m talking about a piece of software ;) ) and now it’s quite finished.

I’ve to say a great “thank you” to my dad. He’s able to do everything (he’s something better than Mac Gyver) and helped me a lot (in fact he has done all the dirty jobs).

Prepare yourself, I’ll put some photos of the house really soon…

a silhouette of a person's head and shoulders, used as a default avatar

openwsman-yast now returns proper datatypes

After five days of hacking last week, a final itch was left which needed scratching. The YaST openwsman plugin only passed strings back and forth, losing all the type information present in the YCP result value. So I added some code to convert basic YCP types to XML (in the plugin) and from XML to Ruby (on the client side). Now the result of a web service call to YaST can be processed directly in Ruby. Here's a code example showing the contents of /proc/modules on a remote machine.
require 'rwsman'
require 'yast'
client = WsMan::Client.new( 'http', 'client.internet.org', 8889, '/wsman', 'user', 'password')
options = WsMan::ClientOption.new
schema = YaST::SCHEMA
uri = schema + "/YCP"
options.property_add( "ycp", "{ return SCR::Read( .proc.modules ); }" )
result = client.invoke( uri, "eval", options )
modhash = YaST.decode_result( result ) # hash of { modulename => { size=>1234, used=>3 } }
Supported are void, bool, integer, float, string, symbol, path, term, list, and map -- should be sufficient for most of YaST. The YaST class is here. You need at least version 1.1.0 of openwsman and openwsman-yast, both available on the openSUSE build service. And, btw, source code for openwsman-yast is now hosted on svn.opensuse.org

a silhouette of a person's head and shoulders, used as a default avatar

Hack week

Last week was Hack week at Novell. At the beginning of the week, I started working on my idea of a out-of-the-box backup/restore/archive manager application for Evolution. Due to some family occasion, I was out of station and hack-week, for three days. When I came back, I took up another idea - a continuation of my Evolution Exchange Performance work. Evolution exchange starts up in just 3 seconds (approx.) now. Patch is in nascent stage and more to come in another couple of days. Stay tuned!

a silhouette of a person's head and shoulders, used as a default avatar

UOF Import Filter for OpenOffice.Org

The UOF - Uniform Office Format is an emerging standard, which is being developed by the Chinese Office Software Work Group (COSWG), led by the China Electronics Standard Institute (CESI), the Ministry of Information Industry (MII), major suppliers of Chinese office software suites, and other academic institutions.

This week is a hackfest week at Novell. I am hacking a UOF( Chinese Office File Format) import filter for OpenOffice.org. This filter is an external component based on ODF-UOF Converter.

An extension is developed so that OpenOffice.Org is able to open UOF text document. Here is some screenshots.






Although some features such as paragraph style, table are supported yet, there are a lot of work need to do. I will continue to work on them when I get time.

a silhouette of a person's head and shoulders, used as a default avatar

XEMBED, Mono and OpenOffice.

XEMBED, Mono and OpenOffice.org

In my last post I talked about the hack I did to get some Java applets running in an OpenOffice.org docking window.

I played a little more with the code and managed to get a XEMBED socket running in an OpenOffice.org docking window. The picture below shows an OpenOffice.org running with a XEMBED ready docking window:



The title bar of the docking window shows the socket id to which XEMBED applications can connect.

I used the following Mono code to connect to the XEMBED socket:

using System;
using Gtk;

// Compile with:
// mcs -pkg:gtk-sharp SamplePlug.cs

public class SamplePlug
{

public static void Main(string[] args) {
if (args.Length != 1) {
Console.WriteLine("Need socket id as an argument.");
return;
}
uint socket_id = UInt32.Parse(args[0]);

Console.WriteLine("using socket "+socket_id);

Application.Init();

Plug plug= new Plug(socket_id);
// plug.Add(new Label("HELLO"));
plug.Add(new Entry("HELLO"));
plug.ShowAll();

Console.WriteLine("running..");
Application.Run();
}
}


The picture below shows it all running:


In theory this'll work not only with Mono but with any application which can talk the XEMBED protocol like e.g. GTK- and QT-based applications.
a silhouette of a person's head and shoulders, used as a default avatar

Remote management with Rails

The Rails demo for remote systems management with WS-Man is available at the openwsman web site.
Just follow the install and configure instructions. In short you need
  • openwsman
    An open source implementation of the ws-management standard.
  • rwsman
    Ruby bindings for openwsman client operations.
  • Ruby On Rails
    Web development that doesn't hurt
  • Railsapp
    Rails demo application for rwsman
Once everything is properly installed, start the Rails web server with ruby script/server. Now point your browser to http://localhost:3000 and you'll see the startup page. Click on the text, then click on Discover and the Discovery page will appear.

Look closely at the Actions line for each host and you'll notice the YaST action for the openSUSE client. This client has my openwsman-yast plugin installed.
The demo application allows to start and stop the desktop (the xdm service to be precise) and to switch the desktop environment between KDE and GNOME. YaST operations

Doc has videotaped a demo, you can find it in the idea.opensuse.org blog.

a silhouette of a person's head and shoulders, used as a default avatar

Evolution Exchange Performance Series - Chapter 3 - Folder loading from 480 secs to < 1 sec

Close to a month now, have been working on squeezing Connector to save some time while it loads the folders. Remember Chapter-1 of my Evolution Exchange Performance Series blog - Yes, I based my optimization work from it. In the attached image, as you can see most of the folder loading time is spent in camel_exchange_folder_construct(). Construction of exchange folder objects does two major things:
  • Scanning the entire folder for any changes since last evolution session and
  • Fetch messages to keep things in sync
These two operations contributed to a big level in connector folder loading time. Fix doesn't refresh if summary is available and scanning for changes, since last evolution session, is moved to a separate thread with appropriate threading-etiquettes.

Here comes the supporting fact for my blog: :)



(2.11.x timing may vary depending upon production servers - response from my test servers are quite quick)

With this fix, Exchange Connector catches up with Microsoft Outlook w.r.t folder loading time. Outlook users will love Evolution 2.11.5 - watch out for more performance hacks. This fixes 442186, part of 341214 and 421091.
a silhouette of a person's head and shoulders, used as a default avatar

Hibernate Logging

Have you ever tried to get hibernate to log SQL? It's quite easy, just set log4j.logger.org.hibernate.SQL=DEBUG, and hey presto, you have SQL statements logged. Except it's not too useful, as most of them are parameterised queries, with lists of question marks instead of values. So you do a search on Google and it turns up millions of entries saying you need to set log4j.logger.org.hibernate.type. But it doesn't help, because all the articles say the value should be INFO, whereas what you really want is log4j.logger.org.hibernate.type=TRACE.

So there you go. Maybe Google will turn up my blog entry instead for you.