Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: loki tests #187

Merged
merged 1 commit into from
Sep 7, 2023
Merged

chore: loki tests #187

merged 1 commit into from
Sep 7, 2023

Conversation

Pehesi97
Copy link
Contributor

What does this PR do?

This PR improves the Loki tests, adding a query to the API for recent log lines.

Related issues

Closes #161.

Checklist before merging

  • My code follows the style guidelines of this project.
  • I have performed a self-review of my own code.
  • I have checked the contributing document.
  • I have checked the existing Pull Requests to see whether someone else has raised a similar idea or question.
  • I have added tests that prove my fix is effective or that my feature works.

@Pehesi97 Pehesi97 requested a review from a team August 31, 2023 19:17
@Pehesi97 Pehesi97 self-assigned this Aug 31, 2023
@Pehesi97
Copy link
Contributor Author

Still trying to improve these, but as a unit test, it doesn't look like a query to the Loki API will return anything useful.

@Pehesi97
Copy link
Contributor Author

Example response:

{
  "status": "success",
  "data": {
    "resultType": "streams",
    "result": [],
    "stats": {
      "summary": {
        "bytesProcessedPerSecond": 0,
        "linesProcessedPerSecond": 0,
        "totalBytesProcessed": 0,
        "totalLinesProcessed": 0,
        "execTime": 0.001228,
        "queueTime": 0.000235,
        "subqueries": 0,
        "totalEntriesReturned": 0,
        "splits": 0,
        "shards": 0
      },
      "querier": {
        "store": {
          "totalChunksRef": 0,
          "totalChunksDownloaded": 0,
          "chunksDownloadTime": 0,
          "chunk": {
            "headChunkBytes": 0,
            "headChunkLines": 0,
            "decompressedBytes": 0,
            "decompressedLines": 0,
            "compressedBytes": 0,
            "totalDuplicates": 0
          }
        }
      },
      "ingester": {
        "totalReached": 1,
        "totalChunksMatched": 0,
        "totalBatches": 0,
        "totalLinesSent": 0,
        "store": {
          "totalChunksRef": 0,
          "totalChunksDownloaded": 0,
          "chunksDownloadTime": 0,
          "chunk": {
            "headChunkBytes": 0,
            "headChunkLines": 0,
            "decompressedBytes": 0,
            "decompressedLines": 0,
            "compressedBytes": 0,
            "totalDuplicates": 0
          }
        }
      },
      "cache": {
        "chunk": {
          "entriesFound": 0,
          "entriesRequested": 0,
          "entriesStored": 0,
          "bytesReceived": 0,
          "bytesSent": 0,
          "requests": 0,
          "downloadTime": 0
        },
        "index": {
          "entriesFound": 0,
          "entriesRequested": 0,
          "entriesStored": 0,
          "bytesReceived": 0,
          "bytesSent": 0,
          "requests": 0,
          "downloadTime": 0
        },
        "result": {
          "entriesFound": 0,
          "entriesRequested": 0,
          "entriesStored": 0,
          "bytesReceived": 0,
          "bytesSent": 0,
          "requests": 0,
          "downloadTime": 0
        }
      }
    }
  }
}

@Pehesi97 Pehesi97 merged commit 0bcadf9 into main Sep 7, 2023
9 checks passed
@Pehesi97 Pehesi97 deleted the chore/issue-161 branch September 7, 2023 12:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

once the demo app is deployed can see the logs in loki?
2 participants