mirror of
https://github.com/hanzoai/tasks.git
synced 2026-10-04 02:04:03 +00:00
## What changed?
<!-- Describe what has changed in this PR -->
Remove license header from every file. Because it is really hard to
follow in this PR here is the summary:
1. License header is removed from all `.go` and `.proto` files
:fireworks::fireworks:🎆.
2. `LICENSE` file in the root directory has only Temporal and Uber
copyrights.
3. 5 other `LICENSE` files added to the packages which have copyrights
different from Temporal and Uber: Datadog, Xargin, "Mat Ryer, Tyler
Bunnell and contributors".
4. `license_file` flag is removed from all code generation tools.
5. `copyright_file` flag is removed from `go:generate mockgen`
directive.
6. All copyright related targets are removed from `Makefile`.
7. Updated Temporal copyright year to 2025 everywhere.
## Why?
<!-- Tell your future self why have you made these changes -->
I double checked with legal department that it is not needed to have
license header in every file. One file per repo is enough. I put all
copyrights to the root `LICENSE` file and removed header from all other
files. Also updated tools and `Makefile`.
181 lines
8.2 KiB
Go
181 lines
8.2 KiB
Go
// Code generated by MockGen. DO NOT EDIT.
|
|
// Source: clientfactory.go
|
|
//
|
|
// Generated by this command:
|
|
//
|
|
// mockgen -package client -source clientfactory.go -destination client_factory_mock.go
|
|
//
|
|
|
|
// Package client is a generated GoMock package.
|
|
package client
|
|
|
|
import (
|
|
reflect "reflect"
|
|
time "time"
|
|
|
|
workflowservice "go.temporal.io/api/workflowservice/v1"
|
|
adminservice "go.temporal.io/server/api/adminservice/v1"
|
|
historyservice "go.temporal.io/server/api/historyservice/v1"
|
|
matchingservice "go.temporal.io/server/api/matchingservice/v1"
|
|
common "go.temporal.io/server/common"
|
|
dynamicconfig "go.temporal.io/server/common/dynamicconfig"
|
|
log "go.temporal.io/server/common/log"
|
|
membership "go.temporal.io/server/common/membership"
|
|
metrics "go.temporal.io/server/common/metrics"
|
|
testhooks "go.temporal.io/server/common/testing/testhooks"
|
|
gomock "go.uber.org/mock/gomock"
|
|
grpc "google.golang.org/grpc"
|
|
)
|
|
|
|
// MockFactory is a mock of Factory interface.
|
|
type MockFactory struct {
|
|
ctrl *gomock.Controller
|
|
recorder *MockFactoryMockRecorder
|
|
isgomock struct{}
|
|
}
|
|
|
|
// MockFactoryMockRecorder is the mock recorder for MockFactory.
|
|
type MockFactoryMockRecorder struct {
|
|
mock *MockFactory
|
|
}
|
|
|
|
// NewMockFactory creates a new mock instance.
|
|
func NewMockFactory(ctrl *gomock.Controller) *MockFactory {
|
|
mock := &MockFactory{ctrl: ctrl}
|
|
mock.recorder = &MockFactoryMockRecorder{mock}
|
|
return mock
|
|
}
|
|
|
|
// EXPECT returns an object that allows the caller to indicate expected use.
|
|
func (m *MockFactory) EXPECT() *MockFactoryMockRecorder {
|
|
return m.recorder
|
|
}
|
|
|
|
// NewHistoryClientWithTimeout mocks base method.
|
|
func (m *MockFactory) NewHistoryClientWithTimeout(timeout time.Duration) (historyservice.HistoryServiceClient, error) {
|
|
m.ctrl.T.Helper()
|
|
ret := m.ctrl.Call(m, "NewHistoryClientWithTimeout", timeout)
|
|
ret0, _ := ret[0].(historyservice.HistoryServiceClient)
|
|
ret1, _ := ret[1].(error)
|
|
return ret0, ret1
|
|
}
|
|
|
|
// NewHistoryClientWithTimeout indicates an expected call of NewHistoryClientWithTimeout.
|
|
func (mr *MockFactoryMockRecorder) NewHistoryClientWithTimeout(timeout any) *gomock.Call {
|
|
mr.mock.ctrl.T.Helper()
|
|
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "NewHistoryClientWithTimeout", reflect.TypeOf((*MockFactory)(nil).NewHistoryClientWithTimeout), timeout)
|
|
}
|
|
|
|
// NewLocalAdminClientWithTimeout mocks base method.
|
|
func (m *MockFactory) NewLocalAdminClientWithTimeout(timeout, largeTimeout time.Duration) (adminservice.AdminServiceClient, error) {
|
|
m.ctrl.T.Helper()
|
|
ret := m.ctrl.Call(m, "NewLocalAdminClientWithTimeout", timeout, largeTimeout)
|
|
ret0, _ := ret[0].(adminservice.AdminServiceClient)
|
|
ret1, _ := ret[1].(error)
|
|
return ret0, ret1
|
|
}
|
|
|
|
// NewLocalAdminClientWithTimeout indicates an expected call of NewLocalAdminClientWithTimeout.
|
|
func (mr *MockFactoryMockRecorder) NewLocalAdminClientWithTimeout(timeout, largeTimeout any) *gomock.Call {
|
|
mr.mock.ctrl.T.Helper()
|
|
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "NewLocalAdminClientWithTimeout", reflect.TypeOf((*MockFactory)(nil).NewLocalAdminClientWithTimeout), timeout, largeTimeout)
|
|
}
|
|
|
|
// NewLocalFrontendClientWithTimeout mocks base method.
|
|
func (m *MockFactory) NewLocalFrontendClientWithTimeout(timeout, longPollTimeout time.Duration) (grpc.ClientConnInterface, workflowservice.WorkflowServiceClient, error) {
|
|
m.ctrl.T.Helper()
|
|
ret := m.ctrl.Call(m, "NewLocalFrontendClientWithTimeout", timeout, longPollTimeout)
|
|
ret0, _ := ret[0].(grpc.ClientConnInterface)
|
|
ret1, _ := ret[1].(workflowservice.WorkflowServiceClient)
|
|
ret2, _ := ret[2].(error)
|
|
return ret0, ret1, ret2
|
|
}
|
|
|
|
// NewLocalFrontendClientWithTimeout indicates an expected call of NewLocalFrontendClientWithTimeout.
|
|
func (mr *MockFactoryMockRecorder) NewLocalFrontendClientWithTimeout(timeout, longPollTimeout any) *gomock.Call {
|
|
mr.mock.ctrl.T.Helper()
|
|
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "NewLocalFrontendClientWithTimeout", reflect.TypeOf((*MockFactory)(nil).NewLocalFrontendClientWithTimeout), timeout, longPollTimeout)
|
|
}
|
|
|
|
// NewMatchingClientWithTimeout mocks base method.
|
|
func (m *MockFactory) NewMatchingClientWithTimeout(namespaceIDToName NamespaceIDToNameFunc, timeout, longPollTimeout time.Duration) (matchingservice.MatchingServiceClient, error) {
|
|
m.ctrl.T.Helper()
|
|
ret := m.ctrl.Call(m, "NewMatchingClientWithTimeout", namespaceIDToName, timeout, longPollTimeout)
|
|
ret0, _ := ret[0].(matchingservice.MatchingServiceClient)
|
|
ret1, _ := ret[1].(error)
|
|
return ret0, ret1
|
|
}
|
|
|
|
// NewMatchingClientWithTimeout indicates an expected call of NewMatchingClientWithTimeout.
|
|
func (mr *MockFactoryMockRecorder) NewMatchingClientWithTimeout(namespaceIDToName, timeout, longPollTimeout any) *gomock.Call {
|
|
mr.mock.ctrl.T.Helper()
|
|
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "NewMatchingClientWithTimeout", reflect.TypeOf((*MockFactory)(nil).NewMatchingClientWithTimeout), namespaceIDToName, timeout, longPollTimeout)
|
|
}
|
|
|
|
// NewRemoteAdminClientWithTimeout mocks base method.
|
|
func (m *MockFactory) NewRemoteAdminClientWithTimeout(rpcAddress string, timeout, largeTimeout time.Duration) adminservice.AdminServiceClient {
|
|
m.ctrl.T.Helper()
|
|
ret := m.ctrl.Call(m, "NewRemoteAdminClientWithTimeout", rpcAddress, timeout, largeTimeout)
|
|
ret0, _ := ret[0].(adminservice.AdminServiceClient)
|
|
return ret0
|
|
}
|
|
|
|
// NewRemoteAdminClientWithTimeout indicates an expected call of NewRemoteAdminClientWithTimeout.
|
|
func (mr *MockFactoryMockRecorder) NewRemoteAdminClientWithTimeout(rpcAddress, timeout, largeTimeout any) *gomock.Call {
|
|
mr.mock.ctrl.T.Helper()
|
|
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "NewRemoteAdminClientWithTimeout", reflect.TypeOf((*MockFactory)(nil).NewRemoteAdminClientWithTimeout), rpcAddress, timeout, largeTimeout)
|
|
}
|
|
|
|
// NewRemoteFrontendClientWithTimeout mocks base method.
|
|
func (m *MockFactory) NewRemoteFrontendClientWithTimeout(rpcAddress string, timeout, longPollTimeout time.Duration) (grpc.ClientConnInterface, workflowservice.WorkflowServiceClient) {
|
|
m.ctrl.T.Helper()
|
|
ret := m.ctrl.Call(m, "NewRemoteFrontendClientWithTimeout", rpcAddress, timeout, longPollTimeout)
|
|
ret0, _ := ret[0].(grpc.ClientConnInterface)
|
|
ret1, _ := ret[1].(workflowservice.WorkflowServiceClient)
|
|
return ret0, ret1
|
|
}
|
|
|
|
// NewRemoteFrontendClientWithTimeout indicates an expected call of NewRemoteFrontendClientWithTimeout.
|
|
func (mr *MockFactoryMockRecorder) NewRemoteFrontendClientWithTimeout(rpcAddress, timeout, longPollTimeout any) *gomock.Call {
|
|
mr.mock.ctrl.T.Helper()
|
|
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "NewRemoteFrontendClientWithTimeout", reflect.TypeOf((*MockFactory)(nil).NewRemoteFrontendClientWithTimeout), rpcAddress, timeout, longPollTimeout)
|
|
}
|
|
|
|
// MockFactoryProvider is a mock of FactoryProvider interface.
|
|
type MockFactoryProvider struct {
|
|
ctrl *gomock.Controller
|
|
recorder *MockFactoryProviderMockRecorder
|
|
isgomock struct{}
|
|
}
|
|
|
|
// MockFactoryProviderMockRecorder is the mock recorder for MockFactoryProvider.
|
|
type MockFactoryProviderMockRecorder struct {
|
|
mock *MockFactoryProvider
|
|
}
|
|
|
|
// NewMockFactoryProvider creates a new mock instance.
|
|
func NewMockFactoryProvider(ctrl *gomock.Controller) *MockFactoryProvider {
|
|
mock := &MockFactoryProvider{ctrl: ctrl}
|
|
mock.recorder = &MockFactoryProviderMockRecorder{mock}
|
|
return mock
|
|
}
|
|
|
|
// EXPECT returns an object that allows the caller to indicate expected use.
|
|
func (m *MockFactoryProvider) EXPECT() *MockFactoryProviderMockRecorder {
|
|
return m.recorder
|
|
}
|
|
|
|
// NewFactory mocks base method.
|
|
func (m *MockFactoryProvider) NewFactory(rpcFactory common.RPCFactory, monitor membership.Monitor, metricsHandler metrics.Handler, dc *dynamicconfig.Collection, testHooks testhooks.TestHooks, numberOfHistoryShards int32, logger, throttledLogger log.Logger) Factory {
|
|
m.ctrl.T.Helper()
|
|
ret := m.ctrl.Call(m, "NewFactory", rpcFactory, monitor, metricsHandler, dc, testHooks, numberOfHistoryShards, logger, throttledLogger)
|
|
ret0, _ := ret[0].(Factory)
|
|
return ret0
|
|
}
|
|
|
|
// NewFactory indicates an expected call of NewFactory.
|
|
func (mr *MockFactoryProviderMockRecorder) NewFactory(rpcFactory, monitor, metricsHandler, dc, testHooks, numberOfHistoryShards, logger, throttledLogger any) *gomock.Call {
|
|
mr.mock.ctrl.T.Helper()
|
|
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "NewFactory", reflect.TypeOf((*MockFactoryProvider)(nil).NewFactory), rpcFactory, monitor, metricsHandler, dc, testHooks, numberOfHistoryShards, logger, throttledLogger)
|
|
}
|