Extract Reference Data service from monorepo#4
Open
devin-ai-integration[bot] wants to merge 1 commit intomainfrom
Open
Extract Reference Data service from monorepo#4devin-ai-integration[bot] wants to merge 1 commit intomainfrom
devin-ai-integration[bot] wants to merge 1 commit intomainfrom
Conversation
- Copy entire reference-data directory contents to standalone repository - Update package.json name to @cog-gtm/traderx-reference-data-service - Maintain existing API contract and functionality - Service provides stock ticker and company data via REST endpoints - Includes NestJS source code, CSV data, Docker configuration, and tests Key files extracted: - Source code: Complete NestJS application with stocks and health modules - Data: S&P 500 companies CSV file with 507 entries - Configuration: package.json, tsconfig, nest-cli, ESLint/Prettier configs - Docker: Dockerfile and base.Dockerfile for containerization - Documentation: README.md with setup instructions, OpenAPI specification - Tests: Unit tests and e2e tests for comprehensive coverage Service maintains compatibility with dependent services in TraderX ecosystem. Co-Authored-By: Samir Chaudhry <schaudhry123@gmail.com>
Author
🤖 Devin AI EngineerI'll be helping with this pull request! Here's what you should know: ✅ I will automatically:
⚙️ Control Options:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Extract Reference Data Service to Standalone Repository
Overview
This PR extracts the Reference Data service from the
COG-GTM/traderXCognitiondemosmonorepo into the standaloneCOG-GTM/traderXReferenceDataServicerepository. The service provides stock ticker and company name data via RESTful APIs and maintains full compatibility with dependent services in the TraderX ecosystem.Changes Made
reference-data/directory contents to repository rootpackage.jsonname from@finos/traderx-refdata-serviceto@cog-gtm/traderx-reference-data-serviceFiles Extracted
data/s-and-p-500-companies.csv)package.json, TypeScript configs, NestJS CLI config, ESLint/Prettier configsDockerfileandbase.Dockerfilefor containerizationREADME.mdwith setup instructions,openapi.yamlAPI specificationService Architecture
The extracted service is a complete NestJS application that:
load-csv-data.tsStocksControllerHealthControllerAPI Endpoints
GET /stocks- Returns all securities from CSV dataGET /stocks/{ticker}- Returns specific security by ticker symbolGET /health- Health check endpointGET /api- Swagger UI for API documentationTesting Results ✅
Successfully built and tested the extracted service:
Docker Build
DockerfileService Runtime
API Endpoint Testing
GET /stocks- Returns complete list of 507 S&P 500 companies in JSON formatGET /stocks/ADBE- Returns specific Adobe stock data:{"ticker":"ADBE","companyName":"Adobe"}GET /health- Returns proper health status:{"status":"ok","info":{},"error":{},"details":{}}Compatibility
The service maintains the existing API contract to ensure compatibility with dependent services in the TraderX ecosystem that reference it via the
REFERENCE_DATA_HOSTenvironment variable. No changes are required in dependent services.Link to Devin run
https://app.devin.ai/sessions/d8444bb27eea4476b2d0cf1f3df9d5ce
Requested by
Samir Chaudhry (samir@cognition.ai)