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

Implement new entities to support new tables #21

Closed
6 tasks done
bsmmoon opened this issue Jan 31, 2016 · 3 comments
Closed
6 tasks done

Implement new entities to support new tables #21

bsmmoon opened this issue Jan 31, 2016 · 3 comments

Comments

@bsmmoon
Copy link

bsmmoon commented Jan 31, 2016

Entities:

@bsmmoon
Copy link
Author

bsmmoon commented Jan 31, 2016

Proposed Schema

Preference : this table holds information for default libraries used by different partners
id, library_id, partner_id, version_id
Unique index on: (library_id, partner_id)

Partner : this table holds authentication information of different partners
id, name, auth_key

Architecture : this table stores different architectures used by various Arduino boards
id, name

Library : this table stores the meta information for external libraries supported by Eratosthenes
id, name, default_header, description, notes, url, owner, repo, in_repo_path, verified, active, last_commit, folder_name
Unique index on: machine_name, folder_name

Version : this table stores detail version information for each libraries
id, library_id, version, description, notes, source_url, release_commit, branch, folder_name
Unique index on: folder_name
Index on: library_id

Architecture_Version : this table describe architecture compatibility with each version of each library
id, version_id, architecture_id

LibraryExample : this table holds examples for libraries supported
id, version_id, name, path, boards
Unique index on: version_id

Extra notes:

  • Rename ExternalLibrary to Library
  • Rename human_name to name and machine_name to default_header

@bsmmoon
Copy link
Author

bsmmoon commented Jan 31, 2016

@thngkaiyuan @Gisonrg Could you correct the table detail? Thanks!

@Gisonrg Gisonrg changed the title Entity and Schema PHP implementation for library version Implementing entities to support new tables Jan 31, 2016
@thngkaiyuan thngkaiyuan changed the title Implementing entities to support new tables Implement new entities to support new tables Jan 31, 2016
@Gisonrg
Copy link

Gisonrg commented Jan 31, 2016

Here we are going to create 6 new entities instead of modifying the existing one, especially for ExternalLibrary and Example.
Reason
If we directly modify the existing entity, we need to change a lot of codes in this branch because we are going to change the ExternalLibrary so all controllers and handlers related to it need to be update as well. We may accidentally break any thing in our changes, which would delay our progress. In addition, we need to modify the function testings as well in order to let the CI pass. Secondly, our proposed schema may expect future changes, which means we may need to revert the changes at some time in the future, and the efforts are wasted.
The plan
Therefore, instead of modifying, we will first create new entities, and make things works for them. It's like a proof-of-concept implementation so we know our plan is feasible. At that time, we can switch the old logic into to our new implementation. In this way, the system will function as normal while our development is going on. If something go wrong in our implementation, we can safely revert some changes easily without affecting the original system.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants