Skip to content

Commit

Permalink
Instrumenting surface query service
Browse files Browse the repository at this point in the history
  • Loading branch information
sigurdp committed Nov 22, 2024
1 parent 4de51d4 commit e75a0ed
Showing 1 changed file with 6 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -82,9 +82,14 @@ async def batch_sample_surface_in_points_async(
yCoords=y_coords,
)

json_request_body = request_body.model_dump()

async with httpx.AsyncClient(timeout=300) as client:
LOGGER.info(f"Running async go point sampling for surface: {surface_name}")
response: httpx.Response = await client.post(url=SERVICE_ENDPOINT, json=request_body.model_dump())

perf_metrics.record_lap("prepare_call")

response: httpx.Response = await client.post(url=SERVICE_ENDPOINT, json=json_request_body)

perf_metrics.record_lap("main-call")

Expand Down

0 comments on commit e75a0ed

Please sign in to comment.