Debug MongoDB with Golang mongo-dirve

cmdMonitor := &event.CommandMonitor{
		Started: func(_ context.Context, evt *event.CommandStartedEvent) {
			log.Printf("Command started: %v\n", evt.Command)
		},
	}

	option := options.Client().ApplyURI(connectionURI).SetMonitor(cmdMonitor)

Leave a Reply

Your email address will not be published. Required fields are marked *