|
6 | 6 | */ |
7 | 7 |
|
8 | 8 | #include "fbpcs/emp_games/lift/metadata_compaction/MetadataCompactionOptions.h" |
| 9 | +#include <gflags/gflags.h> |
| 10 | +#include "fbpcs/emp_games/lift/common/CommonLiftOptions.h" |
9 | 11 |
|
10 | | -DEFINE_int32(party, 1, "1 = publisher, 2 = partner"); |
11 | | -DEFINE_bool( |
12 | | - use_xor_encryption, |
13 | | - true, |
14 | | - "Reveal output with XOR secret shares instead of in the clear to both parties"); |
15 | | -DEFINE_string(server_ip, "127.0.0.1", "Server's IP Address"); |
16 | | -DEFINE_int32( |
17 | | - port, |
18 | | - 10000, |
19 | | - "Network port for establishing connection to other player"); |
20 | | - |
21 | | -// Lift settings |
22 | 12 | DEFINE_string(input_path, "", "Input file to run lift metadata compaction"); |
| 13 | +DEFINE_string( |
| 14 | + output_global_params_base_path, |
| 15 | + "", |
| 16 | + "Local or s3 base path where output global param files are written to"); |
23 | 17 | DEFINE_string( |
24 | 18 | output_global_params_path, |
25 | 19 | "", |
26 | 20 | "Output file to write global params from input data."); |
| 21 | +DEFINE_string( |
| 22 | + output_secret_shares_base_path, |
| 23 | + "", |
| 24 | + "Local or s3 base path where output secret share files are written to"); |
27 | 25 | DEFINE_string( |
28 | 26 | output_secret_shares_path, |
29 | 27 | "", |
30 | 28 | "Output file to write compacted metadata secret share results."); |
| 29 | +// Common lift options |
| 30 | +DEFINE_bool( |
| 31 | + compute_publisher_breakdowns, |
| 32 | + true, |
| 33 | + "To enable or disable computing publisher breakdown for result validation"); |
| 34 | +DEFINE_bool( |
| 35 | + log_cost, |
| 36 | + false, |
| 37 | + "Log cost info into cloud which will be used for dashboard"); |
| 38 | +DEFINE_bool( |
| 39 | + use_tls, |
| 40 | + false, |
| 41 | + "Whether to use TLS when communicating with other parties."); |
| 42 | +DEFINE_bool( |
| 43 | + use_xor_encryption, |
| 44 | + true, |
| 45 | + "Reveal output with XOR secret shares instead of in the clear to both parties"); |
| 46 | +DEFINE_int32(concurrency, 1, "max number of games that will run concurrently"); |
31 | 47 | DEFINE_int32( |
32 | 48 | file_start_index, |
33 | 49 | 0, |
34 | 50 | "First file that will be read with base path"); |
| 51 | +DEFINE_int32( |
| 52 | + num_conversions_per_user, |
| 53 | + 4, |
| 54 | + "Cap and pad to this many conversions per user"); |
35 | 55 | DEFINE_int32(num_files, 0, "Number of files that should be read"); |
36 | | -DEFINE_string( |
37 | | - input_base_path, |
38 | | - "", |
39 | | - "Local or s3 base path for the sharded input files"); |
40 | | -DEFINE_string( |
41 | | - output_global_params_base_path, |
42 | | - "", |
43 | | - "Local or s3 base path where output global param files are written to"); |
44 | | -DEFINE_string( |
45 | | - output_secret_shares_base_path, |
46 | | - "", |
47 | | - "Local or s3 base path where output secret share files are written to"); |
48 | | -DEFINE_int32(concurrency, 1, "max number of games that will run concurrently"); |
| 56 | +DEFINE_int32(party, 1, "1 = publisher, 2 = partner"); |
49 | 57 | DEFINE_int32( |
| 58 | + port, |
| 59 | + 10000, |
| 60 | + "Network port for establishing connection to other player"); |
| 61 | +DEFINE_int64( |
50 | 62 | epoch, |
51 | 63 | 1546300800, |
52 | 64 | "Unixtime of 2019-01-01. Used as our 'new epoch' for timestamps"); |
53 | | -DEFINE_int32( |
54 | | - num_conversions_per_user, |
55 | | - 4, |
56 | | - "Cap and pad to this many conversions per user"); |
57 | | -DEFINE_bool( |
58 | | - compute_publisher_breakdowns, |
59 | | - true, |
60 | | - "To enable or disable computing publisher breakdown for result validation"); |
61 | | - |
62 | | -// TLS Settings |
63 | | -DEFINE_bool( |
64 | | - use_tls, |
65 | | - false, |
66 | | - "Whether to use TLS when communicating with other parties."); |
67 | 65 | DEFINE_string( |
68 | 66 | ca_cert_path, |
69 | 67 | "", |
70 | 68 | "Relative file path where root CA cert is stored. It will be prefixed with $HOME."); |
71 | 69 | DEFINE_string( |
72 | | - server_cert_path, |
| 70 | + input_base_path, |
73 | 71 | "", |
74 | | - "Relative file path where server cert is stored. It will be prefixed with $HOME."); |
| 72 | + "Local or s3 base path for the sharded input files"); |
| 73 | +DEFINE_string(log_cost_s3_bucket, "", "s3 bucket name"); |
| 74 | +DEFINE_string( |
| 75 | + log_cost_s3_region, |
| 76 | + ".s3.us-west-2.amazonaws.com/", |
| 77 | + "s3 region name"); |
| 78 | +DEFINE_string( |
| 79 | + pc_feature_flags, |
| 80 | + "", |
| 81 | + "A String of PC Feature Flags passing from PCS, separated by comma"); |
75 | 82 | DEFINE_string( |
76 | 83 | private_key_path, |
77 | 84 | "", |
78 | 85 | "Relative file path where private key is stored. It will be prefixed with $HOME."); |
79 | | - |
80 | | -// Logging flags |
81 | 86 | DEFINE_string( |
82 | 87 | run_name, |
83 | 88 | "", |
84 | 89 | "A user given run name that will be used in s3 filename"); |
85 | | -DEFINE_bool( |
86 | | - log_cost, |
87 | | - false, |
88 | | - "Log cost info into cloud which will be used for dashboard"); |
89 | | -DEFINE_string(log_cost_s3_bucket, "", "s3 bucket name"); |
90 | | -DEFINE_string( |
91 | | - log_cost_s3_region, |
92 | | - ".s3.us-west-2.amazonaws.com/", |
93 | | - "s3 region name"); |
94 | | - |
95 | 90 | DEFINE_string( |
96 | | - pc_feature_flags, |
| 91 | + server_cert_path, |
97 | 92 | "", |
98 | | - "A String of PC Feature Flags passing from PCS, separated by comma"); |
| 93 | + "Relative file path where server cert is stored. It will be prefixed with $HOME."); |
| 94 | +DEFINE_string(server_ip, "127.0.0.1", "Server's IP Address"); |
0 commit comments