Skip to content

Commit addcd56

Browse files
committed
Linting
1 parent 67dda52 commit addcd56

File tree

4 files changed

+5
-6
lines changed

4 files changed

+5
-6
lines changed

internal/resource/resource_plugin.go

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,12 +9,13 @@ import (
99
"context"
1010
"errors"
1111
"fmt"
12+
"log/slog"
13+
1214
mpi "github.com/nginx/agent/v3/api/grpc/mpi/v1"
1315
"github.com/nginx/agent/v3/internal/config"
1416
response "github.com/nginx/agent/v3/internal/datasource/proto"
1517
"github.com/nginx/agent/v3/internal/logger"
1618
"github.com/nginx/agent/v3/internal/model"
17-
"log/slog"
1819

1920
"github.com/nginx/agent/v3/internal/bus"
2021
)

internal/resource/resource_service.go

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,13 +10,14 @@ import (
1010
"encoding/json"
1111
"errors"
1212
"fmt"
13-
"google.golang.org/protobuf/proto"
1413
"log/slog"
1514
"net"
1615
"net/http"
1716
"strings"
1817
"sync"
1918

19+
"google.golang.org/protobuf/proto"
20+
2021
"github.com/nginxinc/nginx-plus-go-client/v2/client"
2122
"google.golang.org/protobuf/types/known/structpb"
2223

@@ -145,7 +146,6 @@ func (r *ResourceService) UpdateInstances(instanceList []*mpi.Instance) *mpi.Res
145146
} else {
146147
slog.Warn("Error updating resource instances", "instances", instanceList)
147148
}
148-
149149
}
150150

151151
return r.resource
@@ -166,7 +166,6 @@ func (r *ResourceService) DeleteInstances(instanceList []*mpi.Instance) *mpi.Res
166166
} else {
167167
slog.Warn("Error deleting instances from resource", "instances", instanceList)
168168
}
169-
170169
}
171170
r.RemoveOperator(instanceList)
172171

internal/watcher/health/nginx_health_watcher_operator.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ package health
88
import (
99
"context"
1010
"fmt"
11+
1112
mpi "github.com/nginx/agent/v3/api/grpc/mpi/v1"
1213
"github.com/nginx/agent/v3/internal/datasource/host/exec"
1314
processwatcher "github.com/nginx/agent/v3/internal/watcher/process"
@@ -29,7 +30,6 @@ func NewNginxHealthWatcher() *NginxHealthWatcher {
2930
}
3031

3132
func (nhw *NginxHealthWatcher) Health(ctx context.Context, instance *mpi.Instance) (*mpi.InstanceHealth, error) {
32-
3333
health := &mpi.InstanceHealth{
3434
InstanceId: instance.GetInstanceMeta().GetInstanceId(),
3535
InstanceHealthStatus: mpi.InstanceHealth_INSTANCE_HEALTH_STATUS_HEALTHY,

internal/watcher/instance/instance_watcher_service.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -167,7 +167,6 @@ func (iw *InstanceWatcherService) ReparseConfig(ctx context.Context, instanceID
167167
func (iw *InstanceWatcherService) checkForUpdates(
168168
ctx context.Context,
169169
) {
170-
171170
var instancesToParse []*mpi.Instance
172171
correlationID := logger.GenerateCorrelationID()
173172
newCtx := context.WithValue(ctx, logger.CorrelationIDContextKey, correlationID)

0 commit comments

Comments
 (0)