(ctx context.Context, node *Node)
| 177 | } |
| 178 | |
| 179 | func (s *nodeService) UpdateNode(ctx context.Context, node *Node) error { |
| 180 | s.mu.Lock() |
| 181 | defer s.mu.Unlock() |
| 182 | s.nodes[node.ID] = node |
| 183 | return nil |
| 184 | } |
| 185 | |
| 186 | func (s *nodeService) DeleteNode(ctx context.Context, id string) error { |
| 187 | s.mu.Lock() |