| | |
| | | import org.opends.server.api.Backend; |
| | | import org.opends.server.backends.jeb.BackendImpl; |
| | | import org.opends.server.backends.jeb.VerifyConfig; |
| | | import org.opends.server.config.ConfigEntry; |
| | | import org.opends.server.config.ConfigException; |
| | | import org.opends.server.core.CoreConfigManager; |
| | | import org.opends.server.core.DirectoryServer; |
| | |
| | | import static org.opends.server.util.StaticUtils.*; |
| | | import org.opends.server.util.StaticUtils; |
| | | import static org.opends.server.tools.ToolConstants.*; |
| | | |
| | | import org.opends.server.admin.std.server.BackendCfg; |
| | | |
| | | |
| | | /** |
| | |
| | | |
| | | |
| | | // Decode the base DN provided by the user. |
| | | DN verifyBaseDN = null; |
| | | DN verifyBaseDN ; |
| | | try |
| | | { |
| | | verifyBaseDN = DN.decode(baseDNString.getValue()); |
| | |
| | | // Get information about the backends defined in the server. Iterate |
| | | // through them, finding the one backend to be verified. |
| | | Backend backend = null; |
| | | ConfigEntry configEntry = null; |
| | | DN[] baseDNArray = null; |
| | | |
| | | ArrayList<Backend> backendList = new ArrayList<Backend>(); |
| | | ArrayList<ConfigEntry> entryList = new ArrayList<ConfigEntry>(); |
| | | ArrayList<BackendCfg> entryList = new ArrayList<BackendCfg>(); |
| | | ArrayList<List<DN>> dnList = new ArrayList<List<DN>>(); |
| | | BackendToolUtils.getBackends(backendList, entryList, dnList); |
| | | |
| | |
| | | for (int i=0; i < numBackends; i++) |
| | | { |
| | | Backend b = backendList.get(i); |
| | | ConfigEntry entry = entryList.get(i); |
| | | List<DN> baseDNs = dnList.get(i); |
| | | |
| | | for (DN baseDN : baseDNs) |
| | |
| | | if (backend == null) |
| | | { |
| | | backend = b; |
| | | configEntry = entry; |
| | | baseDNArray = new DN[baseDNs.size()]; |
| | | baseDNs.toArray(baseDNArray); |
| | | } |
| | | else |
| | | { |
| | |
| | | try |
| | | { |
| | | BackendImpl jebBackend = (BackendImpl)backend; |
| | | jebBackend.verifyBackend(verifyConfig, configEntry, baseDNArray, null); |
| | | jebBackend.verifyBackend(verifyConfig, null); |
| | | } |
| | | catch (Exception e) |
| | | { |