Device-shadow component is responsible to provide ability to device to resync its configuration, especially when the device got disconnected or its configuration is found to be corrupted.
- Getting Started
- Architecture
- Usage
- How to contribute
- Built with Dependencies
- Code of Conduct
- Contributors
- Security Contact Information
- Support
- Troubleshooting
- License
- Announcements
- Acknowledgments
Device Shadow component exposes API that the Device Client can use to resync its configuration, especially when it got disconnected or its configuration is found to be corrupted.
To build the project in the local working directory after the project has been cloned/forked, run:
mvn clean install
from the command line interface.
The list of tools required to build and run the project:
- Java 17
- Maven
- Container environment
-
Install Docker on your machine by referring to official Docker documnentation to have a Container environment.
checkstyle.xml is the coding standard to follow while writing new/updating existing code.
Checkstyle plugin maven-checkstyle-plugin:3.2.1 is
integrated in pom.xml which runs in the validate phase and check goal of the maven lifecycle and fails
the build if there are any checkstyle errors in the project.
To run checkstyle plugin explicitly, run the following command:
mvn checkstyle:check
To run the tests for this system run the below maven command.
mvn test
Or run a specific test
mvn test -Dtest="TheFirstUnitTest"
To run a method from within a test
mvn test -Dtest="TheSecondUnitTest#whenTestCase2_thenPrintTest2_1"
- The component can be deployed as Kubernetes pod by installing Device Shadow charts.
Link: Charts
- Detailed information about the request and response request and response can be found in API docs Device Shadow restful services.
Sequence diagram of Device Shadow:
This component is used by the device to get its latest configuration details at the time of network outage or device restart.
- Spring - Web framework used for building the application
- Maven - Build tool used for dependency management
- Project Lombok - Auto-generates Java boilerplate code (e.g., getters, setters, builders)
- Apache Common - Java Library
- Jackson - Reading JSON Objects
- Morphia - A Java tool for mapping Java objects to MongoDB documents.
- Logback - Concrete logging implementation used with SLF4J.
- slf4j - Logging facade providing abstraction for various logging frameworks.
- Mockito - Mocking framework for testing.
- JUnit - Unit testing framework.
Please read CONTRIBUTING.md for details on our contribution guidelines, and the process for submitting pull requests to us.
Please read CODE_OF_CONDUCT.md for details on our code of conduct, and the process for submitting pull requests to us.
The list of contributors who participated in this project.
Please read SECURITY.md to raise any security related issues.
Contact the project developers via the project's "dev" list - ecsp-dev
Please read CONTRIBUTING.md for details on how to raise an issue and submit a pull request to us.
This project is licensed under the Apache-2.0 License - see the LICENSE file for details.
All updates to this component are present in our releases page. For the versions available, see the tags on this repository.
