https://docs.couchbase.com/sync-gateway/3.2/whatsnew.html
Eventing Support with Sync Gateway 3.2.0+ and Couchbase Server 7.6.3+
Sync Gateway 3.2.0 now supports improved interoperability with Eventing from Couchbase Server version 7.6.3+.
You can use Eventing to handle data changes that happen when applications interact and to integrate with other Couchbase services such as Data, Query and Full Text Search.
For more information, see Eventing — Server Compatibility
Audit Logging Support
Couchbase now provides Audit Logging support for Sync Gateway. Audit Logging provides tools for administrators to track operational irregularities and to support regulatory and security compliance standards, such as HIPAA
and SOC-2. For more information, see Audit Logging.
What's Changed
- Add 3.1 release manifest by @torcolvin in #6174
- Take a copy of UserData without pointer-hacks that get optimised away by @bbrks in #6175
- enable ineffassign by @torcolvin in #6102
- Make tests work with XATTRS=false by @torcolvin in #6178
- Create 3.0.6 branch by @torcolvin in #6180
- Rest API tweaks for docs by @osfameron in #6182
- CBG-2412: Leaking rest/replicator_test.go goroutines by @gregns1 in #6181
- CBG-2844 update gocb for CCCP polling failure by @torcolvin in #6184
- Fix wrong error being passed into log due to shadowing by @bbrks in #6187
- Don't log if pruneCacheAge didn't prune anything by @bbrks in #6186
- CBG-2842 Always return unauthorized for non authorized public API by @torcolvin in #6183
- CBG-2840 Use go 1.20.3 by @torcolvin in #6191
- CBG-2711 add 3 node cluster option to jenkins by @torcolvin in #6176
- CBG-2807: Allow databases to override CORS config by @torcolvin in #6179
- CBG-2686: fix for dcp resync flake by @gregns1 in #6177
- rename gh actions to standard names by @torcolvin in #6195
- remove spurious warnings by @torcolvin in #6202
- CBG-1971: TestReplicationConcurrentPush flaky test fix by @gregns1 in #6173
- Set up 3.0.7 manifest by @adamcfraser in #6209
- CBG-2877 allow options to contain db-scoped CORS by @torcolvin in #6205
- Always close bootstrap connections from ServerContext.Close() by @bbrks in #6215
- CBG-2901 Port 3.1.0 DCP failover enhancements to main by @adamcfraser in #6213
- Set default for MULTI_NODE to avoid unbound variable error by @bbrks in #6216
- Speed up tests by reducing sleep/wait loop by @torcolvin in #6198
- Correct default value of EnableStarChannel by @bbrks in #6218
- CBG-2911 allow /db/ if default collection is configured with other named collections by @torcolvin in #6222
- CBG-2912 Add release-3.1.1 by @torcolvin in #6220
- fix manifest path for 3.1.0.xml. by @mhocouchbase in #6227
- allow rbac tests to run by @torcolvin in #6225
- flip boolean so test runs only with CBS 7.1 by @torcolvin in #6228
- Sync optimizations for changes and proposeChanges by @snej in #6190
- Produce 3.2.0 from
main
branch by @bbrks in #6753 - CBG-3852: Implementation of single sequence entry for skipped sequence slice by @gregns1 in #6747
- add manifest/3.2.xml back to product-config.json as a disabled entry. by @mhocouchbase in #6760
- CBG-3869: Fix losing user xattr on import feed for docs with no sync data by @gregns1 in #6755
- show diagnostic interface only in internal API by @torcolvin in #6745
- CBG-3721: [Diagnostic API] Import filter and sync function dry run endpoints by @mohammed-madi in #6715
- remove manifest now that 3.2 is main by @torcolvin in #6763
- 3.1.5 branch setup by @adamcfraser in #6766
- CBG-3882 add Content-Length header by @torcolvin in #6767
- CBG-3883 Restore 3.1 handling for admin_channels, admin_roles by @adamcfraser in #6768
- CBG-3703 create a basic bucket to bucket rosmar implementation by @torcolvin in #6761
- CBG-3888 make sure we can write errors to log files by @torcolvin in #6771
- Fix API version from the 3.3 -> 3.2 branch switch by @bbrks in #6778
- CBG-3844 Ensure sequence update waits for callback invocation by @adamcfraser in #6773
- Bump golang.org/x/crypto from 0.21.0 to 0.22.0 by @dependabot in #6775
- Bump golang.org/x/net from 0.22.0 to 0.24.0 by @dependabot in #6774
- Bump to latest Go - 1.22.2 by @bbrks in #6780
- CBG-3891: fix for panic in TestUnmarshalDocFromImportFeed on anemone branch by @gregns1 in #6781
- add gocb bucket feature for multi xattr subdoc operations by @torcolvin in #6779
- CBG-3835 catch error in case there is a valid json but not a JSON object by @torcolvin in #6756
- CBG-3853: Implementation of range sequence entry for skipped sequence slice by @gregns1 in #6764
- CBD-5866, advance build repo SHA by @mhocouchbase in #6783
- CBG-3768 Update only metadata during import by @adamcfraser in #6782
- CBG-3823 log warning if released unused sequence count > 1 million by @torcolvin in #6724
- CBG-3854: Integration of the skipped sequence slice into the cache by @gregns1 in #6789
- Mark minimum version of CBS 7.6.2 for XDCR by @torcolvin in #6792
- Add
SkipTestMain
utility function for clearer output by @bbrks in #6794 - [3.1.6] CBG-3907 build setup by @bbrks in #6793
- Bump github.com/felixge/fgprof from 0.9.3 to 0.9.4 by @dependabot in #6788
- CBG-3905 scope message about searching for database config by @torcolvin in #6790
- Removed GraphQL support (sob!) by @snej in #6803
- CBG-3855: Sequence range removal support by @gregns1 in #6801
- Return correct cas from WriteUpdateWithXattrs by @torcolvin in #6808
- CBG-3912 do JSON comparison using JSONEq by @torcolvin in #6811
- CBG-3915 upgrade to gocb v2.8.1 by @torcolvin in #6813
- CBG-3911 Recreate collections after tearing down databases by @torcolvin in #6809
- CBG-3914 change timeout to wait for authentication failure by @torcolvin in #6814
- CBG-3916 Use DCP feed to purge documents in viewsAndGSIBucketReadier by @adamcfraser in #6817
- Add new tests for WriteUpdateWithXattrs,WriteTombstoneWithXattrs by @torcolvin in #6816
- CBG-3913 replace parseStreamWithXattr with sg-bucket function by @torcolvin in #6812
- Skip test in CE by @torcolvin in #6823
- CBG-3920 Use IsDocNotFoundError in purgeWithDCPFeed by @adamcfraser in #6824
- Bump golang.org/x/crypto from 0.22.0 to 0.23.0 by @dependabot in #6820
- Bump golang.org/x/oauth2 from 0.18.0 to 0.20.0 by @dependabot in #6804
- CBG-3715 add RevNo to FeedEvent, and populate for DCPClient by @torcolvin in #6818
- Always skip TLS verify on TestCouchbaseServerIncorrectLogin when using TLS by @bbrks in #6826
- Test fix: Enable auto import for TestImportRollback by @bbrks in #6825
- allow tests to pass with SG_TEST_USE_XATTRS=false by @torcolvin in #6827
- CBG-1983 use testify assertions by @torcolvin in #6829
- Bump golang.org/x/net from 0.24.0 to 0.25.0 by @dependabot in #6819
- add python formatting and checking with ruff by @torcolvin in #6772
- CBG-3715 fix TestDCPFeedEventTypes by @torcolvin in #6832
- CBG-3921 use IsDocNotFoundError everywhere by @torcolvin in #6828
- CBG-3720: Diagnostic API - get all user channels endpoint by @mohammed-madi in #6647
- Fix skipped user-functions tests by @snej in #6838
- CBG-3942 tag collection in error message by @torcolvin in #6840
- CBG-3940 use atomics for counting docs by @torcolvin in #6841
- CBG-3899 Write _mou on import, resync by @adamcfraser in #6834
- CBG-3843: include collection names in status of resync by @gregns1 in #6839
- CBG-3945: Fix for panic in _clip method on skipped sequence slice by @gregns1 in #6842
- CBG-3867 disallow creating a replication with an empty ID by @torcolvin in #6844
- CBG-3958 Set up 3.1.7 build by @adamcfraser in #6851
- CBG-3957 add reason in all_dbs for why db is offline by @torcolvin in #6849
- CBG-3849 Remove inline cas handling for xattr config persistence by @adamcfraser in #6850
- CBG-3157: Add opt-in send replacementRevs feature when encountering norev by @bbrks in #6822
- CBG-3950 filter principal docs for default collection by @torcolvin in #6845
- CBG-3960: Add norev and replacement rev stats by @bbrks in #6856
- update get status resync api docs to reflect recent changes by @gregns1 in #6863
- CBG-3965 Do not regenerate sequences for principals if collections are specified by @torcolvin in #6859
- CBG-3856: Add missing permissions to GET /db/ endpoint by @gregns1 in #6847
- CBG-3968: include scope name in collections being resynced by @gregns1 in #6866
- CBG-3963 wait for principal doc readiness on resync by @torcolvin in #6864
- CBG-3963 skip index readiness for GSI by @torcolvin in #6870
- CBG-3817: fix incorrect runtime config after conflict error on collection update by @gregns1 in #6855
- CBG-3640: change serviceconfig.json to use new bootstrap config by @gregns1 in #6846
- CBG-3850: Optimise releaseUnusedSequenceRange by @gregns1 in #6831
- CBG-3925: Add FileLogger RotationInterval by @bbrks in #6835
- CBG-3851 move AssertLogContains tests to run without race detector by @torcolvin in #6873
- use golangci-lint v1.59.0 by @torcolvin in #6872
- CBG-3938: use runtime config for log_file_path by @gregns1 in #6877
- Switch to atomic values for RestTester testing.TB reference by @bbrks in #6875
- CBG-3847: log value of sync:seq on startup of a database by @gregns1 in #6876
- Reword missing collection error by @bbrks in #6878
- CBG-3988 Ensure documents are imported when collection added to a db by @adamcfraser in #6882
- Bump golang.org/x/crypto from 0.23.0 to 0.24.0 by @dependabot in #6886
- Bump golang.org/x/net from 0.25.0 to 0.26.0 by @dependabot in #6885
- CBG-3895 allow xattrs to be deleted at the same time as they are updated by @torcolvin in #6791
- CBG-3971 delete mou on normal doc write by @torcolvin in #6888
- CBG-3992 make sure doneChan2 is initialized by @torcolvin in #6890
- CBG-3781 support rhel9 variants and amazon linux 2023 by @torcolvin in #6893
- Support n1ql for LeakyDataStore by @torcolvin in #6879
- CBG-3994: fix for race between config poll and db config update by @gregns1 in #6891
- Bump golang.org/x/oauth2 from 0.20.0 to 0.21.0 by @dependabot in #6884
- CBG-4002: TestJumpInSequencesAtAllocatorSkippedSequenceFill flake by @gregns1 in #6896
- Add
IsDevMode()
andcb_sg_devmode
build tag by @bbrks in #6898 - move logging test to no race by @torcolvin in #6897
- CBG-3785 allow code to work without being in same dir as script by @torcolvin in #6899
- CBG-3941 use infinite waiting for database init manager by @torcolvin in #6889
- CBG-3783 do not print output of lsb_release by @torcolvin in #6900
- CBG-3783 don't output error if command doesn't exist by using variable by @torcolvin in #6902
- CBG-4021 Set up 3.1.8 build by @adamcfraser in #6903
- Add automatic formatting to sgcollect_info, like other python files by @torcolvin in #6907
- CBG-4011 don't add XattrsToDelete on resurrection by @torcolvin in #6901
- CBG-4008 Support all config updates during async initialization by @adamcfraser in #6909
- CBG-4019 Add init_in_progress property to db and verbose all_dbs responses by @adamcfraser in #6910
- CBG-3867 ban empty replications or replication id on REST calls by @torcolvin in #6895
- CBG-4013: Removal of per collection rev cache by @gregns1 in #6906
- CBG-4010 make FileLogger.Close shut down its own goroutines by @torcolvin in #6919
- CBG-4052: setup 3.1.9 builds by @gregns1 in #6922
- CBG-3563 Implement automatic memory profiling by @torcolvin in #6904
- Add missing heap profile docs by @torcolvin in #6932
- CBG-4012 mou handling for imports that modify the document body by @adamcfraser in #6933
- CBG-4053: bump go version to 1.22.5 by @gregns1 in #6926
- correct docs for startup config by @torcolvin in #6931
- Bump golang.org/x/net from 0.26.0 to 0.27.0 by @dependabot in #6944
- CBG-4055: update api docs for all_docs endpoint by @gregns1 in #6929
- CBG-4005 Perform mou bucket capability check once per database initialization by @adamcfraser in #6939
- Merge audit logging feature branch into
main
by @bbrks in #6946 - Add handler serverType to identify HTTP Server associated with requests by @bbrks in #6947
- CBG-4015 Refresh _sync:seq when releasing sequences in nextSequenceGreaterThan by @adamcfraser in #6937
- Adds
AssertfCtx
which conditionally panics or warns based on dev mode by @bbrks in #6948 - CBG-4003 Revocation handling for deleted roles by @adamcfraser in #6938
- CBG-3976 allow injecting global fields into logger by @torcolvin in #6921
- CBG-4025 Invalidate user roles after resync by @adamcfraser in #6942
- CBG-4063: TestVariableRateAllocators test only data race by @gregns1 in #6951
- Make mutateDbConfig only return errors for actual errors by @bbrks in #6952
- CBG-3981: Wire up PUT/POST /db/_config/audit APIs by @bbrks in #6940
- CBG-3977: Add request scoped context information. by @torcolvin in #6930
- don't panic if logger is nil by @torcolvin in #6955
- Add the initial working set of audit events by @bbrks in #6950
- CBG-4048 add audit events for replication by @torcolvin in #6949
- CBG-4050 add auditing for some database events by @torcolvin in #6953
- bugfix: load default audit events into ctx when explicit events are not defined by @bbrks in #6961
- CBG-2206: TestReplicatorDoNotSendDeltaWhenSrcIsTombstone flake by @gregns1 in #6954
- Sort audit JSON properties by @bbrks in #6964
- CBG-4027 Treat on-demand import for GET errors as not found by @adamcfraser in #6957
- CBG-4071 Avoid duplicate persisted events in db config by @adamcfraser in #6967
- OpenAPI Specs: Update /db/_config/audit endpoint body format by @bbrks in #6963
- CBG-4076 temporarily skip tests that can panic with integration tests by @torcolvin in #6968
- CBG-4046 add scope name to context for audit logging by @torcolvin in #6965
- CBG-3807: Diagnostic API - GET user/doc access endpoint by @mohammed-madi in #6892
- Add the most basic negative testing for audit API for non-existent ID by @bbrks in #6970
- CBG-4079: Wire up non-filterable events for validation/auto-enabling by @bbrks in #6972
- CBG-4047: User and role audit events by @gregns1 in #6962
- CBG-4070: fix panic in CheckpointHash function by @gregns1 in #6971
- CBG-4051 audit database creation/read/update/delete by @torcolvin in #6956
- make test robust to named collection or not by @torcolvin in #6973
- CBG-3973: Pass HTTP request information into context for audit log data by @bbrks in #6941
- remove print and make json sorting robust by @torcolvin in #6974
- CBG-4046 Populate test ctx to support audit checks within GetDocument calls by @torcolvin in #6976
- CBG-4084 Test fixes for SG_TEST_USE_DEFAULT_COLLECTION=true by @adamcfraser in #6977
- CBG-4085: Add default collection and non-xattr test CI jobs by @bbrks in #6975
- CBG-3980: Filter audit events based on CB+SG usernames by @bbrks in #6979
- CBG-4064: stamp effective user ID from header by @gregns1 in #6984
- Improve audit log validation errors by @torcolvin in #6986
- CBG-4049 Implement audit event set by @adamcfraser in #6969
- CBG-4046 add document read event by @torcolvin in #6981
- CBG-4072 Upgrade to gocbcore v10.5.1 by @adamcfraser in #6989
- CBG-4045 Implement audit events by @adamcfraser in #6991
- CBG-4068: alter enabled by default/filterable values by @gregns1 in #6985
- Populate fake server address/port for RestTester by @bbrks in #6995
- CBG-4068 follow-up (enable ISGR management events by default) by @bbrks in #6994
- CBG-4069 Restore default nil for loggers by @adamcfraser in #6990
- CBG-4060: Role-based audit filtering by @bbrks in #6980
- Bump github.com/couchbase/gocb/v2 from 2.8.1 to 2.9.1 by @dependabot in #6993
- CBG-4090 Enable fieldGroupAuthenticated by @adamcfraser in #6997
- CBG-4093 Add audit events for all roles, users by @adamcfraser in #7001
- CBG-4058: Globally configurable audit events by @bbrks in #7000
- Add h.user nil check in checkPublicAuth when getting username by @bbrks in #6996
- CBG-4090 (followup) - enable fieldGroupAuthenticated on additional events. by @adamcfraser in #7002
- CBG-4091 Add import and resync events by @adamcfraser in #6999
- Event CSV generator: Include event scope (global/db) by @bbrks in #7003
- CBG-4094: Audit REST API /_local/doc CRUD by @bbrks in #7005
- CBG-4096: add mandatory fields to AuditIDChangesFeedStarted event by @gregns1 in #7004
- CBG-4097: Filter global audit events from GET /db/_config/audit API response by @bbrks in #7006
- CBG-4046 add attachment and create, update, delete events by @torcolvin in #6988
- CBG-4098: Audit document revocation by @bbrks in #7007
- CBG-4100: Call AuditIDClusterInfoRead event by @bbrks in #7009
- CBG-4099: Correct SGcollect start audit event ID by @bbrks in #7008
- [3.2.0 Backport] CBG-4118: Add type checking to mandatory audit fields during event validation by @bbrks in #7019
- [3.2.0 Backport] CBG-4112: Flip defaultDbAuditEnabled by @bbrks in #7018
- [3.2.0 backport] CBG-4115 add AuditIDChangesFeedStarted from blip by @torcolvin in #7026
- [3.2.0 backport] CBG-4123 skip successful auth on silent handlers by @torcolvin in #7027
- [3.2.0 backport] CBG-4113: Differentiate between nil set and empty set of enabled db audit events by @torcolvin in #7028
- [3.2.0 backport] CBG-4120 Fixes for db scoped audit enabled/disabled events by @adamcfraser in #7029
- [3.2.0 Backport] CBG-4139: 3.2.0 Cherry-pick: CBG-4138: Enable log collation by default for audit logging by @bbrks in #7046
- [3.2.0 Backport] CBG-4118: Add type checking to mandatory audit field… by @bbrks in #7054
- [3.2.0 Backport] CBG-4142: Ensure expandFields does not mutate additionalData AuditFields by @bbrks in #7053
- [3.2.0 Backport] CBG-4168: Improve Audit performance (JSON marshalling / expandFields) by @bbrks in #7057
- [3.2.0 backport] CBG-4128 use a non cancellable context for OIDC metadata by @torcolvin in #7063
- CBG-4115 add WaitForPendingChanges to test by @torcolvin in #7065
- Add missing WaitForPendingChanges to fix flake by @torcolvin in #7066
- [3.2.0 Test Fix] Flush loggers before switching logger output to ensure only the audit… by @bbrks in #7067
- [3.2.0 backport] CBG-4172 improve logging for jwts by @torcolvin in #7069
- [3.2.0 backport] CBG-4163 log the source of metadata ID by @torcolvin in #7071
- [3.2.0 backport] CBG-4106 CBG-4105 : remove database if removeCorruptConfigIfExists fails by @torcolvin in #7062
- CBG-4219 [3.2.0 backport] Move duplicate protection on pendingLogs to read side by @adamcfraser in #7100
- CBG-4220 [3.2.0 backport] Pending unused sequences shouldn't update high cache sequence by @adamcfraser in #7102
Full Changelog: 3.1.11...3.2.0