]> git.ipfire.org Git - thirdparty/knot-resolver.git/log
thirdparty/knot-resolver.git
11 years agomodules/block: reworked for new FFI bindings
Marek Vavruša [Mon, 3 Aug 2015 02:00:26 +0000 (04:00 +0200)] 
modules/block: reworked for new FFI bindings

11 years agodaemon/bindings: replaced old Lua/C bindings with LuaJIT FFI
Marek Vavruša [Mon, 3 Aug 2015 02:00:01 +0000 (04:00 +0200)] 
daemon/bindings: replaced old Lua/C bindings with LuaJIT FFI

this is a first step of leaning towards LuaJIT.
the FFI bindings are much faster, simpler and don’t abort traces

daemon core scripting engine is still going to support interpreted Lua, but modules requiring library bindings (such as ‘block’) will require LuaJIT for FFI

11 years agodaemon/ffimodule: simplified pointer to layer capi
Marek Vavruša [Sun, 2 Aug 2015 21:28:42 +0000 (23:28 +0200)] 
daemon/ffimodule: simplified pointer to layer capi

previously the pointer for C layer API was stored in Lua, it is stored directly in module data now for fast access. this doesn’t disturb VM when processing requests.

11 years agolib/resolve: use begin layer for resolution start
Marek Vavruša [Sun, 2 Aug 2015 21:27:21 +0000 (23:27 +0200)] 
lib/resolve: use begin layer for resolution start

this provides a useful callback for per-request operations that can’t wait until the query is completed (e.g. blocking or logging started queries)

11 years agomodules/block: comparison without copying
Marek Vavruša [Sat, 1 Aug 2015 17:53:05 +0000 (19:53 +0200)] 
modules/block: comparison without copying

11 years agodaemon: more aggressive Lua GC, forced GC steps
Marek Vavruša [Sat, 1 Aug 2015 17:51:13 +0000 (19:51 +0200)] 
daemon: more aggressive Lua GC, forced GC steps

the memory could go through the roof with sufficiently high pps, GC now runs at 4x the speed of allocations and doesn’t wait for increase, some callbacks also perform full collection cycle on completion

11 years agomodules/block: cleanup, faster matching
Marek Vavruša [Sat, 1 Aug 2015 16:07:25 +0000 (18:07 +0200)] 
modules/block: cleanup, faster matching

11 years agodaemon/ffimodule: call Lua modules unless in FAIL state
Marek Vavruša [Sat, 1 Aug 2015 16:07:03 +0000 (18:07 +0200)] 
daemon/ffimodule: call Lua modules unless in FAIL state

11 years agodaemon/engine: priority prefix ‘<‘ for modules
Marek Vavruša [Sat, 1 Aug 2015 16:06:32 +0000 (18:06 +0200)] 
daemon/engine: priority prefix ‘<‘ for modules

if the configured modules name is prefixed with ‘<‘ it takes precedence before all others,
e.g. modules = { ‘hints’, ‘<block’ }
means that the ‘hints’ module will be executed in-order (last), and ‘block’ module layer will be called as first in query processing

11 years agodaemon/ffimodule: store layer callbacks in registry
Marek Vavruša [Fri, 31 Jul 2015 16:15:03 +0000 (18:15 +0200)] 
daemon/ffimodule: store layer callbacks in registry

calling a Lua layer now takes only O(1) registry lookup and
pushing the right parameters

11 years agolib/resolve: use maximum unfragmented UDP payload for iter as default
Marek Vavruša [Wed, 22 Jul 2015 10:47:20 +0000 (12:47 +0200)] 
lib/resolve: use maximum unfragmented UDP payload for iter as default

this is a saner default for large answers. instead of waiting for
probably lost/thrown away fragmented packet, do the query over TCP
instead

11 years agodaemon/engine: build OPT RR in advance
Marek Vavruša [Wed, 22 Jul 2015 10:45:03 +0000 (12:45 +0200)] 
daemon/engine: build OPT RR in advance

11 years agolib/resolve: fixed qry flags clearing on NS switch
Marek Vavruša [Wed, 22 Jul 2015 08:39:25 +0000 (10:39 +0200)] 
lib/resolve: fixed qry flags clearing on NS switch

