From ccd66a6d38f7d3a55a4fddd2945d8ab8920b007e Mon Sep 17 00:00:00 2001
From: Nicolas Capponi <nicolas.capponi@forgerock.com>
Date: Mon, 07 Nov 2016 15:05:30 +0000
Subject: [PATCH] OPENDJ-3417 Move management of backends and listeners from DirectoryServer to BackendConfigManager
---
opendj-server-legacy/src/main/java/org/opends/server/backends/LDIFBackend.java | 9 ++++++---
1 files changed, 6 insertions(+), 3 deletions(-)
diff --git a/opendj-server-legacy/src/main/java/org/opends/server/backends/LDIFBackend.java b/opendj-server-legacy/src/main/java/org/opends/server/backends/LDIFBackend.java
index 0283aa2..1b41013 100644
--- a/opendj-server-legacy/src/main/java/org/opends/server/backends/LDIFBackend.java
+++ b/opendj-server-legacy/src/main/java/org/opends/server/backends/LDIFBackend.java
@@ -107,6 +107,9 @@
/** The path to the LDIF file containing the data for this backend. */
private String ldifFilePath;
+ /** The server context. */
+ private ServerContext serverContext;
+
/**
* Creates a new backend with the provided information. All backend
* implementations must implement a default constructor that use
@@ -132,8 +135,7 @@
{
try
{
- DirectoryServer.registerBaseDN(dn, this,
- currentConfig.isIsPrivateBackend());
+ serverContext.getBackendConfigManager().registerBaseDN(dn, this, currentConfig.isIsPrivateBackend());
}
catch (Exception e)
{
@@ -337,7 +339,7 @@
{
try
{
- DirectoryServer.deregisterBaseDN(dn);
+ serverContext.getBackendConfigManager().deregisterBaseDN(dn);
}
catch (Exception e)
{
@@ -1191,6 +1193,7 @@
@Override
public void configureBackend(LDIFBackendCfg config, ServerContext serverContext) throws ConfigException
{
+ this.serverContext = serverContext;
if (config != null)
{
currentConfig = config;
--
Gitblit v1.10.0