Skip to content

Commit

Permalink
Merge pull request tonindexer#39 from Tsunami-Exchange/feat/funding
Browse files Browse the repository at this point in the history
Feat/funding
  • Loading branch information
stfy authored Jul 22, 2024
2 parents 5098b7f + a49fe54 commit 66f0276
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 5 deletions.
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ require (
github.com/uptrace/bun/extra/bunbig v1.1.13-0.20230308071428-7cd855e64a02
github.com/uptrace/go-clickhouse v0.3.0
github.com/urfave/cli/v2 v2.25.1
github.com/xssnick/tonutils-go v1.8.5-0.20231016063454-6d3e0636946d
github.com/xssnick/tonutils-go v1.9.8
)

require (
Expand Down
2 changes: 2 additions & 0 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -203,6 +203,8 @@ github.com/xrash/smetrics v0.0.0-20201216005158-039620a65673 h1:bAn7/zixMGCfxrRT
github.com/xrash/smetrics v0.0.0-20201216005158-039620a65673/go.mod h1:N3UwUGtsrSj3ccvlPHLoLsHnpR27oXr4ZE984MbSER8=
github.com/xssnick/tonutils-go v1.8.5-0.20231016063454-6d3e0636946d h1:M9SaxaPlxCeGEAsdu6yyypjB208e2g7mPymts+0JZC4=
github.com/xssnick/tonutils-go v1.8.5-0.20231016063454-6d3e0636946d/go.mod h1:rqfQ4jsLaFhUUvouz2hTTC02nQGszOhSps7tGAKRC8g=
github.com/xssnick/tonutils-go v1.9.8 h1:Sq382w8H63sjy5y+j13b9mytHPLf7H94LW+OmxZ4h/c=
github.com/xssnick/tonutils-go v1.9.8/go.mod h1:p1l1Bxdv9sz6x2jfbuGQUGJn6g5cqg7xsTp8rBHFoJY=
github.com/yuin/goldmark v1.4.0/go.mod h1:mwnBkeHKe2W/ZEtQ+71ViKU8L12m81fl3OWwC1Zlc8k=
github.com/yuin/goldmark v1.4.13/go.mod h1:6yULJ656Px+3vBD8DxQVa3kxgyrAnzto9xy5taEt/CY=
go.opentelemetry.io/otel v1.13.0 h1:1ZAKnNQKwBBxFtww/GwxNUyTf0AxkZzrukO8MeXqe4Y=
Expand Down
2 changes: 1 addition & 1 deletion internal/app/fetcher/map.go
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ func mapMessageExternal(msg *core.Message, rawTx *tlb.Transaction, rawMsg tlb.Me
switch raw := rawMsg.Msg.(type) {
case *tlb.ExternalMessage:
msg.Type = core.ExternalIn
msg.RawMessage = &rawMsg
msg.RawMessage = rawMsg.AsExternalIn()

msg.DstAddress = *addr.MustFromTonutils(raw.DstAddr)
msg.DstWorkchain = int32(msg.DstAddress.Workchain())
Expand Down
2 changes: 1 addition & 1 deletion internal/app/notifier/notifier_kafka.go
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ func NewKafkaNotifier(cfg *KafkaConfig) *Kafka {
return &Kafka{KafkaConfig: cfg}
}

func MessageToCell(message *tlb.Message) ([]byte, []byte, error) {
func MessageToCell(message tlb.AnyMessage) ([]byte, []byte, error) {
c, err := tlb.ToCell(message)
if err != nil {
return nil, nil, err
Expand Down
4 changes: 2 additions & 2 deletions internal/core/msg.go
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,8 @@ type Message struct {
ch.CHModel `ch:"messages,partition:toYYYYMM(created_at)" json:"-"`
bun.BaseModel `bun:"table:messages" json:"-"`

RawMessage *tlb.Message `ch:"-" bun:"-"`
Type MessageType `ch:",lc" bun:"type:message_type,notnull" json:"type"` // TODO: ch enum
RawMessage tlb.AnyMessage `ch:"-" bun:"-"`
Type MessageType `ch:",lc" bun:"type:message_type,notnull" json:"type"` // TODO: ch enum

Hash []byte `ch:",pk" bun:"type:bytea,pk,notnull" json:"hash"`

Expand Down

0 comments on commit 66f0276

Please sign in to comment.