DZone
Thanks for visiting DZone today,
Edit Profile
  • Manage Email Subscriptions
  • How to Post to DZone
  • Article Submission Guidelines
Sign Out View Profile
  • Post an Article
  • Manage My Drafts
Over 2 million developers have joined DZone.
Log In / Join
Refcards Trend Reports
Events Video Library
Refcards
Trend Reports

Events

View Events Video Library

Zones

Culture and Methodologies Agile Career Development Methodologies Team Management
Data Engineering AI/ML Big Data Data Databases IoT
Software Design and Architecture Cloud Architecture Containers Integration Microservices Performance Security
Coding Frameworks Java JavaScript Languages Tools
Testing, Deployment, and Maintenance Deployment DevOps and CI/CD Maintenance Monitoring and Observability Testing, Tools, and Frameworks
Culture and Methodologies
Agile Career Development Methodologies Team Management
Data Engineering
AI/ML Big Data Data Databases IoT
Software Design and Architecture
Cloud Architecture Containers Integration Microservices Performance Security
Coding
Frameworks Java JavaScript Languages Tools
Testing, Deployment, and Maintenance
Deployment DevOps and CI/CD Maintenance Monitoring and Observability Testing, Tools, and Frameworks

Last call! Secure your stack and shape the future! Help dev teams across the globe navigate their software supply chain security challenges.

Modernize your data layer. Learn how to design cloud-native database architectures to meet the evolving demands of AI and GenAI workloads.

Releasing software shouldn't be stressful or risky. Learn how to leverage progressive delivery techniques to ensure safer deployments.

Avoid machine learning mistakes and boost model performance! Discover key ML patterns, anti-patterns, data strategies, and more.

Related

  • Graceful Shutdown: Spring Framework vs Golang Web Services
  • Build a REST API With Just 2 Classes in Java and Quarkus
  • Dropwizard vs. Micronaut: Unpacking the Best Framework for Microservices
  • How Stalactite ORM Implements Its Fluent DSL

Trending

  • Enhancing Security With ZTNA in Hybrid and Multi-Cloud Deployments
  • Understanding and Mitigating IP Spoofing Attacks
  • It’s Not About Control — It’s About Collaboration Between Architecture and Security
  • Using Python Libraries in Java
  1. DZone
  2. Coding
  3. Frameworks
  4. Learn How to Rapidly Create a Customized CMS with this Java Framework!

Learn How to Rapidly Create a Customized CMS with this Java Framework!

A look at how this CMS allows you to focus on one thing and one thing only, the definition of your own domain.

By 
Ryan Susana user avatar
Ryan Susana
·
Mar. 14, 19 · Analysis
Likes (8)
Comment
Save
Tweet
Share
15.2K Views

Join the DZone community and get the full member experience.

Join For Free

Over the years of being a freelance developer for small to medium businesses, there has been one constant, CRUD applications. They usually consisted of some sort of ‘backend’ that handled the content of an app or website.

Well, for a website, the solution is easy; Wordpress, or maybe Joomla?

Well what, about apps? Back to square one...

I Present to You, Elepy.

Elepy (also on GitHub) is an open-source Headless Content Management Framework for Java and Kotlin. The framework comes bundled with an Admin Control Panel that lets you easily control your content.

The framework lets you focus on one thing and one thing only, the definition of your own domain.

Don’t Believe Me? Just Watch!

Creation of a content type is as easy as annotating the POJOs that define your domain.

import com.elepy.annotations.*;
import com.elepy.models.TextType;

@RestModel(slug = "/products", name = "Name")
public class Product {

    @Identifier
    private String id;

    @Number(minimum = 0)
    private BigDecimal price;

    @Unique
    @Searchable
    private String name;

    @DateTime(maxDate = "2050-01-01")
    private Date expirationDate;

    @Text(TextType.TEXTAREA)
    private String shortDescription;

    @Text(TextType.HTML)
    @PrettyName("This is a detailed description of the Product")
    private String longDescription;


    // Getters and setters. I like to use Project Lombok to automate this :D

}


What about the Database?

Well by default, Elepy uses MongoDB, but provides support for the different flavors of SQL through a Hibernate/JPA extension.

import com.elepy.Elepy;
import com.elepy.admin.ElepyAdminPanel;
import com.mongodb.DB;
import com.mongodb.MongoClient;

public class Main {

    public static void main(String[] args) {

        MongoClient mongoClient = someMongoClientWithConfiguration; // Configure your MongoClient
        DB exampleDB = mongoClient.getDB("example1");

        new Elepy()
                .connectDB(exampleDB)
                .onPort(7777)
                .addModel(Product.class)
                .addExtension(new ElepyAdminPanel())

                //Start Elepy!
                .start();
    }

}

Well, What Now?

That’s it, you just created a CMS!

By navigating to http://localhost:7777/admin, you can log in and administrate your content. Username and Password (in version 1): admin

What Else Can Elepy Do?

Well, it’s a long list. A growing list, because Elepy 2 is under construction! To name a few features: pagination, searching, sorting, and 25+ annotations.

But the true beauty of Elepy lies in its customizability and extendability. It has an entire plugin/module ecosystem, a dependency injection micro-framework, and a routing micro-framework that you can make use of. The best part is that every part of the framework can be extended or replaced. Everything from the presentation to the data access layer.

Keep Up With Elepy

  • Find documentation on https://elepy.com and https://docs.elepy.com
  • (please) Star, follow and contribute to the project on GitHub
  • Google Slides: The Elepy Presentation
  • Elepy Example Repo
Content management system Framework Java (programming language)

Opinions expressed by DZone contributors are their own.

Related

  • Graceful Shutdown: Spring Framework vs Golang Web Services
  • Build a REST API With Just 2 Classes in Java and Quarkus
  • Dropwizard vs. Micronaut: Unpacking the Best Framework for Microservices
  • How Stalactite ORM Implements Its Fluent DSL

Partner Resources

×

Comments

The likes didn't load as expected. Please refresh the page and try again.

ABOUT US

  • About DZone
  • Support and feedback
  • Community research
  • Sitemap

ADVERTISE

  • Advertise with DZone

CONTRIBUTE ON DZONE

  • Article Submission Guidelines
  • Become a Contributor
  • Core Program
  • Visit the Writers' Zone

LEGAL

  • Terms of Service
  • Privacy Policy

CONTACT US

  • 3343 Perimeter Hill Drive
  • Suite 100
  • Nashville, TN 37211
  • support@dzone.com

Let's be friends: