merged JEE fixes with B6port version