-
Notifications
You must be signed in to change notification settings - Fork 3
/
gear.conf
375 lines (314 loc) · 11.8 KB
/
gear.conf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
#########################################
### This is the default configuration for gearpump
### To use the application, you at least need to change gearpump.cluster to point to right master
#########################################
gearpump {
##############################
### Required to change!!
### You need to set the master cluster address here
###
###
### For example, you may start three master
### on node1: bin/master -ip node1 -port 3000
### on node2: bin/master -ip node2 -port 3000
### on node3: bin/master -ip node3 -port 3000
###
### Then you need to set the cluster.masters = ["node1:3000","node2:3000","node3:3000"]
cluster {
masters = ["127.0.0.1:3000"]
}
##############################
### Required to change!!
### You need to set the actual host name here
###
hostname = "127.0.0.1"
## How many slots each worker contains
worker.slots = 1000
## The class responsable for launching the executor process.
## User can switch to "io.gearpump.cluster.worker.CGroupProcessLauncher" to enable CGroup support.
worker.executor-process-launcher = "io.gearpump.cluster.worker.DefaultExecutorProcessLauncher"
## To enable worker use cgroup to make resource isolation,
## set gearpump.worker.executor-process-launcher = "io.gearpump.cluster.worker.CGroupProcessLauncher"
##
## Before enable it, you should also make sure:
## 1. Linux version (>= 2.6.18)
## 2. Have installed cgroup (check the file's existence:/proc/cgroups)
## You can get more information from http://gearpump.io
##
## For cgroup root, it represents the root node in CGroup's hierarchythe.
## It's full path in local file system is "${cpu_mount_point} + root".
## The cpu_mount_point is the cpu subsystem's mount poing in CGroup.
## The root dir should be consistent with the part configured in /etc/cgconfig.conf
cgroup {
root = "gearpump"
## This config only works when cgroup is enabled.
## The value means the number of CPU cores per executor can use, -1 means no limitation.
cpu-core-limit-per-executor = 1
}
## Whether we allow remote debug
remote-debug-executor-jvm = false
### When the resource cannot be allocated in the timeout, then
### the appmaster will shutdown itself.
resource-allocation-timeout-seconds = 120
###########################
### Change the dispather for tasks
### If you don't know what this is about, don't change it
###########################
task-dispatcher = "gearpump.shared-thread-pool-dispatcher"
### verbose gc
### turn on JVM verbose GC
### We will use -verbose:gc -Xloggc: -XX:+PrintGCDetails
### -XX:+PrintGCDateStamps -XX:+PrintTenuringDistribution
### -XX:+PrintGCApplicationConcurrentTime
### -XX:+PrintGCApplicationStoppedTime
verbose-gc = false
###########################
### Metrics setting,
### If you want to use metrics, please change
###########################
### Flag to enable metrics
metrics {
enabled = true
### We will take one metric out of ${sample.rate}
### This config will slightly impact the application's performance, larger rate often brings higher throughput.
sample-rate = 1
report-interval-ms = 3000
# reporter = "logfile"
# reporter = "graphite"
reporter = "akka"
graphite {
## Graphite host settings
host = "127.0.0.1"
port = 2003
}
logfile {
}
}
#######################################
### Logging settings
#######################################
# The log dir for daemon processes
log.daemon.dir = "logs"
# The log dir for applications
log.application.dir = "logs"
serializers {
## Follow this format when adding new serializer for new message types
# "yourpackage.YourClass" = "yourpackage.YourSerializerForThisClass"
## If you intend to use default serializer for this class, then you can write this
# "yourpackage.YourClass" = ""
}
### Gearpump has built-in serialization framework using Kryo.
### User are allowed to use a different serialization framework, like Protobuf
### See [io.gearpump.serializer.FastKryoSerializationFramework] to find how
### a custom serialization framework can be defined.
serialization-framework = "io.gearpump.serializer.FastKryoSerializationFramework"
### Define where the submitted jar file will be stored at
### This path follows the hadoop path schema
### For HDFS, use hdfs://host:port/path/
### For shared NFS folder, use file:///your_nfs_mapping_directory
### jarstore.rootpath = "jarstore/" will points to relative directory where master is started.
### jarstore.rootpath = "/jarstore/" will points to absolute directory on master server
# jarstore.rootpath = "jarstore/"
#########################
### Scheduller for master, it will use this scheduler to schedule resource for
### different applications.
### If you don't know what is this about, don't change it
#########################
scheduling {
scheduler-class = "io.gearpump.cluster.scheduler.PriorityScheduler"
}
#############################################
# Default Configuration for REST, WebSocket, Http services
#############################################
#########################
### services can be started by a command line tool bin/services
### If you don't know what is this about, don't change it
#########################
services {
host = "0.0.0.0"
http = 8090
}
## Time out setting to start a new executor system
## It takes a bit longer time than expected as a new JVM is created
start-executor-system-timeout-ms = 120000
#############################################
## Default Configuration for Gearpump Netty transport layer
## If you don't know what is this about, don't change it
#############################################
netty {
buffer-size = 5242880
max-retries = 30
base-sleep-ms = 100
max-sleep-ms = 1000
message-batch-size = 262144
flush-check-interval = 5
dispatcher = "gearpump.shared-thread-pool-dispatcher"
}
###################
### Appmaster JVM argument configuration
###################
appmaster {
vmargs = "-server -Xss1M -XX:+HeapDumpOnOutOfMemoryError -XX:+UseConcMarkSweepGC -XX:CMSInitiatingOccupancyFraction=80 -XX:+UseParNewGC -XX:NewRatio=3 -Djava.rmi.server.hostname=localhost"
extraClasspath = ""
}
###################
### Executor argument configuration
### Executor JVM can contains multiple tasks
###################
executor {
vmargs = "-server -Xss1M -XX:+HeapDumpOnOutOfMemoryError -XX:+UseConcMarkSweepGC -XX:CMSInitiatingOccupancyFraction=80 -XX:+UseParNewGC -XX:NewRatio=3 -Djava.rmi.server.hostname=localhost"
extraClasspath = ""
}
### Streaming related configuration
streaming {
## We will timeout the task if it cannot register itself to AppMaster in time.
register-task-timeout-ms = 120000
## ack once after sending ack-once-every-message-count messages.
ack-once-every-message-count = 1
## max pending message per task to task connection. If pending message size is
## over this, then the flow control will not allow further sending.
## This value should be bigger than ack-once-every-message-count
max-pending-message-count-per-connection = 2
}
##################################
### Akka Dispatcher configurations
### If you don't know what is this about, don't change it
##################################
shared-thread-pool-dispatcher {
mailbox-type = "akka.dispatch.SingleConsumerOnlyUnboundedMailbox"
throughput = 100
fork-join-executor {
parallelism-factor = 2
parallelism-max = 8
parallelism-min = 2
}
}
single-thread-dispatcher {
type = PinnedDispatcher
}
###########################
### Configuration for yarn module
###########################
yarn {
client {
package-path = "/usr/lib/gearpump/gearpump.zip"
}
applicationmaster {
## Memory of YarnAppMaster
command = "$JAVA_HOME/bin/java -Xmx512m"
memory = "512"
vcores = "1"
queue = "default"
}
master {
## Memory of master daemon
command = "$JAVA_HOME/bin/java -Xmx512m"
memory = "512"
vcores = "1"
}
worker {
## memory of worker daemon
command = "$JAVA_HOME/bin/java -Xmx512m"
containers = "1"
## This also contains all memory for child executors.
memory = "4096"
vcores = "1"
}
services {
enabled = true
}
}
}
### Configuration only visible to master nodes..
gearpump-master {
extensions = [
"akka.contrib.datareplication.DataReplication$"
]
akka {
#########################################
### For log level of Master, you need to change both log4j.properties and this entry
#########################################
loglevel = "INFO"
log-dead-letters = off
log-dead-letters-during-shutdown = off
actor {
## Master forms a akka cluster
provider = "akka.cluster.ClusterActorRefProvider"
}
cluster {
roles = ["master"]
## TODO: in integration test, 15s may be too small
## auto-down-unreachable-after = 90s
## The value of this setting will impact master HA recovery time
auto-down-unreachable-after = 15s
}
remote {
log-remote-lifecycle-events = off
}
}
}
### Configuration only visible to worker nodes...
gearpump-worker {
## Add worker overrided config
akka {
#########################################
### For log level of Worker, you need to change both log4j.properties and this entry
#########################################
loglevel = "INFO"
log-dead-letters = off
log-dead-letters-during-shutdown = off
actor {
provider = "akka.remote.RemoteActorRefProvider"
}
cluster {
roles = ["worker"]
}
remote {
log-remote-lifecycle-events = off
}
}
}
#########################################
### For log level of Akka class, you need to change both log4j.properties and this entry
#########################################
#akka.loglevel = "INFO"
### configurations only visible to UI server.
gearpump-ui {
## Security related settings
gearpump.ui-security {
## Whether enable authentication for UI Server
authentication-enabled = true
## What authenticator to use. The class must implement interface
## io.gearpump.security.Authenticator
authenticator = "io.gearpump.security.ConfigFileBasedAuthenticator"
## Configuration options for authenticator io.gearpump.security.ConfigFileBasedAuthenticator
config-file-based-authenticator = {
## Format: username = "password_hash_value"
## password_hash_value can be generated by running shell tool:
## bin/gear io.gearpump.security.PasswordUtil -password <your raw password>
## Admin users have super permission to do everything
admins = {
## Default Admin. Username: admin, password: admin
## !!! Please replace this builtin account for production cluster for security reason. !!!
"admin" = "AeGxGOxlU8QENdOXejCeLxy+isrCv0TrS37HwA=="
}
## normal user have special permission for certain operations.
users = {
## "user" = "AeGxGOxlU8QENdOXejCeLxy+isrCv0TrS37HwA=="
}
## Guest user can only view the UI with minimum permission. With no permission to submit/change/kill
## a running application.
guests = {
## Default guest. Username: guest, Password: guest
## !!! Please replace this builtin account for production cluster for security reason. !!!
"guest" = "ws+2Dy/FHX4cBb3uKGTR64kZWlWbC91XZRRoew=="
}
}
}
}
## Configurations only visible on Windows operation system..
gearpump-windows {
### On windows, the value must be larger than 10ms, check
### https://github.com/akka/akka/blob/master/akka-actor/src/main/scala/akka/actor/Scheduler.scala#L204
akka.scheduler.tick-duration = 10
}