initial commit -- ported to trunk artemis but not tested