Skip to content

Conversation

@patrickshih-optimizely
Copy link

@patrickshih-optimizely patrickshih-optimizely commented Jun 24, 2020

What does this PR do?
Wraps all push calls with a conditional, which if window.optimizelyEdge (the edge API) exists on a page, it'll push to window.optimizelyEdge instead of window.optimizely.

PR is built on top of #481, as there would be much more unnecessary complications to add Edge to the current master. However, one can still view the differences here.

Are there breaking changes in this PR?
No, we still track and push to window.optimizely in Web.

Any background context you want to provide?
Allows Performance Edge customers to track Performance Edge experiments now.

Is there parity with the server-side/android/iOS integration components (if applicable)?
N/A

Does this require a new integration setting? If so, please explain how the new setting works
N/A

Links to helpful docs and other external resources

nchilada added 5 commits June 12, 2020 16:40
* Don't attempt to interface with Optimizely Classic Web, since Classic is finally dead
* Prepare to support Optimizely Edge, an alternative to Optimizely Web
* Drop all references to customCampaignProperties. It seems to have been documented [here](https://segment.com/docs/connections/destinations/catalog/optimizely-web/#settings) but it couldn't possibly have worked.
* Generally refactor the code and tests.
@patrickshih-optimizely
Copy link
Author

What does this PR do?
Wraps all push calls with a conditional, which if window.optimizelyEdge (the edge API) exists on a page, it'll push to window.optimizelyEdge instead of window.optimizely.

PR is still WIP, blocked on #481

Are there breaking changes in this PR?
No, we still track and push to window.optimizely in Web.

Any background context you want to provide?
Allows Performance Edge customers to track Performance Edge experiments now.

Is there parity with the server-side/android/iOS integration components (if applicable)?
N/A

Does this require a new integration setting? If so, please explain how the new setting works
N/A

Links to helpful docs and other external resources

@patrickshih-optimizely patrickshih-optimizely changed the title [WIP]feat(optimizely): Expose Edge API to track Edge experiments feat(optimizely): Expose Edge API to track Edge experiments Jul 13, 2020
@tysonmote
Copy link

@patrickshih-optimizely I'm going to work on getting this merged and released. Can you rebase on #481? I hit some merge conflicts and I think you'd be best positioned to resolve them. Thanks!

@patrickshih-optimizely
Copy link
Author

@tysonmote Yes, I'll get to rebasing, thanks for the heads up!

@patrickshih-optimizely patrickshih-optimizely force-pushed the patrickshih/rebased-with-edge branch from 72babb5 to 8ba43dd Compare August 12, 2020 00:15
@patrickshih-optimizely patrickshih-optimizely force-pushed the patrickshih/rebased-with-edge branch from 8ba43dd to df45713 Compare August 13, 2020 04:31
@patrickshih-optimizely patrickshih-optimizely force-pushed the patrickshih/rebased-with-edge branch from df45713 to 394547a Compare August 13, 2020 04:36
} catch (e) {
done(e);
}
describe('#initialize on Web', function() {

Choose a reason for hiding this comment

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

A little confusing to tell in the diff, but I moved down both #initialize with Web and #initialize with Edge to the end of the test suite. #initialize with Edge causes #sendWebDecisionToSegment tests to completely fail, but I knew that tests were passing individually. This leads me to believe that there is something (unsure if it already existed or if I introduced it) in the testing module where variables/data aren't being reset before each test.

Putting all the test to the bottom passes all of them now. Maybe someone on the Segment side may have an idea why this is happening?

Choose a reason for hiding this comment

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

I'm happy to help look into this too, if that's helpful. I might have some context from my PR.

@patrickshih-optimizely
Copy link
Author

@tysonmote, I rebased and cleaned up the code to make it more aligned with #481's changes! I asked a question that I was wondering you may might have some understanding on.

@brennan
Copy link
Contributor

brennan commented Sep 21, 2020

Hey Optimizely team, quick FYI that our CI is failing with error An unexpected error occurred: "https://optimizely.jfrog.io/optimizely/api/npm/npm/sinon/-/sinon-9.0.2.tgz: Request failed \"401 Unauthorized\"". when attempting to install this dependency. Is there a publicly-accessible version of the dep we could use for these proposed changes? Thank you! @nchilada @patrickshih-optimizely

@brennan
Copy link
Contributor

brennan commented Sep 22, 2020

Hey @nchilada @patrickshih-optimizely, just wanted to follow up here. It looks as if a number of modules are now imported from Optimizely private jfrog. Curious your thoughts on the best path forward. I can simply replace the imported modules with the corresponding public packages. Thanks!

@patrickshih-optimizely
Copy link
Author

Hi @brennan, there are some recent updates from Optimizely which requires some update in this PR. Sorry for not communicating this earlier; I'll be working on updating this PR this sprint (until 10/2). Once I finish making the changes, I'll ping you in this PR for next steps.

As for the modules imported via private jfrog, I'm not sure if there's another way forward. Seems like your idea with using corresponding public packages would work 👍

@patrickshih-optimizely
Copy link
Author

@brennan, I've updated this PR to reflect the most up-to-date use for Optimizely Edge. This is ready to be reviewed and merged.

I'm also curious if there are any updates with #481, since this PR is build on top of #481. Will #481 be merged first? Heads up @nchilada has since left Optimizely, so if there are any info or questions originally directed to him or Optimizely, please tag me!

@patrickshih-optimizely
Copy link
Author

@brennan, any updates on getting this PR in?

@brennan
Copy link
Contributor

brennan commented Sep 29, 2020

Hey @patrickshih-optimizely. Thanks for following up! I'll take a closer look at this PR today. Note, we're releasing to a limited pool of customers only to validate the PR, then will release to a wider audience.

@patrickshih-optimizely
Copy link
Author

Hi @brennan, let me know if there's any more updates or aspects of this PR that I can address! We're hoping to get this in soon.

@brennan
Copy link
Contributor

brennan commented Oct 7, 2020

Hey @patrickshih-optimizely, and apologies for the delay. I should have time to look this over this week. Note that we're not planning on a general release, however, until a few customers are able to beta test. A few have already agreed to do so.

@patrickshih-optimizely
Copy link
Author

Great, that sounds good. Thanks @brennan !

@brennan
Copy link
Contributor

brennan commented Oct 7, 2020

@patrickshih-optimizely Are you able to look into reverting the yarn.lock changes introduced that reference Optimizely private packages stored on jfrog, or alternatively giving me access? Unfortunately, I'm not able to change any dependencies in ths project without getting a 401 Unauthorized because I don't have access. Thanks!

@patrickshih-optimizely
Copy link
Author

patrickshih-optimizely commented Oct 7, 2020

Hi @brennan, I reverted the yarn.lock file, but kept the dependencies we added in integrations/optimizely/packages.json. Perhaps installing packages locally will work now. Let me know if there's anything else I need to do.

@patrickshih-optimizely
Copy link
Author

Hey @brennan, I understand that y'all will have customers beta this branch first before release. I was wondering if you could let me know what that timeline may look like (for example, details about # of customers, or how long a beta may last). Also, are there other ways of communication that would be more appropriate for updates?

@jenskene
Copy link

Hey @patrickshih-optimizely ! I'm a PM at Segment, and I want to follow up on our work to support the Edge API. We had one customer who was really keen to use it, but they have had a change in team leadership - and in priority. I am checking with our Customer Success Managers to see if there are other customers who are interested in testing out a beta integration. Until we can find a customer willing to try it out and provide feedback, we are on pause.

@meiluo7
Copy link

meiluo7 commented Oct 16, 2020

Hi @jenskene ! I'm the PM from the Optimizely side and curious as to which customer declined the beta? I have a few customers who have raised this in the past so I can definitely reach out to them as well. Thanks!

@jenskene
Copy link

jenskene commented Apr 21, 2021

@meiluo7, @patrickshih-optimizely and @nchilada — Thank you for your patience! We have a customer who is going to test Optimizely Edge, and we want to merge this PR in our next sprint, approx May 3, 2021. I know it has been a while, so let us know if anything has changed. We are also to merge #481. Thank you!

@patrickshih-optimizely
Copy link
Author

thank you for the update @jenskene! I looked over this PR and everything looks good.

We were wondering what the plan is for the customer to test this integration, and if there's any way for us to correspond with the customer and Segment. Specifically, if any questions or concerns come up, is there a better way for us to communicate?

@patrickshih-optimizely
Copy link
Author

hi @jenskene! any updates on merging this PR? Thanks!

@patrickshih-optimizely
Copy link
Author

Hi @jenskene! would love to hear any updates on whether this PR will be merged within your sprint. Thank you!

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.

6 participants