diff --git a/.travis.yml b/.travis.yml
index 32da8de..221baeb 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -31,6 +31,7 @@ before_script:
- sudo luarocks install lua-cjson
- sudo luarocks install luaposix
- sudo luarocks install lunit
+ - sudo luarocks install luasec
- cd ..
script:
diff --git a/README.md b/README.md
index d870827..fc6f4b3 100644
--- a/README.md
+++ b/README.md
@@ -59,14 +59,20 @@ See docs/index.html for more details.
Prerequisites
=============
+To run the tests:
```
- #for unit tests
- $luarocks install lunit
- $luarocks install luaposix
- $luarocks install luasocket
- $luarocks install lua-cjson
-
- #for generating docs
- $luarocks install ldoc
+ luarocks install lunit
+ luarocks install lua-cjson
+ luarocks install luaposix
+ luarocks install luasocket
+ luarocks install luasec
+
+ lunit tests/*.lua
+```
+
+To generate the docs:
```
+ luarocks install ldoc
+ ldoc raven.lua -d docs -p raven-lua
+```
diff --git a/docs/index.html b/docs/index.html
index fbfa7ef..6ca12a4 100644
--- a/docs/index.html
+++ b/docs/index.html
@@ -24,7 +24,7 @@
-
ldoc
+
raven-lua
Contents
@@ -34,7 +34,7 @@
Contents
Modules
-
+
@@ -88,7 +88,8 @@
- Functions
+
+
-
@@ -105,13 +106,20 @@
Parameters:
- dsn
The DSN of the Sentry instance with this format:
-
{PROTOCOL}://{PUBLIC_KEY}:{SECRET_KEY}???/{PATH}{PROJECT_ID}
+ {PROTOCOL}://{PUBLIC_KEY}:{SECRET_KEY}@{HOST}/{PATH}{PROJECT_ID}
http://pub:secret@127.0.0.1:8080/sentry/proj-id
- conf
- client configuration. Conf should be a hash table. Possiable
- keys are: "tags", "logger". For example:
-
{ tags = { foo = "bar", abc = "def" }, logger = "myLogger" }
+ client configuration. Conf should be a hash table. Possible keys are:
+
+ - tags extra tags to include on all reported errors
+ - logger
+ - verify_ssl boolean of whether to perform SSL certificate verification
+ - cafile path to CA certificate bundle file.
+ Required only when using luasec, ngx version uses the lua_ssl_trusted_certificate directive for this.
+
+ For example:
+ { tags = { foo = "bar", abc = "def" }, logger = "myLogger", verify_ssl = false }
@@ -125,10 +133,9 @@
Returns:
Usage:
- local raven = require "raven"
- local rvn = raven:new(dsn, { tags = { foo = "bar", abc = "def" },
- logger = "myLogger" })
+
local raven = require "raven"
+local rvn = raven:new(dsn, { tags = { foo = "bar", abc = "def" },
+ logger = "myLogger" })
@@ -183,12 +190,11 @@
Returns:
Usage:
- local raven = require "raven"
- local rvn = raven:new(dsn, { tags = { foo = "bar", abc = "def" },
- logger = "myLogger" })
- local id, err = rvn:captureException(exception,
- { tags = { foo = "bar", abc = "def" }})
+
local raven = require "raven"
+local rvn = raven:new(dsn, { tags = { foo = "bar", abc = "def" },
+ logger = "myLogger" })
+local id, err = rvn:captureException(exception,
+ { tags = { foo = "bar", abc = "def" }})
@@ -229,12 +235,11 @@
Returns:
Usage:
- local raven = require "raven"
- local rvn = raven:new(dsn, { tags = { foo = "bar", abc = "def" },
- logger = "myLogger" })
- local id, err = rvn:captureMessage("Sample message",
- { tags = { foo = "bar", abc = "def" }})
+
local raven = require "raven"
+local rvn = raven:new(dsn, { tags = { foo = "bar", abc = "def" },
+ logger = "myLogger" })
+local id, err = rvn:captureMessage("Sample message",
+ { tags = { foo = "bar", abc = "def" }})
@@ -264,18 +269,17 @@
Parameters:
Returns:
- "f" 's return value(s)
+ the same with xpcall
Usage:
- function func(a, b, c)
- return a * b + c
- end
- return rvn:call(func, a, b, c)
+
function func(a, b, c)
+ return a * b + c
+end
+return rvn:call(func, a, b, c)
@@ -285,7 +289,8 @@
Usage: