Page tree

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: added info about startup flags

   

Table of Contents

Updated for v0.6.75
To configure t5memory use it's commandline flags. To list all the flags start t5memory with help flag: ./t5memory --help. All flags related to t5memory and not libraries is under otmd.cpp section. Also you can send get request to t5memory_service/flags - it would print all the flags with description and current and default values. Here are those flags

  Flags from /home/or/workspace/translate5/translate5-tm-service-source/source/otmd.cpp:
    -add_premade_socket (if set to true, socket instance would be created
      outside of proxygen and then binded, that made possible to add tcp backog
      event handler and use socket_backog option) type: bool default: false
      currently: true
    -allowLoadingMultipleTmsSimultaneously (If set to true, multiple tms could
      be loaded from the disk at the same time. ) type: bool default: false
    -allowedram (Sets amought RAM(in MB) allowed for service to use)
      type: int64 default: 5000
    -allowedtmdsize (Sets max size of tmd file(in MB) after which t5m would not
      allow to add new data to the tm) type: int64 default: 500
    -debug_sleep_in_request_run (If set, provide artificial delay in every
      request handling execution equal to provided num of microseconds)
      type: int64 default: 0 currently: 10000000
    -disable_aslr (If set to true, process personality would be set to
      ADDR_NO_RANDOMIZE) type: bool default: false currently: true
    -enable_newlines_in_logs ((not working)if set to true, would keep newline
      symbols in the logs, otherwise(by default) newlines would be removed and
      logs would be oneliners) type: bool default: false
    -flush_tm_at_shutdown (If set to true, flushes tm when shutting down the
      app not using shutdown request) type: bool default: false
    -flush_tm_to_disk_with_every_update (If set to true, flushes tm to disk
      with every successfull update request) type: bool default: false
    -forbiddeletefiles (Set to true to keep all files(including temporary and
      tm)) type: bool default: false
    -http_listen_backlog (Sets http options listen backog) type: int64
      default: 128 currently: 32
    -ignore_newer_target_exists_check (if set to true, check for newer already
      saved target would be skipped for saving segments) type: bool
      default: true
    -keep_tm_backups (if set to true, when saving tmd and tmi files, old copies
      would be saved with .old suffix) type: bool default: true
    -limit_num_of_active_requests (If set to true, it would be possible to
      handle only up to servicethreads-1 requests at the same time, the last
      thread would respond with 503 to eliminate creating queue of requests
      waiting to be handled.) type: bool default: false
    -logMutexes (if set to true you would see mutex logs) type: bool
      default: false
    -log_every_request_end (Sets log for every request end  with it's url,
      method etc...) type: bool default: false
    -log_every_request_start (Sets log for every request call with it's url,
      method etc...) type: bool default: false
    -log_memmove_in_compareputdata (if set to true, when saving segment and
      causing memmove in compareputdata functions, just before memmove, data
      would be logged - use this to debug btree crashes.) type: bool
      default: false
    -log_tcp_backog_events (if set to true, tcp backlog events would be
      logged(to enable, add_premade_socket flag should be set to true))
      type: bool default: false currently: true
    -port (What port to listen on) type: int32 default: 4080
    -servicename (Sets service name to use in url) type: string
      default: "t5memory"
    -servicethreads (Sets amought of worker threads for service) type: int32
      default: 5
    -socket_backlog (Sets proxygen socket listen backog(disabled, to enable set
      add_premade_socket=true)) type: int64 default: 1024 currently: 32
    -t5_ip (Which ip to use in t5memory(default is any). Should be in format
      '1.1.1.1', default is to listen to all available ip) type: string
      default: ""
    -t5loglevel (Sets t5memory log level threshold from DEVELOP(0) to
      TRANSACTION(6)) type: int32 default: 2 currently: 3
    -timeout (Sets timeout for service request handling) type: int32
      default: 180000
    -tmListLockDefaultTimeout (Sets tm mutex lock timeout(in ms) for TM
      list(which is used to open and close tms, and hold list of opened tms),
      after which operation would be canceled and mutex would return an error,
      if set to 0, mutex lock would be waited without timeout) type: int64
      default: 3000
    -tmLockDefaultTimeout (Sets tm mutex lock timeout(in ms) for TM after which
      operation would be canceled and mutex would return an error, if set to 0,
      mutex lock would be waited without timeout) type: int64 default: 3000
    -tmRequestLockDefaultTimeout (Sets tm mutex lock timeout(in ms) for part
      where request is requesting tm(which is used to open and close tms, and
      hold list of opened tms), after which operation would be canceled and
      mutex would return an error, if set to 0, mutex lock would be waited
      without timeout) type: int64 default: 3000
    -triplesthreshold (Sets threshold to pre fuzzy filtering based on hashes of
      neibour tokens) type: int32 default: 5
    -useTimedMutexesForReorganizeAndImport (If set to true, in reorganize or
      import thread would be used mutexes with timeouts, and reorganizee or
      import could be canceled, false(by default) - would be used non timed
      mutexes) type: bool default: false
    -wait_for_import_and_reorganize_requests (If set to true, waiting for all
      import and reorganize processes to be done at shutdown when not using
      shutdown request) type: bool default: true


Overview and API introduction

...