// Replace '\n' to real LF
String entryStr = contextEntry.replaceAll( "\\\\n", "\n" );
LdifReader ldifReader = new LdifReader();
List<LdifEntry> entries = ldifReader.parseLdif( entryStr );
if ( ( entries != null ) && ( entries.size() > 0 ) )
{
LdifEntry entry = entries.get( 0 );
jdbmPartition.setContextEntry( entry.getEntry() );