cd7f20a461
* server.xxx endpoints Additional server endpoints in jsonrpc and also some refactoring * server.banner * more endpoints * use lbry.go stop pattern * set genesis hash properly * updates and refactors * remove shutdowncalled and itmut * remove OpenIterators * remove shutdown and done channels from db and use stop group * currently broken, incorporated stop groups into the session manager * set the rest of the default args for tests * add default json rpc http port and cleanup * tests for new jsonrpc endpoints * cleanup and add manage goroutine to stopper pattern * cleanup * NewDebug * asdf * fix
19 lines
491 B
Go
19 lines
491 B
Go
package server
|
|
|
|
import (
|
|
"github.com/lbryio/herald.go/db"
|
|
"github.com/lbryio/lbcd/chaincfg"
|
|
"github.com/lbryio/lbry.go/v3/extras/stop"
|
|
)
|
|
|
|
func (s *Server) AddPeerExported() func(*Peer, bool, bool) error {
|
|
return s.addPeer
|
|
}
|
|
|
|
func (s *Server) GetNumPeersExported() func() int64 {
|
|
return s.getNumPeers
|
|
}
|
|
|
|
func NewSessionManagerExported(db *db.ReadOnlyDBColumnFamily, args *Args, grp *stop.Group, chain *chaincfg.Params) *sessionManager {
|
|
return newSessionManager(db, args, grp, chain)
|
|
}
|