Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/rafiulgits/iothub
Cloud based IoT system solution. MQTT Broker, MQTT Agent, SignalR Hub, Data Source API
https://github.com/rafiulgits/iothub
broker iot iothub mqtt signalr
Last synced: about 10 hours ago
JSON representation
Cloud based IoT system solution. MQTT Broker, MQTT Agent, SignalR Hub, Data Source API
- Host: GitHub
- URL: https://github.com/rafiulgits/iothub
- Owner: rafiulgits
- License: mit
- Created: 2020-04-27T03:28:37.000Z (over 4 years ago)
- Default Branch: master
- Last Pushed: 2023-03-03T23:31:01.000Z (almost 2 years ago)
- Last Synced: 2023-03-05T02:49:12.146Z (almost 2 years ago)
- Topics: broker, iot, iothub, mqtt, signalr
- Language: C#
- Homepage: https://rafiulgits.github.io/IotHub/
- Size: 143 KB
- Stars: 39
- Watchers: 4
- Forks: 11
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
A cloud based IoT solution
IotHub provides an abstract solution of any IoT infrastructure including Broker system, API management, Authentication, Agent management system, so that it can be extended to any preferable IoT solution like **home automation system, supply chain management**.
[Documentation](https://rafiulgits.github.io/IotHub)
****
### Solution Structure
* **IotHub.Agent**
A .NET web project to establish the channel between `MQTT` broker and `SignalR` broker. This agent will publish all `MQTT` broker messages to `SignalR` clients (dashboard, control panel) and send all commands from `SignalR` clients to `MQTT` clients. Agent is using [MQTTnet](https://github.com/chkr1011/MQTTnet) `managed client` to connect with `MQTT` broker.
* **IotHub.API**
A .NET web API project to provide and manage all data sources of the solution. This project use.
* **IotHub.Broker**
A .NET web project to establish a MQTT broker server. Broker is using [MQTTnet](https://github.com/chkr1011/MQTTnet) `server`.
* **IotHub.Common**
A .NET classlib project to provide all common models, enums, exceptions and other stuffs.
* **IotHub.DataTransferObject**
A .NET classlib project, using to transfer data from service layer to service, controller and other service consumers.
* **IotHub.DB**
A .NET classlib project, to provide all database context and settings. Solution is using `MongoDB` as primary database.
* **IotHub.DomianModels**
A .NET classlib project, to provide domain level models.
* **IotHub.Repositories**
A .NET classlib project, to communicate with database or data source and response in domain level. Only `IotHub.Services` have the access to use repository to provide a security level to access domain models.
* **IotHub.Services**
A .NET classlib project, to provide all common services e.g authentication service, user management service, profile management services.
Solution Architecture
***
Broker Architecture
***
### How to use (development)
Very first clone the project using `git clone https://github.com/rafiulgits/IotHub.git` or download the project by clicking on download button.
**Required Environments**
* .NET Core 3.1 or later
* MongoDB**Execution**
* Build the solution by `dotnet build`
* Go to `src/IotHub.API` and from `appsettings.json` set your internal custom credential and use this credential create some new users (including agent one) and profiles
* Run the `src/IotHub.Broker` development server by `dotnet watch run`
* Go to `src/IotHub.Agent` , set agent credentials that you created earlier and run the development server by `dotnet watch run`Development environment is ready to use!
For testing with MQTT clients, [MQTT fx](https://mqttfx.jensd.de/index.php/download) is a good solution. [iothub-dashboard](https://github.com/rafiulgits/iothub-dashboard) is a Reactive example dashboard that will help to find out how to use IotHub solution.
***
### Full Documentations
* [IotHub.Agent Doc](./docs/agent_doc.md)
* [IotHub.Broker Doc](./docs/broker_doc.md)
* [IotHub.API Doc](./docs/api_doc.md)
***
## License
This repository is licensed with the [MIT](./LICENSE) license.