{"id":21625397,"url":"https://github.com/eigr/spawn-dart","last_synced_at":"2025-03-18T19:55:38.714Z","repository":{"id":199357726,"uuid":"702709141","full_name":"eigr/spawn-dart","owner":"eigr","description":"Dart SDK for Spawn applications","archived":false,"fork":false,"pushed_at":"2023-10-22T13:42:35.000Z","size":100,"stargazers_count":2,"open_issues_count":0,"forks_count":1,"subscribers_count":4,"default_branch":"main","last_synced_at":"2025-01-24T22:34:23.852Z","etag":null,"topics":["actor-model","actors","dartlang","durable-computing-model","durable-functions","elixir","erlang","serverless","stateful-actors"],"latest_commit_sha":null,"homepage":"","language":"Dart","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/eigr.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2023-10-09T21:09:01.000Z","updated_at":"2023-10-22T13:43:41.000Z","dependencies_parsed_at":"2023-10-20T01:24:53.052Z","dependency_job_id":"6f246639-fb40-4cde-9379-d7e664e2c2ea","html_url":"https://github.com/eigr/spawn-dart","commit_stats":null,"previous_names":["eigr-labs/spawn-dart"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eigr%2Fspawn-dart","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eigr%2Fspawn-dart/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eigr%2Fspawn-dart/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eigr%2Fspawn-dart/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/eigr","download_url":"https://codeload.github.com/eigr/spawn-dart/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":244297872,"owners_count":20430346,"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":["actor-model","actors","dartlang","durable-computing-model","durable-functions","elixir","erlang","serverless","stateful-actors"],"created_at":"2024-11-25T01:09:04.997Z","updated_at":"2025-03-18T19:55:38.684Z","avatar_url":"https://github.com/eigr.png","language":"Dart","readme":"# Spawn Dart SDK\n\nDart User Language Support for [Spawn](https://github.com/eigr/spawn).\n\n## Table of Contents\n\n1. [Overview](#overview)\n2. [Getting Started](#getting-started)\n\n### Overview\n\nSpawn is a Stateful Serverless Runtime and Framework basead on the [Actor Model](https://youtu.be/7erJ1DV_Tlo) and operates as a Service Mesh.\n\nSpawn's main goal is to remove the complexity in developing services or microservices, providing simple and intuitive APIs, as well as a declarative deployment and configuration model and based on a Serverless architecture and Actor Model.\nThis leaves the developer to focus on developing the business domain while the platform deals with the complexities and infrastructure needed to support the scalable, resilient, distributed, and event-driven architecture that modern systems requires.\n\nSpawn is based on the sidecar proxy pattern to provide a polyglot Actor Model framework and platform.\nSpawn's technology stack, built on the [BEAM VM](https://www.erlang.org/blog/a-brief-beam-primer/) (Erlang's virtual machine) and [OTP](https://www.erlang.org/doc/design_principles/des_princ.html), provides support for different languages from its native Actor model.\n\nFor more information consult the main repository [documentation](https://github.com/eigr/spawn).\n\n### Getting Started\n\nTODO\n\n```proto\nsyntax = \"proto3\";\n\npackage domain;\n\nmessage State {\n  repeated string languages = 1;\n}\n\nmessage Request {\n  string language = 1;\n}\n\nmessage Reply {\n  string response = 1;\n}\n```\n\n```dart\nimport 'package:spawn_app_example/src/generated/protos/domain.pb.dart';\nimport 'package:spawn_dart/spawn_dart.dart';\n\n@StatefulNamedActor(\n  'joe',\n  State,\n)\nclass JoeActor {\n  @Action()\n  Value setLanguage(Request request, Context ctx) {\n    if (ctx.getState().isPresent) {\n      var currentState = ctx.getState().value as State;\n      print(\"Current state is $currentState\");\n    }\n\n    return Value()\n      ..withReponse(Reply.create()..response = \"dart\")\n      ..withState(State.create()..languages.addAll([\"erlang, dart\"]));\n  }\n}\n```\n\n```dart\nimport 'package:spawn_app_example/joe_actor.dart';\nimport 'package:spawn_dart/spawn_dart.dart';\n\nvoid main() {\n  SpawnSystem()\n      .create(\"spawn-system\")\n      .withPort(8091)\n      .withStatefulNamedActor(JoeActor)\n      .start();\n}\n```\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Feigr%2Fspawn-dart","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Feigr%2Fspawn-dart","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Feigr%2Fspawn-dart/lists"}