Log in



Archive for January, 2006

Programming language design

January 31st, 2006 by Peter

Just for the notes, here are some great information sources for programming language design:

http://www.dreamsongs.com/NewFiles/PatternsOfSoftware.pdf

http://www.nondot.org/sabre/Mirrored/AdvProgLangDesign/

http://www.oberon.ethz.ch/books.html

Database vs. Directory

January 30th, 2006 by Peter

We discussed about the storage and retrieval of hierarchical runtime information in general. In the [url=http://www.asg-platform.org]ASG[/url] use case, we needed to store service-related monitoring parameters (like last operation call duration) for later retrieval. Nearly all developers choose a database as natural solution – but why ?

If you look on the history of standardized information models, you see a long tradition of hierarchical directory mechanisms. The traditional OSI concept of a [url=http://de.wikipedia.org/wiki/X.500]X.500[/url] ‘Directory’ (with its according meta-model, the ‘Directory Schema’) evolved to things like LDAPv3 (RFC 2252/2256), NIS (RFC 2307), CORBA naming service and Active Directory. There are multiple implementations, especially for LDAP, which support a high-performance querying and storage of objects and attribute values in the data hierarchy, usually with one round trip (“Find all users which have the following permission”).

Further investigations on the topic pointed out that everything depends on your type of query. Large complicated queries of highly interrelated data are great for a database query optimization technology. Simple queries for specific objects and values (with filtering) might be better handled with some LDAP-based technology. I don’t know too much about the performance of current database technology, but as a student I learned that database updates are comparatively expensive. This might not hold for LDAP. Again, everything depends on your data access patterns …

Subversion Speed

January 23rd, 2006 by Peter

You like Subversion ? Maybe you are one of the many Windows users, which rely on TortoiseSVN. In [url=http://www.asg-platform.org]ASG[/url], we always wondered why TortoiseSVN took so long in comparsion to our Linux machines. Here are some measurements … We performed a SVN update operation on a huge source tree, which was rearranged (directory changes and removals) and then commited to the repository from another machine. We used a Windows and a Linux machine with comparable hardware performance.

[list]
[*]Windows XP, Tortoise (1.2.x): 90s
[*]Windows XP, Cygwin svn command-line tool: 45s
[*]Windows XP, Cygwin svn command-line tool, Google Desktop Search disabled: 35s
[*]Windows XP, Cygwin svn command-line tool, F-Prot disabled: 30s
[*]Debian Sarge, svn command-line tool: 5s
[/list]

With the help of perfmon.exe, we figured out that most of the time is taken for the deletion of directory trees in the Windows tests. Anyway, pretty amazing …

Debian Zones

January 21st, 2006 by Peter

In the [url=http://www.asg-platform.org]ASG[/url] Testbed we successfully use Solaris 10 Zones for different application server and remote terminal environments. The [url=http://www.openvz.org]OpenVZ[/url] project [url=http://openvz.org/news/links/debianplanet-20060111]announced[/url] that their system now also supports my favourite Linux distribution.

Reference Wars

January 17th, 2006 by Peter

At university, we have an increasing problem with literature references to Wikipedia and Google search results. Many students rely their work only on Internet sources, bypassing the classical way of scientific information gathering. If it’s not in Google, it is not relevant.

For me it is funny to see that those people do not understand the problem of information quality management, especially in the Wikipedia case. We encourage the people to rely their literature references on non-URL citations, which is quite simple with things like CiteSeer and the ACM Digital Library. Internally, my professor gave out a quality ranking for information sources:

[list]
[*]Scientific journals
[*]Books
[*]Conference papers
[*]Technical magazines
[*]… (a lot of space)
[*]Wikipedia
[*]Web pages
[/list]

We did an according seminar about fault-tolerant systems, only based on papers which where at least 5 years old. For our Bachelor students, it was a totally new experience, but very exciting. The following (sorry, german) article gives a great explanation of the problem of web information sources:

http://www.heise.de/tp/r4/artikel/20/20982/1.html

Communication of .NET AppDomains

January 11th, 2006 by Peter

We recently researched the communication of different .NET AppDomains (for Java guys: isolates) over Remoting channels. Here is a summary of the results from Martin:

If one application domain is creating another one, then a [i]System.Runtime.Remoting.Channels.CrossAppDomainChannel[/i] is created, with the URI name [i]“XAPPDMN_URI”[/i]. It is based on a [i]MemoryChannel[/i] for serialization. The funny thing is (again) a slight hack for performance optimization. The [url=http://systemobject.com/Object/?o=System.Runtime.Remoting.Messaging.MessageSmuggler][i]System.Runtime.Remoting.Messaging.MessageSmuggler[/i][/url] checks whether Marshalling is really needed for the AppDomain communication. Primitive types, strings and string arrays are simply copied, all other data structures are oficially serialized. The current thread is then moved to the new AppDomain ([i]System.Threading.Thread.EnterContextInternal[/i]) and unpacks the serialized data and all smuggled objects. The [i]ReturnToContext[/i] method moves the thread back to the original AppDomain.

Units of deployment in J2EE

January 9th, 2006 by Peter

We recently discussed, in the context of [url=http://www.asg-platform.org]ASG[/url], which are the units of deployment in J2EE. Everybody knows that you can deploy J2EE enterprise archive files (.ear), web modules (.war), EJB modules (.jar) and resource adapter modules (.rar).

Beside this, you can also deploy another type of file with the extension “.jar”. The J2EE specs allow class libraries to be packaged and deployed as .jar files according to the ‘Extension Mechanism Architecture’. These class libraries then automagically become installed libraries.

J2EE 1.4 Spec. page 139
J2EE 5.0 Spec. page 163

Definition of a Distributed System

January 8th, 2006 by Peter

Definition of a distributed system: You know you have one when the crash of a computer you’ve never heard of stops you from getting any work done.
- Leslie Lamport

64Bit porting – how you compiler might help you

January 6th, 2006 by Peter

Martin v. Loewis is currently working on the 64Bit port of Python for Windows and Linux. He found out that the Microsoft 64bit compilers have specific warnings regarding special portability issues, e.g. with the mapping of size_t to platform data types.

We wondered if there is really no Unix compiler which is able to give such a support in a similar manner. Both the Linux gcc and the Solaris cc claimed the regarding code to be perfect, while Visual Studio gave hundreds of warnings.

In a recent mail, Martin described that the Intel compiler at least seems to have similar capabilities. It seems like there is a focus on the avoidance of false positives in the Unix compiler world, while Microsoft has no problem with spamming the developer with maybe unneccessary warnings. It’s your turn as a developer to the decide which way you like most. Here an excerpt from Martin’s posting:

I just found that the intel compiler (icc 9.0)
also supports compiler warnings for portability
problems.

For the file

#include

int foo(size_t x)
{
return x;
}

it says (with -Wall)

a.c(3): remark #1418: external definition with no prior declaration
int foo(size_t x)
^

a.c(5): remark #1682: implicit conversion of a 64-bit integral type to a smaller integral type (potential portability problem)
return x;
^

If you just want the latter warning, pass -Wp64.

Regards,
Martin

P.S. In case you want to install it on a Debian AMD64 system,
here is the procedure:
1. register at

https://registrationcenter.intel.com/EvalCenter/EvalForm.aspx?ProductID=408

2. download and unpack the l_cc_c_9.0.030 tarfile.

3. don’t try alien, it won’t work.

4. don’t try the Intel install.sh, it won’t work
(atleast, it didn’t work for me)

5. Instead, install with ‘rpm -i –nodeps *.em64t.rpm’

6. edit /opt/intel/cce/9.0/bin/icc, replacing all
occurrences of with /opt/intel/cce/9.0

7. Put the *.lic file that Intel sent you into
/opt/intel/cce/9.0/bin

Back again

January 5th, 2006 by Peter

Its being a long time since the last post … The first blog enthusiasm is over, and in December I only worked on finishing existing, boring stuff.

After christmas, we had a great holiday week [url=http://www.gutshof-bastorf.de/] in the north of Germany[/url]. I promise to provide some photos in the near future. We waited for the new year in a self-made snow cave, which was not as cold as it sounds. The kids (our son and the boy from friends) more or less liked the snow, but where more exited about the ocean. For me, this sounds like a mandatory summer holiday trip ;-)

Technically, nothing really important happened so far. Dan discovered some bugs in the DRMAA test suite, which are written down in the SourceForge tracker items, but not fixed so far. The ASG project is heading towards the next big prototype, and we spend nearly the whole last week in December with building web service servlets in NetBeans 4. Sorry Sun, but the Java IDE’s seems to be years beyond Visual Studio and friends. Install the last VS version, play around with the new .NET 2.0 features and the integrated IIS. This is how Web Service development should look like ! More details ? Just ask …

  • You are currently browsing the troeger.eu blog archives for January, 2006.