11 years agodaemon/worker: per-pkt pools
Marek Vavruša [Tue, 21 Jul 2015 16:00:25 +0000 (18:00 +0200)] 
daemon/worker: per-pkt pools

11 years agolib/zonecut: check if the label hopping failed
Marek Vavruša [Tue, 21 Jul 2015 14:20:14 +0000 (16:20 +0200)] 
lib/zonecut: check if the label hopping failed

11 years agodaemon/main: fixed CID#126582, CID#126580
Marek Vavruša [Tue, 21 Jul 2015 12:45:49 +0000 (14:45 +0200)] 
daemon/main: fixed CID#126582, CID#126580

11 years agodaemon/engine: fixed Lua 5.2 compatibility
Marek Vavruša [Tue, 21 Jul 2015 12:41:57 +0000 (14:41 +0200)] 
daemon/engine: fixed Lua 5.2 compatibility

11 years agobuild: fixed .travis.yml
Marek Vavruša [Tue, 21 Jul 2015 12:33:08 +0000 (14:33 +0200)] 
build: fixed .travis.yml

11 years agodaemon/main: added check for dupfd
Marek Vavruša [Tue, 21 Jul 2015 12:29:54 +0000 (14:29 +0200)] 
daemon/main: added check for dupfd

fixed CID#125374

11 years agoMerge branch 'predict'
Marek Vavruša [Tue, 21 Jul 2015 12:23:21 +0000 (14:23 +0200)] 
Merge branch 'predict'

11 years agomodules/stats: sample all expiring records
Marek Vavruša [Mon, 20 Jul 2015 22:46:53 +0000 (00:46 +0200)] 
modules/stats: sample all expiring records

11 years agolib/resolve: overlay is not copied on startup
Marek Vavruša [Mon, 20 Jul 2015 22:42:48 +0000 (00:42 +0200)] 
lib/resolve: overlay is not copied on startup

this fixes a problem when a module was removed, but pending
queries referenced it, causing a crash. usually when the
server was busy and a module was unloaded.
as we don’t need to copy layers at all, they’re just iterated
from the array of modules using a macro

11 years agomodules/predict: turn off prediction by setting empty period
Marek Vavruša [Sun, 19 Jul 2015 21:39:26 +0000 (23:39 +0200)] 
modules/predict: turn off prediction by setting empty period

11 years agomodules/predict: cleanup
Marek Vavruša [Sun, 19 Jul 2015 12:23:26 +0000 (14:23 +0200)] 
modules/predict: cleanup

11 years agogeneric/lru: 16bit refcounts/length
Marek Vavruša [Sun, 19 Jul 2015 12:23:14 +0000 (14:23 +0200)] 
generic/lru: 16bit refcounts/length

11 years agotests: fixed rplan tests
Marek Vavruša [Sat, 18 Jul 2015 23:56:12 +0000 (01:56 +0200)] 
tests: fixed rplan tests

11 years agolib/rplan: ability to refetch expiring queries
Marek Vavruša [Sat, 18 Jul 2015 22:56:03 +0000 (00:56 +0200)] 
lib/rplan: ability to refetch expiring queries

11 years agolayer/rrcache: minttl 5s default
Marek Vavruša [Sat, 18 Jul 2015 22:55:48 +0000 (00:55 +0200)] 
layer/rrcache: minttl 5s default

11 years agolib/resolve: per-request options, worker.resolve() support
Marek Vavruša [Sat, 18 Jul 2015 22:55:29 +0000 (00:55 +0200)] 
lib/resolve: per-request options, worker.resolve() support

11 years agomodules/predict: cleaned up implementation, doc
Marek Vavruša [Sat, 18 Jul 2015 22:53:25 +0000 (00:53 +0200)] 
modules/predict: cleaned up implementation, doc

11 years agomodules/prefetch: frequent sampling, fetch iteration
Marek Vavruša [Sat, 18 Jul 2015 11:57:15 +0000 (13:57 +0200)] 
modules/prefetch: frequent sampling, fetch iteration

