Skip to content

Using OrbitDBAccessController results in - "Message": "unable to create store: unable to acquire an access controller: unable to create access controller: the OrbitDB instance must provide a key value store" #161

@mar1n3r0

Description

@mar1n3r0

Is there an existing issue for this?

  • I have searched the existing issues

Package version

1.22.1

Golang version

1.23.3

Bug description

// NewIPFSAccessController Returns a default access controller for OrbitDB database
func NewOrbitDBAccessController(ctx context.Context, db iface.BaseOrbitDB, params accesscontroller.ManifestParams, options ...accesscontroller.Option) (accesscontroller.Interface, error) {
	if db == nil {
		return &orbitDBAccessController{}, fmt.Errorf("an OrbitDB instance is required")
	}

	kvDB, ok := db.(iface.OrbitDBKVStoreProvider)
	if !ok {
		return &orbitDBAccessController{}, fmt.Errorf("the OrbitDB instance must provide a key value store")
	}

Somehow expects db which is BaseOrbitDB to implement OrbitDBKVStoreProvider.

Current behavior

"Message": "unable to create store: unable to acquire an access controller: unable to create access controller: the OrbitDB instance must provide a key value store"

Expected behavior

Create a document store with OrbitDBAccessController

Environment

Linux Ubuntu 24.10

Other

No response

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