Skip to content

Commit

Permalink
feat: Update dp
Browse files Browse the repository at this point in the history
  • Loading branch information
scorpiotzh committed Nov 9, 2023
1 parent 0921c4b commit 173317e
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions dascache/das_cache.go
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,17 @@ func (d *DasCache) AddOutPoint(outPoint []string) {
}
}

func (d *DasCache) AddBlockOutPoint(outPoint []string) {
if len(outPoint) == 0 {
return
}
d.rw.Lock()
defer d.rw.Unlock()
for _, v := range outPoint {
d.mapOutPoint[v] = 0
}
}

func (d *DasCache) clearExpiredOutPoint(t time.Duration) {
d.rw.Lock()
defer d.rw.Unlock()
Expand Down

0 comments on commit 173317e

Please sign in to comment.