Skip to content

Commit

Permalink
Merge remote-tracking branch 'jiaxin/debug-redisqueue3' into users/je…
Browse files Browse the repository at this point in the history
…sse/agentr
  • Loading branch information
iwangjintian committed Jan 21, 2025
2 parents 1d88222 + 572dff7 commit d64128a
Show file tree
Hide file tree
Showing 23 changed files with 1,072 additions and 1,113 deletions.
8 changes: 2 additions & 6 deletions api/pkg/apis/v1alpha1/managers/solution/solution-manager.go
Original file line number Diff line number Diff line change
Expand Up @@ -83,9 +83,6 @@ func (s *SolutionManager) Init(context *contexts.VendorContext, config managers.
s.TargetProviders[k] = p
}
}
for key, _ := range providers {
log.Info(" key is %s", key)
}

keylockprovider, err := managers.GetKeyLockProvider(config, providers)
if err == nil {
Expand Down Expand Up @@ -156,7 +153,6 @@ func (s *SolutionManager) Init(context *contexts.VendorContext, config managers.
// The deployment spec may have changed, so the previous target is not in the new deployment anymore
func (s *SolutionManager) GetTargetProviderForStep(target string, role string, deployment model.DeploymentSpec, previousDesiredState *SolutionManagerDeploymentState) (providers.IProvider, error) {
var override tgt.ITargetProvider
log.Info("get step role %s", role)
if role == "container" {
role = "instance"
}
Expand Down Expand Up @@ -296,7 +292,7 @@ func (s *SolutionManager) sendHeartbeat(ctx context.Context, id string, namespac
}
}

func (s *SolutionManager) CleanupHeartbeat(ctx context.Context, id string, namespace string, remove bool) {
func (s *SolutionManager) cleanupHeartbeat(ctx context.Context, id string, namespace string, remove bool) {
if !remove {
return
}
Expand Down Expand Up @@ -367,7 +363,7 @@ func (s *SolutionManager) Reconcile(ctx context.Context, deployment model.Deploy
}()

defer func() {
s.CleanupHeartbeat(ctx, deployment.Instance.ObjectMeta.Name, namespace, remove)
s.cleanupHeartbeat(ctx, deployment.Instance.ObjectMeta.Name, namespace, remove)
}()

stopCh := make(chan struct{})
Expand Down
1 change: 0 additions & 1 deletion api/pkg/apis/v1alpha1/managers/staging/staging-manager.go
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,6 @@ func (s *StagingManager) Init(context *contexts.VendorContext, config managers.M
if err != nil {
return err
}
log.Info(" config is %+v providers is %+v ", config, providers)
queueProvider, err := managers.GetQueueProvider(config, providers)
if err == nil {
s.QueueProvider = queueProvider
Expand Down
2 changes: 1 addition & 1 deletion api/pkg/apis/v1alpha1/providers/providerfactory_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ func TestCreateProvider(t *testing.T) {
if testRedis == "" {
t.Log("Skipping providers.state.redis test as TEST_REDIS is not set")
} else {
provider, err = providerfactory.CreateProvider("providers.state.redis", redisstate.RedisStateProviderConfig{Host: "localhost:6380"})
provider, err = providerfactory.CreateProvider("providers.state.redis", redisstate.RedisStateProviderConfig{Host: "localhost:6379"})
assert.Nil(t, err)
assert.NotNil(t, *provider.(*redisstate.RedisStateProvider))
}
Expand Down
Loading

0 comments on commit d64128a

Please sign in to comment.