@@ -413,13 +413,21 @@ pub async fn get_stream_info(
413413 Ok ( ( web:: Json ( stream_info) , StatusCode :: OK ) )
414414}
415415
416+ #[ tracing:: instrument(
417+ name = "http.put_stream_hot_tier" ,
418+ skip( req, logstream, hottier) ,
419+ fields( stream = tracing:: field:: Empty , tenant = tracing:: field:: Empty , size = hottier. size)
420+ ) ]
416421pub async fn put_stream_hot_tier (
417422 req : HttpRequest ,
418423 logstream : Path < String > ,
419424 Json ( mut hottier) : Json < StreamHotTier > ,
420425) -> Result < impl Responder , StreamError > {
421426 let stream_name = logstream. into_inner ( ) ;
422427 let tenant_id = get_tenant_id_from_request ( & req) ;
428+ tracing:: Span :: current ( )
429+ . record ( "stream" , tracing:: field:: display ( & stream_name) )
430+ . record ( "tenant" , tracing:: field:: debug ( & tenant_id) ) ;
423431 // For query mode, if the stream not found in memory map,
424432 //check if it exists in the storage
425433 //create stream and schema from storage
@@ -478,12 +486,20 @@ pub async fn put_stream_hot_tier(
478486 ) )
479487}
480488
489+ #[ tracing:: instrument(
490+ name = "http.get_stream_hot_tier" ,
491+ skip( req, logstream) ,
492+ fields( stream = tracing:: field:: Empty , tenant = tracing:: field:: Empty )
493+ ) ]
481494pub async fn get_stream_hot_tier (
482495 req : HttpRequest ,
483496 logstream : Path < String > ,
484497) -> Result < impl Responder , StreamError > {
485498 let stream_name = logstream. into_inner ( ) ;
486499 let tenant_id = get_tenant_id_from_request ( & req) ;
500+ tracing:: Span :: current ( )
501+ . record ( "stream" , tracing:: field:: display ( & stream_name) )
502+ . record ( "tenant" , tracing:: field:: debug ( & tenant_id) ) ;
487503 // For query mode, if the stream not found in memory map,
488504 //check if it exists in the storage
489505 //create stream and schema from storage
@@ -504,12 +520,20 @@ pub async fn get_stream_hot_tier(
504520 Ok ( ( web:: Json ( meta) , StatusCode :: OK ) )
505521}
506522
523+ #[ tracing:: instrument(
524+ name = "http.delete_stream_hot_tier" ,
525+ skip( req, logstream) ,
526+ fields( stream = tracing:: field:: Empty , tenant = tracing:: field:: Empty )
527+ ) ]
507528pub async fn delete_stream_hot_tier (
508529 req : HttpRequest ,
509530 logstream : Path < String > ,
510531) -> Result < impl Responder , StreamError > {
511532 let stream_name = logstream. into_inner ( ) ;
512533 let tenant_id = get_tenant_id_from_request ( & req) ;
534+ tracing:: Span :: current ( )
535+ . record ( "stream" , tracing:: field:: display ( & stream_name) )
536+ . record ( "tenant" , tracing:: field:: debug ( & tenant_id) ) ;
513537 // For query mode, if the stream not found in memory map,
514538 //check if it exists in the storage
515539 //create stream and schema from storage
0 commit comments