hunk.code_window: -- | Collection of various server metrics
   data ServerMetrics
     = ServerMetrics
     { smWarpThreads         :: !EKG.Gauge.Gauge
     -- ^ Current Number of warp threads
     , smNumEventsFetched    :: !EKG.Distribution.Distribution
     -- ^ Total Number of events fetched from last 'Event Trigger Fetch'
  
hunk.labels: keep keep keep replace replace replace keep
hunk.after_edit:   { smWarpThreads          :: !EKG.Gauge.Gauge
     -- ^ Current Number of active Warp threads
     , smWebsocketConnections :: !EKG.Gauge.Gauge
     -- ^ Current number of active websocket connections
     , smNumEventsFetched     :: !EKG.Distribution.Distribution
  
hunk.file_path: server/src-lib/Hasura/Server/Init/Config.hs
hunk.type: replace
file: import pytest
  from context import PytestConf
  
  if not PytestConf.config.getoption("--hge-key"):
      pytest.skip("--hge-key flag is missing, skipping tests", allow_module_level=True)
  
  def v1qCompat(hge_ctx, q, headers = {}):
          h = {'X-Hasura-Access-Key': hge_ctx.hge_key}
          resp = hge_ctx.http.post(
              hge_ctx.hge_url + "/v1/query",
              json=q,
              headers=h
          )
          return resp.status_code, resp.json()
  
  class TestGraphQLCompatAccessKey():
  
      export_metadata = {
         "type" : "export_metadata",
         "args" : {}
      }
  
      def test_compact_access_key_export_metadata(self, hge_ctx):
          code, resp = v1qCompat(hge_ctx, self.export_metadata)
          assert code == 200, resp
  