Rapid.Microservices.Framework.Core
8.3.1
dotnet add package Rapid.Microservices.Framework.Core --version 8.3.1
NuGet\Install-Package Rapid.Microservices.Framework.Core -Version 8.3.1
<PackageReference Include="Rapid.Microservices.Framework.Core" Version="8.3.1" />
<PackageVersion Include="Rapid.Microservices.Framework.Core" Version="8.3.1" />
<PackageReference Include="Rapid.Microservices.Framework.Core" />
paket add Rapid.Microservices.Framework.Core --version 8.3.1
#r "nuget: Rapid.Microservices.Framework.Core, 8.3.1"
#addin nuget:?package=Rapid.Microservices.Framework.Core&version=8.3.1
#tool nuget:?package=Rapid.Microservices.Framework.Core&version=8.3.1
Rapid.Microservice.Framework by Vedica AI
Rapid.Microservice.Framework is a plugin-based .NET microservice framework designed for lightning-fast service development. It handles endpoint creation, database management, and job execution out-of-the-box — letting developers focus entirely on business logic.
🚀 Key Features
✅ Auto-generates REST APIs from your plugins along with standard APIs
✅ Automatically creates controller classes for all your model or data model classes
⏱️ Scheduled job execution with simple XML config
💾 Automatic database handling using plugin-based storage engines
🔍 Built-in logging and monitoring for easy debugging
🔄 Plugin architecture for easy extensibility and customization
🔒 Multi-tenancy support with AppId-based data separation
💾 Built-in storage support with SQLite and other pluggable DBs
📡 RESTful querying based on AppId (multi-project/multi-tenant)
⚙️ Self-contained Windows Service for seamless deployment
🔌 Plugin-based development and logic execution (via Jobs)
🧩 Ideal for SaaS and enterprise tools
🛠️ Windows service ready-to-run executable included after build
📦 Installation
dotnet add package Rapid.Microservice.Framework.Core
🛠️ Getting Started
📝 Requirement You want a microservice to:
Read line coverage metrics from nightly build dumps.
Save snapshot data per project.
Expose historical coverage trends via REST APIs.
1️⃣ Create Your Job Plugin Project
Create a Class Library project targeting .NET Framework 4.8.
Add a reference to latest Rapid.Microservice.Framework.Core.
dotnet add package Rapid.Microservice.Framework.Core
2️⃣ Define DTO & Job Class
DTO Class: CodeCoverageDto.cs
[AutoController("CodeCoverage")]
public class CodeCoverageDataResponse : BasicResponse
{
// Inherits standard properties from BasicResponse:
// public string AppId { get; set; }
// public string Color { get; set; }
// public dynamic myData { get; set; } // User can use this field to set any kind of objects like List, Dictionary, etc.
// public string ReportDate { get; set; } // Framework automatically sets this
// public string TimeStamp { get; set; } // Framework automatically sets this
//public string ApiId
public double LineCoverage { get; set; }
public string Project { get; set; }
}
Job Class: CodeCoverageJob.cs
using System;
using Rapid.Microservices.Framework.Core.Common.Logger;
using Rapid.Microservices.Framework.Core.DataAccess;
using Rapid.Microservices.Framework.Core.Infrastructure.JobManager;
using Rapid.Microservices.Controller.PlugIn.Sample.ResponseModels;
namespace Rapid.Microservices.Controller.PlugIn.Sample.Jobs
{
public class CodeCoverageJob : Job<CodeCoverageDataResponse>
{
public override void DoJob(string date, IJobConfiguration jobConfiguration)
{
var AppId = jobConfiguration.AppId; // From JobConfiguration.xml
var project = jobConfiguration.Config["Project"]; // From JobConfiguration.xml
var coverageDumpPath = jobConfiguration.Config["CoverageDumpPath"]; // From JobConfiguration.xml
var lineCoverage = ReadCodeCoverageFromDump(coverageDumpPath);
try
{
var result = new CodeCoverageDataResponse
{
AppId = appId, //Id used to query this data using REST API
LineCoverage = lineCoverage,
ReportDate = date,
Project = project
};
Save(result); // Save api from framework will take of saving data with date to database
}
catch (Exception exception)
{
LoggerService.Error(this, $"Reading CodeCoverage Metrics for {appId} failed", exception);
}
}
}
private double ReadCodeCoverageFromDump(string path)
{
// Implement coverage dump parsing logic
return 78.5;
}
}
1️⃣ Using [AutoController("controllername")] class attribute or/and create the Controller Class
By default, the framework automatically generates controller for all DTO classes with the [AutoController] class level attribute. This allows you to access the API endpoints without creating a controller class manually.
Example:
- In above example, CodeCoverageDto class carries [AutoController("CodeCoverage")], hence the framework creates
CodeCoverageController
class automatically. - Users can access its API endpoints by referencing CodeCoverage in the URL
In case you want to create a custom controller class to add more REST APIs, you can do so by creating a new class and inheriting from BaseController<T>
.
Create a CodeCoverageController.cs
file in your plugin project:
public class CodeCoverageController : BaseController<CodeCoverageDto>
{
// Inherits standard REST APIs:
//http(s)://<host>:port/api/codecoverage/datajson
//http(s)://<host>:port/api/codecoverage/trenddatajson
//http(s)://<host>:port/api/codecoverage/predictiondatajson
//http(s)://<host>:port/api/codecoverage/predictiontrenddatajson
// You can also add custom endpoints here if needed
}
Both AutoController and Custom Controller class leverages built-in APIs from BaseController<T> for:
Endpoint | Description |
---|---|
/api/CodeCoverage/DataJson/AppId | Latest snapshot data by AppId |
/api/CodeCoverage/TrendDataJson/AppId/30 | Historical trend data by AppId and duration in days |
/api/CodeCoverage/PredictionDataJson/AppId | Forecasted snapshot data (if enabled) |
/api/CodeCoverage/PredictionTrendDataJsonAppId/30 | Trend of predictions over time |
Feel free to extend CodeCoverageController with additional custom APIs to meet your business logic needs.
3️⃣ Build the Project
After building, your output bin folder will include:
- Rapid.Microservices.Framework.Service.exe
- configurations/
- Sample_ServiceConfiguration.xml
- Sample_JobConfiguration.xml
- install_service.bat
- uninstall_service.bat
- readme.md
- license.txt
- other binaries
Then rename Sample_ServiceConfiguration.xml to ServiceConfiguration.xml and Sample_JobConfiguration.xml to JobConfiguration.xml
4️⃣ Deploy the Service
Copy all files from bin to your deployment folder:
D:\Microservices\CodeCoverage\
5️⃣ Configure the Service
Edit ServiceConfiguration.xml
<Configurations>
<Service>
<Id>CodeCoverage</Id>
<Name>Code Coverage Service</Name>
<DisplayName>Code Coverage Service</DisplayName>
<Description>Provides snapshot and trend of line coverage for projects</Description>
<Host>localhost</Host>
<Protocol>http</Protocol>
<Port>8010</Port>
<DbPlugIn>sqlite</DbPlugIn>
<PlugIns>CodeCoverage.PlugIn.dll</PlugIns>
<LogFilePath>D:\Microservices\CodeCoverage\logs</LogFilePath>
</Service>
<Jobs>
<Job>
<Name>CodeCoverageJob</Name>
<Enabled>True</Enabled>
<Interval>180</Interval>
</Job>
</Jobs>
<Notification>
<EmailIds>
<To>support@@vedicaai.com</To>
<Cc>operator@@vedicaai.com</Cc>
</EmailIds>
</Notification>
</Configurations>
Then in ServiceConfiguration.xml
📝 Update <PlugIns
> to your dll name.
🕒 <Interval
> is in minutes (e.g., 180 = every 3 hours).
Edit JobConfiguration.xml
Copy
Edit
<Configurations>
<Jobs>
<Job>
<Name>CodeCoverageJob</Name>
<AppId>DataElement-123</AppId>
<Project>MyProjectName</AppId>
<CoverageDumpPath>C:\Build\Artifacts\Coverage\</CoverageDumpPath>
</Job>
</Jobs>
</Configurations>
🆔 Set a unique <AppId> for each Data Element.
6️⃣ Install and Run the Windows Service
Run from deployment folder:
install_service.bat
Then open Services (services.msc), locate Code Coverage Service, and start it.
🌐 Query via REST API
Once the job runs and saves data, retrieve snapshot data using:
GET http://localhost:8010/api/CodeCoverage/DataJson/DataElement-123
Here, DataElement-123
is the AppId and is case sensitive.
✅ Example Response ⇒ Latest Data Element
{
"AppId": "DataElement-123",
"LineCoverage": 78.5,
"ReportDate": "2025-04-04",
"timestamp": "2025-04-04T22:00:00Z",
"Project": "MyProjectName"
}
Also to retrieve trend data using:
GET http://localhost:8010/api/CodeCoverage/TrendDataJson/myproject-123/4
Here, DataElement-123
is the AppId and 4
is the number of days data to fetch.
✅ Example Response ⇒ List of Data Elements
[
{
"AppId": "DataElement-123",
"LineCoverage": 78.5,
"ReportDate": "2025-04-04",
"timestamp": "2025-04-04T22:00:00Z",
"Project": "MyProjectName"
},
{
"AppId": "DataElement-123",
"LineCoverage": 77.5,
"ReportDate": "2025-04-03",
"timestamp": "2025-04-03T22:00:00Z",
"Project": "MyProjectName"
},
{
"AppId": "DataElement-123",
"LineCoverage": 74.5,
"ReportDate": "2025-04-02",
"timestamp": "2025-04-02T22:00:00Z",
"Project": "MyProjectName"
},
{
"AppId": "DataElement-123",
"LineCoverage": 72.5,
"ReportDate": "2025-04-01",
"timestamp": "2025-04-01T22:00:00Z",
"Project": "MyProjectName"
}
]
🧩 Multi-Tenancy & Data Segregation
AppId uniquely identifies each Data Element
All saved Data Element is retrieved using AppId
REST APIs return only Data Element for the specified AppId
🔄 Job Scheduling
Jobs run at intervals configured in ServiceConfiguration.xml
Each job runs in its own execution context
Additional job classes can be added as needed and configured separately in JobConfiguration.xml
💼 Use Cases
Metrics collection services
Build/test/deployment tracking
Health check monitors
Custom backend APIs for dashboards
Internal microservices for enterprise systems
Scheduled microservices (ETL, metrics, data scrapers)
Internal tools (build monitors, test metrics, deployment logs)
SaaS dashboards with project-specific APIs
🧰 Additional Notes
Multi-Tenant Design: AppId enables scoped data separation per data element/project.
Logging: Log path configurable in ServiceConfiguration.xml.
Database: Use sqlite, postgresql, mssql via plugin-based backends.
Job Scheduling: Supports any number of jobs with independent schedules.
Plugin Architecture: Easily extend functionality by creating new plugins.
🔒 Licensing & Support
The Core Framework is not open-source, but is freely distributed via NuGet.
For commercial use, licensing, or integration support:
📍 Quick Reference
Item | Value |
---|---|
Package Name | Rapid.Microservice.Framework.Core |
Service Entry Point | Rapid.Microservices.Framework.Service.exe |
Config Directory | bin/configuration/ |
Endpoint Format - Snapshot data | /api/controller/datajson/appid |
Endpoint Format - Trend data | /api/controller/trenddatajson/appid/duration |
Install Command | install_service.bat |
Uninstall Command | uninstall_service.bat |
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET Framework | net48 is compatible. net481 was computed. |
-
.NETFramework 4.8
- Microsoft.AspNet.WebApi.Core (>= 5.2.9)
- Microsoft.AspNet.WebApi.Owin (>= 5.2.9)
- Microsoft.ML (>= 2.0.1)
- Microsoft.ML.TimeSeries (>= 2.0.1)
- Microsoft.Owin (>= 4.2.2)
- Microsoft.Owin.Cors (>= 4.2.2)
- Microsoft.Owin.Host.HttpListener (>= 4.2.2)
- Microsoft.Owin.Hosting (>= 4.2.2)
- Newtonsoft.Json (>= 13.0.3)
- System.Data.SQLite (>= 1.0.119)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
Version | Downloads | Last updated | |
---|---|---|---|
8.3.1 | 69 | 4/26/2025 | |
8.3.0 | 75 | 4/26/2025 | |
8.2.9 | 143 | 4/25/2025 | |
8.2.8 | 141 | 4/25/2025 | |
8.2.6 | 155 | 4/24/2025 | |
8.2.3 | 149 | 4/6/2025 | |
8.2.2 | 157 | 4/6/2025 | |
8.2.1 | 130 | 4/6/2025 | |
8.2.0 | 78 | 4/5/2025 | |
8.1.4 | 87 | 4/5/2025 | |
8.1.2 | 92 | 4/5/2025 | |
8.0.8 | 109 | 4/4/2025 | |
8.0.0 | 136 | 4/4/2025 | |
7.1.5 | 168 | 3/1/2025 | |
7.1.0 | 129 | 2/26/2025 | |
7.0.3 | 129 | 2/18/2025 | |
7.0.2 | 140 | 2/18/2025 | |
7.0.0 | 128 | 2/16/2025 | |
6.0.8 | 123 | 2/14/2025 | |
5.3.7 | 425 | 8/14/2024 | |
5.1.7 | 186 | 9/17/2023 | |
5.1.6 | 155 | 9/16/2023 | |
5.1.5 | 184 | 9/15/2023 |
- Rapid.Microservices.CrashNotifier.exe added to package and available for Service Recovery=>Run program configuration