2
0
mirror of https://github.com/wangtuanjie/ip17mon.git synced 2020-06-03 16:49:28 +00:00
Go to file
2019-06-05 20:01:56 +08:00
example/qip Makefile for ci 2015-07-02 14:49:28 +08:00
tools update 2015-02-10 11:39:12 +08:00
.gitignore Initial commit 2015-01-20 15:29:44 +08:00
17monipdb.dat add 17monipdb.dat for unit testing 2015-07-02 14:28:10 +08:00
circle.yml more doc and circle ci 2015-07-02 15:09:10 +08:00
ip17mon_test.go more doc and circle ci 2015-07-02 15:09:10 +08:00
ip17mon.go datx and dump api 2019-06-05 20:00:24 +08:00
LICENSE Initial commit 2015-01-20 15:29:44 +08:00
Makefile more doc and circle ci 2015-07-02 15:09:10 +08:00
README.md Makefile for ci 2015-07-02 14:49:28 +08:00

17mon IP location data for Golang

Circle CI

特性

  • 高效的查找算法查询性能100w/s
  • 支持build出的bin文件包含原始数据

安装

go get -u github.com/wangtuanjie/ip17mon

使用

import 
	"fmt"
	"github.com/wangtuanjie/ip17mon"


func init() {
	if err := ip17mon.Init("your data file"); err != nil {
		panic(err)
	}
}

func main() {
	loc, err := ip17mon.Find("116.228.111.18")
	if err != nil {
		fmt.Println("err:", err)
		return
	}
	fmt.Println(loc)
}

更多请参考example

许可证

基于 MIT 协议发布