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

Finish low-level record / link patterns #32

Merged
merged 48 commits into from Jul 8, 2019
Merged

Conversation

pospi
Copy link
Member

@pospi pospi commented Jul 3, 2019

This branch feels like it's stabilising and ready for feedback, there are some cleanup jobs I want to log but will do that separately. This PR:

  • Changes zome names to be type-based. Moves observation.main to observation.economic_event.
  • Adds basic intent capability to planning DNA. Moves planning.main to planning.commitment and adds planning.intent.
  • Wraps up common record management behaviour into a set of helpers in lib/hdk_graph_helpers/src/record_helpers.rs
  • Proposes a pattern for implementing & using traits that manage record behaviour, see lib/hdk_graph_helpers/src/record_interface.rs
  • Wraps up common link management behaviour into a set of helpers in lib/hdk_graph_helpers/src/link_helpers.rs

This will close #18, #19, #20 & #23. #21 can probably be closed and ignored in lieu of finishing all fields for the main flow record types as its logic is no longer any different to #20. Will log the larger job separately when I transcribe my cleanup notes.

AFAIK more or less the only remaining cleanup to get to a nice pattern for the rest of the system is the record macros in #22, which as you can see when you look at intent.rs, commitment.rs & economic_event.rs is simply a case of wrapping the commonalities between those 3 files up.

Does not yet, but needs to:

  • Be able to deserialize the results of cross-zome & cross-DNA method calls into structs in order to intelligently handle them (see MM thread)

pospi added 30 commits June 25, 2019 16:55
…ommitment base anchor (seems a nicer pattern)
…onse typecasting out of cross-zome callbacks
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

Successfully merging this pull request may close these issues.

Implement 'stable ID' record pattern
2 participants