gofr-dev / gofr

An opinionated GoLang framework for accelerated microservice development. Built in support for databases and observability.
https://gofr.dev
Apache License 2.0
3.61k stars 243 forks source link

Add context to all migrators #1183

Open ccoVeille opened 2 weeks ago

ccoVeille commented 2 weeks ago

As per discussed here

passing context is a better option for all other datasource migrators as our migrator interface doesn't have context as paramter in the following methods:

type migrator interface {
    checkAndCreateMigrationTable(c *container.Container) error
    getLastMigration(c *container.Container) int64

    beginTransaction(c *container.Container) transactionData

    commitMigration(c *container.Container, data transactionData) error
    rollback(c *container.Container, data transactionData)
}
ccoVeille commented 2 weeks ago

But we have to wait for this one to be merged

afzal442 commented 1 week ago

Hi, I would like to take this up. This is going to be a straightforward upgrade. Right?

afzal442 commented 6 days ago

cc @coolwednesday @aryanmehrotra any thought?