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

replace optional params in WritableKeystore with metadata object #1788

Open
murali-shris opened this issue Feb 8, 2024 · 4 comments
Open
Assignees
Labels
enhancement New feature or request

Comments

@murali-shris
Copy link
Member

Is your feature request related to a problem? Please describe.

  • Introducing new fields in metadata results in code changes in multiple places and also a breaking change in persistence spec
    Code changes required
  • Introduce optional params in WritableKeystore (put/create methods) in peristence_spec. This results in compilation error in persistence secondary forcing to override these new params.
    This is a breaking change in persistence spec
  • Changes to AtKey → Metadata in at_commons, AtMetaData in persistence secondary server
  • Impl changes to HiveKeyStore and NotificationKeyStore
  • Add new field in implementation in AbstractUpdateVerbHandler , UpdateVerbHandler and ResourceManager

Describe the solution you'd like

  • Modify WritableKeystore signature from put(K key, V value, {int? time_to_live, int? time_to_born, int? time_to_refresh....)
    to put (K key, V value, Metadata metadata)
  • Similar change for create method
  • Explore whether some of the common logic in ResourceManager and AbstractVerbHandler can be moved to a common place.

Describe alternatives you've considered

No response

Additional context

No response

@murali-shris murali-shris added the enhancement New feature or request label Feb 8, 2024
@sitaram-kalluri
Copy link
Member

The AtData class, which encapsulates the value of a key, currently includes both the value itself and its associated metadata. We previously considered maintaining metadata in a separate hive store. Can we consider with removing metadata from AtData and instead storing it in a separate data store?

@murali-shris
Copy link
Member Author

murali-shris commented Feb 12, 2024

The AtData class, which encapsulates the value of a key, currently includes both the value itself and its associated metadata. We previously considered maintaining metadata in a separate hive store. Can we consider with removing metadata from AtData and instead storing it in a separate data store?

@gkc please give your inputs on this change

@gkc
Copy link
Contributor

gkc commented Feb 12, 2024

Not yet. We've not yet decided which next pieces of server optimization to tackle, nor in what order.

@murali-shris
Copy link
Member Author

Code changes done in persistence spec and persistence impl
https://github.com/atsign-foundation/at_server/tree/persistence_spec_refactoring
https://github.com/atsign-foundation/at_server/tree/persistence_impl_refactoring
Pending. Raise PR after testing uptake in at_client and at_server

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

No branches or pull requests

3 participants