light-4j - A fast, lightweight and more productive microservices framework

  •        451

Light 4j is a fast, lightweight and cloud native microservices framework. Light means lightweight, lighting fast and shed light on how to program with modern Java SE. It is 44 times faster than the most popular microservices platform Spring Boot embedded Tomcat and use only 1/5 of memory.

Its features include:

  • Plugin architecture for startup/shutdown hooks and middleware components
  • Distributed OAuth2 JWT security verification as part of the framework
  • Request and response validation against OpenAPI specification at runtime
  • Metrics collected in influxdb and viewed from Grafana Dashboard for both services and clients
  • Global exception handling for runtime exception, api exception and other checked exceptions
  • Mask sensitive data like credit card, sin number etc. before logging
  • Sanitize cross site scripting for query parameters, request headers and body
  • Audit to dump important info or entire request and response.
  • Body parser to support different content types
  • Standardized response code and messages from configuration file
  • Externalized configuration for all modules for dockerized environment
  • CORS pre-flight handler for SPA (Angular or React) from another domain
  • Rate limiting for services that exposed outside to the Internet
  • Service registry and discovery support direct, Consul and Zookeeper
  • Client side discovery and load balance to eliminate proxies
  • A client module that is tightly integrated with Light-OAuth2 and supports traceability

https://github.com/networknt/light-4j

Tags
Implementation
License
Platform

   




Related Projects

Kong - The Microservice API Gateway

  •    Lua

Kong is a cloud-native, fast, scalable, and distributed Microservice Abstraction Layer (also known as an API Gateway, API Middleware or in some cases Service Mesh). Backed by the battle-tested NGINX with a focus on high performance, Kong was made available as an open-source platform in 2015. Under active development, Kong is used in production at thousands of organizations from startups, Global 5000 and Government organizations.

Micronaut - A modern, JVM-based, full-stack framework for building modular, easily testable microservice and serverless applications

  •    Java

Micronaut is a modern, JVM-based, full stack microservices framework designed for building modular, easily testable microservice applications. Micronaut is developed by the creators of the Grails framework and takes inspiration from lessons learnt over the years building real-world applications from monoliths to microservices using Spring, Spring Boot and Grails.

Xenon - Decentralized Control Plane Framework

  •    Java

Xenon is a framework for writing small REST-based services. (Some people call them microservices.) The runtime is implemented in Java and acts as the host for the lightweight, asynchronous services. The programming model is language agnostic (does not rely on Java specific constructs) so implementations in other languages are encouraged. The services can run on a set of distributed nodes. Xenon provides replication, synchronization, ordering, and consistency for the state of the services. Because of the distributed nature of Xenon, the services scale well and are highly available.

Apache Juneau - Single cohesive framework

  •    Java

Apache Juneau is a single cohesive Java ecosystem consisting of the following parts juneau-marshall, juneau-dto, juneau-svl, juneau-config, juneau-rest-server, juneau-rest-client, juneau-microservice.

Javalin - A Simple REST API Library for Java / Kotlin

  •    Java

Javalin is a very lightweight web framework for Kotlin and Java, inspired by Sparkjava and koa.js. Javalin is written in Kotlin with a few functional interfaces written in Java. This was necessary to provide an enjoyable and near identical experience for both Kotlin and Java developers.


Spincast is an highly flexible and open source Java web framework, based on Guice

  •    Java

Spincast is a framework to serve as a backend for Single Page Applications (SPA), to develop old-school HTML generated websites or to be a REST API services platform. Spincast aims to feel more like a library than like a framework. It is not opinionated and favors configuration over convention. Its main goal is to give power to the developers.

swoft - ⚡️ Modern High performance AOP and Coroutine PHP Framework, base on Swoole

  •    PHP

The first high-performance PHP coroutine full-stack componentization framework based on Swoole native coroutine, built-in coroutine web server and commonly-used coroutine client, resident memory, which has no dependency on PHP-FPM, asynchronous non-blocking IO implementation, similar to synchronous client style of writing to achieve the use of asynchronous clients, without complex asynchronous callback, no tedious yield, similar Go language coroutines, flexible annotations framework, a powerful global dependency injection container base on annotations, and great service governance , flexible and powerful AOP, PSR specification implementation, etc., could be used to build high-performance Web systems, APIs, middleware, basic services, microservice and so on. Chinese Document English Document Not yet, please help us write it.

RESTX - the lightweight Java REST framework

  •    Java

RESTX is the lightweight, modular, feature rich, blazing fast, open source Java REST framework. It shares similarities with modern frameworks like Play! like hot compile and a very productive experience, but focused on REST and pure Java.

Kanary - A minimalist web framework for building REST APIs in Kotlin/Java.

  •    Kotlin

A light weight🏋🏿 Kotlin web framework for building🔩⚙ highly scalable📈 web APIs

micro-server - Microserver is a Java 8 native, zero configuration, standards based, battle hardened library to run Java Rest Microservices via a standard Java main class

  •    Java

Microserver is a Java 8 native, zero configuration, standards based, battle hardened library to run Java Rest Microservices via a standard Java main class. Supporting pure Microservice or Micro-monolith styles.

Tars - Tars is a highly performance rpc framework based on naming service using tars protocol and provides a semi-automatic operation platform

  •    C++

