Skip to content

[1.2.X] Fix the issue with generating http service using OpenAPI spec#280

Merged
NipunaRanasinghe merged 3 commits intoballerina-platform:1.2.xfrom
LakshanWeerasinghe:fix#1146
Sep 5, 2025
Merged

[1.2.X] Fix the issue with generating http service using OpenAPI spec#280
NipunaRanasinghe merged 3 commits intoballerina-platform:1.2.xfrom
LakshanWeerasinghe:fix#1146

Conversation

@LakshanWeerasinghe
Copy link
Contributor

Purpose

$subject

Fixes wso2/product-ballerina-integrator#1146

Screen.Recording.2025-09-04.at.15.27.01.mov

@LakshanWeerasinghe LakshanWeerasinghe changed the title Fix the issue with generating http service using OpenAPI spec [1.2.X] Fix the issue with generating http service using OpenAPI spec Sep 4, 2025
Copy link
Contributor

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 PR fixes an issue with generating HTTP services using OpenAPI specifications. The fix ensures the design approach is properly populated before determining whether to use OpenAPI-based or regular service generation.

  • Adds call to populateDesignApproach() to properly initialize service configuration
  • Includes test resources and test case for OpenAPI spec-based service generation
  • Adds validation to verify the fix works correctly with OpenAPI specifications

Reviewed Changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated 1 comment.

File Description
openapi.yaml Test OpenAPI specification with albums API endpoints and schema definitions
add_http_service_from_openapi_spec.json Test configuration for validating OpenAPI-based service generation
AddServiceTest.java Adds test method and skips list for OpenAPI spec validation
HttpServiceBuilder.java Core fix - adds populateDesignApproach() call before OpenAPI processing

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

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
@NipunaRanasinghe NipunaRanasinghe merged commit 44eb185 into ballerina-platform:1.2.x Sep 5, 2025
4 of 5 checks passed
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