From b0f31909d49c1c97b5ced0d0fef0117a8073ab17 Mon Sep 17 00:00:00 2001
From: Fabio Pistolesi <fabio.pistolesi@forgerock.com>
Date: Fri, 06 Feb 2015 14:44:59 +0000
Subject: [PATCH] OPENDJ-1716 CR-5915 Changes in Pluggable backend configuration and preparatory work for OPENDJ-1750 Prepares for a fix in Backup restore for pluggable backends, keeping a single parameter (ds-cfg-java-class) in the configuration. Pluggable backends will need to Extend BackendImpl to be able to be referenced in the configuration. PitBackend is the backend using PersistIt as storage, until a better name comes up.
---
opendj3-server-dev/src/server/org/opends/server/backends/pluggable/RootContainer.java | 10 +++++-----
1 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/opendj3-server-dev/src/server/org/opends/server/backends/pluggable/RootContainer.java b/opendj3-server-dev/src/server/org/opends/server/backends/pluggable/RootContainer.java
index 1f1fc2b..371c1cb 100644
--- a/opendj3-server-dev/src/server/org/opends/server/backends/pluggable/RootContainer.java
+++ b/opendj3-server-dev/src/server/org/opends/server/backends/pluggable/RootContainer.java
@@ -46,11 +46,11 @@
import org.forgerock.opendj.config.server.ConfigException;
import org.opends.server.admin.server.ConfigurationChangeListener;
import org.opends.server.admin.std.server.PersistitBackendCfg;
-import org.opends.server.api.Backend;
import org.opends.server.api.CompressedSchema;
import org.opends.server.backends.persistit.PersistItStorage;
import org.opends.server.backends.pluggable.spi.ReadOperation;
import org.opends.server.backends.pluggable.spi.ReadableStorage;
+import org.opends.server.backends.pluggable.spi.Storage;
import org.opends.server.backends.pluggable.spi.StorageRuntimeException;
import org.opends.server.backends.pluggable.spi.WriteOperation;
import org.opends.server.backends.pluggable.spi.WriteableStorage;
@@ -119,7 +119,7 @@
private final File backendDirectory;
/** The backend to which this entry root container belongs. */
- private final Backend<?> backend;
+ private final BackendImpl backend;
/** The backend configuration. */
private PersistitBackendCfg config;
/** The database environment monitor for this JE environment. */
@@ -143,7 +143,7 @@
* @param backend A reference to the JE back end that is creating this
* root container.
*/
- public RootContainer(Backend<?> backend, PersistitBackendCfg config)
+ public RootContainer(BackendImpl backend, PersistitBackendCfg config)
{
this.backend = backend;
this.config = config;
@@ -161,7 +161,7 @@
*
* @return the underlying storage engine
*/
- PersistItStorage getStorage()
+ Storage getStorage()
{
return storage;
}
@@ -401,7 +401,7 @@
try
{
- storage = new PersistItStorage();
+ storage = (PersistItStorage) backend.newStorageInstance();
storage.initialize(config);
storage.open();
storage.write(new WriteOperation()
--
Gitblit v1.10.0