Verified Commit b91bc88b authored by Erran Carey's avatar Erran Carey Committed by GitLab
Browse files

fix: Revert default connection agent platform type

parent 592d0fa6
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -955,7 +955,7 @@
            "type": "string",
            "enum": ["grpc", "websocket"],
            "enumItemLabels": ["gRPC", "WebSocket"],
            "default": "websocket",
            "default": "grpc",
            "order": 4
          },
          "gitlab.duoAgentPlatform.defaultNamespace": {
+1 −1
Original line number Diff line number Diff line
@@ -193,7 +193,7 @@ describe('LanguageClientWrapper', () => {
              },
              agentPlatform: {
                enabled: true,
                connectionType: 'websocket',
                connectionType: 'grpc',
              },
            },
            duoChat: {
+1 −1
Original line number Diff line number Diff line
@@ -176,7 +176,7 @@ describe('utils/extension_configuration', () => {
    });

    describe.each([
      { connectionType: undefined, expected: 'websocket' },
      { connectionType: undefined, expected: 'grpc' },
      { connectionType: 'grpc', expected: 'grpc' },
      { connectionType: 'websocket', expected: 'websocket' },
      { connectionType: 'invalid', expected: 'invalid' },
+1 −1
Original line number Diff line number Diff line
@@ -105,7 +105,7 @@ export function getAgentPlatformConfiguration(): DuoAgentPlatformConfiguration {

  return {
    enabled: booleanOrDefault(duoAgentPlatformConfig.enabled, true),
    connectionType: duoAgentPlatformConfig.connectionType ?? 'websocket',
    connectionType: duoAgentPlatformConfig.connectionType ?? 'grpc',
    defaultNamespace: duoAgentPlatformConfig.defaultNamespace,
  };
}
+3 −3
Original line number Diff line number Diff line
@@ -18,7 +18,7 @@ describe('ExtensionConfigurationService', () => {
    // Mock getAgentPlatformConfiguration with default value
    jest.spyOn(extensionConfiguration, 'getAgentPlatformConfiguration').mockReturnValue({
      enabled: true,
      connectionType: 'websocket',
      connectionType: 'grpc',
      defaultNamespace: 'gitlab-org',
    });

@@ -63,7 +63,7 @@ describe('ExtensionConfigurationService', () => {
          agentPlatform: {
            enabled: true,
            defaultNamespace: undefined,
            connectionType: 'websocket',
            connectionType: 'grpc',
          },
        },
        pipelineGitRemoteName: undefined,
@@ -104,7 +104,7 @@ describe('ExtensionConfigurationService', () => {
          agentPlatform: {
            enabled: true,
            defaultNamespace: undefined,
            connectionType: 'websocket',
            connectionType: 'grpc',
          },
        },
        pipelineGitRemoteName: 'origin',
Loading