{"id":24114729,"url":"https://github.com/macktb/json-database","last_synced_at":"2025-02-28T10:35:00.393Z","repository":{"id":188826833,"uuid":"333629979","full_name":"macktb/json-database","owner":"macktb","description":"JSON database using GSON library, thread synchronization (multithreading), framework JCommander and sockets.","archived":false,"fork":false,"pushed_at":"2021-09-23T07:59:01.000Z","size":24,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-01-10T16:54:16.297Z","etag":null,"topics":["gson","jcommander","json","multithreading","socket"],"latest_commit_sha":null,"homepage":"","language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/macktb.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2021-01-28T03:06:11.000Z","updated_at":"2021-11-25T12:13:10.000Z","dependencies_parsed_at":"2023-08-17T03:54:08.009Z","dependency_job_id":"c76ba256-1cc9-47a5-8648-2da05a8a94cc","html_url":"https://github.com/macktb/json-database","commit_stats":null,"previous_names":["rutzno/json-database","macktb/json-database"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/macktb%2Fjson-database","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/macktb%2Fjson-database/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/macktb%2Fjson-database/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/macktb%2Fjson-database/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/macktb","download_url":"https://codeload.github.com/macktb/json-database/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":241138670,"owners_count":19916372,"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":["gson","jcommander","json","multithreading","socket"],"created_at":"2025-01-11T05:17:31.038Z","updated_at":"2025-02-28T10:35:00.363Z","avatar_url":"https://github.com/macktb.png","language":"Java","readme":"# JSON-Database\n\n**JSON** (_JavaScript Object Notation_) is a lightweight data-interchange format. \nIt is easy for humans to read and write and for machines to parse and generate. \nIt is less verbose and more readable than `XML`. The _JSON_ filename extension is `.json`. \nThe official Internet media type for _JSON_ is `application/json`.  \n\n**GSON** is a Java serialization/deserialization library to convert _Java Objects_ into \n_JSON_ and vice versa. _Gson_ was created by _Google_ for internal use and later open sourced.\n\n[_JCommander_](http://jcommander.org) is a very small _Java_ framework that makes it trivial to parse \ncommand line parameters. You annotate fields with descriptions of your options.\n\nWe need synchronization because all our threads will work with the same file.\nSince we can't write the file in two separate threads simultaneously, we used \n`java.util.concurrent.locks.ReentrantReadWriteLock` class, an implementation of the \n`ReadWriteLock` interface which provides a pair of read-write lock. It allows multiple readers \nof the resource but only a single writer. Once a writer locks the resource, it \nwaits until all the readers finish reading and only then starts to write. \nThe readers can freely read the file even though other readers locked it, but if \nthe writer locks the file, no readers can read it.\n\n`\u003c/\u003e`","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmacktb%2Fjson-database","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmacktb%2Fjson-database","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmacktb%2Fjson-database/lists"}