update cicd
This commit is contained in:
@@ -7,7 +7,6 @@ import (
|
||||
"google.golang.org/grpc/codes"
|
||||
"google.golang.org/grpc/status"
|
||||
proto "stream.api/internal/api/proto/agent/v1"
|
||||
"stream.api/internal/dto"
|
||||
)
|
||||
|
||||
func (s *Server) RegisterAgent(ctx context.Context, req *proto.RegisterAgentRequest) (*proto.RegisterAgentResponse, error) {
|
||||
@@ -39,7 +38,7 @@ func (s *Server) UnregisterAgent(ctx context.Context, _ *proto.Empty) (*proto.Em
|
||||
return nil, status.Error(codes.Unauthenticated, "invalid session")
|
||||
}
|
||||
for _, jobID := range s.getAgentJobs(agentID) {
|
||||
_ = s.jobService.UpdateJobStatus(ctx, jobID, dto.JobStatusFailure)
|
||||
_ = s.jobService.HandleAgentDisconnect(ctx, jobID)
|
||||
s.untrackJobAssignment(agentID, jobID)
|
||||
}
|
||||
s.sessions.Delete(token)
|
||||
|
||||
Reference in New Issue
Block a user