Spring Content

Cloud-Native Headless Content Services for Spring.

For creating services that manage content such as documents, images and digital assets such as video.

Build your own cloud-native, scale-out headless content services using the exact same components as the Enterprise Content Management (ECM) vendors such as Documentum and OpenText, without the hassle.

Features

Modules

Coming Soon

Overview

spring-content-arch
Figure 1. understanding how Spring Content fits into the Spring eco-system

Quick Start

<dependency>
    <groupId>com.github.paulcwarren</groupId>
    <artifactId>spring-content-fs-boot-starter</artifactId>
    <version>0.0.6</version>
</dependency>

For a quick taste, look at the following domain object:

@Entity
public class SopDocument {

    private @Id @GeneratedValue Long id;
    private String title;
    private String[] authors, keywords;

    // Spring Content managed attribute
    private @ContentId String contentId;

    private SopDocument() {}
    public SopDocument(String title, String[] authors, String[] keywords)   {
        this.title = title;
        this.authors = authors;
        this.keywords = keywords;
    }
}

This defines a simple JPA entity with a few structured data fields; title, authors and keywords and one Spring Content-managed data field; @ContentId.

The structured data fields are handled in the usual way through a CrudRepository<SopDocument,String> interface.

Content is handled separately with a ContentStore interface:-

public interface SopDocumentContent extends ContentStore<SopDocument, String> {
}

This interface extends Spring Content’s ContentStore, defines the type (SopDocument) and the id type (String). Put this code inside a Spring Boot application with spring-boot-starter-data-jpa and spring-content-fs-boot-starter like this:

@SpringBootApplication
public class MyApp {

    public static void main(String[] args) {
        SpringApplication.run(MyApp.class, args);
    }
}

Launch your app and Spring Content (having been autoconfigured by Boot) will automatically craft a concrete set of operations for handling content associated with this Entity:

To see more following out first Getting Started Guide, or watch our SpringOne 2016 talk.

Reference Documentation

Module
Spring Content S3 Current Lastest Release
Spring Content Filesystem Current Lastest Release
Spring Content Mongo Current Lastest Release
Spring Content JPA Current Lastest Release
Spring Content REST Current Lastest Release