I have a Java application that is loosely as follows:
GcpLineageTransportConfig gcpLineageTransportConfig = new GcpLineageTransportConfig();
gcpLineageTransportConfig.setProjectId("**********");
gcpLineageTransportConfig.setLocation("us-central1");
OpenLineageClient client = OpenLineageClient.
builder().
transport(new GcpLineageTransport(gcpLineageTransportConfig)).
build();
...
client.emit(runStateUpdate);
client.close();
What I find is that the application does not send the event. If I change the logic to:
client.emit(runStateUpdate);
System.out.println("Sleeping 5 seconds");
Thread.sleep(1000*5);
client.close();
the event is sent. What I believe is happening is that since the default is to transmit the event asynchronously (I.e. immediate return from client.emit(...)), I believe that client.close() is not waiting for queued event emission requests to be sent/flushed/processed. I believe this to be an error. The call to client.close() should block/wait for queued emitted events to be processed before returning.
I have a Java application that is loosely as follows:
What I find is that the application does not send the event. If I change the logic to:
the event is sent. What I believe is happening is that since the default is to transmit the event asynchronously (I.e. immediate return from
client.emit(...)), I believe thatclient.close()is not waiting for queued event emission requests to be sent/flushed/processed. I believe this to be an error. The call toclient.close()should block/wait for queued emitted events to be processed before returning.