All Projects → contentacms → Contentajs

contentacms / Contentajs

Licence: mit
A nodejs server that proxies to Contenta CMS and holds custom code.

Programming Languages

javascript
184084 projects - #8 most used programming language

Projects that are alternatives of or similar to Contentajs

Laravel Zero
A PHP framework for console artisans
Stars: ✭ 2,821 (+3034.44%)
Mutual labels:  application, performance
Nodepress
😎 RESTful API service for Blog/CMS, powered by @nestjs
Stars: ✭ 829 (+821.11%)
Mutual labels:  cms, express
Home
Project Glimpse: Node Edition - Spend less time debugging and more time developing.
Stars: ✭ 260 (+188.89%)
Mutual labels:  express, performance
Tensei
🚀 Content management and distribution with a touch of elegance.
Stars: ✭ 217 (+141.11%)
Mutual labels:  cms, express
Stationery Cms
💡基于laravel-admin1.6.0开发的办公用品管理系统,含excel导出、查询快递功能
Stars: ✭ 37 (-58.89%)
Mutual labels:  cms, express
Notadd
A microservice development architecture based on nest.js. —— 基于 Nest.js 的微服务开发架构。
Stars: ✭ 2,556 (+2740%)
Mutual labels:  cms, express
Vue 163 Music
【停止维护】网易云音乐web版,支持PC端常用功能,localStorage保存播放列表
Stars: ✭ 788 (+775.56%)
Mutual labels:  express, proxy
Fiber
⚡️ Express inspired web framework written in Go
Stars: ✭ 17,334 (+19160%)
Mutual labels:  express, performance
Essay
A blog system based on Nuxt.js
Stars: ✭ 913 (+914.44%)
Mutual labels:  cms, express
Blender
The Laravel template used for our CMS like projects
Stars: ✭ 862 (+857.78%)
Mutual labels:  application, cms
Cms
GleezCMS - A Light, Simple, Flexible Content Management System
Stars: ✭ 200 (+122.22%)
Mutual labels:  cms, performance
Mern Stack Authentication
Secure MERN Stack CRUD Web Application using Passport.js Authentication
Stars: ✭ 60 (-33.33%)
Mutual labels:  application, express
Payload
Headless CMS and Application Framework built with Node.js, React and MongoDB
Stars: ✭ 154 (+71.11%)
Mutual labels:  cms, express
Portfusion
Haskell-powered cross-platform transport-layer distributed reverse / forward proxy & tunneling solution – currently available for all TCP protocols (RDP, VNC, HTTP(S), SSH, ...).
Stars: ✭ 177 (+96.67%)
Mutual labels:  application, proxy
Porn Vault
💋 Manage your ever-growing porn collection. Using Vue & GraphQL
Stars: ✭ 1,634 (+1715.56%)
Mutual labels:  cms, express
Memoize State
The magic memoization for the State management. ✨🧠
Stars: ✭ 305 (+238.89%)
Mutual labels:  proxy, performance
Fortio
Fortio load testing library, command line tool, advanced echo server and web UI in go (golang). Allows to specify a set query-per-second load and record latency histograms and other useful stats.
Stars: ✭ 2,199 (+2343.33%)
Mutual labels:  proxy, performance
Bandwidth Hero Proxy
⚡️ Proxy that compresses images to low-resolution
Stars: ✭ 130 (+44.44%)
Mutual labels:  express, proxy
Mean Angular5 Passport Authentication
Securing MEAN Stack (Angular 5) Web Application using Passport Authentication
Stars: ✭ 24 (-73.33%)
Mutual labels:  application, express
Http Proxy Middleware
⚡ The one-liner node.js http-proxy middleware for connect, express and browser-sync
Stars: ✭ 8,730 (+9600%)
Mutual labels:  express, proxy

ContentaJS Contenta logo

ContentaJS is a project that integrates with Contenta CMS to provide an high performing headless CMS. It also provides a nodejs application where to host your Server Side Rendering and custom code integrations.

Contenta Stack Architecture

IMPORTANT: this project is meant to be a starting kit for the node integration of your application based on Contenta CMS. We do not provide upgrade paths or backwards compatibility. The model for this is Fork & Go.

