Skip to content

Commit

Permalink
remove extra logs
Browse files Browse the repository at this point in the history
  • Loading branch information
mateeullahmalik committed Aug 12, 2024
1 parent 31238ec commit 273550f
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 21 deletions.
5 changes: 1 addition & 4 deletions p2p/kademlia/store/sqlite/sqlite.go
Original file line number Diff line number Diff line change
Expand Up @@ -157,8 +157,6 @@ func NewStore(ctx context.Context, dataDir string, _ time.Duration, _ time.Durat
}
}

log.WithContext(ctx).Info("p2p database successfully opened")

s.db = db
dbFilePath = dbFile

Expand All @@ -172,7 +170,7 @@ func NewStore(ctx context.Context, dataDir string, _ time.Duration, _ time.Durat
return nil, fmt.Errorf("cannot create meta store: %w", err)
}
}
log.WithContext(ctx).Info("p2p database started")

return s, nil
}

Expand Down Expand Up @@ -440,7 +438,6 @@ func (s *Store) Retrieve(_ context.Context, key []byte) ([]byte, error) {
PostAccessUpdate([]string{hkey})
}

fmt.Println("Data from local store")
if len(r.Data) > 0 {
return r.Data, nil
}
Expand Down
16 changes: 0 additions & 16 deletions walletnode/cmd/app.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,7 @@ import (
"path/filepath"
"sync"

"github.com/pastelnetwork/gonode/common/storage/rqstore"
"github.com/pastelnetwork/gonode/common/storage/ticketstore"
"github.com/pastelnetwork/gonode/p2p"
"github.com/pastelnetwork/gonode/p2p/kademlia/store/cloud.go"

"github.com/pastelnetwork/gonode/common/cli"
"github.com/pastelnetwork/gonode/common/configurer"
Expand Down Expand Up @@ -276,19 +273,6 @@ func runApp(ctx context.Context, config *configs.Config) error {
scoreService := score.NewScoreService(pastelClient)
healthCheckChallengeService := healthcheckchallenge.NewHealthCheckChallengeService(pastelClient)

rqstore, err := rqstore.NewSQLiteRQStore(filepath.Join(defaultPath, "rqstore.db"))
if err != nil {
return errors.Errorf("could not create rqstore, %w", err)
}
defer rqstore.Close()

// p2p service (currently using kademlia)
cloudStorage := cloud.NewRcloneStorage("bucket", "spec")
_, err = p2p.New(ctx, &p2p.Config{DataDir: "/home/matee/.pastel/p2pdata"}, pastelClient, nil, rqstore, cloudStorage)
if err != nil {
return errors.Errorf("could not create p2p service, %w", err)
}

fileMappings := &sync.Map{}
server := api.NewAPIServer(config.API, fileMappings, pastelClient,
services.NewNftAPIHandler(apiSrcvConf, fileMappings, nftRegister, nftSearch, nftDownload),
Expand Down
1 change: 0 additions & 1 deletion walletnode/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ require (
github.com/json-iterator/go v1.1.12
github.com/pastelnetwork/gonode/common v0.0.0-20240229105633-1f295fe18563
github.com/pastelnetwork/gonode/mixins v0.0.0-00010101000000-000000000000
github.com/pastelnetwork/gonode/p2p v0.0.0-00010101000000-000000000000
github.com/pastelnetwork/gonode/pastel v0.0.0-00010101000000-000000000000
github.com/pastelnetwork/gonode/proto v0.0.0-00010101000000-000000000000
github.com/pastelnetwork/gonode/raptorq v0.0.0-00010101000000-000000000000
Expand Down

0 comments on commit 273550f

Please sign in to comment.