MCPcopy Create free account

hub / github.com/geziyor/geziyor / functions

Functions177 in github.com/geziyor/geziyor

↓ 91 callersMethodSet
Set stores the []byte representation of a response against a key
cache/cache.go:56
↓ 82 callersMethodGet
Get returns the []byte representation of a cached response and a bool set to true if the value isn't empty
cache/cache.go:54
↓ 57 callersMethodDo
Do sends an HTTP request
geziyor.go:220
↓ 54 callersMethodClose
()
cache/cache.go:589
↓ 36 callersFunctionresetTest
()
cache/cache_test.go:169
↓ 23 callersFunctionNewGeziyor
NewGeziyor creates new Geziyor with default values. If options provided, options
geziyor.go:44
↓ 23 callersMethodStart
Start starts scraping
geziyor.go:142
↓ 18 callersFunctionNewRequest
NewRequest returns a new Request given a method, URL, and optional body.
client/request.go:43
↓ 18 callersFunctiongetFreshness
getFreshness will return one of fresh/stale/transparent based on the cache-control values of the request and the response fresh indicates the respons
cache/cache.go:338
↓ 13 callersMethodRoundTrip
(req *http.Request)
cache/cache_test.go:1192
↓ 10 callersFunctionparseCacheControl
(headers http.Header)
cache/cache.go:528
↓ 7 callersMethodDelete
Delete removes the value associated with the key
cache/cache.go:58
↓ 7 callersFunctionNewMemoryCacheTransport
NewMemoryCacheTransport returns a new Transport using the in-memory cache implementation
cache/cache.go:621
↓ 6 callersMethodDoRequest
DoRequest selects appropriate request handler, client or Chrome
client/client.go:94
↓ 5 callersFunctionSetDefaultHeader
SetDefaultHeader sets header if not exists before
client/client.go:275
↓ 5 callersFunctioncontainsHeader
(headers []string, header string)
cache/cache_test.go:1130
↓ 5 callersFunctiongetEndToEndHeaders
(respHeaders http.Header)
cache/cache.go:463
↓ 4 callersMethodProcessRequest
(r *client.Request)
middleware/duplicate_requests.go:16
↓ 4 callersFunctionnewClientDefault
newClientDefault creates new client with default options
client/client_test.go:151
↓ 3 callersMethodCancel
Cancel request
client/request.go:38
↓ 3 callersFunctionConvertMapToHeader
ConvertMapToHeader converts map[string]interface{} to http.Header
client/client.go:294
↓ 3 callersFunctionDefaultString
DefaultString returns first non-empty string
internal/strings.go:4
↓ 3 callersFunctionNewClient
NewClient creates http.Client with modified values for typical web scraper
client/client.go:60
↓ 3 callersMethodRoundTrip
RoundTrip is a wrapper for caching requests. If there is a fresh Response already in cache, then it will be returned without connecting to the server.
cache/cache.go:126
↓ 3 callersFunctioncacheKey
cacheKey returns the cache key for req.
cache/cache.go:62
↓ 3 callersFunctionkeyToFilename
(key string)
cache/diskcache/diskcache.go:41
↓ 2 callersFunctionCachedResponse
CachedResponse returns the cached http.Response for req if present, and nil otherwise.
cache/cache.go:72
↓ 2 callersFunctionConvertHeaderToMap
ConvertHeaderToMap converts http.Header to map[string]interface{}
client/client.go:283
↓ 2 callersMethodCookies
Cookies returns the cookies to send in a request for the given URL.
client/client.go:263
↓ 2 callersFunctionDate
Date parses and returns the value of the Date header.
cache/cache.go:307
↓ 2 callersFunctionNew
New returns a new Cache that will store files in basePath
cache/diskcache/diskcache.go:48
↓ 2 callersFunctionNew
New returns a new Cache that will store items in an in-memory map
cache/memorycache/memorycache.go:36
↓ 2 callersFunctionPleaseCache
PleaseCache excercises a Cache implementation.
cache/cache.go:594
↓ 2 callersMethodPost
Post issues a POST to the specified URL
geziyor.go:210
↓ 2 callersMethodRead
Read reads the next len(p) bytes from R or until R is drained. The return value n is the number of bytes read. If R has no data to return, err is io.E
cache/cache.go:580
↓ 2 callersFunctioncloneRequest
cloneRequest returns a clone of the provided *http.Request. The clone is a shallow copy of the struct and its Header map. (This function copyright goa
cache/cache.go:514
↓ 2 callersMethoddo
Do sends an HTTP request
geziyor.go:233
↓ 2 callersFunctionheaderAllCommaSepValues
headerAllCommaSepValues returns all comma-separated values (each with whitespace trimmed) for header name in headers. According to Section 4.2 of the
cache/cache.go:552
↓ 2 callersMethodsince
(d time.Time)
cache/cache.go:324
↓ 1 callersMethodClient
Client returns an *http.Client that caches responses.
cache/cache.go:106
↓ 1 callersFunctionContainsInt
ContainsInt checks whether []int contains int
internal/strings.go:30
↓ 1 callersFunctionContainsString
ContainsString checks whether []string ContainsString string
internal/strings.go:20
↓ 1 callersFunctionDefaultRune
DefaultRune returns first non-empty rune
internal/strings.go:12
↓ 1 callersMethodExport
(exports chan interface{})
export/export.go:6
↓ 1 callersMethodExport
Export exports response data as CSV streaming file
export/csv.go:20
↓ 1 callersMethodExport
Export exports response data as JSON streaming file
export/json.go:20
↓ 1 callersMethodExport
Export exports response data as JSON
export/json.go:50
↓ 1 callersMethodGet
Get issues a GET to the specified URL.
geziyor.go:177
↓ 1 callersMethodGetRendered
GetRendered issues GET request using headless browser Opens up a new Chrome instance, makes request, waits for rendering HTML DOM and closed. Rendered
geziyor.go:189
↓ 1 callersMethodHead
Head issues a HEAD to the specified URL
geziyor.go:200
↓ 1 callersMethodIsHTML
IsHTML checks if response content is HTML by looking content-type header
client/response.go:37
↓ 1 callersMethodJoinURL
JoinURL joins base response URL and provided relative URL. DEPRECATED: Use response.Request.URL.Parse(relativeURL) instead.
client/response.go:26
↓ 1 callersFunctionNew
New returns a new Cache that will store leveldb in path
cache/leveldbcache/leveldbcache.go:35
↓ 1 callersFunctionNewDelay
(requestDelayRandomize bool, requestDelay time.Duration)
middleware/delay.go:15
↓ 1 callersFunctionNewMetrics
NewMetrics creates new metrics with given metrics.Type
metrics/metrics.go:38
↓ 1 callersFunctionNewRedirectionHandler
NewRedirectionHandler returns maximum allowed redirection function with provided maxRedirect
client/client.go:303
↓ 1 callersFunctionNewRobotsTxt
(client *client.Client, metrics *metrics.Metrics, robotsDisabled bool)
middleware/robotstxt.go:21
↓ 1 callersFunctionNewTransport
NewTransport returns a new Transport with the provided Cache implementation and MarkCachedResponses set to true
cache/cache.go:97
↓ 1 callersMethodProcessRequest
(r *client.Request)
middleware/middleware.go:16
↓ 1 callersMethodProcessResponse
(r *client.Response)
middleware/middleware.go:21
↓ 1 callersFunctionRoundRobinProxy
RoundRobinProxy creates a proxy switcher function which rotates ProxyURLs on every request. The proxy type is determined by the URL scheme. "http", "h
client/proxy.go:34
↓ 1 callersMethodRoundTripDummy
RoundTripDummy has no awareness of any HTTP Cache-Control directives. Every request and its corresponding response are cached. When the same request i
cache/cache.go:136
↓ 1 callersMethodRoundTripRFC2616
RoundTripRFC2616 provides a RFC2616 compliant HTTP cache, i.e. with HTTP Cache-Control awareness, aimed at production and used in continuous runs to a
cache/cache.go:182
↓ 1 callersFunctionStartMetricsServer
StartMetricsServer starts server that handles metrics Prometheus: http://localhost:2112/metrics Expvar : http://localhost:2112/debug/vars
metrics/metrics.go:99
↓ 1 callersMethodacquireSem
(req *client.Request)
geziyor.go:270
↓ 1 callersFunctioncanStaleOnError
Returns true if either the request or the response includes the stale-if-error cache control extension: https://tools.ietf.org/html/rfc5861
cache/cache.go:421
↓ 1 callersFunctioncanStore
(reqCacheControl, respCacheControl cacheControl)
cache/cache.go:491
↓ 1 callersMethoddoRequestChrome
doRequestChrome opens up a new chrome instance and makes request
client/client.go:171
↓ 1 callersMethoddoRequestClient
doRequestClient is a simple wrapper to read response according to options.
client/client.go:124
↓ 1 callersMethodinterruptSignalWaiter
interruptSignalWaiter waits data from provided channels and stops scraper if shutdownChan channel receives SIGINT
geziyor.go:313
↓ 1 callersFunctionjsonMarshalLine
jsonMarshalLine adds tab and comma around actual data
export/json.go:86
↓ 1 callersFunctionnewGatewayTimeoutResponse
(req *http.Request)
cache/cache.go:501
↓ 1 callersMethodrecoverMe
recoverMe prevents scraping being crashed. Logs error and stack trace
geziyor.go:305
↓ 1 callersMethodreleaseSem
(req *client.Request)
geziyor.go:291
↓ 1 callersFunctionsetup
()
cache/cache_test.go:41
↓ 1 callersMethodstartExporters
()
geziyor.go:326
↓ 1 callersFunctionteardown
()
cache/cache_test.go:164
↓ 1 callersFunctionvaryMatches
varyMatches will return false unless all of the cached values for the headers listed in Vary match the new request
cache/cache.go:112
FunctionBenchmarkRequests
Make sure to increase open file descriptor limits before running
geziyor_test.go:381
FunctionBenchmarkWhole
(b *testing.B)
geziyor_test.go:413
MethodDelete
Delete removes the response with key from the cache
cache/leveldbcache/leveldbcache.go:30
MethodDelete
Delete removes the response with key from the cache
cache/diskcache/diskcache.go:36
MethodDelete
Delete removes key from the cache
cache/memorycache/memorycache.go:29
MethodExport
Export logs exported data to console as pretty printed
export/pprint.go:12
MethodGet
Get returns the response corresponding to key if present
cache/leveldbcache/leveldbcache.go:15
MethodGet
Get returns the response corresponding to key if present
cache/diskcache/diskcache.go:20
MethodGet
Get returns the []byte representation of the response and true if present, false if not
cache/memorycache/memorycache.go:14
MethodGetProxy
(pr *http.Request)
client/proxy.go:19
FunctionNewWithDB
NewWithDB returns a new Cache using the provided leveldb as underlying storage.
cache/leveldbcache/leveldbcache.go:49
FunctionNewWithDiskv
NewWithDiskv returns a new Cache using the provided Diskv as underlying storage.
cache/diskcache/diskcache.go:59
MethodProcessRequest
(r *client.Request)
middleware/robotstxt.go:30
MethodProcessRequest
(r *client.Request)
middleware/headers.go:12
MethodProcessRequest
(r *client.Request)
middleware/allowed_domains.go:15
MethodProcessRequest
(r *client.Request)
middleware/metrics.go:14
MethodProcessRequest
(r *client.Request)
middleware/delay.go:22
MethodProcessResponse
(r *client.Response)
middleware/log_stats.go:13
MethodProcessResponse
(r *client.Response)
middleware/metrics.go:18
MethodProcessResponse
(r *client.Response)
middleware/parse_html.go:15
MethodSet
Set saves a response to the cache as key
cache/leveldbcache/leveldbcache.go:25
MethodSet
Set saves a response to the cache as key
cache/diskcache/diskcache.go:30
next →1–100 of 177, ranked by callers