You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: core/cmd/hoverfly/main.go
+5-5Lines changed: 5 additions & 5 deletions
Original file line number
Diff line number
Diff line change
@@ -64,7 +64,7 @@ var logOutputFlags arrayFlags
64
64
varresponseBodyFilesPathstring
65
65
varresponseBodyFilesAllowedOriginFlagsarrayFlags
66
66
varjournalIndexingKeyFlagsarrayFlags
67
-
varjournalBodyMemoryLimit util.MemorySize
67
+
varjournalBodySizeLimit util.MemorySize
68
68
69
69
constboltBackend="boltdb"
70
70
constinmemoryBackend="memory"
@@ -211,7 +211,7 @@ func main() {
211
211
flag.StringVar(&responseBodyFilesPath, "response-body-files-path", "", "When a response contains a relative bodyFile, it will be resolved against this absolute path (default is CWD)")
212
212
flag.Var(&responseBodyFilesAllowedOriginFlags, "response-body-files-allow-origin", "When a response contains a url in bodyFile, it will be loaded only if the origin is allowed")
213
213
flag.Var(&journalIndexingKeyFlags, "journal-indexing-key", "Key to setup indexing on journal")
214
-
flag.Var(&journalBodyMemoryLimit, "journal-body-memory-limit", "Memory size limit for a request or response body in the journal (e.g., '128KB', '2MB'). Memory size is unbounded by default")
214
+
flag.Var(&journalBodySizeLimit, "journal-body-size-limit", "Set the memory size limit for a request or response body in the journal (e.g., '128KB', '2MB'). Defaults to unbounded")
215
215
216
216
flag.Parse()
217
217
@@ -236,8 +236,8 @@ func main() {
236
236
*journalSize=0
237
237
}
238
238
239
-
ifjournalBodyMemoryLimit>0 {
240
-
log.Infof("Journal body memory limit is set to: %s", journalBodyMemoryLimit.String())
239
+
ifjournalBodySizeLimit>0 {
240
+
log.Infof("Journal body size limit is set to: %s", journalBodySizeLimit.String())
Copy file name to clipboardExpand all lines: docs/pages/reference/hoverfly/hoverfly.output
+12-14Lines changed: 12 additions & 14 deletions
Original file line number
Diff line number
Diff line change
@@ -47,11 +47,12 @@ Usage of hoverfly:
47
47
Generate CA certificate and private key for MITM
48
48
-import value
49
49
Import from file or from URL (i.e. '-import my_service.json' or '-import http://mypage.com/service_x.json'
50
+
-journal-body-size-limit value
51
+
Set the memory size limit for a request or response body in the journal (e.g., '128KB', '2MB'). Defaults to unbounded
52
+
-journal-indexing-key value
53
+
Key to setup indexing on journal
50
54
-journal-size int
51
55
Set the size of request/response journal (default 1000)
52
-
-journal-indexing-key string
53
-
Specify the index key using which you want to index journal. Index shares same syntax as the one for templating, such as Request.QueryParam.myParam or Request.Header.X-Header-Id.[1].
54
-
It is used for extracting the data from the journal entry to use as a key for that entry.
55
56
-key string
56
57
Private key of the CA used to sign MITM certificates
57
58
-listen-on-host string
@@ -72,38 +73,34 @@ Usage of hoverfly:
72
73
Set the amount of logs to be stored in memory (default 1000)
73
74
-metrics
74
75
Enable metrics logging to stdout
75
-
-post-serve-action string
76
-
Set local post serve action by passing the action name, binary and the path of the action script and delay in Ms separated by space.
77
-
(i.e. -post-serve-action "<action name> python3 <script path to load> 1000" -post-serve-action "<action name> python3 <script path to load> 3000")
78
-
Set remote post serve action by passing the action name, remote host and delay in Ms separated by space.
We can set multiple post serve actions and use in our simulation schema file.
81
76
-middleware string
82
77
Set middleware by passing the name of the binary and the path of the middleware script separated by space. (i.e. '-middleware "python script.py"')
83
78
-modify
84
79
Start Hoverfly in modify mode - applies middleware (required) to both outgoing and incoming HTTP traffic
85
80
-no-import-check
86
81
Skip duplicate request check when importing simulations
82
+
-pac-file string
83
+
Path to the pac file to be imported on startup
87
84
-password string
88
85
Password for new user
89
86
-password-hash string
90
87
Password hash for new user instead of password
91
88
-plain-http-tunneling
92
89
Use plain http tunneling to host with non-443 port
90
+
-post-serve-action value
91
+
Set post serve action by passing the action name, binary and the path of the action script and delay in Ms separated by space. (i.e. i.e. '-post-serve-action "webhook python script.py 2000"')
93
92
-pp string
94
93
Proxy port - run proxy on another port (i.e. '-pp 9999' to run proxy on port 9999)
95
94
-response-body-files-allow-origin value
96
95
When a response contains a url in bodyFile, it will be loaded only if the origin is allowed
97
96
-response-body-files-path string
98
-
When a response contains a relative bodyFile, it will be resolved against this path (default is CWD)
97
+
When a response contains a relative bodyFile, it will be resolved against this absolute path (default is CWD)
99
98
-spy
100
99
Start Hoverfly in spy mode, similar to simulate but calls real server when cache miss
101
100
-synthesize
102
101
Start Hoverfly in synthesize mode (middleware is required)
103
-
-templating-data-source
104
-
Set templating CSV data source by passing data source name and CSV data file path separated by space.
0 commit comments