{"id":20564033,"url":"https://github.com/comake/solid-dgraph","last_synced_at":"2025-04-14T15:10:21.850Z","repository":{"id":42679568,"uuid":"467737049","full_name":"comake/solid-dgraph","owner":"comake","description":null,"archived":false,"fork":false,"pushed_at":"2023-03-07T15:17:28.000Z","size":1868,"stargazers_count":9,"open_issues_count":4,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-03-28T04:02:14.347Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/comake.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2022-03-09T01:36:19.000Z","updated_at":"2024-07-03T15:40:43.000Z","dependencies_parsed_at":"2024-10-23T19:33:58.004Z","dependency_job_id":"4d29ee61-8fd2-4cc3-9165-8df371f1c231","html_url":"https://github.com/comake/solid-dgraph","commit_stats":{"total_commits":35,"total_committers":2,"mean_commits":17.5,"dds":0.02857142857142858,"last_synced_commit":"53bb41241e25db5575dee08253417ef5ae853666"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/comake%2Fsolid-dgraph","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/comake%2Fsolid-dgraph/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/comake%2Fsolid-dgraph/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/comake%2Fsolid-dgraph/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/comake","download_url":"https://codeload.github.com/comake/solid-dgraph/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248729211,"owners_count":21152375,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-16T04:23:32.866Z","updated_at":"2025-04-14T15:10:21.818Z","avatar_url":"https://github.com/comake.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Dgraph database backend extension for the Community Solid Server\n\nStore data in your Solid Pod with a [Dgraph Database](https://dgraph.io/).\n\n### Disclaimer\n\nThe schema and queries within this repository are built with the assumption that your Dgraph instance uses a custom fork of Dgraph where the predicate list feature has been re-added. This is so that we can query for any arbitrary/dynamic predicates a node may have. [unigraph-dev/dgraph](https://github.com/unigraph-dev/dgraph) is an example where `expand(_userpredicate_)` can be used to fetch all the predicates a node has. It was used to develop this repo.\n\n\n## How to use Solid Dgraph\n\n#### Install\nFrom the npm package registry:\n```shell\nmkdir my-server\ncd my-server\nnpm install @solid/community-server@v4.0.0 @comake/solid-dgraph\n```\n\n#### Configure\nIn your `my-server` folder (or whatever the name of your project is):\n\nCreate a `config.json` file from [this template](https://github.com/comake/solid-dgraph/blob/main/config-example.json), and fill out your settings. The only important changes to make to the [default config](https://github.com/CommunitySolidServer/CommunitySolidServer/blob/main/config/default.json) are to add `solid-dgraph` into `@context` and change the backend to dgraph:\n\n```diff\n-\"files-scs:config/storage/backend/*.json\",\n+\"files-csd:config/storage/backend/dgraph.json\",\n```\n\n\nOptionally, you can change the connection settings for your Dgraph database by adding parameters to the `DgraphDataAccessor` in the `@graph` section such as:\n```json\n{\n  \"@id\": \"urn:solid-dgraph:default:DgraphDataAccessor\",\n  \"comment\": \"The configuration to connect to the Dgraph instance.\",\n  \"DgraphDataAccessor:_configuration_connectionUri\": \"https://mySpecialConnectionUri\",\n  \"DgraphDataAccessor:_configuration_grpcPort\": \"1234\",\n}\n```\nIf you do not include this section, `connectionUri` defaults to `localhost` and `grpcPort` defaults to `9080`, which are the Dgraph defaults.\n\n#### Run\nExecute the following command:\n```shell\nnpx community-solid-server -c config.json -m .\n```\nOr add the command to `scripts` inside your package.json like so:\n```json\n{\n  \"scripts\": {\n    \"start\": \"npx community-solid-server -c config.json -m .\"\n  }\n}\n```\n\n## How to contribute to Solid Dgraph\n\nExecute the following commands:\n```shell\ngit clone https://github.com/comake/solid-dgraph.git\ncd solid-dgraph\nnpm ci\n```\n\n## TODO\n- [ ] Add separate unit tests for DgraphClient.ts and mock it in the tests for DgraphDataAccessor\n- [ ] Add option to create secure connection to Dgraph (i.e. instead of `grpc.credentials.createInsecure()`)\n- [ ] Integration tests\n\n## License\n\n©2022-present Comake, Inc., [MIT License](https://github.com/comake/solid-dgraph/blob/main/LICENSE)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcomake%2Fsolid-dgraph","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcomake%2Fsolid-dgraph","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcomake%2Fsolid-dgraph/lists"}