Skip to content

watermill\_examples\real-world-examples\delayed-messages no work #614

@2637309949

Description

@2637309949

Steps to reproduce

watermill_examples\real-world-examples\delayed-messages compile error

# delayed-messages
.\main.go:45:56: cannot use db (variable of type *"database/sql".DB) as "github.com/ThreeDotsLabs/watermill-sql/v4/pkg/sql".ContextExecutor value in argument to sql.NewDelayedPostgreSQLPublisher: *"database/sql".DB does not implement "github.com/ThreeDotsLabs/watermill-sql/v4/pkg/sql".ContextExecutor (wrong type for method ExecContext)       
                have ExecContext(context.Context, string, ...any) ("database/sql".Result, error)
                want ExecContext(context.Context, string, ...any) ("github.com/ThreeDotsLabs/watermill-sql/v4/pkg/sql".Result, error)
.\main.go:158:59: cannot use db (variable of type *"database/sql".DB) as "github.com/ThreeDotsLabs/watermill-sql/v4/pkg/sql".Beginner value in argument to sql.NewDelayedPostgreSQLSubscriber: *"database/sql".DB does not implement "github.com/ThreeDotsLabs/watermill-sql/v4/pkg/sql".Beginner (wrong type for method BeginTx)
                have BeginTx(context.Context, *"database/sql".TxOptions) (*"database/sql".Tx, error)
                want BeginTx(context.Context, *"database/sql".TxOptions) ("github.com/ThreeDotsLabs/watermill-sql/v4/pkg/sql".Tx, error)

Expected behavior

Actual behavior

Possible solution

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions