Skip to content
Snippets Groups Projects
Commit 8615e1f0 authored by Florian Fittkau's avatar Florian Fittkau
Browse files

...

parent d0bf532e
No related branches found
No related tags found
No related merge requests found
......@@ -85,18 +85,34 @@ public class TCPConnector extends AbstractSink implements IWriter, IStringRecord
@Override
public void sendOutStringRecord(final StringRegistryRecord record) {
sendOutStringRecordOnlyIfFull(record);
while (!finishedSendingStrings) {
try {
Thread.sleep(1);
} catch (final InterruptedException e) {
}
}
if (record.getRecordSizeInBytes() > stringBuffer.remaining()) {
prioritizedSend(stringBuffer);
}
record.putIntoByteBuffer(stringBuffer, stringRegistry, this);
prioritizedSend(stringBuffer);
}
@Override
public void sendOutStringRecordOnlyIfFull(final StringRegistryRecord record) {
public void sendOutStringRecordAll(final StringRegistryRecord record) {
if (record.getRecordSizeInBytes() > stringBuffer.remaining()) {
prioritizedSend(stringBuffer);
}
record.putIntoByteBuffer(stringBuffer, stringRegistry, this);
}
@Override
public void sendOutStringRecordAllSingle(final StringRegistryRecord record) {
sendOutStringRecordAll(record);
prioritizedSend(stringBuffer);
}
@Override
public void processRecord(final IRecord record) {
if (record instanceof Trace) {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment