-
Notifications
You must be signed in to change notification settings - Fork 108
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Loading status checks…
Store LDAPv3 database in SQL JDBC database (#454)
Showing
14 changed files
with
881 additions
and
51 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
74 changes: 74 additions & 0 deletions
74
...main/resources/config/xml/org/forgerock/opendj/server/config/JDBCBackendConfiguration.xml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,74 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<!-- | ||
The contents of this file are subject to the terms of the Common Development and | ||
Distribution License (the License). You may not use this file except in compliance with the | ||
License. | ||
You can obtain a copy of the License at legal/CDDLv1.0.txt. See the License for the | ||
specific language governing permission and limitations under the License. | ||
When distributing Covered Software, include this CDDL Header Notice in each file and include | ||
the License file at legal/CDDLv1.0.txt. If applicable, add the following below the CDDL | ||
Header, with the fields enclosed by brackets [] replaced by your own identifying | ||
information: "Portions Copyright [year] [name of copyright owner]". | ||
Copyright 2024 3A Systems LLC | ||
! --> | ||
<adm:managed-object name="jdbc-backend" plural-name="jdbc-backends" | ||
package="org.forgerock.opendj.server.config" | ||
extends="pluggable-backend" xmlns:adm="http://opendj.forgerock.org/admin" | ||
xmlns:ldap="http://opendj.forgerock.org/admin-ldap" | ||
xmlns:cli="http://opendj.forgerock.org/admin-cli"> | ||
<adm:synopsis> | ||
A <adm:user-friendly-name/> stores application data in JDBC source. | ||
</adm:synopsis> | ||
<adm:description> | ||
It is the traditional "directory server" backend and is similar to | ||
the backends provided by the Sun Java System Directory Server. The | ||
<adm:user-friendly-name /> | ||
stores the entries in an encoded form and also provides indexes that | ||
can be used to quickly locate target entries based on different | ||
kinds of criteria. | ||
</adm:description> | ||
<adm:profile name="ldap"> | ||
<ldap:object-class> | ||
<ldap:name>ds-cfg-jdbc-backend</ldap:name> | ||
<ldap:superior>ds-cfg-pluggable-backend</ldap:superior> | ||
</ldap:object-class> | ||
</adm:profile> | ||
<adm:property-override name="java-class" advanced="true"> | ||
<adm:default-behavior> | ||
<adm:defined> | ||
<adm:value> | ||
org.opends.server.backends.jdbc.Backend | ||
</adm:value> | ||
</adm:defined> | ||
</adm:default-behavior> | ||
</adm:property-override> | ||
|
||
<adm:property name="db-directory" mandatory="true"> | ||
<adm:TODO>Default this to the db/backend-id</adm:TODO> | ||
<adm:synopsis> | ||
Specifies the connection string | ||
</adm:synopsis> | ||
<adm:description> | ||
jdbc:postgresql://localhost/test | ||
</adm:description> | ||
<adm:requires-admin-action> | ||
<adm:component-restart /> | ||
</adm:requires-admin-action> | ||
<adm:default-behavior> | ||
<adm:defined> | ||
<adm:value>jdbc:postgresql://localhost/test</adm:value> | ||
</adm:defined> | ||
</adm:default-behavior> | ||
<adm:syntax> | ||
<adm:string /> | ||
</adm:syntax> | ||
<adm:profile name="ldap"> | ||
<ldap:attribute> | ||
<ldap:name>ds-cfg-db-directory</ldap:name> | ||
</ldap:attribute> | ||
</adm:profile> | ||
</adm:property> | ||
</adm:managed-object> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
31 changes: 31 additions & 0 deletions
31
opendj-server-legacy/src/main/java/org/opends/server/backends/jdbc/Backend.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
/* | ||
* The contents of this file are subject to the terms of the Common Development and | ||
* Distribution License (the License). You may not use this file except in compliance with the | ||
* License. | ||
* | ||
* You can obtain a copy of the License at legal/CDDLv1.0.txt. See the License for the | ||
* specific language governing permission and limitations under the License. | ||
* | ||
* When distributing Covered Software, include this CDDL Header Notice in each file and include | ||
* the License file at legal/CDDLv1.0.txt. If applicable, add the following below the CDDL | ||
* Header, with the fields enclosed by brackets [] replaced by your own identifying | ||
* information: "Portions Copyright [year] [name of copyright owner]". | ||
* | ||
* Copyright 2024 3A Systems, LLC. | ||
*/ | ||
package org.opends.server.backends.jdbc; | ||
|
||
import org.forgerock.opendj.config.server.ConfigException; | ||
import org.forgerock.opendj.server.config.server.JDBCBackendCfg; | ||
import org.opends.server.backends.pluggable.BackendImpl; | ||
import org.opends.server.core.ServerContext; | ||
|
||
public class Backend extends BackendImpl<JDBCBackendCfg>{ | ||
|
||
@Override | ||
protected Storage configureStorage(JDBCBackendCfg cfg, ServerContext serverContext) throws ConfigException | ||
{ | ||
return new Storage(cfg, serverContext); | ||
} | ||
|
||
} |
Oops, something went wrong.