Download Adoptium JDK
Download maven binary tar.gz https://maven.apache.org/download.cgi
tar -xpache-maven-3.8.7-bin.tar.gz
This is the source repository for the Java components related to my Programming the Internet of Things book and Connected Devices IoT course. These are shell wrappers ONLY and are not a solution set (which is a separate repository, not yet released). For convenience to the reader, some basic functionality has already been implemented (such as configuration logic, consts, interfaces, a simple certificate file load utility, and test cases).
The code in this repository is largely comprised of shell classes that are designed to be implemented by the reader and are NOT solutions. These shell classes and their relationships respresent a notional design that aligns with the requirements listed in Programming the IoT Requirements. These requirements encapsulate the programming exercises presented in my book Programming the Internet of Things: An Introduction to Building Integrated, Device to Cloud IoT Solutions.
Please see the following links to access exercises, errata / clarifications, and the e-book:
If you're reading Programming the Internet of Things: An Introduction to Building Integrated, Device to Cloud IoT Solutions, you'll see a tie-in with the exercises described in each chapter and this repository. Most of the code in the main src tree is NOT implemented by design. It's intended for you - as the reader of my book (and possibly a student in one of my IoT courses) - to implement by filling in the implementation details as you work through each exercise.
A solution set is available, although I haven't yet released it. Stay tuned for updates on this topic.
These components are all written in Java 11 (or higher), and correlate to the exercises designed for the Gateway Device Application (GDA) specified in my book Programming the Internet of Things: An Introduction to Building Integrated, Device to Cloud IoT Solutions.
This repository is comprised of the following top level paths:
- config: Contains basic configuration file(s).
- src: Contains the following source trees:
- src/main/java: The main source tree for java-components. Keep in mind that most of these classes are shell representations ONLY and must be implemented as part of the exercises referenced above.
- src/test/java: The test source tree for java-components. These are designed to perform very basic unit and integration testing of the implementation of the exercises referenced above. This tree is sectioned by part - part01, part02, part03, and part04 - which correspond to the structure of Programming the Internet of Things.
Here are some other files at the top level that are important to review:
- pom.xml: The Maven project configuration file, with relevant depedencies, etc.
- README.md: This README.me file.
- LICENSE: The repository's LICENSE file.
Lastly, here are some 'dot' ('.{filename}') files pertaining to dev environment setup that you may find useful (or not - if so, just delete them after cloning the repo):
- .classpath: The Eclipse IDE CLASSPATH configuration file for your Java environment that may / may not be useful for your own cloned instance.
- .gitignore: The obligatory .gitignore that you should probably keep in place, with any additions that are relevant for your own cloned instance.
- .project: The Eclipse IDE project configuration file that may / may not be useful for your own cloned instance. Note that using this file to help create your Eclipse IDE project will result in the project name 'piot-java-components' (which can be changed, of course).
- .settings/org.eclipse.jdt.core.prefs: The Eclipse IDE settings file, which is only included to assist with setting up an Eclipse dev environment related to my IoT courses and book exercises, which may / may not be useful for your own cloned instance.
NOTE: The directory structure and all files are subject to change based on feedback I receive from readers of my book and students in my IoT class, as well as improvements I find to be helpful for overall repo betterment.
PR's are disabled while the codebase is being developed.
Much of this repository, and in particular unit and integration tests, will continue to evolve, so please check back regularly for potential updates. Please note that API changes can - and likely will - occur at any time.
This repository has external dependencies on other open source projects. I'm grateful to the open source community and authors / maintainers of the following libraries:
Core exercises:
- californium-core
- Reference: Eclipse Foundation, Inc. Californium (Cf) - CoAP for Java. (2020) [Online]. Available. https://github.com/eclipse/californium.
- californium/scandium-core
- Reference: Eclipse Foundation, Inc. Scandium (Sc) - Security for Californium. (2021) [Online]. Available. https://github.com/eclipse/californium/tree/master/scandium-core.
- commons-cli
- Reference: The Apache Software Foundation. Commons CLI. (2019) [Online]. Available. https://commons.apache.org/proper/commons-cli/.
- commons-configuration
- Reference: The Apache Software Foundation. Commons Configuration. (2020) [Online]. Available: https://commons.apache.org/proper/commons-configuration/.
- eclipse paho
- Reference: Eclipse Foundation, Inc. Eclipse Paho Java Client. (2020) [Online]. Available: https://github.com/eclipse/paho.mqtt.java.
- gson
- Reference: Google. Gson. (2008) [Online]. Available: https://github.com/google/gson.
- javax mail
- Reference: Oracle. JavaMail. (2018) [Online]. Available: https://javaee.github.io/javamail/.
- jedis
- Reference: J. Leibiusky. Jedis. (2020) [Online]. Available: https://github.com/redis/jedis.
- junit
- Reference: JUnit. JUnit 4. (2020) [Online]. Available: https://junit.org/junit4/.
NOTE: This list will be updated as others are incorporated.
For typical questions (and answers) to the repositories of the Programming the IoT project, please see the FAQ.
This code base is under active development.
If any code samples or other technology this work contains, describes, and / or is subject to open source licenses or the intellectual property rights of others, it is your responsibility to ensure that your use thereof complies with such licenses and/or rights.
Please see LICENSE if you plan to use this code.