Skip to content

Commit ce0802d

Browse files
NataliaIvakinaAlexicaWrightlidiazuinrenetapopovaloveleif
authored
Release 5.26 (#237)
* bump dev to 5.21 (#205) * Replacing underscores with hyphens for crawlability (#206) * Bump Neo4j version to 5.22 and driver v to 5.23 (#208) * Update `dev` to 5.23 (#213) * Bump version number to 5.24 (#215) * Update preview version to 5.25 (#220) * Add documentation for user procedure memory resource tracking * Bump the Neo4j v.n. to 5.25 and the Java driver to 5.26.1 (#227) * Bump express in the dev-dependencies group across 1 directory (#224) Bumps the dev-dependencies group with 1 update in the / directory: [express](https://github.com/expressjs/express). Updates `express` from 4.19.1 to 4.21.1 - [Release notes](https://github.com/expressjs/express/releases) - [Changelog](https://github.com/expressjs/express/blob/4.21.1/History.md) - [Commits](expressjs/express@4.19.1...4.21.1) --- updated-dependencies: - dependency-name: express dependency-type: direct:development update-type: version-update:semver-minor dependency-group: dev-dependencies ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * Fix the code example (#228) * Update setup.adoc (#222) (#230) gradle "compile" deprecated in version 7.x - replaced by "implementation." Correcting. Co-authored-by: Q | Andrew Righter <[email protected]> * Introduce DatabaseSeedProvider and deprecated SeedProvider * Update modules/ROOT/pages/extending-neo4j/project-setup.adoc Co-authored-by: NataliaIvakina <[email protected]> * Update modules/ROOT/pages/extending-neo4j/project-setup.adoc Co-authored-by: NataliaIvakina <[email protected]> * Update modules/ROOT/pages/extending-neo4j/project-setup.adoc Co-authored-by: NataliaIvakina <[email protected]> * Update modules/ROOT/pages/extending-neo4j/project-setup.adoc Co-authored-by: NataliaIvakina <[email protected]> * Update modules/ROOT/pages/extending-neo4j/project-setup.adoc Co-authored-by: NataliaIvakina <[email protected]> * Update modules/ROOT/pages/extending-neo4j/project-setup.adoc Co-authored-by: NataliaIvakina <[email protected]> * Update modules/ROOT/pages/extending-neo4j/project-setup.adoc Co-authored-by: NataliaIvakina <[email protected]> * Update driver version (#234) --------- Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: Jessica Wright <[email protected]> Co-authored-by: Lidia Zuin <[email protected]> Co-authored-by: Reneta Popova <[email protected]> Co-authored-by: Love Kristofer Leifland <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Q | Andrew Righter <[email protected]> Co-authored-by: Jack Waudby <[email protected]> Co-authored-by: Jack Waudby <[email protected]>
1 parent 810a9e7 commit ce0802d

File tree

4 files changed

+183
-103
lines changed

4 files changed

+183
-103
lines changed

antora.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,10 +6,10 @@ nav:
66
- modules/ROOT/content-nav.adoc
77
asciidoc:
88
attributes:
9-
neo4j-version: '5.25'
10-
neo4j-version-exact: '5.25.1'
11-
neo4j-buildnumber: '5.25'
12-
java-driver-version: '5.26.3'
9+
neo4j-version: '5.26'
10+
neo4j-version-exact: '5.26.0'
11+
neo4j-buildnumber: '5.26'
12+
java-driver-version: '5.27.0'
1313
neo4j-documentation-branch: 'dev'
1414
page-origin-private: false
1515
neo4j-javadocs-base-uri: "https://neo4j.com/docs/java-reference/5/javadocs"

modules/ROOT/pages/extending-neo4j/project-setup.adoc

Lines changed: 59 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -156,6 +156,65 @@ Include this dependency to build against the Neo4j-provided API:
156156

157157
=== Implement Java class
158158

159+
[role=label--new-5.26]
160+
==== `DatabaseSeedProvider`
161+
162+
In Neo4j 5.26, the `DatabaseSeedProvider` was introduced to replace the now-deprecated `SeedProvider`.
163+
164+
[source, java]
165+
----
166+
import com.neo4j.dbms.seeding.DatabaseSeedProvider;
167+
168+
public class CustomDatabaseSeedProvider implements DatabaseSeedProvider {
169+
170+
@Override
171+
public boolean matches(String uri) {
172+
// Return true if uri is supported by this
173+
// provider.
174+
}
175+
176+
@Override
177+
public InputStream stream(
178+
String uri,
179+
Map<String, Object> options) throws IOException {
180+
// This method should obtain an input stream in an
181+
// implementation specific way.
182+
}
183+
184+
@Override
185+
public void inject(Dependencies dependencies) {
186+
// This method should provide implementation
187+
// specific dependencies to the provider.
188+
}
189+
190+
public static class CustomDependencies implements Dependencies {
191+
@Override
192+
public <T> T resolveDependency(Class<T> type) {
193+
// This method should resolve dependencies
194+
// required by the provider.
195+
}
196+
}
197+
}
198+
----
199+
200+
To implement the custom database seed provider, you must define three methods on the top-level `DatabaseSeedProvider` interface:
201+
202+
* A method to match the URIs that the provider can manage.
203+
* A method to stream backups or dumps from a specified URI.
204+
* A method to inject dependencies in the provider.
205+
206+
Additionally, you must implement a method on the nested `Dependencies` interface to resolve any dependencies required by your seed provider implementation.
207+
208+
Typically, the match method uses the URI scheme (the part specified before the first colon) to determine whether it can support the given URI or not.
209+
For example, `file`, `http`, `https` etc.
210+
211+
The stream method should implement a scheme-specific way to obtain an input stream for the backup or dump.
212+
213+
Implementation-specific seed configuration can be passed through from options specified in the `CREATE DATABASE` command using `seedConfig`.
214+
215+
[role=label--deprecated-5.26]
216+
==== `SeedProvider`
217+
159218
[source, java]
160219
----
161220
import com.neo4j.dbms.seeding.ParsedSeedProviderConfig;

0 commit comments

Comments
 (0)