{"id":20642670,"url":"https://github.com/alumbra/alumbra.pipeline","last_synced_at":"2025-12-12T01:12:25.627Z","repository":{"id":57713108,"uuid":"73320243","full_name":"alumbra/alumbra.pipeline","owner":"alumbra","description":"Ring Handler for GraphQL Execution","archived":false,"fork":false,"pushed_at":"2017-05-01T15:32:07.000Z","size":111,"stargazers_count":3,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2024-04-14T07:11:29.767Z","etag":null,"topics":["graphql","ring","ring-handler"],"latest_commit_sha":null,"homepage":"http://alumbra.github.io/alumbra.pipeline","language":"Clojure","has_issues":false,"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/alumbra.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}},"created_at":"2016-11-09T20:51:01.000Z","updated_at":"2018-01-24T20:35:48.000Z","dependencies_parsed_at":"2022-09-06T02:10:40.620Z","dependency_job_id":null,"html_url":"https://github.com/alumbra/alumbra.pipeline","commit_stats":null,"previous_names":["alumbra/alumbra.ring"],"tags_count":6,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alumbra%2Falumbra.pipeline","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alumbra%2Falumbra.pipeline/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alumbra%2Falumbra.pipeline/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alumbra%2Falumbra.pipeline/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/alumbra","download_url":"https://codeload.github.com/alumbra/alumbra.pipeline/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":249182807,"owners_count":21226123,"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":["graphql","ring","ring-handler"],"created_at":"2024-11-16T16:09:47.528Z","updated_at":"2025-12-12T01:12:20.597Z","avatar_url":"https://github.com/alumbra.png","language":"Clojure","funding_links":[],"categories":[],"sub_categories":[],"readme":"# alumbra.pipeline\n\nThis library provides a pipeline implementation for [GraphQL][graphql] query\nexecution, as well as a Ring-compatible handler encapsulating this task. It uses\npluggable components that consume/produce data structures as described in\n[alumbra.spec][alumbra-spec].\n\n[![Build Status](https://travis-ci.org/alumbra/alumbra.pipeline.svg?branch=master)](https://travis-ci.org/alumbra/alumbra.pipeline)\n[![Clojars Project](https://img.shields.io/clojars/v/alumbra/pipeline.svg)](https://clojars.org/alumbra/pipeline)\n\n[graphql]: http://graphql.org\n[alumbra-spec]: https://github.com/alumbra/alumbra.spec\n\n## Usage\n\n### Ring Handler\n\nTo create a GraphQL-capable Ring endpoint, you need to supply a series of\n[alumbra.spec][alumbra-spec]-compatible components:\n\n```clojure\n(require '[alumbra.pipeline :as pipeline])\n\n(pipeline/handler\n  {:parser-fn       ...\n   :validator-fn    ...\n   :canonicalize-fn ...\n   :context-fn       (fn [request] (read-auth request))\n   :executor-fn      (fn [context canonical-operation] ...)})\n```\n\nNote that:\n\n- `:parser-fn` should consume an `InputStream` and return a value conforming to\n  either `:alumbra/document` or `:alumbra/parser-errors`,\n- `:validator-fn` should consume an `:alumbra/document` and return either `nil` or\n  a value conforming to `:alumbra/validation-errors`,\n- `:canonicalize-fn` should consume a validated `:alumbra/document` and return a\n  value conforming to `:alumbra/canonical-document`,\n- `:context-fn` should consume a Ring request map and produce any value\n  representing the context of the GraphQL query,\n- `:executor-fn` should consume the value produced by `:context`, as well as an\n  `:alumbra/canonical-operation`, and produce the resolved value as a map.\n\nA variant of this handler that uses pre-defined components can be found in\nthe main [alumbra][alumbra] repository.\n\n[alumbra]: https://github.com/alumbra/alumbra\n\n### Raw Executor\n\nA low-level query executor can be constructed using `alumbra.pipeline/executor`.\nSee its docstring for more information.\n\n## License\n\n```\nMIT License\n\nCopyright (c) 2016 Yannick Scherer\n\nPermission is hereby granted, free of charge, to any person obtaining a copy\nof this software and associated documentation files (the \"Software\"), to deal\nin the Software without restriction, including without limitation the rights\nto use, copy, modify, merge, publish, distribute, sublicense, and/or sell\ncopies of the Software, and to permit persons to whom the Software is\nfurnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in all\ncopies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\nAUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\nLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\nOUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\nSOFTWARE.\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Falumbra%2Falumbra.pipeline","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Falumbra%2Falumbra.pipeline","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Falumbra%2Falumbra.pipeline/lists"}