Skip to content

Conversation

ssreerama
Copy link
Contributor

@ssreerama ssreerama commented Sep 23, 2025

Pull Request Template – vscode-mssql

Description

This pull request adds support for SQL Server container publishing by introducing new constants, localization strings, validation logic, and utility functions. The changes primarily focus on enabling configuration and validation of SQL Server container deployment options in the publishing workflow.

Localization and User Messaging:

  • Added new localization strings for SQL Server container publishing options, including port number, admin password, image tag, and license agreement acceptance, as well as validation messages for port and password requirements (localization/l10n/bundle.l10n.json, localization/xliff/vscode-mssql.xlf). [1] [2] [3] [4] [5] [6] [7] [8]

Constants and Configuration:

  • Introduced new constants for SQL Server Docker publishing, including registry/repository names, default values, and publish target types in src/constants/constants.ts.

Validation and Utility Logic:

  • Added validation logic for SQL Server port number and admin password complexity, as well as utility functions for Docker image/tag selection and license agreement info in the new file src/publishProject/dockerUtils.ts.

Form Component and Messaging Integration:

  • Updated src/constants/locConstants.ts to expose new localized messages and validation functions for use in publish dialogs.
  • Updated src/publishProject/formComponentHelpers.ts to import and use the new validation logic for form components.

Controller Integration:

  • Passed the sqlProjectsService to the publish project webview controller for extended functionality in SQL Server container publishing (src/controllers/mainController.ts).

** New Files for the target section**

  • Created a separate jsx file target section that carries its specific functionality
  • dockerUtils for docker specific validations and image retrieval based on the sql project target version
  • projectUtils for the project validations and helper methods

Code Changes Checklist

  • New or updated unit tests added
  • All existing tests pass (npm run test)
  • Code follows contributing guidelines
  • Telemetry/logging updated if relevant
  • No regressions or UX breakage

Reviewers: Please read our reviewer guidelines

1 TargetSection

Copy link

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This pull request adds SQL Server container publishing functionality to the vscode-mssql extension. The changes enable users to deploy SQL databases to local development containers by introducing new form fields, validation logic, and Docker integration utilities.

Key changes include:

  • Added container-specific form fields (port, admin password, image tag, license acceptance) with validation
  • Implemented Docker image tag fetching and selection based on project target version
  • Extended the publish dialog state and form interfaces to support container deployment options

Reviewed Changes

Copilot reviewed 16 out of 16 changed files in this pull request and generated 4 comments.

Show a summary per file
File Description
test/unit/publishProjectDialog.test.ts New test file for publish dialog functionality
src/sharedInterfaces/publishDialog.ts Extended interfaces with container fields and project properties
src/reactviews/pages/PublishProject/types.ts New type definitions for publish form context
src/reactviews/pages/PublishProject/publishProject.tsx Updated main dialog with validation and script generation logic
src/reactviews/pages/PublishProject/components/PublishTargetSection.tsx Enhanced target section with container field rendering
src/reactviews/pages/PublishProject/components/PublishProfileSection.tsx Refactored to use shared type definitions
src/reactviews/pages/PublishProject/components/ConnectionSection.tsx Updated to use shared type definitions
src/publishProject/publishProjectWebViewController.ts Enhanced controller with Docker integration and immutable state updates
src/publishProject/projectUtils.ts New utility functions for project properties and form validation
src/publishProject/formComponentHelpers.ts Added container-specific form components with validation
src/publishProject/dockerUtils.ts New Docker utilities for image selection and validation
src/controllers/mainController.ts Updated to pass SQL projects service to publish controller
src/constants/locConstants.ts Added localization strings for container publishing
src/constants/constants.ts Added Docker-related constants and publish target types
localization/xliff/vscode-mssql.xlf Updated localization file with new strings
localization/l10n/bundle.l10n.json Updated localization bundle with new strings

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

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.

3 participants