Skip to content

Commit

Permalink
chore: updating pnp-preview-refresh to master branch (#853)
Browse files Browse the repository at this point in the history
* fix(azure-iothub): fix signatue for getTwin, updateTwin, updateModuleTwin to use Twin

fix #673

* improvement(provisioning samples): use the results of the registration to create and open device

* test(azure-iot-device-mqtt): reformat _mqtt_test.js (#741)

* (chore) add issue templates workflow

* Delete ISSUE_TEMPLATE.md

* Update bug-report.md

* fix(azure-iot-mqtt-base): forceReconnect for disconnecting hang in mqtt-base (#770)

* release(2020-04-24): bump package versions (#771)

Co-authored-by: Azure IoT Client Build <aziotclb@microsoft.com>

* refactor: update to mqtt.js v4 (#772)

* build: update to mqtt.js v4

* refactor: add debug logs

* fix: eslint issue

* chore: remove network_e2e directory - no longer used (#775)

* refactor: expose connection error in mqtt (#776)

* release(2020-05-07): bump package versions (#788)

* release(2020-05-07): bump package versions

Co-authored-by: Azure IoT Client Build <aziotclb@microsoft.com>

* refactor(multipe packages): c2d states no longer using booleans (#797)

This moves the logic of checking if C2D is enabled down to the transport level, since it is not necessarily accurate to represent it at the device client level. There is not enough information at that level to make totally accurate judgements of if it is connected or not.

* chore(azure-iot-device-amqp): debug logs for c2d (#804)

* build: update to mqtt.js v4

* chore: add debug logs

* chore(azure-iot-device): updating api version to support twin arrays (#806)

* improvement(azure-iot-mqtt-base): maintain knowledge of on the wire publishes (#808)

By tracking the on the wire publishes we can reliably complete in case of disconnects or other
errors.

* feat(azure-iot-mqtt-device): modelID option (#809)

This adds the setOption for ModelID, which will enable users to use the existing device client library as a PnP library. To accomodate the lack of support in the existing service API, a switching API call has been added that will use the preview API version if the modelID is set.

* release(2020-05-28): bump package versions (#810)

Co-authored-by: Azure IoT Client Build <aziotclb@microsoft.com>

* Create synctodevops.yml

* chore(azure-iot-provisioning-device): update samples to use env var (#816)

* Add CodeQL security scanning (#815)

Co-authored-by: Anthony V. Ercolano <anthonyvercolano@users.noreply.github.com>

* improvement(azure-iot-mqtt-base): add timeouts to publishes that have… (#818)

* improvement(azure-iot-mqtt-base): add timeouts to publishes that have not been PUBACKed by the service

744

* update classes and unique identifiers.

* chore: create config.yml for issue templates (#823)

* chore: create config.yml for issue templates

* chore: update technical question for msft q&a

* fix: add vanity link for IoT help

* chore: update technical question options

* fix: add https://

* fix: add https://

* fix: add https://

* fix: add https://

Co-authored-by: Anthony V. Ercolano <anthonyvercolano@users.noreply.github.com>

* feat(azure-iot-device): adds emit to connect (#819)

'connect' is emitted whenever the device transport FSM enters the "connected" state for MQTT, and "authenticated" for AMQP.

* fix(azure-iot-device): lint error on simple sample (#826)

* fix(azure-iot-device): lint error on simple sample

* fix(azure-iot-device): add sample linting to the CI

* refactor(multiple): update to typescript 3.7.5 move to dist instead of lib parameter checking and suppression (#824)

* chore: updating docs to clarify edge support for linux only

* refactor(multiple): update to typescript 3.7.5 move to dist etc (#830)

* chore: node pnp sample for summer

* chore: update prov sample to use env variables (#831)

* chore: node pnp sample for summer

* refactor(multiple): update to typescript 3.7.5 move to dist vs lib other minor (#833)

* chore: node pnp sample for summer

* chore: rename digital-twin-model-id to model-id in mqtt (#829)

* chore: node pnp sample for summer

* chore: node pnp sample for summer

* chore: initial addition of pnp simple thermostat sample (#827)

* chore: node pnp sample for summer

* release(2020-07-06): bump package versions (#838)

Co-authored-by: Azure IoT Client Build <aziotclb@microsoft.com>

* chore: fixing the sample for feedback (#839)

* chore: remove writable property in reported (#842)

* chore: some changes

* chore: some changes

* chore: some changes

* Update pnpTemperatureController.js

* Updated file upload sample to reflect current SDK changes. (#834)

* fix(sample): update sample to use current SDK changes

* fix(sample): update to use latest SDK changes, add use strict

* fix(sample): update sample to use current SDK changes, fix linting issue

* Update upload_to_blob_advanced.js

* Update upload_to_blob_advanced.js

Co-authored-by: Chandler Lattin <chlattin@microsoft.com>
Co-authored-by: Anthony V. Ercolano <anthonyvercolano@users.noreply.github.com>
Co-authored-by: Yoseph Maguire <yoseph.maguire@microsoft.com>
Co-authored-by: Yoseph Maguire <yoseph.maguire@gmail.com>

* chore: align environment variable names

* Update pnpTemperatureController.js

* chore: removing all the lib folders in repo

Co-authored-by: Anthony Ercolano <toercola@microsoft.com>
Co-authored-by: Anthony V. Ercolano <anthonyvercolano@users.noreply.github.com>
Co-authored-by: Yoseph Maguire <yoseph.maguire@microsoft.com>
Co-authored-by: Elena Horton <52430760+elhorton@users.noreply.github.com>
Co-authored-by: Azure IoT Client Build <aziotclb@microsoft.com>
Co-authored-by: Justin Hutchings <jhutchings1@users.noreply.github.com>
Co-authored-by: olivakar <oliva.kar@microsoft.com>
Co-authored-by: olivakar <oliva.tanusree@gmail.com>
Co-authored-by: Chandler Lattin <chandlerlattin@knights.ucf.edu>
Co-authored-by: Chandler Lattin <chlattin@microsoft.com>
Co-authored-by: Yoseph Maguire <yoseph.maguire@gmail.com>
  • Loading branch information
12 people committed Jul 20, 2020
1 parent cdd8f5d commit 63a9cf1
Show file tree
Hide file tree
Showing 275 changed files with 6,338 additions and 47,177 deletions.
4 changes: 2 additions & 2 deletions .github/CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@

# Need Support?
- **Have a feature request for SDKs?** Please post it on [User Voice](https://feedback.azure.com/forums/321918-azure-iot) to help us prioritize
- **Have a technical question?** Ask on [Stack Overflow with tag "azure-iot-hub"](https://stackoverflow.com/questions/tagged/azure-iot-hub)
- **Have a technical question?** Please see [IoT support options](https://aka.ms/IoTHelp) for information on posting questions on Microsoft Q&A and Stack overflow using the "azure-iot-sdk" tag.
- **Need Support?** Every customer with an active Azure subscription has access to [support](https://docs.microsoft.com/en-us/azure/azure-supportability/how-to-create-azure-support-request) with guaranteed response time. Consider submitting a ticket and get assistance from Microsoft support team
- **Found a bug?** Please help us fix it by thoroughly documenting it and filing an issue on GitHub (See below).

Expand Down Expand Up @@ -56,4 +56,4 @@ We use requirement documents to describe the expected behavior for each code mod
When contributing to markdown requirement docs (located in the `devdoc` folder alongside the code, you should use `99` for a developer id, and just increment the last number of the requirement to be unique.

## Adding new files
If your contribution is not part of an already existed code, you must create a new requirement file and a new set of unit tests project in the appropriate `devdoc` and `test` directories.
If your contribution is not part of an already existed code, you must create a new requirement file and a new set of unit tests project in the appropriate `devdoc` and `test` directories.
29 changes: 0 additions & 29 deletions .github/ISSUE_TEMPLATE.md

This file was deleted.

56 changes: 56 additions & 0 deletions .github/ISSUE_TEMPLATE/bug-report.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
---
name: Bug Report
about: Create a bug report to help us improve
title: ''
labels: bug
assignees: ''

---

------------------------------- delete below -------------------------------

INSTRUCTIONS
==========

Please follow the instructions and template below to save us time requesting additional information from you. For more information on all of your support options, please see [Azure IoT support and help options](https://aka.ms/IoTHelp).

*If this is an issue encountered by following a Microsoft document, please open an issue on that page itself. This ensures the fastest targeted response, and you can do this by scrolling all the way down to the bottom of the page to the **Feedback** section to report the issue.*

1. Search existing issues to avoid creating duplicates.

2. If possible test using the [latest release](https://github.com/Azure/azure-iot-sdk-node/releases) to make sure your issues has not already been fixed.

3. Do not share information from your Azure subscription here (connection strings, service names (IoT Hub name, Device Provisioning Service scope ID), etc...). If you need to share any of this information, you can create a ticket and [get assistance from Microsoft Support](https://docs.microsoft.com/en-us/azure/azure-supportability/how-to-create-azure-support-request).

4. Include enough information for us to address the bug:

- A detailed description.
- A [Minimal Complete Reproducible Example](https://stackoverflow.com/help/mcve). This is code we can cut and paste into a readily available sample and run, or a link to a project you've written that we can compile to reproduce the bug.
- Console logs.

5. Delete these instructions before submitting the bug.

Below is a generic bug report format. We recommend you use it as a template and replace the information below each header with your own.

------------------------------- delete above -------------------------------

# Context

- **OS and version used:** <VERSION> <!-- Windows 10, Ubuntu 18.04... -->
- **Node.js version:** <VERSION> <!-- in a command prompt: node --version -->
- **npm version:** <VERSION> <!-- in a command prompt: npm --version -->
- **list of installed packages:** <VERSION> <!-- in a command prompt, from the directory containing your code: npm list -->
- **cloned repo:** <VERSION> <!-- **If** you are using a cloned sdk repository, in a command prompt: git describe -->

## Description of the issue

Please be as detailed as possible: which feature has a problem, how often does it fail, etc.

## Code sample exhibiting the issue

Please remove any connection string information!

## Console log of the issue

Consider setting the DEBUG environment variable to '*'. This will produce a much more verbose output that will help debugging
Don't forget to remove any connection string information!
5 changes: 5 additions & 0 deletions .github/ISSUE_TEMPLATE/config.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
blank_issues_enabled: false
contact_links:
- name: Azure IoT support and help options
url: https://aka.ms/IoTHelp
about: The main landing page for all Azure IoT support options.
43 changes: 43 additions & 0 deletions .github/ISSUE_TEMPLATE/feature-request.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
---
name: Feature Request
about: Suggest an idea for this project
title: "[feature request]"
labels: enhancement
assignees: ''

---

------------------------------- delete below -------------------------------

Thank you for raising a feature request! To get started, here's a few things to consider:

# 1) Check existing requests:
- We track large feature requests through our [UserVoice page](https://feedback.azure.com/forums/321918-azure-iot). Be sure to check this out first!

- Before submitting a request, please ensure it has not already been submitted. If it has, please upvote and/or comment on the request. This will increase its visibility and raise its priority.

- Similarly, if this is a minor suggestion or enhancement, please check our existing [Github issues](https://github.com/Azure/azure-iot-sdk-node/issues) to ensure it has not already been raised. If so, please comment on the issue to add support and raise visibility for it.

# 2) File your request:
- Now, if your feature has not yet been raised, please follow the below guidance:
- If this is a large feature request (may require support across different languages or enables an entirely new scenario), please file it on our [UserVoice page](https://feedback.azure.com/forums/321918-azure-iot).

- If this is a minor suggestion or enhancement (scoped only to this language), please file it as an issue following the format below.

As an open source project, we welcome PRs for new features, and we don't want to reject any hard work you've done to contribute. **So propose your solution through an issue first** so we can discuss the changes, and if things look good we will ask you submit a PR to implement the changes.

------------------------------- delete above -------------------------------

**Is your feature request related to a problem? Please describe.**
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]

**Describe the solution you'd like**
A clear and concise description of what you want to happen.

**Describe alternatives you've considered**
A clear and concise description of any alternative solutions or features you've considered.

**Additional context**
Add any other context or screenshots about the feature request here.

Thank you for helping make this project even better!
22 changes: 22 additions & 0 deletions .github/ISSUE_TEMPLATE/technical-question.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
---
name: Technical Question
about: Ask a technical question related to the SDK
title: "[Technical Question]"
labels: question
assignees: ''

---

------------------------------- delete below -------------------------------

Thank you for asking a technical question! If your question is "why doesn't my code work?", please see [submit a bug report](https://github.com/Azure/azure-iot-sdk-node/issues/new?assignees=&labels=bug&template=bug-report.md&title=) instead.

We encourage you to submit technical questions related to the SDK on Stack Overflow. We actively monitor all questions tagged wtih "azure-iot-sdk".

Additionally, if your technical question requires submitting service logs, you can submit an [Azure Support Ticket](https://docs.microsoft.com/en-us/azure/azure-supportability/how-to-create-azure-support-request).

If you have a question specifically on a Microsoft page you've read, please open an issue on the document itself. This ensures you get the fastest targeted response, and you can do this by scrolling to the bottom of the page to the **Feedback** section.

For more information on the support options available to you, please see [Azure IoT support and help options](https://aka.ms/IoTHelp).

------------------------------- delete above -------------------------------
52 changes: 52 additions & 0 deletions .github/workflows/codeql.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
name: "Code scanning - action"

on:
push:
pull_request:
schedule:
- cron: '0 19 * * 0'

jobs:
CodeQL-Build:

# CodeQL runs on ubuntu-latest and windows-latest
runs-on: ubuntu-latest

steps:
- name: Checkout repository
uses: actions/checkout@v2
with:
# We must fetch at least the immediate parents so that if this is
# a pull request then we can checkout the head.
fetch-depth: 2

# If this run was triggered by a pull request event, then checkout
# the head of the pull request instead of the merge commit.
- run: git checkout HEAD^2
if: ${{ github.event_name == 'pull_request' }}

# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
uses: github/codeql-action/init@v1
# Override language selection by uncommenting this and choosing your languages
# with:
# languages: go, javascript, csharp, python, cpp, java

# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
# If this step fails, then you should remove it and run the build manually (see below)
- name: Autobuild
uses: github/codeql-action/autobuild@v1

# ℹ️ Command-line programs to run using the OS shell.
# 📚 https://git.io/JvXDl

# ✏️ If the Autobuild fails above, remove it and uncomment the following three lines
# and modify them (or add more) to build your code if your project
# uses a compiled language

#- run: |
# make bootstrap
# make release

- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v1
23 changes: 23 additions & 0 deletions .github/workflows/synctodevops.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@

name: Sync issue to Azure DevOps work item

"on":
issues:
types:
[opened, edited, deleted, closed, reopened, labeled, unlabeled]

jobs:
alert:
runs-on: ubuntu-latest
steps:
- uses: danhellem/github-actions-issue-to-work-item@master
env:
ado_token: "${{ secrets.ADO_PERSONAL_ACCESS_TOKEN }}"
github_token: "${{ secrets.GH_PERSONAL_ACCESS_TOKEN }}"
ado_organization: "${{ secrets.ADO_ORGANIZATION }}"
ado_project: "${{ secrets.ADO_PROJECT }}"
ado_area_path: "${{ secrets.ADO_AREA_PATH }}"
ado_wit: "Bug"
ado_new_state: "New"
ado_close_state: "Done"
ado_bypassrules: false
48 changes: 27 additions & 21 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -208,33 +208,39 @@ $RECYCLE.BIN/
**/*.map

# Typescript compiler output files
common/core/lib/
common/transport/amqp/lib/
common/transport/http/lib/
common/transport/mqtt/lib/

device/core/lib/
device/transport/amqp/lib/
device/transport/http/lib/
device/transport/mqtt/lib/
common/core/dist/
common/transport/amqp/dist/
common/transport/http/dist/
common/transport/mqtt/dist/

device/core/dist/
device/transport/amqp/dist/
device/transport/http/dist/
device/transport/mqtt/dist/
device/ts-samples/*.js

provisioning/service/lib
provisioning/transport/amqp/lib/
provisioning/transport/http/lib/
provisioning/transport/mqtt/lib/
provisioning/device/lib/
provisioning/device/ts-samples/lib
provisioning/service/dist
provisioning/transport/amqp/dist/
provisioning/transport/http/dist/
provisioning/transport/mqtt/dist/
provisioning/device/dist/
provisioning/device/ts-samples/dist

security/x509/lib
security/tpm/lib
security/symmetric/lib
security/x509/dist
security/tpm/dist
security/symmetric/dist

service/lib
service/dist

ts-e2e/lib
ts-e2e/dist

longhaultests/lib
longhaultests/dist

digitaltwins/device/dist
digitaltwins/samples/device/typescript/dist
digitaltwins/samples/service/typescript/dist
digitaltwins/service/dist
digitaltwins/model_repository/dist

digitaltwins/device/dist
digitaltwins/samples/device/typescript/dist
Expand Down
2 changes: 1 addition & 1 deletion build/tools/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
},
"homepage": "https://github.com/azure/azure-iot-sdk-node#readme",
"dependencies": {
"azure-iothub": "1.12.0-pnp-refresh.0",
"azure-iothub": "1.12.4",
"chalk": "^1.1.3",
"pem": "^1.14.2",
"yargs": "^15.3.1"
Expand Down
3 changes: 2 additions & 1 deletion common/core/.npmignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,5 @@ devdoc/
test/
samples/
src/
lib/**/*.map
dist/**/*.map
.nyc_output
28 changes: 14 additions & 14 deletions common/core/common.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,21 +2,21 @@
// Licensed under the MIT license. See LICENSE file in the project root for full license information.

import { EventEmitter } from 'events';
import { Message } from './lib/message';
import { Message } from './dist/message';

export import endpoint = require('./lib/endpoint');
export import errors = require('./lib/errors');
export import results = require('./lib/results');
export { ResultWithHttpResponse } from './lib/results';
export { anHourFromNow, encodeUriComponentStrict } from './lib/authorization';
export { ConnectionString } from './lib/connection_string';
export import endpoint = require('./dist/endpoint');
export import errors = require('./dist/errors');
export import results = require('./dist/results');
export { ResultWithHttpResponse } from './dist/results';
export { anHourFromNow, encodeUriComponentStrict } from './dist/authorization';
export { ConnectionString } from './dist/connection_string';
export { Message }
export { SharedAccessSignature } from './lib/shared_access_signature';
export { RetryOperation } from './lib/retry_operation';
export { RetryPolicy, NoRetry, ExponentialBackOffWithJitter } from './lib/retry_policy';
export { AuthenticationProvider, AuthenticationType } from './lib/authentication_provider';
export { getAgentPlatformString } from './lib/utils';
export { Callback, ErrorCallback, NoErrorCallback, DoubleValueCallback, TripleValueCallback, HttpResponseCallback, callbackToPromise, doubleValueCallbackToPromise, errorCallbackToPromise, noErrorCallbackToPromise, tripleValueCallbackToPromise, httpCallbackToPromise } from './lib/promise_utils'
export { SharedAccessSignature } from './dist/shared_access_signature';
export { RetryOperation } from './dist/retry_operation';
export { RetryPolicy, NoRetry, ExponentialBackOffWithJitter } from './dist/retry_policy';
export { AuthenticationProvider, AuthenticationType } from './dist/authentication_provider';
export { getAgentPlatformString } from './dist/utils';
export { Callback, ErrorCallback, NoErrorCallback, DoubleValueCallback, TripleValueCallback, HttpResponseCallback, callbackToPromise, doubleValueCallbackToPromise, errorCallbackToPromise, noErrorCallbackToPromise, tripleValueCallbackToPromise, httpCallbackToPromise } from './dist/promise_utils'

export interface Receiver extends EventEmitter {
on(type: 'message', func: (msg: Message) => void): this;
Expand All @@ -25,4 +25,4 @@ export interface Receiver extends EventEmitter {
on(type: string, func: Function): this;
}

export { TransportConfig, X509 } from './lib/authorization';
export { TransportConfig, X509 } from './dist/authorization';
Loading

0 comments on commit 63a9cf1

Please sign in to comment.