log every compute_tast
[hiphop-php.git] / hphp / hack / src / stubs / logging / hackEventLogger.ml
blobb0fff716d5f35e46fcc5db92c181ac831315aadb
1 (*
2 * Copyright (c) 2015, Facebook, Inc.
3 * All rights reserved.
5 * This source code is licensed under the MIT license found in the
6 * LICENSE file in the "hack" directory of this source tree.
8 *)
10 type serialized_globals = Serialized_globals
12 let serialize_globals () = Serialized_globals
14 type rollout_flags = {
15 use_direct_decl_parser: bool;
16 longlived_workers: bool;
17 require_saved_state: bool;
18 stream_errors: bool;
19 force_shallow_decl_fanout: bool;
20 log_from_client_when_slow_monitor_connections: bool;
21 naming_sqlite_in_hack_64: bool;
22 use_hack_64_naming_table: bool;
23 enable_disk_heap: bool;
24 ide_max_num_decls: int;
25 ide_max_num_shallow_decls: int;
26 ide_max_num_linearizations: int;
29 let flush () = ()
31 let deserialize_globals _ = ()
33 let set_use_watchman _ = ()
35 let set_use_full_fidelity_parser _ = ()
37 let set_lazy_incremental _ = ()
39 let set_search_chunk_size _ = ()
41 let set_changed_mergebase _ = ()
43 let set_from _ = ()
45 let set_hhconfig_version _ = ()
47 let set_rollout_flags _ = ()
49 let typechecker_exit _ _ _ ~exit_type:_ ~exit_code:_ ~exit_status:_ ~is_oom:_ =
52 let init
53 ~root:_
54 ~hhconfig_version:_
55 ~init_id:_
56 ~custom_columns:_
57 ~informant_managed:_
58 ~rollout_flags:_
59 ~time:_
60 ~max_workers:_
61 ~profile_owner:_
62 ~profile_desc:_ =
65 let init_worker
66 ~root:_
67 ~hhconfig_version:_
68 ~init_id:_
69 ~custom_columns:_
70 ~rollout_flags:_
71 ~time:_
72 ~profile_owner:_
73 ~profile_desc:_ =
76 let init_monitor
77 ~from:_
78 ~custom_columns:_
79 ~proc_stack:_
80 ~hhconfig_version:_
81 ~rollout_flags:_
84 _ =
87 let init_batch_tool ~init_id:_ ~root:_ ~time:_ = ()
89 let starting_first_server _ = ()
91 let refuse_to_restart_server ~reason:_ ~server_state:_ ~version_matches:_ = ()
93 let server_receipt_to_monitor_write_exn ~server_receipt_to_monitor_file:_ _ = ()
95 let server_receipt_to_monitor_read_exn ~server_receipt_to_monitor_file:_ _ _ =
98 let init_lazy_end
99 _ ~state_distance:_ ~approach_name:_ ~init_error:_ ~init_type:_ =
102 let server_is_partially_ready () = ()
104 let server_is_ready _ = ()
106 let load_deptable_end _ = ()
108 let saved_state_download_and_load_done
109 ~load_state_approach:_
110 ~success:_
111 ~state_result:_
112 ~load_state_natively_64bit:_
116 let tried_to_be_hg_aware_with_precomputed_saved_state_warning _ = ()
118 let init_start ~experiments_config_meta:_ _ = ()
120 let nfs_root _ = ()
122 let load_state_worker_end ~is_cached:_ _ _ = ()
124 let vcs_changed_files_end _ _ = ()
126 let type_check_dirty ~start_t:_ ~dirty_count:_ ~recheck_count:_ = ()
128 let out_of_date _ = ()
130 let lock_stolen _ = ()
132 let client_init ~init_id:_ ~custom_columns:_ _ = ()
134 let serverless_ide_init ~init_id:_ = ()
136 let client_set_mode _ = ()
138 let serverless_ide_set_root _ = ()
140 let client_start _ = ()
142 let client_stop _ = ()
144 let client_restart ~data:_ = ()
146 let client_check_start () = ()
148 let client_check _ _ = ()
150 let client_lsp_method_handled
151 ~root:_
152 ~method_:_
153 ~kind:_
154 ~path_opt:_
155 ~result_count:_
156 ~result_extra_telemetry:_
157 ~tracking_id:_
158 ~start_queue_time:_
159 ~start_hh_server_state:_
160 ~start_handle_time:_
161 ~serverless_ide_flag:_ =
164 let client_lsp_method_exception
165 ~root:_
166 ~method_:_
167 ~kind:_
168 ~path_opt:_
169 ~tracking_id:_
170 ~start_queue_time:_
171 ~start_hh_server_state:_
172 ~start_handle_time:_
173 ~serverless_ide_flag:_
174 ~message:_
175 ~data_opt:_
176 ~source:_ =
179 let serverless_ide_bug ~message:_ ~data:_ = ()
181 let client_lsp_exception ~root:_ ~message:_ ~data_opt:_ ~source:_ = ()
183 let serverless_ide_startup ~component:_ ~start_time:_ = ()
185 let serverless_ide_local_files ~local_file_count:_ = ()
187 let serverless_ide_destroy_ok _ = ()
189 let serverless_ide_destroy_error _ _ _ = ()
191 let server_hung_up
192 ~external_exit_status:_
193 ~underlying_exit_status:_
194 ~client_exn:_
195 ~client_stack:_
196 ~server_stack:_
197 ~server_msg:_ =
200 let client_bad_exit ~command_name:_ _ _ = ()
202 let glean_globalrev_supplied ~globalrev:_ = ()
204 let glean_globalrev_from_hg ~globalrev:_ ~start_time:_ = ()
206 let glean_globalrev_error _ = ()
208 let glean_init _ ~start_time:_ = ()
210 let glean_init_failure _ ~stack:_ = ()
212 let glean_fetch_namespaces ~count:_ ~start_time:_ = ()
214 let glean_fetch_namespaces_error _ = ()
216 let ranked_autocomplete_duration ~start_time:_ = ()
218 let ranked_autocomplete_request_duration ~start_time:_ = ()
220 let monitor_dead_but_typechecker_alive () = ()
222 let client_established_connection _ = ()
224 let client_establish_connection_exception _ = ()
226 let client_connect_once ~t_start:_ = ()
228 let client_connect_once_failure ~t_start:_ _ = ()
230 let client_connect_to_monitor_slow_log () = ()
232 let client_connect_autostart () = ()
234 let check_response _ = ()
236 let got_client_channels _ = ()
238 let get_client_channels_exception _ = ()
240 let got_persistent_client_channels _ = ()
242 let get_persistent_client_channels_exception _ = ()
244 let handled_connection _ = ()
246 let handle_connection_exception _ _ = ()
248 let handled_persistent_connection _ = ()
250 let handle_persistent_connection_exception _ _ ~is_fatal:_ = ()
252 let handled_command
253 _ ~start_t:_ ~major_gc_time:_ ~minor_gc_time:_ ~parsed_files:_ =
256 let remote_scheduler_get_dirty_files_end _ _ = ()
258 let remote_scheduler_update_dependency_graph_end ~edges:_ _ = ()
260 let remote_scheduler_save_naming_end _ = ()
262 let credentials_check_failure _ _ = ()
264 let credentials_check_end _ _ = ()
266 let remote_worker_type_check_end _ = ()
268 let remote_worker_load_naming_end _ = ()
270 let recheck_end _ _ _ _ _ = ()
272 let indexing_end ~desc:_ _ = ()
274 let parsing_end _ _ ~parsed_count:_ = ()
276 let parsing_end_for_init _ _ ~parsed_count:_ ~desc:_ = ()
278 let parsing_end_for_typecheck _ _ ~parsed_count:_ = ()
280 let naming_costly_iter ~start_t:_ = ()
282 let naming_end ~count:_ _ _ = ()
284 let global_naming_end ~count:_ ~desc:_ ~heap_size:_ ~start_t:_ = ()
286 let run_search_end _ = ()
288 let update_search_end _ _ = ()
290 let naming_from_saved_state_end _ = ()
292 let naming_sqlite_local_changes_nonempty _ = ()
294 let type_decl_end _ = ()
296 let first_redecl_end _ _ = ()
298 let second_redecl_end _ _ = ()
300 let type_check_primary_position_bug ~current_file:_ ~message:_ ~stack:_ = ()
302 let type_check_exn_bug ~path:_ ~pos:_ ~e:_ = ()
304 let invariant_violation_bug ~path:_ ~pos:_ ~desc:_ _ = ()
306 let type_check_end
308 ~heap_size:_
309 ~started_count:_
310 ~count:_
311 ~adhoc_profiling:_
312 ~desc:_
313 ~experiments:_
314 ~start_t:_ =
317 let notifier_returned _ _ = ()
319 let load_state_exn _ = ()
321 let prechecked_update_rechecked _ = ()
323 let prechecked_evaluate_init _ _ = ()
325 let prechecked_evaluate_incremental _ _ = ()
327 let check_mergebase_failed _ _ = ()
329 let check_mergebase_success _ = ()
331 let type_at_pos_batch ~start_time:_ ~num_files:_ ~num_positions:_ ~results:_ =
334 let with_id ~stage:_ _ f = f ()
336 let with_rechecked_stats _ _ _ f = f ()
338 let with_init_type _ f = f ()
340 let with_check_kind _ f = f ()
342 let state_loader_dirty_files _ = ()
344 let changed_while_parsing_end _ = ()
346 let save_decls_end _ _ = ()
348 let save_decls_failure _ = ()
350 let load_decls_end _ = ()
352 let load_decls_failure _ _ = ()
354 let saved_state_load_ok _ ~start_time:_ = ()
356 let saved_state_load_failure _ ~start_time:_ = ()
358 let saved_state_dirty_files_ok ~start_time:_ = ()
360 let saved_state_dirty_files_failure _ ~start_time:_ = ()
362 (** Informant events *)
363 let init_informant_prefetcher_runner _ = ()
365 let informant_decision_on_saved_state
366 ~start_t:_ ~state_distance:_ ~incremental_distance:_ =
369 let informant_induced_kill _ = ()
371 let informant_induced_restart _ = ()
373 let informant_no_xdb_result _ = ()
375 let informant_prefetcher_success _ = ()
377 let informant_prefetcher_failed _ _ = ()
379 let informant_prefetcher_timed_out _ = ()
381 let informant_state_leave _ = ()
383 let find_svn_rev_failed _ _ = ()
385 let find_svn_rev_success _ = ()
387 let find_xdb_match_failed _ _ = ()
389 let find_xdb_match_success _ = ()
391 let find_xdb_match_timed_out _ = ()
393 let informant_find_saved_state_failed _ = ()
395 let informant_find_saved_state_success ~distance:_ _ = ()
397 let revision_tracker_init_svn_rev_failed _ = ()
399 let xdb_malformed_result _ = ()
401 (** Watchman Event Watcher client running in the informant *)
402 let informant_watcher_not_available _ = ()
404 let informant_watcher_unknown_state _ = ()
406 let informant_watcher_mid_update_state _ = ()
408 let informant_watcher_settled_state _ = ()
410 let informant_watcher_starting_server_from_settling _ = ()
412 (** Server Monitor events *)
413 let accepting_on_socket_exception _ = ()
415 let malformed_build_id _ = ()
417 let send_fd_failure _ = ()
419 let typechecker_already_running _ = ()
421 (** Watchman Event Watcher events *)
422 let init_watchman_event_watcher _ _ = ()
424 let init_watchman_failed _ = ()
426 let restarting_watchman_subscription _ = ()
428 let watchman_uncaught_exception _ = ()
430 let monitor_giving_up_exception _ = ()
432 let processed_clients _ = ()
434 let search_symbol_index
435 ~query_text:_
436 ~max_results:_
437 ~results:_
438 ~kind_filter:_
439 ~duration:_
440 ~actype:_
441 ~caller:_
442 ~search_provider:_ =
445 let shallow_decl_errors_emitted _ = ()
447 let server_progress_write_exn ~server_progress_file:_ _ = ()
449 let server_progress_read_exn ~server_progress_file:_ _ = ()
451 let worker_exception _ = ()
453 module ProfileTypeCheck = struct
454 let process_file ~recheck_id:_ ~path:_ ~telemetry:_ = ()
456 let compute_tast ~path:_ ~telemetry:_ ~start_time:_ = ()
458 let get_telemetry_url ~init_id:_ ~recheck_id:_ = ""
461 module CGroup = struct
462 let error _ = ()
464 let step
465 ~cgroup:_
466 ~step_group:_
467 ~step:_
468 ~start_time:_
469 ~total_start:_
470 ~totalswap_start:_
471 ~anon_start:_
472 ~shmem_start:_
473 ~file_start:_
474 ~total_hwm:_
475 ~total:_
476 ~totalswap:_
477 ~anon:_
478 ~shmem:_
479 ~file:_ =
483 module ReHulk = struct
484 let profile
485 ~recheck_id:_
486 ~start_time:_
487 ~action:_
488 ~re_worker:_
489 ~queued_duration:_
490 ~input_upload_duration:_
491 ~input_fetch_duration:_
492 ~output_upload_duration:_
493 ~output_fetch_duration:_
494 ~worker_duration:_
495 ~execution_duration:_ =
499 module Memory = struct
500 let profile_if_needed () = ()
503 module ProfileDecl = struct
504 let count_decl
505 ~kind:_
506 ~cpu_duration:_
507 ~decl_id:_
508 ~decl_name:_
509 ~decl_origin:_
510 ~decl_file:_
511 ~decl_callstack:_
512 ~decl_start_time:_
513 ~subdecl_member_name:_
514 ~subdecl_eagerness:_
515 ~subdecl_callstack:_
516 ~subdecl_start_time:_ =
520 module Rage = struct
521 let rage_start ~rageid:_ ~desc:_ ~root:_ ~from:_ ~disk_config:_ = ()
523 let rage
524 ~rageid:_
525 ~desc:_
526 ~vscode_bugid:_
527 ~merged_logs:_
528 ~root:_
529 ~from:_
530 ~hhconfig_version:_
531 ~disk_config:_
532 ~experiments:_
533 ~experiments_config_meta:_
534 ~items:_
535 ~result:_
536 ~start_time:_ =
539 let get_telemetry_url ~(rageid : string) : string = rageid