Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Buffered FIFO interface to datastore

License

NotificationsYou must be signed in to change notification settings

ipfs/go-dsqueue

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

26 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Build StatusGoDoc

Buffered FIFO interface to the datastore

The dsqueue package provides a buffered FIFO queue backed by aBatching Datastore. Queued items are persisted in the datastore when the input buffer is full, after some amount of idle time, and when the queue is shuddown.

Documentation

https://pkg.go.dev/github.com/ipfs/go-dsqueue

Example

ds=getBatchingDatastore()dsq:=dsqueue.New(ds,"ExampleQueue")deferdsq.Close()c,err:=cid.Decode("QmPNHBy5h7f19yJDt7ip9TvmMRbqmYsa6aetkrsc1ghjLB")iferr!=nil {panic(err)}dsq.Put(c.Bytes())out:=<-dsq.Out()c2,err:=cid.Parse(out)iferr!=nil {panic(err)}ifc2!=c {fmt.Fprintln(os.Stderr,"cids are not quual")}

Lead Maintainer

@gammazero

Contributing

Contributions are welcome! This repository is part of the IPFS project and therefore governed by ourcontributing guidelines.

License

SPDX-License-Identifier: Apache-2.0 OR MIT

About

Buffered FIFO interface to datastore

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Contributors3

  •  
  •  
  •  

Languages


[8]ページ先頭

©2009-2025 Movatter.jp