Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
Bedrock Mission!

Learn more

View all

Sign in to view all badges

Adobe Summit 2023 [19th to 23rd March, Las Vegas and Virtual] | Complete AEM Session & Lab list

How to start sling with RDBMS | AEM Community Blog Seeding

Avatar

Administrator

BlogImage.jpg

How to start sling with RDBMS by Wemblog

Abstract

Prerequisite: Make sure that you have mysql or oracle install. Here is instruction https://dev.mysql.com/doc/mysql-installation-excerpt/5.7/en/

Currently sling comes out of the box with Tar and Mongo persistent manager but setting up RDBMS instruction is hard to find.

Note that sling underneath has Oak for data persistence and OAK does support different type of RDB persistence that you can get it from here. https://jackrabbit.apache.org/oak/docs/nodestore/document/rdb-document-store.html

Here are steps to set up RDB persistence for sling.

Step 1: Checkout sling project from https://sling.apache.org/downloads.cgi
example
git clone https://github.com/apache/sling-org-apache-sling-starter.git
OR
git clone https://github.com/apache/sling-org-apache-sling-app-cms.git

Step 2: find oak.txt either under src/main/provisioning or builder/src/main/provisioning

Step 3: Add the following lines in oak.txt

[artifacts startLevel=15 runModes=oak_rdb]
mysql/mysql-connector-java/8.0.20
com.h2database/h2-mvstore/1.4.194
org.apache.sling/org.apache.sling.datasource/1.0.4

org.apache.sling.datasource.DataSourceFactory-mysql.config
url="jdbc:mysql://localhost:3306/slingcms"
driverClassName="com.mysql.jdbc.Driver"
username="root"
password=""
datasource.name="oak"
validationQuery="show\ tables"
connectionProperties="serverTimezone\=UTC"
Step 4: Find boot.txt which is under the same folder where oak.txt was and append the following in property sling.run.mode.install.options

sling.run.mode.install.options=oak_tar,oak_mongo,oak_rdb

Read Full Blog

How to start sling with RDBMS

Q&A

Please use this thread to ask the related questions.

Topics

Topics help categorize Community content and increase your ability to discover relevant content.

0 Replies

The ultimate experience is back.

Join us in Vegas to build skills, learn from the world's top brands, and be inspired.

Register Now