wcong / ants-go Goto Github PK
View Code? Open in Web Editor NEWopen source, distributed, restful crawler engine in golang
License: MIT License
open source, distributed, restful crawler engine in golang
License: MIT License
add test func
send it to alpha
cluster
as title
what if master down,
restart to do what
record cookie and update by server,
multiply cookie client
we can send message by tcp
github.com/wcong/ants-go/ants/util
found packages util (conf.go) and main (skiplist.go)
what if one node is down
reclaim the request of lost node
add proxy setting for crawler
how does nodes elect a master node,and each node share the cluster info
write as much as possible to test ants
I should make one demo first
should do some basic thing
Restructure my code
change the entrance of program from node to all action,for example http server , tcp server
An error has occurred after I run the muiltiply_spider several times.
2015/04/22 14:54:03 http.go:41: get request:/crawl
2015/04/22 14:54:03 http.go:91: start spider: muiltiply_spider
2015/04/22 14:54:03 downloader.go:46: start downloader
2015/04/22 14:54:03 scraper.go:47: start scraper
2015/04/22 14:54:03 distributer.go:74: start distributer
2015/04/22 14:54:03 distributer.go:90: muiltiply_spider :distribute: 192.168.206.128:8300 :request: http://www.baidu.com/s?wd=1
2015/04/22 14:54:03 report.go:80: start reporter
2015/04/22 14:54:04 downloader.go:96: muiltiply_spider depth: 0 download url: http://www.baidu.com/s?wd=1
2015/04/22 14:54:14 downloader.go:103: Get http://www.baidu.com/s?wd=1: read tcp 180.76.3.151:80: use of closed network connection
2015/04/22 14:54:14 scraper.go:91: muiltiply_spider :start to scrapy: http://www.baidu.com/s?wd=1
2015/04/22 14:54:14 scraper.go:95: muiltiply_spiderruntime error: invalid memory address or nil pointer dereference
2015/04/22 14:54:15 report.go:101: muiltiply_spider :report request to master: http://www.baidu.com/s?wd=1
2015/04/22 14:54:15 report.go:109: stop reporter
2015/04/22 14:54:16 distributer.go:97: stop distributer
I just found rpc is a very good way for node communicate .
so change native tcp to rpc
change package to go way
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.