| | |
| | | // TODO: Cache the buffer? |
| | | ByteStringBuilder buffer = new ByteStringBuilder(); |
| | | entry.encode(buffer, encodeConfig); |
| | | putEntryToDB(entry.getDN().toNormalizedString(), |
| | | putEntryToDB(entry.getName().toNormalizedString(), |
| | | backend, entryID, buffer); |
| | | } catch (Exception e) { |
| | | if (debugEnabled()) { |
| | |
| | | // See if the entry already exists in the cache. If it does, then we |
| | | // will fail and not actually store the entry. |
| | | if (entryCacheIndex.dnMap.containsKey( |
| | | entry.getDN().toNormalizedString())) { |
| | | entry.getName().toNormalizedString())) { |
| | | return false; |
| | | } |
| | | } finally { |
| | |
| | | // TODO: Cache the buffer? |
| | | ByteStringBuilder buffer = new ByteStringBuilder(); |
| | | entry.encode(buffer, encodeConfig); |
| | | return putEntryToDB(entry.getDN().toNormalizedString(), |
| | | return putEntryToDB(entry.getName().toNormalizedString(), |
| | | backend, entryID, buffer); |
| | | } catch (Exception e) { |
| | | if (debugEnabled()) { |