11 years agomodules/prefetch: 5x multisampling, 20% jitter
Marek Vavruša [Fri, 17 Jul 2015 22:10:29 +0000 (00:10 +0200)] 
modules/prefetch: 5x multisampling, 20% jitter

11 years agomodules/prefetch: multisampling, expiring prefetch, configurable window
Marek Vavruša [Fri, 17 Jul 2015 16:19:29 +0000 (18:19 +0200)] 
modules/prefetch: multisampling, expiring prefetch, configurable window

11 years agomodules/stats: log frequent and expiring queries
Marek Vavruša [Fri, 17 Jul 2015 16:17:03 +0000 (18:17 +0200)] 
modules/stats: log frequent and expiring queries

11 years agomodules/prefetch: wip
Marek Vavruša [Wed, 15 Jul 2015 08:21:44 +0000 (10:21 +0200)] 
modules/prefetch: wip

11 years agolib/resolve: fixed TCP retransmit
Marek Vavruša [Fri, 17 Jul 2015 14:57:20 +0000 (16:57 +0200)] 
lib/resolve: fixed TCP retransmit

11 years agodaemon/worker: cleanup ioreq recycling, correct checking of ioreq validity
Marek Vavruša [Fri, 17 Jul 2015 14:57:07 +0000 (16:57 +0200)] 
daemon/worker: cleanup ioreq recycling, correct checking of ioreq validity

before only current I/O handle was tracked for each subrequest, but the
requests may have outlived it (connect request isn't cancelable for
example), if such request terminated after the request was finished,
it checked the address of potentially stale task

11 years agoAlways change results from travis to gitter.im since it doesn't clutter main chat
Ondřej Surý [Fri, 17 Jul 2015 09:38:22 +0000 (11:38 +0200)] 
Always change results from travis to gitter.im since it doesn't clutter main chat

11 years agoAdded Gitter badge
The Gitter Badger [Thu, 16 Jul 2015 14:51:46 +0000 (14:51 +0000)] 
Added Gitter badge

11 years agoCall the webhook only on change/change
Ondřej Surý [Thu, 16 Jul 2015 15:12:10 +0000 (17:12 +0200)] 
Call the webhook only on change/change

11 years agoEnable gitter.im webhook
Ondřej Surý [Thu, 16 Jul 2015 15:11:17 +0000 (17:11 +0200)] 
Enable gitter.im webhook

11 years agoMerge commit '931d736540012dd8a770650434b3d901434930e3'
Marek Vavruša [Wed, 15 Jul 2015 16:20:48 +0000 (18:20 +0200)] 
Merge commit '931d736540012dd8a770650434b3d901434930e3'

11 years agodaemon/worker: cleanup and fixed early memset
Marek Vavruša [Wed, 15 Jul 2015 15:20:04 +0000 (17:20 +0200)] 
daemon/worker: cleanup and fixed early memset

11 years agodaemon/io: use recvmmsg for master sockets, recvmsg otherwise
Marek Vavruša [Wed, 15 Jul 2015 15:19:43 +0000 (17:19 +0200)] 
daemon/io: use recvmmsg for master sockets, recvmsg otherwise

this applies for Linux with recvmmsg() support only

11 years agodaemon/worker: fixed bad memory access with delayed send completion
Marek Vavruša [Wed, 15 Jul 2015 15:19:20 +0000 (17:19 +0200)] 
daemon/worker: fixed bad memory access with delayed send completion

when the timeout event was fired, it started another step in query
resolution, but there may have been pending events on previous handle
if the events on the previous handle completed, they would check the
memory of their task (which may have been non-existent) and possibly
double-close the handle

11 years agolayer/iterate: do DNS 0x20 only for outbound queries
Marek Vavruša [Tue, 14 Jul 2015 17:31:18 +0000 (19:31 +0200)] 
layer/iterate: do DNS 0x20 only for outbound queries

no need to scramble queries satisfied from cache

11 years agodaemon/worker: smaller starting mempool per request (16k)
Marek Vavruša [Tue, 14 Jul 2015 11:26:42 +0000 (13:26 +0200)] 
daemon/worker: smaller starting mempool per request (16k)

