@@ -27,6 +27,9 @@ namespace node_module fb303
2727namespace go fb303.thrift.fb303_core
2828namespace js fb303
2929
30+ include " thrift/annotation/cpp.thrift"
31+ include " thrift/annotation/thrift.thrift"
32+
3033/**
3134 * Common status reporting mechanism across all services
3235 */
@@ -49,15 +52,19 @@ service BaseService {
4952 /**
5053 * Gets the status of this service
5154 */
52- fb303_status getStatus () (
53- priority = ' IMPORTANT' ,
54- cpp.generate_deprecated_header_client_methods ,
55- );
55+ @thrift.DeprecatedUnvalidatedAnnotations{
56+ items = {"cpp.generate_deprecated_header_client_methods": "1"},
57+ }
58+ @thrift.Priority{level = thrift.RpcPriority.IMPORTANT}
59+ fb303_status getStatus();
5660
5761 /**
5862 * Returns a descriptive name of the service
5963 */
60- string getName () (cpp.generate_deprecated_header_client_methods );
64+ @thrift.DeprecatedUnvalidatedAnnotations{
65+ items = {"cpp.generate_deprecated_header_client_methods": "1"},
66+ }
67+ string getName();
6168
6269 /**
6370 * Returns the version of the service
@@ -68,44 +75,49 @@ service BaseService {
6875 * User friendly description of status, such as why the service is in
6976 * the dead or warning state, or what is being started or stopped.
7077 */
71- string getStatusDetails () (priority = ' IMPORTANT' );
78+ @thrift.Priority{level = thrift.RpcPriority.IMPORTANT}
79+ string getStatusDetails();
7280
7381 /**
7482 * Gets the counters for this service
7583 */
76- map<string, i64> getCounters () (thread = ' eb' );
84+ @cpp.ProcessInEbThreadUnsafe
85+ map<string, i64> getCounters();
7786
7887 /**
7988 * Gets a subset of counters which match a
8089 * Perl Compatible Regular Expression for this service
8190 */
82- map<string, i64> getRegexCounters (1: string regex ) (thread = ' eb' );
91+ @cpp.ProcessInEbThreadUnsafe
92+ map<string, i64> getRegexCounters(1: string regex);
8393
8494 /**
8595 * Get counter values for a specific list of keys. Returns a map from
8696 * key to counter value; if a requested counter doesn't exist, it won't
8797 * be in the returned map.
8898 */
89- map<string, i64> getSelectedCounters (1: list<string> keys ) (thread = ' eb' );
99+ @cpp.ProcessInEbThreadUnsafe
100+ map<string, i64> getSelectedCounters(1: list<string> keys);
90101
91102 /**
92103 * Gets the value of a single counter
93104 */
94- i64 getCounter (1: string key ) (priority = ' IMPORTANT' );
105+ @thrift.Priority{level = thrift.RpcPriority.IMPORTANT}
106+ i64 getCounter(1: string key);
95107
96108 /**
97109 * Gets the exported string values for this service
98110 */
99- map<string, string> getExportedValues () (priority = ' IMPORTANT' );
111+ @thrift.Priority{level = thrift.RpcPriority.IMPORTANT}
112+ map<string, string> getExportedValues();
100113
101114 /**
102115 * Get exported strings for a specific list of keys. Returns a map from
103116 * key to string value; if a requested key doesn't exist, it won't
104117 * be in the returned map.
105118 */
106- map<string, string> getSelectedExportedValues (1: list<string> keys ) (
107- priority = ' IMPORTANT' ,
108- );
119+ @thrift.Priority{level = thrift.RpcPriority.IMPORTANT}
120+ map<string, string> getSelectedExportedValues(1: list<string> keys);
109121
110122 /**
111123 * Gets a subset of exported values which match a
@@ -116,7 +128,8 @@ service BaseService {
116128 /**
117129 * Gets the value of a single exported string
118130 */
119- string getExportedValue (1: string key ) (priority = ' IMPORTANT' );
131+ @thrift.Priority{level = thrift.RpcPriority.IMPORTANT}
132+ string getExportedValue(1: string key);
120133
121134 /**
122135 * Sets an option
@@ -136,5 +149,6 @@ service BaseService {
136149 /**
137150 * Returns the unix time that the server has been running since
138151 */
139- i64 aliveSince () (priority = ' IMPORTANT' );
152+ @thrift.Priority{level = thrift.RpcPriority.IMPORTANT}
153+ i64 aliveSince();
140154}
0 commit comments