nginx-clojure / Nginx Clojure
Licence: other
Nginx module for embedding Clojure or Java or Groovy programs, typically those Ring based handlers.
Stars: ✭ 961
Programming Languages
Labels
Projects that are alternatives of or similar to Nginx Clojure
Nginx Json Proxy
An experiment with openresty, lua and nginx
Stars: ✭ 10 (-98.96%)
Mutual labels: nginx
Nano Nginx
Nano container with nginx preconfigured as reverse proxy
Stars: ✭ 15 (-98.44%)
Mutual labels: nginx
Caprover
Scalable PaaS (automated Docker+nginx) - aka Heroku on Steroids
Stars: ✭ 7,964 (+728.72%)
Mutual labels: nginx
Streamcaster
Live streaming platform built with Node.js and React
Stars: ✭ 20 (-97.92%)
Mutual labels: nginx
Status Nginx Module
A http status module for pure nginx, which is in production already.
Stars: ✭ 10 (-98.96%)
Mutual labels: nginx
Docker Nginx Consul Template
A consul-template powered Nginx container.
Stars: ✭ 27 (-97.19%)
Mutual labels: nginx
Nginx Cleantalk Service
LUA configuration to filter any POST requests.
Stars: ✭ 13 (-98.65%)
Mutual labels: nginx
Drupal With Nginx
Running Drupal using nginx: an idiosyncratically crafted bleeding edge configuration.
Stars: ✭ 878 (-8.64%)
Mutual labels: nginx
Docker Nginx Php Mysql
Docker With Nginx PHP 7.2 And Mysql 5.x for developer
Stars: ✭ 21 (-97.81%)
Mutual labels: nginx
Swarm Examples
Beispiel-Code zum Artikel "Continuous Deployment mit Docker Swarm" im Java Magazin 12.17
Stars: ✭ 11 (-98.86%)
Mutual labels: nginx
Phpdock
PHP development Docker inspired by Laradock with a focus on configuring PHPStorm for remote debugging. For an improved approach to this, please see: laravel-laradock-phpstorm
Stars: ✭ 20 (-97.92%)
Mutual labels: nginx
Wp Vps Build Guide
A verbose build guide for a modern, high-performance WordPress production VPS.
Stars: ✭ 31 (-96.77%)
Mutual labels: nginx
Kube Nginx Proxy
Nginx reverse proxy for Kubernetes services and pods powered by annotations
Stars: ✭ 31 (-96.77%)
Mutual labels: nginx
Nginx-Clojure
Nginx-Clojure is a Nginx module for embedding Clojure or Java or Groovy programs, typically those Ring based handlers.
Core Features
The latest release is v0.5.2, more detail changes about it can be found from Release History.
- Compatible with Ring and obviously supports those Ring based frameworks, such as Compojure etc.
- Http Services by using Clojure / Java / Groovy to write simple handlers for http services.
- Nginx Access Handler by Clojure / Java / Groovy
- Nginx Header Filter by Clojure / Java / Groovy
- Nginx Body Filter by Clojure / Java / Groovy
- NEW: Nginx Log Handler by Clojure / Java / Groovy
- NEW: HTTP V2 support in both standard edition and embedded edition which are compiled against Nginx 1.18.0
- NEW: Support Java 9, 10, 11, 12
- Pub/Sub Among Nginx Worker Processes
- Shared Map based on shared memory & Shared Map based Ring session store
- Support Sente, see this PR
- Support Per-message Compression Extensions (PMCEs) for WebSocket
- APIs for Embedding Nginx-Clojure into a Standard Clojure/Java/Groovy App
- Server Side Websocket
- A build-in Jersey container to support java standard RESTful web services (JAX-RS 2.0)
- Tomcat 8 embedding support (so servlet 3.1/jsp/sendfile/JSR-356 websocket work within nginx!)
- Dynamic proxying by using Clojure / Java / Groovy to write a simple nginx rewrite handler to set var or return errors before proxy pass or content ring handler
- Non-blocking coroutine based socket which is Compatible with Java Socket API and works well with largely existing java library such as apache http client, mysql jdbc drivers. With this feature one java main thread can handle thousands of connections.
- Handle multiple sockets parallel in sub coroutines, e.g. we can invoke two remote services at the same time.
- Asynchronous callback API of socket/Channel for some advanced usage
- Long Polling & Server Sent Events
- Run initialization clojure code when nginx worker starting
- Support user defined http request method
- Compatible with the Nginx lastest most stable version 1.18.0. (Nginx 1.14.x, 1.12.x, 1.8.x, 1.6.x, 1.4.x is also ok, older version is not tested and maybe works.)
- One of benifits of Nginx is worker processes are automatically restarted by a master process if they crash
- Utilize lazy headers and direct memory operation between Nginx and JVM to fast handle dynamic contents from Clojure or Java code.
- Utilize Nginx zero copy file sending mechanism to fast handle static contents controlled by Clojure or Java code.
- Support Linux x64, Linux x86 32bit, Win32, Win64 and Mac OS X. Freebsd version can also be got from Freebsd ports.
By the way it is very fast, the benchmarks can be found HERE(with wrk2).
Jar Repository
Nginx-Clojure has already been published to https://clojars.org/ whose maven repository is
<repository>
<id>clojars.org</id>
<url>http://clojars.org/repo</url>
</repository>
After adding clojars repository, you can reference nginx-clojure 0.5.2 , e.g.
Leiningen (clojure, no need to add clojars repository which is a default repository for Leiningen)
[nginx-clojure "0.5.2"]
Gradle (groovy/java)
compile "nginx-clojure:nginx-clojure:0.5.2"
Maven
<dependency>
<groupId>nginx-clojure</groupId>
<artifactId>nginx-clojure</artifactId>
<version>0.5.2</version>
</dependency>
Documents
- Quick Start
- Downloads
- Installation
- Configuration
- Nginx Handlers
- Advanced Topic
- Embedding Nginx-Clojure into A standard App
- Server Channel for Long Polling & Server Sent Events
- Pub/Sub Among Nginx Worker Processes
- Shared Map & Session Store
- Asynchronous Client Channel
- About Logging
- Sever Side WebSocket
- Java standard RESTful web services with Jersey
- Embeding Tomcat
- Use Spring Framework with Nginx-Clojure Java Handlers
- Example Project about Jersey & Spring with Nginx-Clojure
- More about Nginx Worker Process
- More about Nginx-Clojure
- Directives Reference
- API Reference (Clojure)
- Example Projects
- Github Repository of Documents
License
Copyright © 2013-2020 Zhang, Yuexiang (xfeep) and released under the BSD 3-Clause license.
This program uses:
- Re-rooted ASM bytecode engineering library which is distributed under the BSD 3-Clause license
- Modified Continuations Library Written by Matthias Mann is distributed under the BSD 3-Clause license
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].