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
Over 2 million developers have joined DZone. Join Today! Thanks for visiting DZone today,
Edit Profile Manage Email Subscriptions Moderation Admin Console How to Post to DZone Article Submission Guidelines
View Profile
Sign Out
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

Migrate, Modernize and Build Java Web Apps on Azure: This live workshop will cover methods to enhance Java application development workflow.

Kubernetes in the Enterprise: The latest expert insights on scaling, serverless, Kubernetes-powered AI, cluster security, FinOps, and more.

A Guide to Continuous Integration and Deployment: Learn the fundamentals and understand the use of CI/CD in your apps.

Related

  • Java 21 Is a Major Step for Java: Non-Blocking IO and Upgraded ZGC
  • A PDF Framework That Solves the Pain Points of Enterprise Development
  • Automate Migration Assessment With XML Linter
  • Smart BDD vs. Cucumber Using Java and JUnit5

Trending

  • How to Submit a Post to DZone
  • Modern Application Performance
  • A Roadmap to True Observability
  • CI/CD Software Design Patterns and Anti-Patterns
  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.

Ryan Susana user avatar by
Ryan Susana
·
Mar. 14, 19 · Analysis
Like (8)
Save
Tweet
Share
14.8K 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

  • Java 21 Is a Major Step for Java: Non-Blocking IO and Upgraded ZGC
  • A PDF Framework That Solves the Pain Points of Enterprise Development
  • Automate Migration Assessment With XML Linter
  • Smart BDD vs. Cucumber Using Java and JUnit5

Comments

Partner Resources

X

ABOUT US

  • About DZone
  • Send feedback
  • Careers
  • 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: