Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Install Plugin to the app #39

Closed
issmail-basel opened this issue Jul 26, 2021 · 0 comments
Closed

Install Plugin to the app #39

issmail-basel opened this issue Jul 26, 2021 · 0 comments
Assignees

Comments

@issmail-basel
Copy link
Contributor

Description

There are two "installation" of plugins.

  1. Installing plugin to app - only required in the first time for each plugin. Note that it is treated as different plugin even if only version is different
  2. Installing plugin to scene

1. Installing plugin to app

  1. Fetch archive data from GitHub
    • URL is https://github.com/OWNER_NAME/REPOSTIROY_NAME/archive/BRANCH_NAME.zip but OWNER_NAME, REPOSTIROY_NAME and BRANCH_NAME will be changed for each plugin.
    • You can impl the logic in internal/infrastructure/github
  2. Extract and find reearth.json file (there is partial impl in internal/infrastructure/npm)
    • You can impl the logic in internal/infrastructure/github
  3. Parse it with pkg/plugin/manifest and you'll get plugin.Plugin struct and some property.Schema structs. If no error, you can save them (plugin and property schemas).
    • You can impl the logic in pkg/scene/sceneops (e.g. PluginInstaller)
  • PluginMetadata: created
  • PluginInstaller
    • Accept any gateway.PluginRepository in constructor
    • func Install(PluginMetadata) (manifest.Manifest, error)
  • internal/infrastructure/github

2. Installing plugin to scene

You can implement the following in usecase layer.

  1. Load the scene
  2. Add a new plugin to scene.PluginSystem
  3. If the same plugin is already installed, an error should be occurred.
@issmail-basel issmail-basel added this to the sprint18 milestone Jul 26, 2021
@HideBa HideBa assigned rot1024 and unassigned HideBa and mimoham24 Aug 6, 2021
@HideBa HideBa closed this as completed Aug 6, 2021
KeisukeYamashita pushed a commit that referenced this issue Aug 13, 2022
* feat: tag system domain models (#39)

* feat: tag system domain models

* refactor: * add tag interface * tag -> group and tag->item conversation

* testing: generate test cases for the tagID

* resolve notes

* fix unit tests errors

* add NewId test code
fix NewId func

* add more test cases
refactor some parts

* feat: tag system data-layer (mongo) (#44)

* feat: tag system data-layer (mongo)

* remove len > 0 check

* goimport

* Update pkg/tag/group_builder.go

Co-authored-by: rot1024 <aayhrot@gmail.com>

* Update pkg/tag/item_builder.go

Co-authored-by: rot1024 <aayhrot@gmail.com>

* rename itemFrom and groupFrom funcs

Co-authored-by: rot1024 <aayhrot@gmail.com>

* feat: create tag group and tag item (#45)

* tag item and group schema

* feat: creat tags (GQL schema)

* tag items and tag groups resolvers

* datalayer (dummy memory) and usecases

* receive list by reference

* check if nil for list

* resolve notes

* generate new models

* feat: memory infrastructure (#46)

* refactor: implement memory infrastructure

* test: implement memory infrastructure test cases

* test: fix FindByScene test case

* feat: attach/detach tag from layer (#50)

* tag item and group schema

* feat: creat tags (GQL schema)

* tag items and tag groups resolvers

* datalayer (dummy memory) and usecases

* receive list by reference

* check if nil for list

* feat: introduce tags to layers

* feat: attach/detach tags from layers

* fix imports

* refactor: resolve notes

* test: test units for tags

* refactor: resolve notes

* feat: attach/detach tag item from group (#52)

* refactor: transform group tags list to reference

* feat: attach/detach tags

* refactor: use params as use-case input

* test: mongodoc testing (#61)

* test: mongodoc testing

* resolve notes

* feat: remove tag (#58)

* feat: remove a tag (init)

* feat: remove tag

* feat: remove tag usecase and infra

* resolve notes

* feat: tag system queries (#54)

* feat: tag system queries

* resolve notes

* feat: update tag (#49)

* tag item and group schema

* feat: creat tags (GQL schema)

* tag items and tag groups resolvers

* datalayer (dummy memory) and usecases

* receive list by reference

* check if nil for list

* feat: rename tag group

* refactor: rename -> update

* resolve notes

* resolve notes

* change find by id func return type

* Merge branch 'tag-system' of https://github.com/reearth/reearth-backend into tag/update-group-label

# Conflicts:
#	internal/adapter/gql/generated.go
#	internal/adapter/gql/gqlmodel/convert_tag.go

* fix testing

* resolve notes

* resolve notes

* resolve notes

Co-authored-by: HideBa <baba.papa1120.ba@gmail.com>
Co-authored-by: rot1024 <aayhrot@gmail.com>
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants