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

Is it possible to use this proxy code to intercept messages? #87

Open
osoykan opened this issue Apr 2, 2024 · 0 comments
Open

Is it possible to use this proxy code to intercept messages? #87

osoykan opened this issue Apr 2, 2024 · 0 comments

Comments

@osoykan
Copy link

osoykan commented Apr 2, 2024

Hi,

I would like to capture what is consumed and published from an application, and I want the application to go through a Kafka proxy. Does this source code (without docker image) serve this purpose if I used it as a library in my code-base?

Idea:

graph LR
    A[Application]
    subgraph KP[Kafka Proxy]
        B[Consumer]
        C[Producer]
        S[In Memory Message Store]
    end
    A --> KP
    KP --> K[Kafka]
    K --> KP
    subgraph T[Testing]
      V[Observation, shouldBeConsumed, shouldBePublished]
    end
    KP --> T
    KP --> A 
Loading
 kafka {
        shouldBePublished<ExampleMessage> {
            actual.aggregateId == 123 
                    && actual.metadata.topic = "example-topic" 
                    && actual.metadata.headers["example-header"] == "example-value"
        }
        shouldBeConsumed<ExampleMessage> {
            actual.aggregateId == 123
                    && actual.metadata.topic = "example-topic"
                    && actual.metadata.headers["example-header"] == "example-value"
        }
    }

The need is coming from this library that I ve been developing: https://github.com/Trendyol/stove

Do you think that the idea is possible with the proxy?

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

No branches or pull requests

1 participant