{"id":18660128,"url":"https://github.com/lafriks/xormstore","last_synced_at":"2025-04-11T20:31:09.559Z","repository":{"id":50070452,"uuid":"124640294","full_name":"lafriks/xormstore","owner":"lafriks","description":"XORM backend for gorilla sessions","archived":false,"fork":false,"pushed_at":"2025-01-07T10:11:28.000Z","size":5235,"stargazers_count":9,"open_issues_count":1,"forks_count":4,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-25T17:49:20.685Z","etag":null,"topics":["go","golang","golang-library","gorilla","session-store","sessionstorage","xorm"],"latest_commit_sha":null,"homepage":null,"language":"Go","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/lafriks.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":"2018-03-10T09:18:21.000Z","updated_at":"2025-02-18T09:18:28.000Z","dependencies_parsed_at":"2022-09-26T18:00:48.056Z","dependency_job_id":null,"html_url":"https://github.com/lafriks/xormstore","commit_stats":null,"previous_names":[],"tags_count":7,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lafriks%2Fxormstore","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lafriks%2Fxormstore/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lafriks%2Fxormstore/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lafriks%2Fxormstore/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/lafriks","download_url":"https://codeload.github.com/lafriks/xormstore/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248476232,"owners_count":21110237,"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":["go","golang","golang-library","gorilla","session-store","sessionstorage","xorm"],"created_at":"2024-11-07T07:39:14.811Z","updated_at":"2025-04-11T20:31:09.233Z","avatar_url":"https://github.com/lafriks.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"[![GoDoc](https://godoc.org/github.com/lafriks/xormstore?status.svg)](https://godoc.org/github.com/lafriks/xormstore)\n[![Build Status](https://travis-ci.org/lafriks/xormstore.svg?branch=master)](https://travis-ci.org/lafriks/xormstore)\n[![codecov](https://codecov.io/gh/lafriks/xormstore/branch/master/graph/badge.svg)](https://codecov.io/gh/lafriks/xormstore)\n\n#### XORM backend for gorilla sessions\n\n    go get github.com/lafriks/xormstore\n\n#### Example\n\n```go\n// initialize and setup cleanup\nstore := xormstore.New(engine, []byte(\"secret\"))\n// db cleanup every hour\n// close quit channel to stop cleanup\nquit := make(chan struct{})\ngo store.PeriodicCleanup(1*time.Hour, quit)\n```\n\n```go\n// in HTTP handler\nfunc handlerFunc(w http.ResponseWriter, r *http.Request) {\n  session, err := store.Get(r, \"session\")\n  session.Values[\"user_id\"] = 123\n  store.Save(r, w, session)\n  http.Error(w, \"\", http.StatusOK)\n}\n```\n\nFor more details see [xormstore godoc documentation](https://godoc.org/github.com/lafriks/xormstore).\n\n#### Testing\n\nJust sqlite3 tests:\n\n    go test\n\nAll databases using docker:\n\n    ./test\n\nIf docker is not local (docker-machine etc):\n\n    DOCKER_IP=$(docker-machine ip dev) ./test\n\n#### License\n\nxormstore is licensed under the MIT license. See [LICENSE](LICENSE) for the full license text.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flafriks%2Fxormstore","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flafriks%2Fxormstore","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flafriks%2Fxormstore/lists"}