Skip to content

Latest commit

 

History

History
22 lines (20 loc) · 1.75 KB

event_logging.md

File metadata and controls

22 lines (20 loc) · 1.75 KB

Event logging

Note: Testing event logging requires labs access to deployment-eventlog05.eqiad.wmflabs

To test event logging:

  • ensure event logging is enabled via Gear icon > Send usage reports

  • select Staging scheme in Xcode, then in Configuration's current property, change the staging options to return Configuration.staging(options: [.deploymentLabsForEventLogging]).

  • get the app install id:

    • run app in the simulator
    • pause
    • paste po [[NSUserDefaults standardUserDefaults] wmf_appInstallId]; in the Xcode console and copy the resulting string
  • ssh to labs: ssh deployment-eventlog05.eqiad.wmflabs

  • tail the following files (tail keeps stream open and prints last few lines of a file any time it changes) with the app install id and the id of the schema being tested (from MPopov):

    • /srv/log/eventlogging/all-events.log
      • only has events which have been validated against the appropriate schemas
    • /srv/log/eventlogging/client-side-events.log
      • has all incoming events (as raw, encoded URI query strings) regardless of their validity
    • /var/log/eventlogging/[email protected]
    • /var/log/eventlogging/[email protected]
      • if there are any issues with the incoming events or their validation, there will be detailed messages in the two eventlogging-processor@-client-side-XX logs

    Example:

    • tail -f /srv/log/eventlogging/all-events.log | grep "<app install id>" | grep "<schema id>"