Page MenuHomeFreeBSD

pfsync: Unconditionally push packets when requesting state updates
ClosedPublic

Authored by kp on Mar 15 2021, 6:26 PM.

Details

Summary

When we request a bulk sync we need to ensure we actually send out that
request, not just buffer it until we have enough data to send a full
packet.

PR: 254236
Submitted by: topical AT gmx.net
MFC after: 2 weeks

Diff Detail

Repository
R10 FreeBSD src repository
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

kp requested review of this revision.Mar 15 2021, 6:26 PM

I would suggest to change pfsync_request_update() to unconditionally make pfsync_push() on the bucket, regardless of request type (bulk or a single state). This will allow for some batching and shorten stuff executed from the callout context. After this change the call to pfsync_sendout() from the pfsync_request_update() can be changed to 0 in first arguemnt.

kp retitled this revision from pfsync: Flush all buckets when requesting a bulk sync to pfsync: Unconditionally push packets when requesting state updates.

I would suggest to change pfsync_request_update() to unconditionally make pfsync_push() on the bucket, regardless of request type (bulk or a single state). This will allow for some batching and shorten stuff executed from the callout context. After this change the call to pfsync_sendout() from the pfsync_request_update() can be changed to 0 in first arguemnt.

Yeah, that makes sense too. Requesting state updates should be very rare anyway, so not buffering them should be safe.

This revision was not accepted when it landed; it landed in state Needs Review.Mar 17 2021, 7:22 PM
This revision was automatically updated to reflect the committed changes.