{"id":16619551,"url":"https://github.com/java-edge/iddd_samples","last_synced_at":"2025-07-26T21:33:20.923Z","repository":{"id":94726117,"uuid":"341822855","full_name":"Java-Edge/IDDD_Samples","owner":"Java-Edge","description":" DDD最佳实践《实践领域驱动设计》案例代码","archived":false,"fork":false,"pushed_at":"2021-02-24T08:08:42.000Z","size":468,"stargazers_count":1,"open_issues_count":0,"forks_count":2,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-06-21T06:05:59.370Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Java-Edge.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.txt","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":"2021-02-24T07:58:44.000Z","updated_at":"2021-10-04T11:16:58.000Z","dependencies_parsed_at":null,"dependency_job_id":"cec4066d-ab68-4bf6-8277-c411b0c19731","html_url":"https://github.com/Java-Edge/IDDD_Samples","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/Java-Edge/IDDD_Samples","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Java-Edge%2FIDDD_Samples","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Java-Edge%2FIDDD_Samples/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Java-Edge%2FIDDD_Samples/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Java-Edge%2FIDDD_Samples/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Java-Edge","download_url":"https://codeload.github.com/Java-Edge/IDDD_Samples/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Java-Edge%2FIDDD_Samples/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":267243615,"owners_count":24058949,"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","status":"online","status_checked_at":"2025-07-26T02:00:08.937Z","response_time":62,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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-10-12T02:42:15.516Z","updated_at":"2025-07-26T21:33:20.845Z","avatar_url":"https://github.com/Java-Edge.png","language":"Java","funding_links":[],"categories":[],"sub_categories":[],"readme":"These are the sample Bounded Contexts from the book\n\"Implementing Domain-Driven Design\" by Vaughn Vernon:\n\nhttp://vaughnvernon.co/?page_id=168\n\nThe models and surrounding architectural mechanisms\nmay be in various states of flux as the are refined\nover time. Some tests may be incomplete. The code is\nnot meant to be a reflection of a production quality\nwork, but rather as a set of reference projects for\nthe book.\n\nPoints of Interest\n==================\n\nThe iddd_agilepm project uses a key-value store as\nits underlying persistence mechanism, and in particular\nis LevelDB. Actually the LevelDB in use is a pure Java\nimplementation: https://github.com/dain/leveldb\n\nCurrently iddd_agilepm doesn't employ a container of\nany kind (such as Spring).\n\nThe iddd_collaboration project uses Event Sourcing and\nCQRS. It purposely avoids the use of an object-relational\nmapper, showing that a simple JDBC-based query engine\nand DTO matter can be used instead. This technique does\nhave its limitations, but it is meant to be small and fast\nand require no configuration or annotations. It is not\nmeant to be perfect.\n\nIt may be helpful to make one additional mental note on\nthe iddd_collaboration CQRS implementation. To keep the\nexample simple it persists the Event Sourced write model\nand the CQRS read model in one thread. Since two different\nstores are used--LevelDB for the Event Journal and MySQL\nfor the read model--there may be very slight opportunities\nfor inconsistency, but not much. The idea was to keep the\ntwo models as close to consistent as possible without\nusing the same data storage (and transaction) for both.\nTwo different storage mechanisms were used purposely to\ndemonstrate that they can be separate.\n\nThe iddd_identityaccess project uses object-relational\nmapping (Hibernate), but so as not to leave it \"boring\" it\nprovides a RESTful client interface and even publishes\nDomain-Event notifications via REST (logs) and RabbitMQ.\n\nFinally the iddd_common project provides a number of reusable\ncomponents. This is not an attempt to be a framework, but\njust leverages reuse to the degree that code copying doesn't\nliter each project. This is not a recommendation, but it\ndid work well and save a considerable amount of work while\nproducing the samples.\n\nUsage\n=====\n\nRequires\n--------\n\n- Java 7 (8+ does not work)\n- MySQL Client + Server\n- RabbitMQ\n\nSetup (with Docker)\n-------------------\n\nTo make it easy to run the tests and it requirements,\nthe `startContainers.sh` script is provided. Which\nwill start a:\n- MySQL Server container\n- RabbitMQ Server container\n- RabbitMQ Management container\n\nIf the `mysql` command is available, which is the mysql client,\nalso the required SQL scripts will be imported into the MySQL\nServer.\n\nIf you use the `startContainers.sh` script, you don't need\nMySQL Server and RabbitMQ installed locally. Instead,\nDocker needs to be installed as the script will start\nMySQL and RabbitMQ in Docker containers.\n\nBuild\n------\n\nYou can build the project by running:\n\n```\n./gradlew build\n```\n\nThis automatically downloads Gradle and builds the project, including running the tests.\n\nThe Gradle build using Maven repositories was provided by\nMichael Andrews (Github michaelajr and Twitter @MichaelAJr).\nThanks much!\n\n\nI hope you benefit from the samples.\n\nVaughn Vernon\nAuthor: Implementing Domain-Driven Design\nTwitter: @VaughnVernon\nhttp://vaughnvernon.co/\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjava-edge%2Fiddd_samples","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjava-edge%2Fiddd_samples","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjava-edge%2Fiddd_samples/lists"}