mofuw

mofuw is *MO*re *F*aster, *U*ltra *W*ebserver

Readme

mofuw

Author: 2vg License: MIT

MOre Fast Ultra Web server.

もふぅ ꒰ᐡ - ﻌ - ᐡ꒱ ♡ @2vg

mofuw is Meccha hayai Asynchronous I/O no super Fast de Ultra minimal na Web server on Nim.

mofuw is a high-performance web server (or web framework) made with Nim.

By default, routing is built in and it is possible to start developing Web application immediately.

mofuw places emphasis on compatibility between usability and performance.

Please make sure that mofuw will be redesigned considerably.

it will be different from the previous one.

Feature

  • cross platform(Windows, macOS, Linux)
  • high-performance
  • low used memory
  • Asynchronous I/O
  • builtin routing
  • support static file serving
  • support SSL
  • support HTTP pipeline / HTTP Streaming
  • support WebSocket
  • support virtual host, multi SSL
  • support multi port server
  • zero copy parser
  • Easy API, create Web Application or extended Web server
  • multi-thread event-loop

Build Status

Linux: Build Status

macOS: Build Status

Windows: Build status

Why is Windows at the bottom of build status section ?

A. because Windows is shitty.

Warning

mofuw is now developping.

please be careful when using.

Require

  • Nim >= 0.18.0
  • mofuparser
  • mofuhttputils

Support Platforms

  • Windows10 (tested on x64)
  • Linux (tested on x64 ArchLinux)
  • macOS

awesome mofuw project

Setup

before mofuw install,

need Nim setup.

※ this is Nim-devel.

curl -L https://github.com/2vg/mofuw/raw/master/setup.sh | sh

after setup, need add /bin directory path to PATH.

Usage

see tests

you want to ask how to build ? B U I L D ? hahaha, is joke ?

mofuw is non need B U I L D.

install is need only nimble install or git clone.

of course, installed Nim >= 0.18.0.

see setup section.

nimble install mofuw

or,

git clone https://github.com/2vg/mofuw

you can use "import mofuw". this only.

minimal example is this 👇

import ../../src/mofuw

proc handler(ctx: MofuwCtx) {.async.} =
  if ctx.getPath == "/":
    mofuwOK("Hello, World!")
  else:
    mofuwResp(HTTP404, "tet/plain", "Not Found")

newServeCtx(
  port = 8080,
  handler = handler
).serve()

W O W, super E A S Y !!!!!! AMAZING !!!!!!!

and...... hyper F A S T !!!!!!! YEAHHHHHHHHHHH.....

if you will using mofuw, you will be very surprised.

if you want to see more example, see tests

Benchmark

Update(2018 - 06 - 11): mofuw is 24th on json tests :3 techempowerRound16/JSON serialization

Update(2018 - 04 - 07): mofuw is very fast :) tbrand/which_is_the_fastest Issue#104

Contribute

Pull requests are welcome !!!!!

I am looking for someone who develops mofuw together.

Especially if there are people who can speed up and refactor it is the best!

Special Thanks

  • jester (using jester's utils, and study macro)
  • kubo39 (awesome... backlog proc, fix somaxconn, and more. super thx!)
  • Thanks a lot dom96, and all Nimmers !
Need help? Read Nimble
Author:
2vg
No tagged versions available
License: MIT

Project website Hosted docs