I'm trying to create a push query in my react native app and read the results.
What I have so far is...
const requestOptions = {
method: 'POST',
headers: { 'Content-Type': 'application/vnd.ksql.v1+json'},
body: JSON.stringify({ ksql: `SELECT * FROM my_stream EMIT CHANGES;` }),
};
fetch('http://localhost:8088/query', requestOptions)
.then(response => console.log(response.json()))
This successfully creates the push query but I'm not sure how to read the query results as they come in. Since the query continuously runs, I don't get any response. Is it possible to read from a push query that is created from a fetch request?