splunk / docker-logging-plugin

Splunk Connect for Docker is a Docker logging plugin that allows docker containers to send their logs directly to Splunk Enterprise or a Splunk Cloud deployment.
Apache License 2.0
65 stars 25 forks source link

Partial logging fix #13

Closed anushjay closed 6 years ago

anushjay commented 6 years ago
sharonx commented 6 years ago

I suggest that we change reference to partial to temp

To me the logic is:

for each message the reader reads:
    append it to a temporary buffer
    if partial == False or Timer is up or Size limit is exceeded:
        flush temp buffer
anushjay commented 6 years ago

@chenziliang Made changes after your review.

anushjay commented 6 years ago

@sharonx Made changes as per your request.

anushjay commented 6 years ago

@chenziliang @sharonx Made changes so messages are verified for sending before adding to buffer. Please review when you get a chance. All tests are passing.

sharonx commented 6 years ago

We can merge the PR first. However, I'd like to see unit tests for tempBuffer.

chenziliang commented 6 years ago

It is way cleaner right now. LGTM. Thanks !