aboutsummaryrefslogtreecommitdiff
path: root/plugin/kubernetes/handler.go (follow)
AgeCommit message (Collapse)AuthorFilesLines
2019-02-24plugin/kubernetes: create dns.Msg later (#2604)Gravatar Miek Gieben 1-18/+16
There is no need to do this at the top of the handler, move this down into the function. Signed-off-by: Miek Gieben <miek@miek.nl>
2019-01-08plugin/kubernetes: fix case preservation and add test (#2430)Gravatar Chris O'Haver 1-2/+3
* fix case preservation and add test * only fix case in k8s
2018-12-30disable ra flag for several plugins (#2408)Gravatar Isolus 1-1/+1
* disable ra flag for several plugins * removed unnecessary assignment * removed more unnecessary assignments
2018-10-22Unblock startup if kubernetes API is unavailable (#2126)Gravatar Kevin Nisbet 1-0/+4
2018-08-29Default to scrubbing replies in the server (#2012)Gravatar Miek Gieben 1-2/+0
Every plugin needs to deal with EDNS0 and should call Scrub to make a message fit the client's buffer. Move this functionality into the server and wrapping the ResponseWriter into a ScrubWriter that handles these bits for us. Result: Less code and faster, because multiple chained plugins could all be calling scrub and SizeAndDo - now there is just one place. Most tests in file/* and dnssec/* needed adjusting because in those unit tests you don't see OPT RRs anymore. The DNSSEC signer was also looking at the returned OPT RR to see if it needed to sign - as those are now added by the server (and thus later), this needed to change slightly. Scrub itself still exist (for backward compat reasons), but has been made a noop. Scrub has been renamed to scrub as it should not be used by external plugins. Fixes: #2010 Signed-off-by: Miek Gieben <miek@miek.nl>
2018-06-11Remove dnsutil.Dedup (#1867)Gravatar Miek Gieben 1-4/+0
Remove the code and remove the call in etcd and kubernetes handlers. This does mean we should not add dups in the first place, which means adding maps in backend_lookup to prevent dups from begin added. This should cut down on the allocations because dnsutil.Dedup is very expensive by converting everything to strings, we avoid doing that now.
2018-05-01Do Compress only when need in request.Scrub (#1760)Gravatar Miek Gieben 1-1/+2
* Remove Compress by default Set Compress = true in Scrub only when the message doesn not fit the advertized buffer. Doing compression is expensive, so try to avoid it. Master vs this branch pkg: github.com/coredns/coredns/plugin/cache BenchmarkCacheResponse-2 50000 24774 ns/op pkg: github.com/coredns/coredns/plugin/cache BenchmarkCacheResponse-2 100000 21960 ns/op * and make it compile
2018-04-22all: fix plugin import ordering (#1717)Gravatar Miek Gieben 1-2/+2
Got a bit messed up with stb lib "context" usage.
2018-04-20global: move to context (#1699)Gravatar Miek Gieben 1-1/+2
* global: move to context Move from golang.org/x/net/context to std lib's context. Change done with: for i in $(grep -l '/context' **/*.go); do sed -e 's|golang.org/x/net/context|context|' -i $i; echo $i; done for i in **/*.go; do goimports -w $i; done * drop from dns.pb.go as well
2018-02-14plugin/kubernetes: Add upstream @self and loop count (#1484)Gravatar Chris O'Haver 1-13/+14
* add upstream @self and loop count * 1st round of feedback * allow argless upstream * update test * readmes * feedback
2018-02-08support for zone transfer for kubernetes (#1259)Gravatar Brad Beam 1-0/+3
* plugin/kubernetes: axfr Hook up dynamic SOA serial by setting ResourceEventHandlerFuncs in dnsController. Add prototype of returns msg.Services via the Transfer function. Leave expanding this to RRs out of scope for a bit. * plugin/kubernetes: axfr Respond to AXFR queries * Fixing race condition * Fixing instantiation of dnstest writer * Updates from review
2018-01-07Add pkg/fall for Fallthrough (#1355)Gravatar Miek Gieben 1-1/+1
* Add pkg/fall for Fallthrough Move this into it's own package to facilitate tests. Important bug was fixed: make the names fully qualified. Add fall package to hosts, reverse, etcd, and fix kubernetes and any tests. The k8s tests are still as-is, might need a future cleanup.
2018-01-06kubernetes: Add zone filtering to fallthrough (#1353)Gravatar John Belamaric 1-1/+1
* Add zone filtering to fallthrough * Doh. gofmt * Update documentation
2017-12-07Changing switch to compare on constants versus strings (#1285)Gravatar Brad Beam 1-10/+10
2017-09-14Remove the word middleware (#1067)Gravatar Miek Gieben 1-0/+86
* Rename middleware to plugin first pass; mostly used 'sed', few spots where I manually changed text. This still builds a coredns binary. * fmt error * Rename AddMiddleware to AddPlugin * Readd AddMiddleware to remain backwards compat