Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 12 additions & 9 deletions .github/workflows/docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ on:
# push:
# branches: [main]
# paths:
# - 'docs/**'
# - 'spring-data-valkey/src/main/resources/io/valkey/springframework/data/valkey/config/spring-valkey-1.0.xsd'
# - "docs/**"
# - "spring-data-valkey/src/main/resources/io/valkey/springframework/data/valkey/config/spring-valkey-1.0.xsd"

permissions:
contents: read
Expand All @@ -31,7 +31,7 @@ jobs:
with:
node-version: "20"
cache: "npm"
cache-dependency-path: docs/package-lock.json
cache-dependency-path: "docs/package-lock.json"

- name: Setup JDK
uses: actions/setup-java@v4
Expand All @@ -46,21 +46,24 @@ jobs:
run: npm ci
working-directory: ./docs

- name: Build Astro docs
run: npm run build
working-directory: ./docs

- name: Generate JavaDocs
run: |
./mvnw javadoc:javadoc -pl spring-data-valkey -DskipTests
mkdir -p docs/dist/api/java
cp -r spring-data-valkey/target/site/apidocs/* docs/dist/api/java/
./mvnw javadoc:javadoc -pl spring-boot-starter-data-valkey -DskipTests
mkdir -p docs/dist/spring-data-valkey/api/java
mkdir -p docs/dist/spring-boot-starter-data-valkey/api/java
cp -r spring-data-valkey/target/reports/apidocs/* docs/dist/spring-data-valkey/api/java/
cp -r spring-boot-starter-data-valkey/target/reports/apidocs/* docs/dist/spring-boot-starter-data-valkey/api/java/

- name: Copy Schema
run: |
mkdir -p docs/dist/schema/valkey
cp spring-data-valkey/src/main/resources/io/valkey/springframework/data/valkey/config/spring-valkey-1.0.xsd docs/dist/schema/valkey/

- name: Build docs
run: npm run build
working-directory: ./docs

- name: Upload artifact
uses: actions/upload-pages-artifact@v3
with:
Expand Down
2 changes: 0 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,5 @@ appendonlydir
build/
node_modules
node
package-lock.json
package.json
.mvn/.develocity
.flattened-pom.xml
57 changes: 41 additions & 16 deletions DEVELOPER.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ Spring Data Valkey is organized as a multi-module Maven project:
* **[`spring-data-valkey`](spring-data-valkey/)** - Core Spring Data Valkey library
* **[`spring-boot-starter-data-valkey`](spring-boot-starter-data-valkey/)** - Spring Boot starter for auto-configuration
* **[`examples`](examples/)** - Example applications demonstrating various Spring Data features
* **[`performance`](performance/)** - Performance testing and benchmarking tools

## Prerequisites

Expand Down Expand Up @@ -99,19 +98,6 @@ $ ./mvnw -q exec:java -pl examples/spring-boot

For detailed information about all available examples and their specific features, see the [examples](examples/) directory.

## Performance Testing

```bash
# Default performance test with infrastructure management
$ make performance

# Test with different clients against existing Valkey instance
$ ./mvnw -q exec:java -pl performance -Dclient=valkeyglide
$ ./mvnw -q exec:java -pl performance -Dclient=lettuce
```

For detailed information about all available performance tests and benchmarking options, see the [performance](performance/) directory.

## Logging Configuration

### Spring Boot
Expand Down Expand Up @@ -156,6 +142,45 @@ For non-Spring Boot applications, configure logging via `logback.xml` in your cl
</configuration>
```

## Redis Source Alignment

This repository is forked from Spring Data Redis and related projects. This section documents the source repositories to help with future upgrades, patches, and alignment.

| Local Module | Redis Source Repository | Branch/Tag | Notes |
|--------------|------------------------|------------|-------|
| `./` | [spring-data-build](https://github.com/spring-projects/spring-data-build) | `3.5.1` | Parent for Spring Data modules |
| `spring-data-valkey/` | [spring-data-redis](https://github.com/spring-projects/spring-data-redis) | `3.5.1` | Core Spring Data Redis functionality |
| `spring-boot-starter-data-valkey/` | [spring-boot](https://github.com/spring-projects/spring-boot) | `3.5.1` | Spring Boot auto-configuration for Redis |
| `docs/` | [spring-data-redis](https://github.com/spring-projects/spring-data-redis) | `3.5.1` | Documentation |
| `examples/` | [spring-data-examples](https://github.com/spring-projects/spring-data-examples) | `main` | Redis examples |

Key changes from Redis source:
- **Package names**:
- Spring Data: `org.springframework.data.redis.*` → `io.valkey.springframework.data.valkey.*`
- Spring Boot: `org.springframework.boot.*.redis.*` → `io.valkey.springframework.boot.*.valkey.*`
- **Class names and properties**: `*Redis*` → `*Valkey*` or `*redis*` → `*valkey*`
- **Dependencies**:
- Spring Data: `org.springframework.data:spring-data-redis` → `io.valkey.springframework.data:spring-data-valkey`
- Spring Boot: `org.springframework.boot:spring-boot-starter-data-redis` → `io.valkey.springframework.boot:spring-boot-starter-data-valkey`
- **Driver support**: Added Valkey GLIDE as the primary driver
- **Documentation**: Migrated from Antora/AsciiDoc to Starlight/Markdown

## Deploying Documentation

The documentation is deployed to GitHub Pages using GitHub Actions. This includes the Astro Starlight documentation under `docs/`, as well as the Spring Data Valkey JavaDocs and schema.

Manually trigger the *Docs* workflow in GitHub Actions for a given branch to deploy the documentation on that branch. The documentation will then be available at `https://valkey-io.github.io/spring-data-valkey/` or `https://spring.valkey.io` (CNAME redirect).

### Local Development

```bash
$ cd docs
$ npm install
$ npm run dev
```

The documentation will be available at `http://localhost:4321/`.

## Release Process

### Version Management
Expand Down Expand Up @@ -195,6 +220,6 @@ $ git push origin v1.0.0
## Additional Resources

* [Valkey Documentation](https://valkey.io/docs/)
* [Spring Data Documentation](https://docs.spring.io/spring-data/redis/reference/)
* [Valkey GLIDE Client](https://github.com/valkey-io/valkey-glide)
* [Valkey GLIDE Java Client Reference](https://glide.valkey.io/languages/java/)
* [Spring Data Reference](https://spring.io/projects/spring-data)
* [Spring Boot Reference](https://docs.spring.io/spring-boot/reference/)
8 changes: 4 additions & 4 deletions MIGRATION.md
Original file line number Diff line number Diff line change
Expand Up @@ -444,7 +444,7 @@ $ find path/to/project -type f \( -name "*.java" -o -name "*.properties" -o -nam

## Additional Resources

- [Valkey Documentation](https://valkey.io/docs/)
- [Valkey GLIDE](https://github.com/valkey-io/valkey-glide)
- [Spring Data Redis Documentation](https://docs.spring.io/spring-data/redis/reference/)
- [Spring Data Redis](https://github.com/spring-projects/spring-data-redis)
- [Valkey GLIDE Java Client Reference](https://glide.valkey.io/languages/java/)
- [Spring Data Valkey Reference](https://spring.valkey.io/)
- [Spring Data Redis Reference](https://docs.spring.io/spring-data/redis/reference/)
- [Spring Boot Reference](https://docs.spring.io/spring-boot/reference/)
7 changes: 7 additions & 0 deletions NOTICE.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
Spring Data Valkey
Copyright 2025-2026 Amazon.com, Inc. or its affiliates

This product is a derivative work based on Spring Data Redis.
Original work Copyright 2008-2024 VMware, Inc.

This product includes software developed by VMware, Inc. (https://spring.io/)
5 changes: 2 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -131,10 +131,9 @@ If you're migrating from Spring Data Redis, see the [Migration Guide](MIGRATION.

## Documentation

For general usage patterns and API documentation, refer to:
* [Spring Data Redis Reference Documentation](https://docs.spring.io/spring-data/redis/reference/) - Most concepts apply to Valkey
* [Spring Data Valkey Reference](https://spring.valkey.io/) - For general usage patterns and API documentation
* [Valkey Documentation](https://valkey.io/docs/) - For Valkey-specific features and commands

## License

Spring Data Valkey is Open Source software released under the [Apache 2.0 license](https://www.apache.org/licenses/LICENSE-2.0.html).
Spring Data Valkey is Open Source software released under the Apache 2.0 license. See [LICENSE.txt](LICENSE.txt) and [NOTICE.txt](NOTICE.txt) for details.
6 changes: 6 additions & 0 deletions docs/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
.astro/
dist/
node_modules/

.env
.env.production
90 changes: 90 additions & 0 deletions docs/astro.config.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,90 @@
// @ts-check
import { defineConfig } from 'astro/config';
import starlight from '@astrojs/starlight';
import rehypeExternalLinks from 'rehype-external-links';

// https://astro.build/config
export default defineConfig({
site: 'https://spring.valkey.io',
markdown: {
rehypePlugins: [
[rehypeExternalLinks, { target: '_blank', rel: ['noopener', 'noreferrer'] }]
]
},
integrations: [
starlight({
title: 'Spring Data Valkey',
logo: {
light: './src/assets/spring-data-valkey-logo-with-name-light.svg',
dark: './src/assets/spring-data-valkey-logo-with-name-dark.svg',
replacesTitle: true,
},
customCss: ['./src/styles/custom.css', './src/styles/code-wrap.css'],
favicon: '/favicon-32x32.png',
social: [
{ icon: 'github', label: 'GitHub', href: 'https://github.com/valkey-io/spring-data-valkey' }
],
sidebar: [
{
label: 'Overview',
items: [
{ label: 'Spring Data Valkey', slug: 'overview' },
{ label: 'Spring Boot', slug: 'commons/spring-boot' },
{ label: 'Features', slug: 'commons/features' },
{ label: 'Migrating Spring Data', slug: 'commons/migration' },
]
},
{
label: 'Valkey',
items: [
{ label: 'Valkey Overview', slug: 'valkey' },
{ label: 'Getting Started', slug: 'valkey/getting-started' },
{ label: 'Drivers', slug: 'valkey/drivers' },
{ label: 'Connection Modes', slug: 'valkey/connection-modes' },
{ label: 'ValkeyTemplate', slug: 'valkey/template' },
{ label: 'Valkey Cache', slug: 'valkey/valkey-cache' },
{ label: 'Cluster', slug: 'valkey/cluster' },
{ label: 'Hash Mapping', slug: 'valkey/hash-mappers' },
{ label: 'Pub/Sub Messaging', slug: 'valkey/pubsub' },
{ label: 'Valkey Streams', slug: 'valkey/valkey-streams' },
{ label: 'Scripting', slug: 'valkey/scripting' },
{ label: 'Valkey Transactions', slug: 'valkey/transactions' },
{ label: 'Pipelining', slug: 'valkey/pipelining' },
{ label: 'Support Classes', slug: 'valkey/support-classes' },
]
},
{
label: 'Valkey Repositories',
items: [
{ label: 'Valkey Repositories Overview', slug: 'repositories' },
{ label: 'Core concepts', slug: 'repositories/core-concepts' },
{ label: 'Defining Repository Interfaces', slug: 'repositories/definition' },
{ label: 'Creating Repository Instances', slug: 'repositories/create-instances' },
{ label: 'Usage', slug: 'valkey/valkey-repositories/usage' },
{ label: 'Object Mapping Fundamentals', slug: 'repositories/object-mapping' },
{ label: 'Object-to-Hash Mapping', slug: 'valkey/valkey-repositories/mapping' },
{ label: 'Keyspaces', slug: 'valkey/valkey-repositories/keyspaces' },
{ label: 'Secondary Indexes', slug: 'valkey/valkey-repositories/indexes' },
{ label: 'Time To Live', slug: 'valkey/valkey-repositories/expirations' },
{ label: 'Valkey-specific Query Methods', slug: 'valkey/valkey-repositories/queries' },
{ label: 'Query by Example', slug: 'valkey/valkey-repositories/query-by-example' },
{ label: 'Valkey Repositories Running on a Cluster', slug: 'valkey/valkey-repositories/cluster' },
{ label: 'Valkey Repositories Anatomy', slug: 'valkey/valkey-repositories/anatomy' },
{ label: 'Projections', slug: 'repositories/projections' },
{ label: 'Custom Repository Implementations', slug: 'repositories/custom-implementations' },
{ label: 'Publishing Events from Aggregate Roots', slug: 'repositories/core-domain-events' },
{ label: 'Null Handling of Repository Methods', slug: 'repositories/null-handling' },
{ label: 'CDI Integration', slug: 'valkey/valkey-repositories/cdi-integration' },
{ label: 'Repository query keywords', slug: 'repositories/query-keywords-reference' },
{ label: 'Repository query return types', slug: 'repositories/query-return-types-reference' },
]
},
{ label: 'Observability', slug: 'observability' },
{ label: 'Appendix', slug: 'appendix' },
{ label: 'Valkey Project ↗', link: 'https://valkey.io/', attrs: { target: '_blank' } },
{ label: 'Javadoc ↗', link: 'https://spring.valkey.io/spring-data-valkey/api/java/index.html', attrs: { target: '_blank' } },
{ label: 'Spring Boot Javadoc ↗', link: 'https://spring.valkey.io/spring-boot-starter-data-valkey/api/java/index.html', attrs: { target: '_blank' } },
],
}),
],
});
Loading