Tars comes from the robot in Interstellar movie. Tars is a high-performance RPC framework based on name service and Tars protocol, also integrated administration platform, and implemented hosting-service via flexible schedule. Tars, aka TAF(Total Application Framework), has been used in Tencent since 2008. It supports C++,Java,Nodejs and php for now. This framework offers a set of solution for development, maintenance and testing, which making develop, deploy and testing service efficiently. It integrated extensible protocol for encoding/decoding, high-performance RPC communication framework, name service, monitor, statistics and configuration. You can use it to develop your reliable distributed application based on microservice fast, and reach fully efficient service management.

Tars - Tars is a highly performance rpc framework based on naming service using tars protocol and provides a semi-automatic operation platform

  •    C++

Tars comes from the robot in Interstellar movie. Tars is a high-performance RPC framework based on name service and Tars protocol, also integrated administration platform, and implemented hosting-service via flexible schedule. Tars, aka TAF(Total Application Framework), has been used in Tencent since 2008. It supports C++,Java,Nodejs and php for now. This framework offers a set of solution for development, maintenance and testing, which making develop, deploy and testing service efficiently. It integrated extensible protocol for encoding/decoding, high-performance RPC communication framework, name service, monitor, statistics and configuration. You can use it to develop your reliable distributed application based on microservice fast, and reach fully efficient service management.

hemera - 🔬 Writing reliable & fault-tolerant microservices with https://nats.io

  •    Javascript

Hemera (/ˈhɛmərə/; Ancient Greek: Ἡμέρα [hɛːméra] "day") is a small wrapper around the NATS driver. NATS is a simple, fast and reliable solution for the internal communication of a distributed system. It chooses simplicity and reliability over guaranteed delivery. We want to provide a toolkit to develop micro services in an easy and powerful way. We provide a pattern matching RPC style. You don't have to worry about the transport. NATS is powerful.Hemera has not been designed for high performance on a single process. It has been designed to create lots of microservices doesn't matter where they live. It choose simplicity and reliability as primary goals. It act together with NATS as central nervous system of your distributed system. Transport independency was not considered to be a relevant factor. In addition we use pattern matching which is very powerful. The fact that Hemera needs a broker is an argument which should be taken into consideration when you compare hemera with other frameworks. The relevant difference between microservice frameworks like senecajs, molecurer is not the performance or modularity its about the complexity you need to manage. Hemera is expert in providing an interface to work with lots of services in the network, NATS is the expert to deliver the message at the right place. Hemera is still a subscriber of NATS with some magic in routing and extensions. We don't have to worry about all different aspects in a distributed system like routing, load-balancing, service-discovery, clustering, health-checks ...

smoke-framework - A light-weight server-side service framework written in the Swift programming language

  •    Swift

The Smoke Framework is a light-weight server-side service framework written in Swift and using SwiftNIO for its networking layer by default. The framework can be used for REST-like or RPC-like services and in conjunction with code generators from service models such as Swagger/OpenAPI. The framework has built in support for JSON-encoded request and response payloads.

api-platform - REST and GraphQL framework to build modern API-driven projects (server-side and client-side)

  •    Javascript

The official project documentation is available on the API Platform website. API Platform embraces open web standards (Swagger, JSON-LD, GraphQL, Hydra, HAL, JWT, OAuth, HTTP...) and the Linked Data movement. Your API will automatically expose structured data in Schema.org/JSON-LD. It means that your API Platform application is usable out of the box with technologies of the semantic web.

turbo - Turbo is a framework built for LuaJIT 2 to simplify the task of building fast and scalable network applications

  •    Lua

Turbo is a framework built for LuaJIT 2 to simplify the task of building fast and scalable network applications. It uses a event-driven, non-blocking, no thread design to deliver excellent performance and minimal footprint to high-load applications while also providing excellent support for embedded uses. The toolkit can be used for HTTP REST API's, traditional dynamic web pages through templating, open connections like WebSockets, or just as high level building blocks for native speed network applications. First and foremost the framework is aimed at the HTTP(S) protocol. This means web developers and HTTP API developers are the first class citizens. But the framework contains generic nuts and bolts such as; a I/O loop, IO Stream classes, customizeable TCP (with SSL) server classes giving it value for everyone doing any kind of high performance network application. It will also speak directly to your exising C libraries, and happily also create native C struct's for the ultimate memory and CPU performance.

connexion - Swagger/OpenAPI First framework for Python on top of Flask with automatic endpoint validation & OAuth2 support

  •    Python

Connexion is a framework on top of Flask that automagically handles HTTP requests based on OpenAPI 2.0 Specification (formerly known as Swagger Spec) of your API described in YAML format. Connexion allows you to write a Swagger specification, then maps the endpoints to your Python functions; this makes it unique, as many tools generate the specification based on your Python code. You can describe your REST API in as much detail as you want; then Connexion guarantees that it will work as you specified.With Connexion, you write the spec first. Connexion then calls your Python code, handling the mapping from the specification to the code. This incentivizes you to write the specification so that all of your developers can understand what your API does, even before you write a single line of code.

dropwizard - A damn simple library for building production-ready RESTful web services.

  •    Java

Dropwizard is a Java framework for developing ops-friendly, high-performance, RESTful web services. It pulls together stable, mature libraries from the Java ecosystem into a simple, light-weight package that lets you focus on getting things done.