• Stars
    star
    202
  • Rank 193,691 (Top 4 %)
  • Language
    Lua
  • License
    MIT License
  • Created about 15 years ago
  • Updated 4 months ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Copas is a dispatcher based on coroutines that can be used by TCP/IP servers.

Copas 4.7

Unix build Coveralls code coverage Luacheck SemVer Licence

Copas is a dispatcher based on coroutines that can be used for asynchronous networking. For example TCP or UDP based servers. But it also features timers and client support for http(s), ftp and smtp requests.

It uses LuaSocket as the interface with the TCP/IP stack and LuaSec for ssl support.

A server or thread registered with Copas should provide a handler for requests and use Copas socket functions to send the response. Copas loops through requests and invokes the corresponding handlers. For a full implementation of a Copas HTTP server you can refer to Xavante as an example.

Copas is free software and uses the same license as Lua (MIT), and can be downloaded from its GitHub page.

The easiest way to install Copas is through LuaRocks:

luarocks install copas

For more details see the documentation.

Releasing a new version

  • update changelog in docs (index.html, update history and status sections)
  • update version in copas.lua
  • update version at the top of this README,
  • update copyright years if needed
  • update rockspec
  • commit as release X.Y.Z
  • tag as vX_Y_Z and as X.Y.Z
  • push commit and tag
  • upload to luarocks
  • test luarocks installation

More Repositories

1

Penlight

A set of pure Lua libraries focusing on input data handling (such as reading configuration files), functional programming (such as map, reduce, placeholder expressions,etc), and OS path management. Much of the functionality is inspired by the Python standard libraries.
Lua
1,883
star
2

luasocket

Network support for the Lua language
HTML
1,814
star
3

busted

Elegant Lua unit testing.
Lua
1,387
star
4

luafilesystem

LuaFileSystem is a Lua library developed to complement the set of functions related to file systems offered by the standard Lua distribution.
C
891
star
5

ldoc

LDoc is a LuaDoc-compatible documentation generator which can also process C extension source. Markdown may be optionally used to render comments, as well as integrated readme documentation and pretty-printed example files.
Lua
774
star
6

luasql

LuaSQL is a simple interface from Lua to a DBMS.
Lua
536
star
7

luasec

LuaSec
C
364
star
8

luacov

LuaCov is a simple coverage analyzer for Lua code.
Lua
295
star
9

lua-compat-5.3

Compatibility module providing Lua-5.3-style APIs for Lua 5.2 and 5.1
C
225
star
10

luassert

Assertion library for Lua
Lua
202
star
11

lua_cliargs

A command-line argument parsing module for Lua.
Lua
120
star
12

md5

MD5 offers basic cryptographic facilities for Lua 5.1.
C
109
star
13

cgilua

CGILua is a tool for creating dynamic HTML pages and manipulating input data from Web forms.
Lua
93
star
14

lua-iconv

Lua bindings for POSIX iconv
Lua
90
star
15

lualogging

A simple API to use logging features in Lua
Lua
51
star
16

say

Lua string hashing library, useful for internationalization
Lua
45
star
17

luaexpat

LuaExpat is a SAX XML parser based on the Expat library
Lua
23
star
18

luasystem

Platform independent system calls for Lua
C
19
star
19

lua-mimetypes

fixed repo of https://luarocks.org/modules/luarocks/mimetypes
Lua
6
star
20

luasyslog

Addon for lualogging to log to the system log on unix systems
Lua
6
star
21

moon-sand

Sandbox to mess with CIβ€Œ deployments using LunarModules CI key(s)
Lua
2
star
22

expadom

An XML DOM Level 2 Core implementation in Lua, based on the (Lua)Expat parser.
Lua
2
star
23

lunarmodules

providing the profile page (README.md) for the Lunar Modules organization
2
star
24

.github

Lunarmodules profile page and reusable workflows
2
star
25

lua-lace

Lua Access Control Engine
Lua
2
star