Skip to content

feat: Added ODP Segment Manager Implementation - #790

Merged
opti-jnguyen merged 5 commits into
masterfrom
jnguyen/odp-segment-manager
Nov 23, 2022
Merged

feat: Added ODP Segment Manager Implementation#790
opti-jnguyen merged 5 commits into
masterfrom
jnguyen/odp-segment-manager

Conversation

@opti-jnguyen

@opti-jnguyen opti-jnguyen commented Oct 7, 2022

Copy link
Copy Markdown
Contributor

Summary

  • JavaScript implementation of the ODP segment manager.

  • Provides an internal API for fetching segments.

  • Includes OdpConfig, a class that represents a configuration used for ODP integration, and OdpOption, an enum that can hold one of two ODP option values for cache handling.

  • Additionally this PR includes a refactor of several previously implement ODP components including LRU Cache, the ODP Segment API Manager (previously GraphQL Manager), the ODP Events API Manager (previously Rest API Manager), etc. to proper folders and with refocused naming conventions as discussed with @jaeopt and @zashraf1985

Test plan

  • Added unit tests for OdpSegmentManager and OdpConfig.

Issues

@coveralls

coveralls commented Oct 7, 2022

Copy link
Copy Markdown

Coverage Status

Coverage increased (+0.005%) to 93.468% when pulling 503e068 on jnguyen/odp-segment-manager into 510d247 on master.

@opti-jnguyen opti-jnguyen changed the title ODP Segment Manager Implementation feat: Added ODP Segment Manager Implementation Oct 8, 2022
@opti-jnguyen opti-jnguyen changed the title feat: Added ODP Segment Manager Implementation WIP: feat: Added ODP Segment Manager Implementation Oct 8, 2022
@opti-jnguyen
opti-jnguyen force-pushed the jnguyen/odp-segment-manager branch from 369ac65 to 0af3793 Compare October 25, 2022 10:02
@opti-jnguyen opti-jnguyen changed the title WIP: feat: Added ODP Segment Manager Implementation feat: Added ODP Segment Manager Implementation Oct 25, 2022
@opti-jnguyen

Copy link
Copy Markdown
Contributor Author

@jaeopt / @zashraf1985 - updated and ready for review now.

@jaeopt jaeopt left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good! A couple of restructuring/renaming requests. They can be addressed here or in other PRs.

Comment thread packages/optimizely-sdk/lib/utils/enums/index.ts Outdated
Comment thread packages/optimizely-sdk/lib/plugins/odp/odp_segment_manager.ts Outdated
Comment thread packages/optimizely-sdk/lib/plugins/odp/odp_segment_manager.ts Outdated
Comment thread packages/optimizely-sdk/lib/plugins/odp/odp_segment_manager.ts Outdated

@zashraf1985 zashraf1985 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks Good overall, requested a few minor changes here and there. I have a question about the location of these classes though. I believe, we kept those things in plugins which will be injected from the entry points based on the platform. The OdpOption and OdpSegmentManager are core classes which are independent of the platforms. These can go inside core in my opinion.

Comment thread packages/optimizely-sdk/lib/plugins/odp/odp_segment_manager.ts Outdated
Comment thread packages/optimizely-sdk/lib/plugins/odp/odp_segment_manager.ts Outdated
Comment thread packages/optimizely-sdk/lib/plugins/odp/odp_option.ts Outdated
@opti-jnguyen
opti-jnguyen requested a review from jaeopt November 16, 2022 16:27

@jaeopt jaeopt left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@opti-jnguyen
opti-jnguyen merged commit ce4224d into master Nov 23, 2022
@opti-jnguyen
opti-jnguyen deleted the jnguyen/odp-segment-manager branch November 23, 2022 18:50
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.

4 participants