mirror of
https://github.com/hanzoai/tasks.git
synced 2026-11-02 12:22:18 +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`.
153 lines
5.1 KiB
Go
153 lines
5.1 KiB
Go
// Code generated by MockGen. DO NOT EDIT.
|
|
// Source: controller.go
|
|
//
|
|
// Generated by this command:
|
|
//
|
|
// mockgen -package shard -source controller.go -destination controller_mock.go
|
|
//
|
|
|
|
// Package shard is a generated GoMock package.
|
|
package shard
|
|
|
|
import (
|
|
context "context"
|
|
reflect "reflect"
|
|
|
|
namespace "go.temporal.io/server/common/namespace"
|
|
pingable "go.temporal.io/server/common/pingable"
|
|
interfaces "go.temporal.io/server/service/history/interfaces"
|
|
gomock "go.uber.org/mock/gomock"
|
|
)
|
|
|
|
// MockController is a mock of Controller interface.
|
|
type MockController struct {
|
|
ctrl *gomock.Controller
|
|
recorder *MockControllerMockRecorder
|
|
isgomock struct{}
|
|
}
|
|
|
|
// MockControllerMockRecorder is the mock recorder for MockController.
|
|
type MockControllerMockRecorder struct {
|
|
mock *MockController
|
|
}
|
|
|
|
// NewMockController creates a new mock instance.
|
|
func NewMockController(ctrl *gomock.Controller) *MockController {
|
|
mock := &MockController{ctrl: ctrl}
|
|
mock.recorder = &MockControllerMockRecorder{mock}
|
|
return mock
|
|
}
|
|
|
|
// EXPECT returns an object that allows the caller to indicate expected use.
|
|
func (m *MockController) EXPECT() *MockControllerMockRecorder {
|
|
return m.recorder
|
|
}
|
|
|
|
// CloseShardByID mocks base method.
|
|
func (m *MockController) CloseShardByID(shardID int32) {
|
|
m.ctrl.T.Helper()
|
|
m.ctrl.Call(m, "CloseShardByID", shardID)
|
|
}
|
|
|
|
// CloseShardByID indicates an expected call of CloseShardByID.
|
|
func (mr *MockControllerMockRecorder) CloseShardByID(shardID any) *gomock.Call {
|
|
mr.mock.ctrl.T.Helper()
|
|
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "CloseShardByID", reflect.TypeOf((*MockController)(nil).CloseShardByID), shardID)
|
|
}
|
|
|
|
// GetPingChecks mocks base method.
|
|
func (m *MockController) GetPingChecks() []pingable.Check {
|
|
m.ctrl.T.Helper()
|
|
ret := m.ctrl.Call(m, "GetPingChecks")
|
|
ret0, _ := ret[0].([]pingable.Check)
|
|
return ret0
|
|
}
|
|
|
|
// GetPingChecks indicates an expected call of GetPingChecks.
|
|
func (mr *MockControllerMockRecorder) GetPingChecks() *gomock.Call {
|
|
mr.mock.ctrl.T.Helper()
|
|
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetPingChecks", reflect.TypeOf((*MockController)(nil).GetPingChecks))
|
|
}
|
|
|
|
// GetShardByID mocks base method.
|
|
func (m *MockController) GetShardByID(shardID int32) (interfaces.ShardContext, error) {
|
|
m.ctrl.T.Helper()
|
|
ret := m.ctrl.Call(m, "GetShardByID", shardID)
|
|
ret0, _ := ret[0].(interfaces.ShardContext)
|
|
ret1, _ := ret[1].(error)
|
|
return ret0, ret1
|
|
}
|
|
|
|
// GetShardByID indicates an expected call of GetShardByID.
|
|
func (mr *MockControllerMockRecorder) GetShardByID(shardID any) *gomock.Call {
|
|
mr.mock.ctrl.T.Helper()
|
|
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetShardByID", reflect.TypeOf((*MockController)(nil).GetShardByID), shardID)
|
|
}
|
|
|
|
// GetShardByNamespaceWorkflow mocks base method.
|
|
func (m *MockController) GetShardByNamespaceWorkflow(namespaceID namespace.ID, workflowID string) (interfaces.ShardContext, error) {
|
|
m.ctrl.T.Helper()
|
|
ret := m.ctrl.Call(m, "GetShardByNamespaceWorkflow", namespaceID, workflowID)
|
|
ret0, _ := ret[0].(interfaces.ShardContext)
|
|
ret1, _ := ret[1].(error)
|
|
return ret0, ret1
|
|
}
|
|
|
|
// GetShardByNamespaceWorkflow indicates an expected call of GetShardByNamespaceWorkflow.
|
|
func (mr *MockControllerMockRecorder) GetShardByNamespaceWorkflow(namespaceID, workflowID any) *gomock.Call {
|
|
mr.mock.ctrl.T.Helper()
|
|
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetShardByNamespaceWorkflow", reflect.TypeOf((*MockController)(nil).GetShardByNamespaceWorkflow), namespaceID, workflowID)
|
|
}
|
|
|
|
// InitialShardsAcquired mocks base method.
|
|
func (m *MockController) InitialShardsAcquired(arg0 context.Context) error {
|
|
m.ctrl.T.Helper()
|
|
ret := m.ctrl.Call(m, "InitialShardsAcquired", arg0)
|
|
ret0, _ := ret[0].(error)
|
|
return ret0
|
|
}
|
|
|
|
// InitialShardsAcquired indicates an expected call of InitialShardsAcquired.
|
|
func (mr *MockControllerMockRecorder) InitialShardsAcquired(arg0 any) *gomock.Call {
|
|
mr.mock.ctrl.T.Helper()
|
|
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "InitialShardsAcquired", reflect.TypeOf((*MockController)(nil).InitialShardsAcquired), arg0)
|
|
}
|
|
|
|
// ShardIDs mocks base method.
|
|
func (m *MockController) ShardIDs() []int32 {
|
|
m.ctrl.T.Helper()
|
|
ret := m.ctrl.Call(m, "ShardIDs")
|
|
ret0, _ := ret[0].([]int32)
|
|
return ret0
|
|
}
|
|
|
|
// ShardIDs indicates an expected call of ShardIDs.
|
|
func (mr *MockControllerMockRecorder) ShardIDs() *gomock.Call {
|
|
mr.mock.ctrl.T.Helper()
|
|
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "ShardIDs", reflect.TypeOf((*MockController)(nil).ShardIDs))
|
|
}
|
|
|
|
// Start mocks base method.
|
|
func (m *MockController) Start() {
|
|
m.ctrl.T.Helper()
|
|
m.ctrl.Call(m, "Start")
|
|
}
|
|
|
|
// Start indicates an expected call of Start.
|
|
func (mr *MockControllerMockRecorder) Start() *gomock.Call {
|
|
mr.mock.ctrl.T.Helper()
|
|
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Start", reflect.TypeOf((*MockController)(nil).Start))
|
|
}
|
|
|
|
// Stop mocks base method.
|
|
func (m *MockController) Stop() {
|
|
m.ctrl.T.Helper()
|
|
m.ctrl.Call(m, "Stop")
|
|
}
|
|
|
|
// Stop indicates an expected call of Stop.
|
|
func (mr *MockControllerMockRecorder) Stop() *gomock.Call {
|
|
mr.mock.ctrl.T.Helper()
|
|
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Stop", reflect.TypeOf((*MockController)(nil).Stop))
|
|
}
|