an average request from cache requires ~12k, an average iterative request 16-64k
this reduces allocation cost when there are now pools on the freelist

11 years agodaemon/worker: satisfy subreq sockets from freelist
Marek Vavruša [Tue, 14 Jul 2015 11:24:46 +0000 (13:24 +0200)] 
daemon/worker: satisfy subreq sockets from freelist

since the structures are ~ same size as I/O requests (udp_send_t being 60B larger than others), they all share the same freelist

11 years agodaemon/io: fix closing TCP sockets without worker knowing it
Marek Vavruša [Tue, 14 Jul 2015 11:22:38 +0000 (13:22 +0200)] 
daemon/io: fix closing TCP sockets without worker knowing it

11 years agodaemon/worker: track ipv4/ipv6 requests
Marek Vavruša [Mon, 13 Jul 2015 22:48:01 +0000 (00:48 +0200)] 
daemon/worker: track ipv4/ipv6 requests

11 years agolib/rrcache: allow replacement of expiring records
Marek Vavruša [Mon, 13 Jul 2015 22:24:51 +0000 (00:24 +0200)] 
lib/rrcache: allow replacement of expiring records

11 years agomodules/stats: 10-100-1000 ms latency tracking
Marek Vavruša [Mon, 13 Jul 2015 22:19:34 +0000 (00:19 +0200)] 
modules/stats: 10-100-1000 ms latency tracking

11 years agomodules/stats: expose frequent queries LRU turnover
Marek Vavruša [Mon, 13 Jul 2015 16:29:31 +0000 (18:29 +0200)] 
modules/stats: expose frequent queries LRU turnover

11 years agogeneric/lru: count updates in slot for item-slot stickiness
Marek Vavruša [Mon, 13 Jul 2015 16:22:50 +0000 (18:22 +0200)] 
generic/lru: count updates in slot for item-slot stickiness

11 years agomodules/stats: fixed potential crash on empty prefix
Marek Vavruša [Mon, 13 Jul 2015 14:16:27 +0000 (16:16 +0200)] 
modules/stats: fixed potential crash on empty prefix

11 years agodaemon/lua: fixed output printing
Marek Vavruša [Mon, 13 Jul 2015 13:34:37 +0000 (15:34 +0200)] 
daemon/lua: fixed output printing

11 years agoMerge branch 'stats-improved' into prefetch-wip
Marek Vavruša [Mon, 13 Jul 2015 13:58:13 +0000 (15:58 +0200)] 
Merge branch 'stats-improved' into prefetch-wip

11 years agomodules/stats: sample list of most frequent iterative queries
Marek Vavruša [Mon, 13 Jul 2015 13:57:20 +0000 (15:57 +0200)] 
modules/stats: sample list of most frequent iterative queries

the stats module keeps track of frequent iterative queries using
probabilistic sampling. the list includes subrequests.
it is useful for tracking over time, prefetching and anomaly reporting

11 years agomodules/stats: persistent metrics table
Marek Vavruša [Mon, 13 Jul 2015 13:37:50 +0000 (15:37 +0200)] 
modules/stats: persistent metrics table

enumerated metrics are always present (set to 0 if not used), this fixes
missing values when not measuring and provides a faster access to common
data

11 years agogeneric/lru: evictions counter to aid efficiency prediction
Marek Vavruša [Mon, 13 Jul 2015 13:35:19 +0000 (15:35 +0200)] 
generic/lru: evictions counter to aid efficiency prediction

11 years agodaemon/lua: fixed output printing
Marek Vavruša [Mon, 13 Jul 2015 13:34:37 +0000 (15:34 +0200)] 
daemon/lua: fixed output printing

11 years agotests: can execute specific tests, fixed EDNS+RR merging
Marek Vavruša [Fri, 10 Jul 2015 01:15:26 +0000 (03:15 +0200)] 
tests: can execute specific tests, fixed EDNS+RR merging

11 years agodoc: updated lib
Marek Vavruša [Thu, 9 Jul 2015 00:11:48 +0000 (02:11 +0200)] 
doc: updated lib

