Skip to content

Commit 0227f68

Browse files
committed
LDEV-6270 document maven cache providers
1 parent c3e4bb9 commit 0227f68

1 file changed

Lines changed: 21 additions & 0 deletions

File tree

docs/recipes/maven-based-extensions.md

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -107,6 +107,26 @@ jdbc: "[{'class':'org.postgresql.Driver','maven':'org.postgresql:postgresql:42.7
107107

108108
The `maven:` attribute tells Lucee to use Maven-style classloading (via `getRPCClassLoader()`) to find the class, rather than looking for it in OSGi bundles.
109109

110+
## Maven Based Cache Providers
111+
112+
OSGi-based cache extensions have always registered the cache class alongside the bundle that contains it, so Lucee can resolve the class later when a cache connection is created:
113+
114+
```
115+
cache: "[{'class':'org.lucee.extension.myCache.MyCache','bundle-name':'my.cache.bundle','bundle-version':'1.0.0'}]"
116+
```
117+
118+
Maven-based extensions work the same way — the manifest stores the class name and its Maven coordinates at install time:
119+
120+
```
121+
cache: "[{'class':'org.lucee.extension.aws.dynamodb.DynamoDBCache','maven':'org.lucee:dynamodb:1.0.0.0'}]"
122+
```
123+
124+
When a cache connection is later created using that class name — via the admin UI, application config, or programmatically — Lucee looks up the stored coordinates and loads the class via the Maven classloader.
125+
126+
Full support for all cache creation paths (including programmatic) landed in **7.1.0.93+**, **7.0.4.21+**, and **6.2.7.7+** ([LDEV-6270](https://luceeserver.atlassian.net/browse/LDEV-6270)).
127+
128+
See **[DynamoDB](https://github.com/lucee/extension-dynamodb)** for a complete reference implementation of this pattern.
129+
110130
## Maven Dependency Format (GAVSO)
111131

112132
Maven coordinates in Lucee use **colon-separated** Gradle-style notation:
@@ -239,6 +259,7 @@ The typical build process for a Maven-based extension:
239259
| --- | --- | --- | --- |
240260
| `/maven/` folder extraction from `.lex` || 7.0.0.68+ | 6.2.0.300+ |
241261
| Manifest `cache:`/`jdbc:` with `maven:` || 7.0.0.68+ | 6.2.0.285+ |
262+
| Maven cache provider (all creation paths) | 7.1.0.93+ | 7.0.4.21+ | 6.2.7.7+ |
242263
| `start-bundles: false` ||||
243264
| GAVSO coordinate parsing ||||
244265
| TLD `maven=` (custom tags) | 7.1.0.2+ | 7.0.2.86+ ||

0 commit comments

Comments
 (0)