code: func Open(path string) (*DB, error) {
  	db := &DB{}
  	// initialize trees and indexes
  	db.keys = btree.New(btreeDegrees, nil)
  	db.exps = btree.New(btreeDegrees, &exctx{db})
  	db.idxs = make(map[string]*index)
  	// initialize default configuration
  	db.config = Config{
  		SyncPolicy:           EverySecond,
  		AutoShrinkPercentage: 100,
  		AutoShrinkMinSize:    32 * 1024 * 1024,
  	}
  	// turn off persistence for pure in-memory
  	db.persist = path != ":memory:"
  	if db.persist {
  		var err error
  		// hardcoding 0666 as the default mode.
  		db.file, err = os.OpenFile(path, os.O_CREATE|os.O_RDWR, 0666)
  		if err != nil {
  			return nil, err
  		}
  		// load the database from disk
  		if err := db.load(); err != nil {
  			// close on error, ignore close error
  			_ = db.file.Close()
  			return nil, err
  		}
  	}
  	// start the background manager.
  	go db.backgroundManager()
  	return db, nil
  }
docs: // Open opens a database at the provided path.
  // If the file does not exist then it will be created automatically.