Why loki returns logs not in order?

As i understand it shouldn’t work so, am i misunderstand smth, or is it a bug?
i use loki 3.3.2

my request is as follows:

curl -H 'X-Scope-OrgID: javaapps' \
    --data-urlencode 'start=1741167572' \
    --data-urlencode 'query={service_name="aero-service"} | HTTP_REQUEST_LOG = "true"' \
    --data-urlencode 'limit=50' \
    http://localhost:13100/loki/api/v1/query_range | python3 -m json.tool

but as result i receive the log timestamp not in proper order:

  1. 1741167957366000000
  2. 1741167956561000000
  3. 1741167957931000000

while they had to be in order 2 → 1 → 3
Is this a bug? Or i misunderstand smth?
see below the complete response:

{
    "status": "success",
    "data": {
        "resultType": "streams",
        "result": [
            {
                "stream": {
                    "HTTP_REQUEST_LOG": "true",
                    "correlation_id": "cccc458f5b57e01ab68a403167f3a329",
                    "detected_level": "WARN",
                    "flags": "1",
                    "level": "WARN",
                    "method": "GET",
                    "observed_timestamp": "1741167957367017322",
                    "otel": "1.47.0-2.13.1",
                    "protocol": "HTTP/1.1",
                    "request": "/api/aero/asdf/asdf",
                    "request_received_at": "2025-03-05T09:45:57.338287110Z",
                    "response_content_type": "application/json",
                    "response_sent_at": "2025-03-05T09:45:57.366675595Z",
                    "response_status": "404",
                    "response_time_ms": "28",
                    "scope_name": "net.ccom.platform.backend.custom.logging.filters.CcomRequestLoggingFilter",
                    "service_instance_id": "597409cb-7a97-402f-a65e-074393dfa9bd",
                    "service_name": "aero-service",
                    "service_namespace": "ccom-dev",
                    "service_version": "2.23.0-SNAPSHOT",
                    "severity_number": "9",
                    "severity_text": "INFO",
                    "span_id": "c969043b750e62c7",
                    "thread_id": "18192",
                    "thread_name": "http-nio-8080-exec-3",
                    "trace_id": "cccc458f5b57e01ab68a403167f3a329"
                },
                "values": [
                    [
                        "1741167957366000000",
                        "GET request: '/api/aero/asdf/asdf' time took: 28 ms, status: 404"
                    ]
                ]
            },
            {
                "stream": {
                    "HTTP_REQUEST_LOG": "true",
                    "correlation_id": "c7bbaca512602a0496445c26561259ce",
                    "detected_level": "WARN",
                    "flags": "1",
                    "level": "WARN",
                    "method": "GET",
                    "observed_timestamp": "1741167956562608266",
                    "otel": "1.47.0-2.13.1",
                    "protocol": "HTTP/1.1",
                    "request": "/api/aero/asdf/asdf",
                    "request_received_at": "2025-03-05T09:45:56.518879145Z",
                    "response_content_type": "application/json",
                    "response_sent_at": "2025-03-05T09:45:56.561504763Z",
                    "response_status": "404",
                    "response_time_ms": "42",
                    "scope_name": "net.ccom.platform.backend.custom.logging.filters.CcomRequestLoggingFilter",
                    "service_instance_id": "597409cb-7a97-402f-a65e-074393dfa9bd",
                    "service_name": "aero-service",
                    "service_namespace": "ccom-dev",
                    "service_version": "2.23.0-SNAPSHOT",
                    "severity_number": "9",
                    "severity_text": "INFO",
                    "span_id": "8f06997fc2fbceb3",
                    "thread_id": "18193",
                    "thread_name": "http-nio-8080-exec-4",
                    "trace_id": "c7bbaca512602a0496445c26561259ce"
                },
                "values": [
                    [
                        "1741167956561000000",
                        "GET request: '/api/aero/asdf/asdf' time took: 42 ms, status: 404"
                    ]
                ]
            },
            {
                "stream": {
                    "HTTP_REQUEST_LOG": "true",
                    "correlation_id": "aa94e1d7cdd5baed5038c216e577a381",
                    "detected_level": "WARN",
                    "flags": "1",
                    "level": "WARN",
                    "method": "GET",
                    "observed_timestamp": "1741167957931979632",
                    "otel": "1.47.0-2.13.1",
                    "protocol": "HTTP/1.1",
                    "request": "/api/aero/asdf/asdf",
                    "request_received_at": "2025-03-05T09:45:57.912759502Z",
                    "response_content_type": "application/json",
                    "response_sent_at": "2025-03-05T09:45:57.931762333Z",
                    "response_status": "404",
                    "response_time_ms": "19",
                    "scope_name": "net.ccom.platform.backend.custom.logging.filters.CcomRequestLoggingFilter",
                    "service_instance_id": "597409cb-7a97-402f-a65e-074393dfa9bd",
                    "service_name": "aero-service",
                    "service_namespace": "ccom-dev",
                    "service_version": "2.23.0-SNAPSHOT",
                    "severity_number": "9",
                    "severity_text": "INFO",
                    "span_id": "c0c3ca7c278606a6",
                    "thread_id": "18194",
                    "thread_name": "http-nio-8080-exec-5",
                    "trace_id": "aa94e1d7cdd5baed5038c216e577a381"
                },
                "values": [
                    [
                        "1741167957931000000",
                        "GET request: '/api/aero/asdf/asdf' time took: 19 ms, status: 404"
                    ]
                ]
            }
        ],
        "stats": {
            "summary": {
                "bytesProcessedPerSecond": 171424,
                "linesProcessedPerSecond": 760,
                "totalBytesProcessed": 4056,
                "totalLinesProcessed": 18,
                "execTime": 0.023661,
                "queueTime": 0.000336,
                "subqueries": 0,
                "totalEntriesReturned": 3,
                "splits": 2,
                "shards": 2,
                "totalPostFilterLines": 6,
                "totalStructuredMetadataBytesProcessed": 2592
            },
            "querier": {
                "store": {
                    "totalChunksRef": 0,
                    "totalChunksDownloaded": 0,
                    "chunksDownloadTime": 0,
                    "queryReferencedStructuredMetadata": false,
                    "chunk": {
                        "headChunkBytes": 0,
                        "headChunkLines": 0,
                        "decompressedBytes": 0,
                        "decompressedLines": 0,
                        "compressedBytes": 0,
                        "totalDuplicates": 3,
                        "postFilterLines": 0,
                        "headChunkStructuredMetadataBytes": 0,
                        "decompressedStructuredMetadataBytes": 0
                    },
                    "chunkRefsFetchTime": 12759047,
                    "congestionControlLatency": 0,
                    "pipelineWrapperFilteredLines": 0
                }
            },
            "ingester": {
                "totalReached": 5,
                "totalChunksMatched": 2,
                "totalBatches": 6,
                "totalLinesSent": 6,
                "store": {
                    "totalChunksRef": 0,
                    "totalChunksDownloaded": 0,
                    "chunksDownloadTime": 0,
                    "queryReferencedStructuredMetadata": true,
                    "chunk": {
                        "headChunkBytes": 4056,
                        "headChunkLines": 18,
                        "decompressedBytes": 0,
                        "decompressedLines": 0,
                        "compressedBytes": 0,
                        "totalDuplicates": 0,
                        "postFilterLines": 6,
                        "headChunkStructuredMetadataBytes": 2592,
                        "decompressedStructuredMetadataBytes": 0
                    },
                    "chunkRefsFetchTime": 0,
                    "congestionControlLatency": 0,
                    "pipelineWrapperFilteredLines": 0
                }
            },
            "cache": {
                "chunk": {
                    "entriesFound": 0,
                    "entriesRequested": 0,
                    "entriesStored": 0,
                    "bytesReceived": 0,
                    "bytesSent": 0,
                    "requests": 0,
                    "downloadTime": 0,
                    "queryLengthServed": 0
                },
                "index": {
                    "entriesFound": 0,
                    "entriesRequested": 0,
                    "entriesStored": 0,
                    "bytesReceived": 0,
                    "bytesSent": 0,
                    "requests": 0,
                    "downloadTime": 0,
                    "queryLengthServed": 0
                },
                "result": {
                    "entriesFound": 0,
                    "entriesRequested": 0,
                    "entriesStored": 0,
                    "bytesReceived": 0,
                    "bytesSent": 0,
                    "requests": 0,
                    "downloadTime": 0,
                    "queryLengthServed": 0
                },
                "statsResult": {
                    "entriesFound": 0,
                    "entriesRequested": 0,
                    "entriesStored": 0,
                    "bytesReceived": 0,
                    "bytesSent": 0,
                    "requests": 0,
                    "downloadTime": 0,
                    "queryLengthServed": 0
                },
                "volumeResult": {
                    "entriesFound": 0,
                    "entriesRequested": 0,
                    "entriesStored": 0,
                    "bytesReceived": 0,
                    "bytesSent": 0,
                    "requests": 0,
                    "downloadTime": 0,
                    "queryLengthServed": 0
                },
                "seriesResult": {
                    "entriesFound": 0,
                    "entriesRequested": 0,
                    "entriesStored": 0,
                    "bytesReceived": 0,
                    "bytesSent": 0,
                    "requests": 0,
                    "downloadTime": 0,
                    "queryLengthServed": 0
                },
                "labelResult": {
                    "entriesFound": 0,
                    "entriesRequested": 0,
                    "entriesStored": 0,
                    "bytesReceived": 0,
                    "bytesSent": 0,
                    "requests": 0,
                    "downloadTime": 0,
                    "queryLengthServed": 0
                },
                "instantMetricResult": {
                    "entriesFound": 0,
                    "entriesRequested": 0,
                    "entriesStored": 0,
                    "bytesReceived": 0,
                    "bytesSent": 0,
                    "requests": 0,
                    "downloadTime": 0,
                    "queryLengthServed": 0
                }
            },
            "index": {
                "totalChunks": 0,
                "postFilterChunks": 0,
                "shardsDuration": 0,
                "usedBloomFilters": false
            }
        }
    }
}

Your return shows 3 streams returned. Logs are only sorted within each stream.