@@ -37,7 +37,7 @@ public function __construct(
3737
3838public function serialize (mixed $ data ,string $ format ,array $ context = []):string
3939 {
40- $ context [self ::DEBUG_TRACE_ID ] =$ traceId =uniqid ( );
40+ $ context [self ::DEBUG_TRACE_ID ] =$ traceId =substr ( hash ( ' xxh128 ' , random_bytes ( 14 )), 0 , 6 );
4141
4242$ startTime =microtime (true );
4343$ result =$ this ->serializer ->serialize ($ data ,$ format ,$ context );
@@ -52,7 +52,7 @@ public function serialize(mixed $data, string $format, array $context = []): str
5252
5353public function deserialize (mixed $ data ,string $ type ,string $ format ,array $ context = []):mixed
5454 {
55- $ context [self ::DEBUG_TRACE_ID ] =$ traceId =uniqid ( );
55+ $ context [self ::DEBUG_TRACE_ID ] =$ traceId =substr ( hash ( ' xxh128 ' , random_bytes ( 14 )), 0 , 6 );
5656
5757$ startTime =microtime (true );
5858$ result =$ this ->serializer ->deserialize ($ data ,$ type ,$ format ,$ context );
@@ -67,7 +67,7 @@ public function deserialize(mixed $data, string $type, string $format, array $co
6767
6868public function normalize (mixed $ object , ?string $ format =null ,array $ context = []):array |string |int |float |bool |\ArrayObject |null
6969 {
70- $ context [self ::DEBUG_TRACE_ID ] =$ traceId =uniqid ( );
70+ $ context [self ::DEBUG_TRACE_ID ] =$ traceId =substr ( hash ( ' xxh128 ' , random_bytes ( 14 )), 0 , 6 );
7171
7272$ startTime =microtime (true );
7373$ result =$ this ->serializer ->normalize ($ object ,$ format ,$ context );
@@ -82,7 +82,7 @@ public function normalize(mixed $object, ?string $format = null, array $context
8282
8383public function denormalize (mixed $ data ,string $ type , ?string $ format =null ,array $ context = []):mixed
8484 {
85- $ context [self ::DEBUG_TRACE_ID ] =$ traceId =uniqid ( );
85+ $ context [self ::DEBUG_TRACE_ID ] =$ traceId =substr ( hash ( ' xxh128 ' , random_bytes ( 14 )), 0 , 6 );
8686
8787$ startTime =microtime (true );
8888$ result =$ this ->serializer ->denormalize ($ data ,$ type ,$ format ,$ context );
@@ -97,7 +97,7 @@ public function denormalize(mixed $data, string $type, ?string $format = null, a
9797
9898public function encode (mixed $ data ,string $ format ,array $ context = []):string
9999 {
100- $ context [self ::DEBUG_TRACE_ID ] =$ traceId =uniqid ( );
100+ $ context [self ::DEBUG_TRACE_ID ] =$ traceId =substr ( hash ( ' xxh128 ' , random_bytes ( 14 )), 0 , 6 );
101101
102102$ startTime =microtime (true );
103103$ result =$ this ->serializer ->encode ($ data ,$ format ,$ context );
@@ -112,7 +112,7 @@ public function encode(mixed $data, string $format, array $context = []): string
112112
113113public function decode (string $ data ,string $ format ,array $ context = []):mixed
114114 {
115- $ context [self ::DEBUG_TRACE_ID ] =$ traceId =uniqid ( );
115+ $ context [self ::DEBUG_TRACE_ID ] =$ traceId =substr ( hash ( ' xxh128 ' , random_bytes ( 14 )), 0 , 6 );
116116
117117$ startTime =microtime (true );
118118$ result =$ this ->serializer ->decode ($ data ,$ format ,$ context );