11 years agodoc: updated dependencies
Marek Vavruša [Thu, 9 Jul 2015 00:03:57 +0000 (02:03 +0200)] 
doc: updated dependencies

11 years agodoc: updated library doc for developers
Marek Vavruša [Wed, 8 Jul 2015 23:58:43 +0000 (01:58 +0200)] 
doc: updated library doc for developers

11 years agoMerge branch 'async-io-requests'
Marek Vavruša [Wed, 8 Jul 2015 20:49:49 +0000 (22:49 +0200)] 
Merge branch 'async-io-requests'

11 years agodaemon/worker: fixed leak
Marek Vavruša [Wed, 8 Jul 2015 16:09:59 +0000 (18:09 +0200)] 
daemon/worker: fixed leak

11 years agodaemon/worker: asynchronous I/O requests
Marek Vavruša [Wed, 8 Jul 2015 01:36:48 +0000 (03:36 +0200)] 
daemon/worker: asynchronous I/O requests

this can coalesce sends/writes in future versions of libuv

11 years agodaemon/worker: compile-time support for recvmmsg in worker buffers
Marek Vavruša [Wed, 8 Jul 2015 01:36:02 +0000 (03:36 +0200)] 
daemon/worker: compile-time support for recvmmsg in worker buffers

11 years agolib: faster rdata iterators
Marek Vavruša [Tue, 7 Jul 2015 23:28:53 +0000 (01:28 +0200)] 
lib: faster rdata iterators

11 years agodaemon: worker can accept multiple pkts, cleanup
Marek Vavruša [Tue, 7 Jul 2015 21:43:05 +0000 (23:43 +0200)] 
daemon: worker can accept multiple pkts, cleanup

11 years agodaemon: fork earlier, keep instance id in 'worker.id'
Marek Vavruša [Tue, 7 Jul 2015 21:39:50 +0000 (23:39 +0200)] 
daemon: fork earlier, keep instance id in 'worker.id'

this fixes an issue with libuv sometimes crashing with mismatching number
of descriptors with REUSEPORT

11 years agodoc: fixed typo
Marek Vavruša [Mon, 6 Jul 2015 14:17:06 +0000 (16:17 +0200)] 
doc: fixed typo

11 years agoMerge branch 'prefetch-wip'
Marek Vavruša [Mon, 6 Jul 2015 14:13:48 +0000 (16:13 +0200)] 
Merge branch 'prefetch-wip'

11 years agodoc: added documentation for worker api
Marek Vavruša [Mon, 6 Jul 2015 14:13:09 +0000 (16:13 +0200)] 
doc: added documentation for worker api

11 years agomodules/prefetch: fixed lua error on bad queries, iterative
Marek Vavruša [Mon, 6 Jul 2015 00:06:41 +0000 (02:06 +0200)] 
modules/prefetch: fixed lua error on bad queries, iterative

11 years agolayer/rrcache: cache authority only if chasing referral/cname
Marek Vavruša [Mon, 6 Jul 2015 00:02:55 +0000 (02:02 +0200)] 
layer/rrcache: cache authority only if chasing referral/cname

11 years agomodules/prefetch: basic prefetching of frequently used records
Marek Vavruša [Sun, 5 Jul 2015 20:14:10 +0000 (22:14 +0200)] 
modules/prefetch: basic prefetching of frequently used records

11 years agomodules: api fixups
Marek Vavruša [Sun, 5 Jul 2015 20:13:07 +0000 (22:13 +0200)] 
modules: api fixups

11 years agodaemon/bindings: cleanup, checking, rrclass wrapper
Marek Vavruša [Sun, 5 Jul 2015 20:11:13 +0000 (22:11 +0200)] 
daemon/bindings: cleanup, checking, rrclass wrapper

11 years agodaemon/bindings: Lua API for worker (resolve, stats)
Marek Vavruša [Sun, 5 Jul 2015 20:09:48 +0000 (22:09 +0200)] 
daemon/bindings: Lua API for worker (resolve, stats)

