()
| 28 | ) |
| 29 | |
| 30 | func composeControllerWatcherFilters() dbCommon.PayloadFilterFunc { |
| 31 | return watcher.WithAny( |
| 32 | watcher.WithAll( |
| 33 | watcher.WithAny( |
| 34 | watcher.WithEntityTypeFilter(dbCommon.RepositoryEntityType), |
| 35 | watcher.WithEntityTypeFilter(dbCommon.OrganizationEntityType), |
| 36 | watcher.WithEntityTypeFilter(dbCommon.EnterpriseEntityType), |
| 37 | ), |
| 38 | watcher.WithAny( |
| 39 | watcher.WithOperationTypeFilter(dbCommon.CreateOperation), |
| 40 | watcher.WithOperationTypeFilter(dbCommon.DeleteOperation), |
| 41 | watcher.WithOperationTypeFilter(dbCommon.UpdateOperation), |
| 42 | ), |
| 43 | ), |
| 44 | // Watch for credential updates so we can propagate them to non-running workers. |
| 45 | watcher.WithAll( |
| 46 | watcher.WithAny( |
| 47 | watcher.WithEntityTypeFilter(dbCommon.GithubCredentialsEntityType), |
| 48 | watcher.WithEntityTypeFilter(dbCommon.GiteaCredentialsEntityType), |
| 49 | ), |
| 50 | watcher.WithOperationTypeFilter(dbCommon.UpdateOperation), |
| 51 | ), |
| 52 | ) |
| 53 | } |
| 54 | |
| 55 | func composeWorkerWatcherFilters(entity params.ForgeEntity) dbCommon.PayloadFilterFunc { |
| 56 | return watcher.WithAny( |
no test coverage detected