Skip to content

Instantly share code, notes, and snippets.

View knobunc's full-sized avatar

Ben Bennett knobunc

  • Red Hat
View GitHub Profile
@knobunc
knobunc / Sample run
Last active April 12, 2017 19:51
Test program for ratelimiter
$ go run test.go
Started at 2017-04-12 11:49:21.515360854 -0400 EDT
Invoking at 2017-04-12 11:49:21.515439764 -0400 EDT
Invoked at 2017-04-12 11:49:21.515464339 -0400 EDT
Called at 2017-04-12 11:49:21.515469714 -0400 EDT
Invoking at 2017-04-12 11:49:22.515583917 -0400 EDT
Invoking at 2017-04-12 11:49:23.51571878 -0400 EDT
Invoking at 2017-04-12 11:49:24.515809571 -0400 EDT
Invoking at 2017-04-12 11:49:25.515949779 -0400 EDT
Returned at 2017-04-12 11:49:26.515627721 -0400 EDT
package main
import (
"fmt"
"log"
"net"
"sync"
"time"
"github.com/miekg/dns"