Forum OpenACS Development: RFC: Using tDOM instead of nsxml

Making a first step towards what I have announced in this thread (https://openacs.org/forums/message-view?message_id=94670) about the work I've been doing recently. There has been discussions about this in the past, so, here's a quick introduction to tDOM (not tcldom) and why I think that it should be adopted as a replacement of ns_xml.

tDOM (http://www.tdom.org/) combines high performance XML data processing with easy and powerful Tcl scripting functionality. tDOM is one of the fastest ways to manipulate XML with a scripting language and uses very few memory. It is currently maintained by Jochen Löwer and Rolf Ade with regular contributions by Zoran Vasiljevic (aolserver core team member). tDOM is more feature-complete (see the tDOM homepage for a synopsis of the features provided) than ns_xml. ns_xml only provides a minimum set of features.

Many people from the community are using it in private projects and I think it should be included as part of OpenACS. As soon as I return to Cyprus I will post the necessary changes which are not more than changing the xml procs file and a few snippets of code in the package manager. I did mail the changes to a few members of the community so if they want to go ahead and post either here or in the file storage it should be great.

Finally, in case someone considers this a bad idea, it would be easy to configure the xml procs library so that it loads either ns_xml or tDOM depending on which module is loaded in the aolserver configuration file.

More RFCs and new packages when I return to Cyprus.

Collapse
Posted by Roberto Mello on
Hi Neophytos,

I thought Bart Teewise was already working into integrating tDOM into OpenACS. Bart, can you comment?

-Roberto

Collapse
Posted by Neophytos Demetriou on
Hi Roberto, I don't know what/how Bart is doing but nevertheless if tDOM makes it into OpenACS it would be great and will open new horizons for people that need to do advanced xml processing. The next RFC I am going to post when I return back home is very much tDOM dependent. It is about a package that handles ODP data and enables openacs web sites to have the DMOZ catalog. ODP data is huge around 600MB  compressed!
Collapse
Posted by Neophytos Demetriou on
Ok, I found the thread. You are right Roberto. Bart did work on tDOM support. Here is the thread:
https://openacs.org/forums/message-view?message_id=84897

However, it seems that Bart's changes did not make into the core (I've just checked the xml procs library). Can't say why.

Still, could we get this effort going again.

Collapse
Posted by Don Baccus on
It is scheduled to happen in OpenACS 5.0 (currently HEAD), and Bart agreed to take it on since you have not been available.
Collapse
Posted by Neophytos Demetriou on
It is good to hear that tDOM is going into the core. I'll post about the DMOZ package when I'm back.

(I was not available to who?)

Collapse
Posted by Tom Jackson on

In AOLserver4, using tDOM means you just do something like:

eval package require tDom

I'm not sure of the exact syntax, but you can load any tcl package into AOLserver4, so there isn't any need for a C level module anymore.

Collapse
Posted by Bart Teeuwisse on
I have replaced ns_xml with tDOM in an earlier OACS 4.6 version (around 4.6.1). However, I have not committed my changes yet because it would require people to install tDOM while all the documentation still refers to ns_xml. What would be a good time to swich over from ns_xml to tDOM?

For the record. Both libraries can be loaded at the same time and packages depending on ns_xml will still work. My changes only concern the XML procedures in the core.

My suggestion is to compare notes with Neophytos before making any changes.

/Bart

Collapse
Posted by Peter Marklund on
Bart,
regarding timing I'll let Don have the final say. However, I talked to Don about exactly this issue at the social, and it seems to me the best time would be as soon as possible *after* we've done the 4.6 merge on head. That merge should happen within a week.

The reason for making the change soon is that head is supposed to grow increasingly stable as we approach summer. On the other hand since we have so many major new features that we want to go in we will accept the risk of destabilizing head initially.

I want to point out here (as Don has maybe done already somewhere) that 4.6.3 is supposed to be purely a bug fix release (no new features).

Collapse
Posted by Neophytos Demetriou on
Bart, I'll contact you as soon as I'm back to Cyprus. BTW, I think that you should also be included in my list (my apologies for forgetting to include you) in this thread:
https://openacs.org/forums/message-view?message_id=94728
Collapse
Posted by Don Baccus on
The merge with HEAD will start within a week, hopefully (Jeff was hoping to get started on it after he returns from holiday this weekend), I think it may take a couple of weeks to get it finished.

And, yes, I've stated elsewhere that 4.6.3 will be a bug fix release ONLY and it will come SOON (next weekend perhaps?)

Anyway ... mid-May should be a safe target date for Bart to jump in and commit his tDOM changes, after consulting with Neophytos.  Maybe earlier but Bart, if you're busy and need to plan your time in advance mid-May's "it".

Collapse
Posted by Bart Teeuwisse on
Alright then. I'll stay tuned for the 4.6.3 release after which I will merge the tDOM changes to the head of 4.7.

/Bart

Collapse
Posted by Neophytos Demetriou on
I've sent my changes to Bart. As soon as Bart commits the tdom changes I'll write about the dmoz and rss packages I've talked about in another thread.