Skip to content

lint & several fix for .md #81

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Aug 5, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
59 changes: 29 additions & 30 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
# AWS IoT SDK for Java v2

This document provides information about the AWS IoT device SDK for Java V2.

If you have any issues or feature requests, please file an issue or pull request.
Expand All @@ -14,38 +15,40 @@ This SDK is built on the AWS Common Runtime, a collection of libraries
cross-platform, high-performance, secure, and reliable. The libraries are bound
to Java by the [aws-crt-java](https://github.com/awslabs/aws-crt-java) package.


*__Jump To:__*

* [Installation](#Installation)
* [Mac-Only TLS Behavior](#Mac-Only-TLS-Behavior)
* [Samples](samples)
* [Getting Help](#Getting-Help)
* [Giving Feedback and Contributions](#Giving-Feedback-and-Contributions)
* [More Resources](#More-Resources)



## Installation

### Minimum Requirements
* Java 8 or above

** Set JAVA_HOME first
* Java 8 or above

* Set JAVA_HOME first

### Requirements to build the AWS CRT locally
* CMake 3.1+
* Clang 3.9+ or GCC 4.4+ or MSVC 2015+

* CMake 3.1+
* Clang 3.9+ or GCC 4.4+ or MSVC 2015+

### Build IoT Device SDK from source
```

``` sh
git clone https://github.com/awslabs/aws-iot-device-sdk-java-v2.git
# update the version of the CRT being used
mvn versions:use-latest-versions -Dincludes="software.amazon.awssdk.crt*"
mvn clean install
```

### Build CRT from source
```sh

``` sh
# NOTE: use the latest version of the CRT here

git clone --branch v0.4.20 https://github.com/awslabs/aws-crt-java.git
Expand All @@ -58,9 +61,11 @@ mvn clean install
```

#### Android

Supports API 26 or newer.
NOTE: The shadow sample does not currently complete on android due to its dependence on stdin keyboard input.
```sh

``` sh
git clone --recursive --branch v0.6.2 https://github.com/awslabs/aws-crt-java.git
git clone https://github.com/awslabs/aws-iot-device-sdk-java-v2.git
cd aws-crt-java/android
Expand All @@ -72,7 +77,8 @@ cd ../aws-iot-device-sdk-java-v2/android
```

Add the following to your project's build.gradle:
```groovy

``` groovy
repositories {
mavenCentral()
maven {
Expand All @@ -85,55 +91,48 @@ dependencies {
}
```



## Mac-Only TLS Behavior

Please note that on Mac, once a private key is used with a certificate, that certificate-key pair is imported into the Mac Keychain. All subsequent uses of that certificate will use the stored private key and ignore anything passed in programmatically. Beginning in v1.2.6, when a stored private key from the Keychain is used, the following will be logged at the "info" log level:
Please note that on Mac, once a private key is used with a certificate, that certificate-key pair is imported into the Mac Keychain. All subsequent uses of that certificate will use the stored private key and ignore anything passed in programmatically. When a stored private key from the Keychain is used, the following will be logged at the "info" log level:

```
static: certificate has an existing certificate-key pair that was previously imported into the Keychain. Using key from Keychain instead of the one provided.
```



## Samples

[Samples README](samples)


## Getting Help

Use the following sources for information :
* Check api and developer guides.
* Check for similar issues already opened.

If you still can’t find a solution to your problem open an [issue](https://github.com/aws/aws-iot-device-sdk-java-v2/issues)

* Check api and developer guides.
* Check for similar issues already opened.

If you still can’t find a solution to your problem open an [issue](https://github.com/aws/aws-iot-device-sdk-java-v2/issues)

## Giving Feedback and Contributions

We need your help in making this SDK great. Please participate in the community and contribute to this effort by submitting issues, participating in discussion forums and submitting pull requests through the following channels.
* [Contributions Guidelines](master/CONTRIBUTING.md)
* Articulate your feature request or upvote existing ones on our [Issues](https://github.com/aws/aws-iot-device-sdk-java-v2/issues?q=is%3Aissue+is%3Aopen+label%3Afeature-request) page.
* Submit [Issues](https://github.com/aws/aws-iot-device-sdk-java-v2/issues)

* [Contributions Guidelines](master/CONTRIBUTING.md)
* Articulate your feature request or upvote existing ones on our [Issues](https://github.com/aws/aws-iot-device-sdk-java-v2/issues?q=is%3Aissue+is%3Aopen+label%3Afeature-request) page.
* Submit [Issues](https://github.com/aws/aws-iot-device-sdk-java-v2/issues)

## More Resources

* [AWS IoT Core Documentation](https://docs.aws.amazon.com/iot/)
* [Developer Guide](https://docs.aws.amazon.com/iot/latest/developerguide/what-is-aws-iot.html) ([source](https://github.com/awsdocs/aws-iot-docs))
* [Issues](https://github.com/aws/aws-iot-device-sdk-java-v2/issues)
* [Dev Blog](https://aws.amazon.com/blogs/?awsf.blog-master-iot=category-internet-of-things%23amazon-freertos%7Ccategory-internet-of-things%23aws-greengrass%7Ccategory-internet-of-things%23aws-iot-analytics%7Ccategory-internet-of-things%23aws-iot-button%7Ccategory-internet-of-things%23aws-iot-device-defender%7Ccategory-internet-of-things%23aws-iot-device-management%7Ccategory-internet-of-things%23aws-iot-platform)
* [AWS IoT Core Documentation](https://docs.aws.amazon.com/iot/)
* [Developer Guide](https://docs.aws.amazon.com/iot/latest/developerguide/what-is-aws-iot.html) ([source](https://github.com/awsdocs/aws-iot-docs))
* [Issues](https://github.com/aws/aws-iot-device-sdk-java-v2/issues)
* [Dev Blog](https://aws.amazon.com/blogs/?awsf.blog-master-iot=category-internet-of-things%23amazon-freertos%7Ccategory-internet-of-things%23aws-greengrass%7Ccategory-internet-of-things%23aws-iot-analytics%7Ccategory-internet-of-things%23aws-iot-button%7Ccategory-internet-of-things%23aws-iot-device-defender%7Ccategory-internet-of-things%23aws-iot-device-management%7Ccategory-internet-of-things%23aws-iot-platform)

Integration with AWS IoT Services such as
[Device Shadow](https://docs.aws.amazon.com/iot/latest/developerguide/iot-device-shadows.html)
[Jobs](https://docs.aws.amazon.com/iot/latest/developerguide/iot-jobs.html)
[Fleet Provisioning](https://docs.aws.amazon.com/iot/latest/developerguide/provision-wo-cert.html)
is provided by code that been generated from a model of the service.


# License
## License

This library is licensed under the Apache 2.0 License.
18 changes: 10 additions & 8 deletions samples/README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#Samples
# Samples

## Shadow

Expand All @@ -23,7 +23,8 @@ value.
Source: `samples/Shadow`

To Run:
```

``` sh
> mvn exec:java -pl samples/Shadow -Dexec.mainClass=shadow.ShadowSample -Dexec.args='--endpoint <endpoint> --rootca /path/to/AmazonRootCA1.pem --cert <cert path> --key <key path> --thingName <thing name>'
```

Expand Down Expand Up @@ -98,7 +99,8 @@ On startup, the sample describes a job that is pending execution.
Source: `samples/Jobs`

To Run:
```

``` sh
> mvn exec:java -pl samples/Jobs -Dexec.mainClass=jobs.JobsSample -Dexec.args='--endpoint <endpoint> --rootca /path/to/AmazonRootCA1.pem --cert <cert path> --key <key path> --thingName <thing name>'
```

Expand Down Expand Up @@ -173,15 +175,15 @@ Source: `samples/Identity`
cd ~/samples/Identity

Run the sample using CreateKeysAndCertificate:
```

``` sh
mvn exec:java -Dexec.mainClass="identity.FleetProvisioningSample" -Dexec.args="--endpoint <endpoint> --rootca <root ca path>
--cert <cert path> --key <private key path> --templateName <templatename> --templateParameters <templateParams>"
```

Run the sample using CreateCertificateFromCsr:
```

``` sh
mvn exec:java -Dexec.mainClass="identity.FleetProvisioningSample" -Dexec.args="--endpoint <endpoint> --rootca <root ca path>
--cert <cert path> --key <private key path> --templateName <templatename> --templateParameters <templateParams> --csr <csr path>"
```
Expand Down Expand Up @@ -231,4 +233,4 @@ and receive.
]
}
</pre>
</details>
</details>