Skip to content

Commit

Permalink
chore: use v2 configs in nodejs (#941)
Browse files Browse the repository at this point in the history
  • Loading branch information
jsalaber authored Aug 22, 2024
1 parent 2732e13 commit 9619f58
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -170,7 +170,7 @@ describe('EnvironmentConfigManager Unit Tests', () => {
}),
)
expect(trackSDKConfigEvent_mock).toBeCalledWith(
'https://config-cdn.devcycle.com/config/v1/server/sdkKey.json',
'https://config-cdn.devcycle.com/config/v2/server/sdkKey.json',
expect.any(Number),
expect.objectContaining({ resStatus: 200 }),
undefined,
Expand All @@ -192,7 +192,7 @@ describe('EnvironmentConfigManager Unit Tests', () => {
'Failed to download DevCycle config.',
)
expect(trackSDKConfigEvent_mock).toBeCalledWith(
'https://config-cdn.devcycle.com/config/v1/server/sdkKey.json',
'https://config-cdn.devcycle.com/config/v2/server/sdkKey.json',
expect.any(Number),
undefined,
expect.objectContaining({
Expand Down
4 changes: 2 additions & 2 deletions lib/shared/config-manager/src/CDNConfigSource.ts
Original file line number Diff line number Diff line change
Expand Up @@ -90,8 +90,8 @@ export class CDNConfigSource extends ConfigSource {

getConfigURL(sdkKey: string, kind: 'server' | 'bootstrap'): string {
if (kind === 'bootstrap') {
return `${this.cdnURI}/config/v1/server/bootstrap/${sdkKey}.json`
return `${this.cdnURI}/config/v2/server/bootstrap/${sdkKey}.json`
}
return `${this.cdnURI}/config/v1/server/${sdkKey}.json`
return `${this.cdnURI}/config/v2/server/${sdkKey}.json`
}
}

0 comments on commit 9619f58

Please sign in to comment.