11 years agolib/cache: track expiring records in cache
Marek Vavruša [Sun, 5 Jul 2015 20:07:18 +0000 (22:07 +0200)] 
lib/cache: track expiring records in cache

11 years agoprefetch wip
Marek Vavruša [Thu, 2 Jul 2015 20:09:22 +0000 (22:09 +0200)] 
prefetch wip

11 years agolib/utils: fixed recycle on already filled packet
Marek Vavruša [Fri, 3 Jul 2015 22:25:38 +0000 (00:25 +0200)] 
lib/utils: fixed recycle on already filled packet

11 years agobindings: pkt:get(section,id) wrapper
Marek Vavruša [Thu, 2 Jul 2015 20:09:01 +0000 (22:09 +0200)] 
bindings: pkt:get(section,id) wrapper

11 years agolib: cleanup
Marek Vavruša [Fri, 3 Jul 2015 22:01:12 +0000 (00:01 +0200)] 
lib: cleanup

11 years agoblock: improved suffix match, added doc
Marek Vavruša [Fri, 3 Jul 2015 14:27:34 +0000 (16:27 +0200)] 
block: improved suffix match, added doc

11 years agomodules+bindings: cleanup
Marek Vavruša [Fri, 3 Jul 2015 14:27:12 +0000 (16:27 +0200)] 
modules+bindings: cleanup

11 years agoMerge branch 'tests_wrapped' into 'master'
Marek Vavruša [Fri, 3 Jul 2015 12:08:34 +0000 (14:08 +0200)] 
Merge branch 'tests_wrapped' into 'master'

Tests wrapped

See merge request !15

11 years agotests: style fixes, notes
Marek Vavruša [Fri, 3 Jul 2015 11:58:51 +0000 (13:58 +0200)] 
tests: style fixes, notes

11 years agoscripts: updated broken Lua build on some linkers
Marek Vavruša [Fri, 3 Jul 2015 11:39:22 +0000 (13:39 +0200)] 
scripts: updated broken Lua build on some linkers

11 years agoscripts: updated broken Lua build on some linkers
Marek Vavruša [Fri, 3 Jul 2015 11:39:22 +0000 (13:39 +0200)] 
scripts: updated broken Lua build on some linkers

11 years agotests: integration tests with wrapped syscalls
Grigorii Demidov [Fri, 3 Jul 2015 11:31:05 +0000 (13:31 +0200)] 
tests: integration tests with wrapped syscalls

11 years agobuild: placed ldflags after libraries (may be static)
Marek Vavruša [Fri, 3 Jul 2015 11:21:13 +0000 (13:21 +0200)] 
build: placed ldflags after libraries (may be static)

11 years agoMerge branch 'hive-wip'
Marek Vavruša [Tue, 30 Jun 2015 22:34:17 +0000 (00:34 +0200)] 
Merge branch 'hive-wip'

11 years agodoc: documented forked mode
Marek Vavruša [Tue, 30 Jun 2015 22:33:36 +0000 (00:33 +0200)] 
doc: documented forked mode

11 years agodaemon/bindings: missing brk in wrapped lookup tables
Marek Vavruša [Mon, 29 Jun 2015 23:53:25 +0000 (01:53 +0200)] 
daemon/bindings: missing brk in wrapped lookup tables

11 years agolib: helping compiler with early returns
Marek Vavruša [Mon, 29 Jun 2015 23:08:44 +0000 (01:08 +0200)] 
lib: helping compiler with early returns

11 years agodaemon/main: cleanup, forking and remote tty
Marek Vavruša [Mon, 29 Jun 2015 22:27:00 +0000 (00:27 +0200)] 
daemon/main: cleanup, forking and remote tty

when the daemon starts in non-interactive mode, it creates a pipe in the ‘tty/<pid>’ which can be used to interact with it remotely - much wow

e.g. $ socat - UNIX-CONNECT:tty/38284

11 years agocontrib/ccan: added ‘asprintf’ compatibility
Marek Vavruša [Mon, 29 Jun 2015 22:25:16 +0000 (00:25 +0200)] 
contrib/ccan: added ‘asprintf’ compatibility