Travis Coverage David Dependency Management Last Commit Node Documented with emdaer

Videos

Contenta JS: Introduction

Contenta JS video

Tutorial: Install Contenta CMS + Contenta JS

Contenta JS video

Why?

Contenta CMS (aka the Drupal part) is designed to serve your project’s content. ContentaJS (aka the node.js part) is designed to serve the requests to your client side applications. Some of those requests will end up requesting data from Contenta CMS, others won’t.

You may need ContentaJS because for many reasons you will end up needing a node.js server for your project anyways. You may as well use an opinionated and optimized starter kit that will solve many of your needs without effort.

Microservices

If your API needs to aggregate data for use on the front-end from other services you should not use PHP for that. That is because, in practice, all I/O in Drupal is blocking and the performance of these tasks is usually very poor.

Examples of this are:

  • Showing weather data from a 3rd party API.
  • If you need to make requests to an analytics tool.
  • If you need to run a request through an anti-fraud service before accessing the content.

In these situations you will want to treat Contenta CMS just as any other microservice. Then you will need a server, like this one written in node.js, to orchestrate the different microservices.

Server-Side Rendering

Chances are that you are building a website as part of your digital project. In most cases you will be using a front-end framework like React, Vue, Angular, etc. All of those frameworks recommend using server-side rendering for many reasons. In order to implement server-side rendering you will need a node.js server.

You can use this node.js server (aka ContentaJS) to implement server-side rendering on.

Performance

Your LAMP stack (or alternative) runs your Contenta CMS installation. We all know how flexible and powerful Drupal is. But at the same time it is not great from a performance point of view. In fact it can rapidly become your bottleneck.

With ContentaJS you can reduce the load in your LAMP stack. This is because you don’t even need to hit this stack to access cached responses. ContentaJS will fetch the data from cache, and will only check with Drupal when there is no cache. That reduces greatly the amount of requests Apache needs to process. This reduces the load on Drupal, hence improving performance overall.

ContentaJS integrates transparently with Contenta CMS and can analyze requests that will fail in Drupal. When that happens the request never hits Drupal thus reducing the load there. Examples of this are: a request to a non-existing resource, a request that contains a payload that doesn’t validate against the schema of the resource, etc.

Other

Other server tasks like executing actions on cron, or sending emails, etc. can be done in this node.js server (and/or the machine running it) instead of on the LAMP stack.

Features

This section is still under development.

The main features of this project cover:

  • Automatic integration with the API exposed by your Contenta CMS install. Just provide the URL of the site and everything is taken care of for you.
    • JSON API integration.
    • JSON RPC integration.
    • Subrequests integration.
    • Open API integration.
  • Multi-threaded nodejs server that takes advantage of all the cores of the server’s CPU.
  • A Subrequests server for request aggregation. Learn more about subrequests.
  • A Redis integration via @contentacms/redis.
  • Type safe development environment using Flow.
  • Configurable CORS.

Installation

In order to install ContentaJS you will need to meet the following requirements:

  • nodejs ^8.11.1 or higher. This corresponds to lts/carbon.
  • A working installation of Contenta CMS.
  • A Redis server (optional). Use the @contentacms/redis module to leverage the Redis cache back-end.

See the installation instructions.

Internal Development Notes

This is a dumping ground of notes. This section will disappear eventually, it’s just meant to save ideas for documentation to process some other time.

  • Introduce the ability to timeout requests.
  • Create a separate package using passport to integrate with Simple OAuth.
  • If all subrequests are to the CMS forward the blueprint to Drupal’s subrequests.
  • Compute the appropriate cache-control header from subquests responses.
  • Make sure to mention that the /healthckeck is for auto-scaling policies.
  • Create a @contentacms/redisShare submodule for a shared Redis server between Drupal and node.
  • Document that the proxied requests are not cached because they are considered end responses. The appropriate caching should be in the edge cache layer.
  • Make Cache-Control header overrides configurable.
  • Check feature conflict between cors.maxAge and OPTIONS cache control header.
  • Document better the JSON RPC support.
  • Add documentation about the cache controls

Contributors

Contributors
Mateu Aguiló Bosch

License

@contentacms/contentajs is MIT licensed.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].