@@ -6,27 +6,24 @@ import (
6
6
"net/http"
7
7
8
8
"github.com/prometheus/client_golang/prometheus/promhttp"
9
- "github.com/tonkeeper/opentonapi/pkg/blockchain/indexer"
10
- "github.com/tonkeeper/opentonapi/pkg/spam"
11
- "github.com/tonkeeper/tongo"
12
- "github.com/tonkeeper/tongo/liteapi"
13
- "go.uber.org/zap"
14
- "golang.org/x/exp/maps"
15
-
16
9
"github.com/tonkeeper/opentonapi/pkg/addressbook"
17
10
"github.com/tonkeeper/opentonapi/pkg/api"
18
11
"github.com/tonkeeper/opentonapi/pkg/app"
19
12
"github.com/tonkeeper/opentonapi/pkg/blockchain"
13
+ "github.com/tonkeeper/opentonapi/pkg/blockchain/indexer"
20
14
"github.com/tonkeeper/opentonapi/pkg/config"
21
15
"github.com/tonkeeper/opentonapi/pkg/litestorage"
22
16
"github.com/tonkeeper/opentonapi/pkg/pusher/sources"
17
+ "github.com/tonkeeper/opentonapi/pkg/spam"
18
+ "github.com/tonkeeper/tongo"
19
+ "github.com/tonkeeper/tongo/liteapi"
20
+ "go.uber.org/zap"
23
21
)
24
22
25
23
func main () {
26
24
27
25
cfg := config .Load ()
28
26
log := app .Logger (cfg .App .LogLevel )
29
- book := addressbook .NewAddressBook (log , config .AddressPath , config .JettonPath , config .CollectionPath )
30
27
31
28
storageBlockCh := make (chan indexer.IDandBlock )
32
29
@@ -46,10 +43,9 @@ func main() {
46
43
log ,
47
44
client ,
48
45
litestorage .WithPreloadAccounts (cfg .App .Accounts ),
49
- litestorage .WithTFPools (book .TFPools ()),
50
- litestorage .WithKnownJettons (maps .Keys (book .GetKnownJettons ())),
51
46
litestorage .WithBlockChannel (storageBlockCh ),
52
47
)
48
+ book := addressbook .NewAddressBook (log , config .AddressPath , config .JettonPath , config .CollectionPath , storage )
53
49
// The executor is used to resolve DNS records.
54
50
tongo .SetDefaultExecutor (storage )
55
51
0 commit comments