Repository: dapr/components-contrib
Pull request #1035 (2021-07-24 13:03:38)

SNS and SQS topic/queue names + SNS subscription deletion bugfix
# Description
* Implement proposed sanitized names for topics, queues and subscriptions in SNS/SQS, instead of SHA256 hashed strings
* Bugfix for deletion of SQS subscription on SNS upon daprd termination

## Issue reference
https://github.com/dapr/components-contrib/issues/1034

https://github.com/dapr/components-contrib/issues/1029

Please reference the issue this PR will close: #_[issue number]_

## Checklist

Please make sure you've completed the relevant tasks for this PR, out of the following list:

* [x] Code compiles correctly
* [x] Created/updated tests
* [ ] Extended the documentation / Created issue in the https://github.com/dapr/docs/ repo: dapr/docs#_[issue number]_


microsoft-cla[bot]: [![CLA assistant check](https://cla.opensource.microsoft.com/pull/badge/not_signed)](https://cla.opensource.microsoft.com/dapr/components-contrib?pullRequest=1035) <br/>Thank you for your submission, we really appreciate it. Like many open source projects, we ask that you sign our [Contributor License Agreement](https://cla.opensource.microsoft.com/dapr/components-contrib?pullRequest=1035) before we can accept your contribution.<br/><br/>:x: amimimor [sign now](https://cla.opensource.microsoft.com/dapr/components-contrib?pullRequest=1035)<br/><sub>You have signed the CLA already but the status is still pending? Let us [recheck](https://cla.opensource.microsoft.com/check/dapr/components-contrib?pullRequest=1035) it.</sub>
yaron2: /cc @pkedy 
daixiang0: lgtm
amimimor: hi @daixiang0 @pkedy - sorry to bother, but can you trigger the build workflows so that this PR can proceed? I've run gofmt + gofumpt as the previous builds where crashing partly due to the lack of proper formatting (In my "defense" I'd say I didn't see those as required for contribution)
codecov[bot]: # [Codecov](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr) Report
> Merging [#1035](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr) (cb0f2e5) into [master](https://codecov.io/gh/dapr/components-contrib/commit/80f0110fa80e768a7c92873c17217e311a13850c?el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr) (80f0110) will **increase** coverage by `0.26%`.
> The diff coverage is `59.72%`.

[![Impacted file tree graph](https://codecov.io/gh/dapr/components-contrib/pull/1035/graphs/tree.svg?width=650&height=150&src=pr&token=DHERT4KDFA&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr)](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr)

```diff
@@            Coverage Diff             @@
##           master    #1035      +/-   ##
==========================================
+ Coverage   34.03%   34.30%   +0.26%     
==========================================
  Files         133      132       -1     
  Lines       10750    10771      +21     
==========================================
+ Hits         3659     3695      +36     
+ Misses       6710     6690      -20     
- Partials      381      386       +5     
```


| [Impacted Files](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr) | Coverage Δ | |
|---|---|---|
| [bindings/smtp/smtp.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-YmluZGluZ3Mvc210cC9zbXRwLmdv) | `47.69% <0.00%> (ø)` | |
| [state/memcached/memcached.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-c3RhdGUvbWVtY2FjaGVkL21lbWNhY2hlZC5nbw==) | `38.23% <50.00%> (+12.78%)` | :arrow_up: |
| [state/cassandra/cassandra.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-c3RhdGUvY2Fzc2FuZHJhL2Nhc3NhbmRyYS5nbw==) | `25.97% <58.33%> (+2.73%)` | :arrow_up: |
| [pubsub/aws/snssqs/snssqs.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-cHVic3ViL2F3cy9zbnNzcXMvc25zc3FzLmdv) | `28.99% <60.00%> (+3.12%)` | :arrow_up: |
| [state/redis/redis.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-c3RhdGUvcmVkaXMvcmVkaXMuZ28=) | `43.03% <68.00%> (+4.45%)` | :arrow_up: |
| [state/cloudstate/cloudstate\_crdt.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-c3RhdGUvY2xvdWRzdGF0ZS9jbG91ZHN0YXRlX2NyZHQuZ28=) | `9.09% <0.00%> (+0.41%)` | :arrow_up: |

------

[Continue to review full report at Codecov](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr)
> `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=footer&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr). Last update [7df53a1...cb0f2e5](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=lastupdated&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr).

codecov[bot]: # [Codecov](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr) Report
> Merging [#1035](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr) (cb0f2e5) into [master](https://codecov.io/gh/dapr/components-contrib/commit/80f0110fa80e768a7c92873c17217e311a13850c?el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr) (80f0110) will **increase** coverage by `0.26%`.
> The diff coverage is `59.72%`.

> :exclamation: Current head cb0f2e5 differs from pull request most recent head 6913338. Consider uploading reports for the commit 6913338 to get more accurate results
[![Impacted file tree graph](https://codecov.io/gh/dapr/components-contrib/pull/1035/graphs/tree.svg?width=650&height=150&src=pr&token=DHERT4KDFA&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr)](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr)

```diff
@@            Coverage Diff             @@
##           master    #1035      +/-   ##
==========================================
+ Coverage   34.03%   34.30%   +0.26%     
==========================================
  Files         133      132       -1     
  Lines       10750    10771      +21     
==========================================
+ Hits         3659     3695      +36     
+ Misses       6710     6690      -20     
- Partials      381      386       +5     
```


| [Impacted Files](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr) | Coverage Δ | |
|---|---|---|
| [bindings/smtp/smtp.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-YmluZGluZ3Mvc210cC9zbXRwLmdv) | `47.69% <0.00%> (ø)` | |
| [state/memcached/memcached.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-c3RhdGUvbWVtY2FjaGVkL21lbWNhY2hlZC5nbw==) | `38.23% <50.00%> (+12.78%)` | :arrow_up: |
| [state/cassandra/cassandra.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-c3RhdGUvY2Fzc2FuZHJhL2Nhc3NhbmRyYS5nbw==) | `25.97% <58.33%> (+2.73%)` | :arrow_up: |
| [pubsub/aws/snssqs/snssqs.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-cHVic3ViL2F3cy9zbnNzcXMvc25zc3FzLmdv) | `28.99% <60.00%> (+3.12%)` | :arrow_up: |
| [state/redis/redis.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-c3RhdGUvcmVkaXMvcmVkaXMuZ28=) | `43.03% <68.00%> (+4.45%)` | :arrow_up: |
| [state/cloudstate/cloudstate\_crdt.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-c3RhdGUvY2xvdWRzdGF0ZS9jbG91ZHN0YXRlX2NyZHQuZ28=) | `9.09% <0.00%> (+0.41%)` | :arrow_up: |

------

[Continue to review full report at Codecov](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr)
> `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=footer&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr). Last update [4d916c7...6913338](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=lastupdated&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr).

amimimor: due to the passing of time my fork had drifted away from origin/master so I've merged it to be able to proceed with this PR. Awaiting approvers to trigger the build/test workflow
codecov[bot]: # [Codecov](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr) Report
> Merging [#1035](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr) (6913338) into [master](https://codecov.io/gh/dapr/components-contrib/commit/80f0110fa80e768a7c92873c17217e311a13850c?el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr) (80f0110) will **increase** coverage by `0.27%`.
> The diff coverage is `53.08%`.

[![Impacted file tree graph](https://codecov.io/gh/dapr/components-contrib/pull/1035/graphs/tree.svg?width=650&height=150&src=pr&token=DHERT4KDFA&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr)](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr)

```diff
@@            Coverage Diff             @@
##           master    #1035      +/-   ##
==========================================
+ Coverage   34.03%   34.30%   +0.27%     
==========================================
  Files         133      132       -1     
  Lines       10750    10767      +17     
==========================================
+ Hits         3659     3694      +35     
+ Misses       6710     6688      -22     
- Partials      381      385       +4     
```


| [Impacted Files](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr) | Coverage Δ | |
|---|---|---|
| [bindings/smtp/smtp.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-YmluZGluZ3Mvc210cC9zbXRwLmdv) | `47.69% <0.00%> (ø)` | |
| [pubsub/kafka/kafka.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-cHVic3ViL2thZmthL2thZmthLmdv) | `19.27% <0.00%> (+0.45%)` | :arrow_up: |
| [state/memcached/memcached.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-c3RhdGUvbWVtY2FjaGVkL21lbWNhY2hlZC5nbw==) | `38.23% <50.00%> (+12.78%)` | :arrow_up: |
| [state/cassandra/cassandra.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-c3RhdGUvY2Fzc2FuZHJhL2Nhc3NhbmRyYS5nbw==) | `25.97% <58.33%> (+2.73%)` | :arrow_up: |
| [pubsub/aws/snssqs/snssqs.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-cHVic3ViL2F3cy9zbnNzcXMvc25zc3FzLmdv) | `28.99% <60.00%> (+3.12%)` | :arrow_up: |
| [state/redis/redis.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-c3RhdGUvcmVkaXMvcmVkaXMuZ28=) | `43.03% <68.00%> (+4.45%)` | :arrow_up: |

------

[Continue to review full report at Codecov](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr)
> `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=footer&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr). Last update [4d916c7...6913338](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=lastupdated&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr).

amimimor: @artursouza the build is failing because of Conformance Tests / state.redis 
how do we proceed? (it's a dependency downloading issue)
codecov[bot]: # [Codecov](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr) Report
> Merging [#1035](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr) (6913338) into [master](https://codecov.io/gh/dapr/components-contrib/commit/80f0110fa80e768a7c92873c17217e311a13850c?el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr) (80f0110) will **increase** coverage by `0.27%`.
> The diff coverage is `53.08%`.

> :exclamation: Current head 6913338 differs from pull request most recent head b2e13b1. Consider uploading reports for the commit b2e13b1 to get more accurate results
[![Impacted file tree graph](https://codecov.io/gh/dapr/components-contrib/pull/1035/graphs/tree.svg?width=650&height=150&src=pr&token=DHERT4KDFA&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr)](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr)

```diff
@@            Coverage Diff             @@
##           master    #1035      +/-   ##
==========================================
+ Coverage   34.03%   34.30%   +0.27%     
==========================================
  Files         133      132       -1     
  Lines       10750    10767      +17     
==========================================
+ Hits         3659     3694      +35     
+ Misses       6710     6688      -22     
- Partials      381      385       +4     
```


| [Impacted Files](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr) | Coverage Δ | |
|---|---|---|
| [bindings/smtp/smtp.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-YmluZGluZ3Mvc210cC9zbXRwLmdv) | `47.69% <0.00%> (ø)` | |
| [pubsub/kafka/kafka.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-cHVic3ViL2thZmthL2thZmthLmdv) | `19.27% <0.00%> (+0.45%)` | :arrow_up: |
| [state/memcached/memcached.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-c3RhdGUvbWVtY2FjaGVkL21lbWNhY2hlZC5nbw==) | `38.23% <50.00%> (+12.78%)` | :arrow_up: |
| [state/cassandra/cassandra.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-c3RhdGUvY2Fzc2FuZHJhL2Nhc3NhbmRyYS5nbw==) | `25.97% <58.33%> (+2.73%)` | :arrow_up: |
| [pubsub/aws/snssqs/snssqs.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-cHVic3ViL2F3cy9zbnNzcXMvc25zc3FzLmdv) | `28.99% <60.00%> (+3.12%)` | :arrow_up: |
| [state/redis/redis.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-c3RhdGUvcmVkaXMvcmVkaXMuZ28=) | `43.03% <68.00%> (+4.45%)` | :arrow_up: |

------

[Continue to review full report at Codecov](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr)
> `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=footer&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr). Last update [be88343...b2e13b1](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=lastupdated&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr).

codecov[bot]: # [Codecov](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr) Report
> Merging [#1035](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr) (6913338) into [master](https://codecov.io/gh/dapr/components-contrib/commit/80f0110fa80e768a7c92873c17217e311a13850c?el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr) (80f0110) will **increase** coverage by `0.27%`.
> The diff coverage is `53.08%`.

> :exclamation: Current head 6913338 differs from pull request most recent head ba8bd26. Consider uploading reports for the commit ba8bd26 to get more accurate results
[![Impacted file tree graph](https://codecov.io/gh/dapr/components-contrib/pull/1035/graphs/tree.svg?width=650&height=150&src=pr&token=DHERT4KDFA&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr)](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr)

```diff
@@            Coverage Diff             @@
##           master    #1035      +/-   ##
==========================================
+ Coverage   34.03%   34.30%   +0.27%     
==========================================
  Files         133      132       -1     
  Lines       10750    10767      +17     
==========================================
+ Hits         3659     3694      +35     
+ Misses       6710     6688      -22     
- Partials      381      385       +4     
```


| [Impacted Files](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr) | Coverage Δ | |
|---|---|---|
| [bindings/smtp/smtp.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-YmluZGluZ3Mvc210cC9zbXRwLmdv) | `47.69% <0.00%> (ø)` | |
| [pubsub/kafka/kafka.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-cHVic3ViL2thZmthL2thZmthLmdv) | `19.27% <0.00%> (+0.45%)` | :arrow_up: |
| [state/memcached/memcached.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-c3RhdGUvbWVtY2FjaGVkL21lbWNhY2hlZC5nbw==) | `38.23% <50.00%> (+12.78%)` | :arrow_up: |
| [state/cassandra/cassandra.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-c3RhdGUvY2Fzc2FuZHJhL2Nhc3NhbmRyYS5nbw==) | `25.97% <58.33%> (+2.73%)` | :arrow_up: |
| [pubsub/aws/snssqs/snssqs.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-cHVic3ViL2F3cy9zbnNzcXMvc25zc3FzLmdv) | `28.99% <60.00%> (+3.12%)` | :arrow_up: |
| [state/redis/redis.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-c3RhdGUvcmVkaXMvcmVkaXMuZ28=) | `43.03% <68.00%> (+4.45%)` | :arrow_up: |

------

[Continue to review full report at Codecov](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr)
> `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=footer&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr). Last update [7496adf...ba8bd26](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=lastupdated&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr).

codecov[bot]: # [Codecov](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr) Report
> Merging [#1035](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr) (6913338) into [master](https://codecov.io/gh/dapr/components-contrib/commit/80f0110fa80e768a7c92873c17217e311a13850c?el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr) (80f0110) will **increase** coverage by `0.27%`.
> The diff coverage is `53.08%`.

> :exclamation: Current head 6913338 differs from pull request most recent head 3660b5b. Consider uploading reports for the commit 3660b5b to get more accurate results
[![Impacted file tree graph](https://codecov.io/gh/dapr/components-contrib/pull/1035/graphs/tree.svg?width=650&height=150&src=pr&token=DHERT4KDFA&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr)](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr)

```diff
@@            Coverage Diff             @@
##           master    #1035      +/-   ##
==========================================
+ Coverage   34.03%   34.30%   +0.27%     
==========================================
  Files         133      132       -1     
  Lines       10750    10767      +17     
==========================================
+ Hits         3659     3694      +35     
+ Misses       6710     6688      -22     
- Partials      381      385       +4     
```


| [Impacted Files](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr) | Coverage Δ | |
|---|---|---|
| [bindings/smtp/smtp.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-YmluZGluZ3Mvc210cC9zbXRwLmdv) | `47.69% <0.00%> (ø)` | |
| [pubsub/kafka/kafka.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-cHVic3ViL2thZmthL2thZmthLmdv) | `19.27% <0.00%> (+0.45%)` | :arrow_up: |
| [state/memcached/memcached.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-c3RhdGUvbWVtY2FjaGVkL21lbWNhY2hlZC5nbw==) | `38.23% <50.00%> (+12.78%)` | :arrow_up: |
| [state/cassandra/cassandra.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-c3RhdGUvY2Fzc2FuZHJhL2Nhc3NhbmRyYS5nbw==) | `25.97% <58.33%> (+2.73%)` | :arrow_up: |
| [pubsub/aws/snssqs/snssqs.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-cHVic3ViL2F3cy9zbnNzcXMvc25zc3FzLmdv) | `28.99% <60.00%> (+3.12%)` | :arrow_up: |
| [state/redis/redis.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-c3RhdGUvcmVkaXMvcmVkaXMuZ28=) | `43.03% <68.00%> (+4.45%)` | :arrow_up: |

------

[Continue to review full report at Codecov](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr)
> `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=footer&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr). Last update [b73d817...3660b5b](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=lastupdated&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr).

yaron2: > hi @daixiang0 @pkedy @artursouza
> I'd like to proceed with this PR but the build fails on other sub projects which I haven't changed, please advise
> I'll be thankful if you could trigger another build and follow up on its results (as I'm suspecting it would fail)
> Thanks

Sorry for the late response. running now.
codecov[bot]: # [Codecov](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr) Report
> Merging [#1035](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr) (ba8bd26) into [master](https://codecov.io/gh/dapr/components-contrib/commit/80f0110fa80e768a7c92873c17217e311a13850c?el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr) (80f0110) will **increase** coverage by `0.20%`.
> The diff coverage is `39.65%`.

> :exclamation: Current head ba8bd26 differs from pull request most recent head 3660b5b. Consider uploading reports for the commit 3660b5b to get more accurate results
[![Impacted file tree graph](https://codecov.io/gh/dapr/components-contrib/pull/1035/graphs/tree.svg?width=650&height=150&src=pr&token=DHERT4KDFA&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr)](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr)

```diff
@@            Coverage Diff             @@
##           master    #1035      +/-   ##
==========================================
+ Coverage   34.03%   34.23%   +0.20%     
==========================================
  Files         133      132       -1     
  Lines       10750    10792      +42     
==========================================
+ Hits         3659     3695      +36     
- Misses       6710     6711       +1     
- Partials      381      386       +5     
```


| [Impacted Files](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr) | Coverage Δ | |
|---|---|---|
| [bindings/smtp/smtp.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-YmluZGluZ3Mvc210cC9zbXRwLmdv) | `47.69% <0.00%> (ø)` | |
| [pubsub/azure/eventhubs/eventhubs.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-cHVic3ViL2F6dXJlL2V2ZW50aHVicy9ldmVudGh1YnMuZ28=) | `23.91% <0.00%> (-4.30%)` | :arrow_down: |
| [pubsub/kafka/kafka.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-cHVic3ViL2thZmthL2thZmthLmdv) | `19.27% <0.00%> (+0.45%)` | :arrow_up: |
| [state/mongodb/mongodb.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-c3RhdGUvbW9uZ29kYi9tb25nb2RiLmdv) | `16.76% <0.00%> (-0.20%)` | :arrow_down: |
| [tests/conformance/common.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-dGVzdHMvY29uZm9ybWFuY2UvY29tbW9uLmdv) | `14.93% <0.00%> (-0.42%)` | :arrow_down: |
| [state/memcached/memcached.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-c3RhdGUvbWVtY2FjaGVkL21lbWNhY2hlZC5nbw==) | `38.23% <50.00%> (+12.78%)` | :arrow_up: |
| [state/cassandra/cassandra.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-c3RhdGUvY2Fzc2FuZHJhL2Nhc3NhbmRyYS5nbw==) | `25.97% <58.33%> (+2.73%)` | :arrow_up: |
| [pubsub/aws/snssqs/snssqs.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-cHVic3ViL2F3cy9zbnNzcXMvc25zc3FzLmdv) | `28.99% <60.00%> (+3.12%)` | :arrow_up: |
| [state/redis/redis.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-c3RhdGUvcmVkaXMvcmVkaXMuZ28=) | `42.85% <66.66%> (+4.28%)` | :arrow_up: |

------

[Continue to review full report at Codecov](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr)
> `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=footer&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr). Last update [b73d817...3660b5b](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=lastupdated&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr).

codecov[bot]: # [Codecov](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr) Report
> Merging [#1035](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr) (3660b5b) into [master](https://codecov.io/gh/dapr/components-contrib/commit/80f0110fa80e768a7c92873c17217e311a13850c?el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr) (80f0110) will **increase** coverage by `0.49%`.
> The diff coverage is `51.13%`.

[![Impacted file tree graph](https://codecov.io/gh/dapr/components-contrib/pull/1035/graphs/tree.svg?width=650&height=150&src=pr&token=DHERT4KDFA&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr)](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr)

```diff
@@            Coverage Diff             @@
##           master    #1035      +/-   ##
==========================================
+ Coverage   34.03%   34.53%   +0.49%     
==========================================
  Files         133      132       -1     
  Lines       10750    10870     +120     
==========================================
+ Hits         3659     3754      +95     
- Misses       6710     6736      +26     
+ Partials      381      380       -1     
```


| [Impacted Files](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr) | Coverage Δ | |
|---|---|---|
| [pubsub/azure/eventhubs/eventhubs.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-cHVic3ViL2F6dXJlL2V2ZW50aHVicy9ldmVudGh1YnMuZ28=) | `23.91% <0.00%> (-4.30%)` | :arrow_down: |
| [pubsub/azure/servicebus/servicebus.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-cHVic3ViL2F6dXJlL3NlcnZpY2VidXMvc2VydmljZWJ1cy5nbw==) | `30.49% <0.00%> (-0.62%)` | :arrow_down: |
| [pubsub/azure/servicebus/subscription.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-cHVic3ViL2F6dXJlL3NlcnZpY2VidXMvc3Vic2NyaXB0aW9uLmdv) | `0.00% <0.00%> (ø)` | |
| [pubsub/kafka/kafka.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-cHVic3ViL2thZmthL2thZmthLmdv) | `19.27% <0.00%> (+0.45%)` | :arrow_up: |
| [state/mongodb/mongodb.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-c3RhdGUvbW9uZ29kYi9tb25nb2RiLmdv) | `16.76% <0.00%> (-0.20%)` | :arrow_down: |
| [state/sqlserver/migration.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-c3RhdGUvc3Fsc2VydmVyL21pZ3JhdGlvbi5nbw==) | `0.00% <0.00%> (ø)` | |
| [tests/conformance/common.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-dGVzdHMvY29uZm9ybWFuY2UvY29tbW9uLmdv) | `14.93% <0.00%> (-0.42%)` | :arrow_down: |
| [state/memcached/memcached.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-c3RhdGUvbWVtY2FjaGVkL21lbWNhY2hlZC5nbw==) | `38.23% <50.00%> (+12.78%)` | :arrow_up: |
| [state/cassandra/cassandra.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-c3RhdGUvY2Fzc2FuZHJhL2Nhc3NhbmRyYS5nbw==) | `25.97% <58.33%> (+2.73%)` | :arrow_up: |
| [pubsub/aws/snssqs/snssqs.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-cHVic3ViL2F3cy9zbnNzcXMvc25zc3FzLmdv) | `28.99% <60.00%> (+3.12%)` | :arrow_up: |
| ... and [5 more](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree-more&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr) | |

------

[Continue to review full report at Codecov](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr)
> `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=footer&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr). Last update [b73d817...3660b5b](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=lastupdated&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr).

yaron2: @amimimor were you able to test the component to make sure there are no regressions?
amimimor: Yes. I tested it several times and it’s now on our staging environment

On Fri, 6 Aug 2021 at 23:53 Yaron Schneider ***@***.***>
wrote:

> @amimimor <https://github.com/amimimor> were you able to test the
> component to make sure there are no regressions?
>
> —
> You are receiving this because you were mentioned.
>
>
> Reply to this email directly, view it on GitHub
> <https://github.com/dapr/components-contrib/pull/1035#issuecomment-894512915>,
> or unsubscribe
> <https://github.com/notifications/unsubscribe-auth/AAHL4SRQUU4K4H2KKNPK25DT3RDWNANCNFSM5A5OYIGQ>
> .
>
-- 
All the best,
Amit Mor

codecov[bot]: # [Codecov](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr) Report
> Merging [#1035](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr) (3660b5b) into [master](https://codecov.io/gh/dapr/components-contrib/commit/80f0110fa80e768a7c92873c17217e311a13850c?el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr) (80f0110) will **increase** coverage by `0.49%`.
> The diff coverage is `51.13%`.

> :exclamation: Current head 3660b5b differs from pull request most recent head d9d2316. Consider uploading reports for the commit d9d2316 to get more accurate results
[![Impacted file tree graph](https://codecov.io/gh/dapr/components-contrib/pull/1035/graphs/tree.svg?width=650&height=150&src=pr&token=DHERT4KDFA&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr)](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr)

```diff
@@            Coverage Diff             @@
##           master    #1035      +/-   ##
==========================================
+ Coverage   34.03%   34.53%   +0.49%     
==========================================
  Files         133      132       -1     
  Lines       10750    10870     +120     
==========================================
+ Hits         3659     3754      +95     
- Misses       6710     6736      +26     
+ Partials      381      380       -1     
```


| [Impacted Files](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr) | Coverage Δ | |
|---|---|---|
| [pubsub/azure/eventhubs/eventhubs.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-cHVic3ViL2F6dXJlL2V2ZW50aHVicy9ldmVudGh1YnMuZ28=) | `23.91% <0.00%> (-4.30%)` | :arrow_down: |
| [pubsub/azure/servicebus/servicebus.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-cHVic3ViL2F6dXJlL3NlcnZpY2VidXMvc2VydmljZWJ1cy5nbw==) | `30.49% <0.00%> (-0.62%)` | :arrow_down: |
| [pubsub/azure/servicebus/subscription.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-cHVic3ViL2F6dXJlL3NlcnZpY2VidXMvc3Vic2NyaXB0aW9uLmdv) | `0.00% <0.00%> (ø)` | |
| [pubsub/kafka/kafka.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-cHVic3ViL2thZmthL2thZmthLmdv) | `19.27% <0.00%> (+0.45%)` | :arrow_up: |
| [state/mongodb/mongodb.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-c3RhdGUvbW9uZ29kYi9tb25nb2RiLmdv) | `16.76% <0.00%> (-0.20%)` | :arrow_down: |
| [state/sqlserver/migration.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-c3RhdGUvc3Fsc2VydmVyL21pZ3JhdGlvbi5nbw==) | `0.00% <0.00%> (ø)` | |
| [tests/conformance/common.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-dGVzdHMvY29uZm9ybWFuY2UvY29tbW9uLmdv) | `14.93% <0.00%> (-0.42%)` | :arrow_down: |
| [state/memcached/memcached.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-c3RhdGUvbWVtY2FjaGVkL21lbWNhY2hlZC5nbw==) | `38.23% <50.00%> (+12.78%)` | :arrow_up: |
| [state/cassandra/cassandra.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-c3RhdGUvY2Fzc2FuZHJhL2Nhc3NhbmRyYS5nbw==) | `25.97% <58.33%> (+2.73%)` | :arrow_up: |
| [pubsub/aws/snssqs/snssqs.go](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-cHVic3ViL2F3cy9zbnNzcXMvc25zc3FzLmdv) | `28.99% <60.00%> (+3.12%)` | :arrow_up: |
| ... and [5 more](https://codecov.io/gh/dapr/components-contrib/pull/1035/diff?src=pr&el=tree-more&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr) | |

------

[Continue to review full report at Codecov](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr)
> `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=footer&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr). Last update [38de305...d9d2316](https://codecov.io/gh/dapr/components-contrib/pull/1035?src=pr&el=lastupdated&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr).


Patch:
diff --git a/pubsub/aws/snssqs/snssqs.go b/pubsub/aws/snssqs/snssqs.go
index 79892dcb..1c8a7a33 100644
--- a/pubsub/aws/snssqs/snssqs.go
+++ b/pubsub/aws/snssqs/snssqs.go
@@ -2,7 +2,6 @@ package snssqs
 
 import (
 	"context"
-	"crypto/sha256"
 	"encoding/json"
 	"errors"
 	"fmt"
@@ -20,8 +19,8 @@ import (
 type snsSqs struct {
 	// key is the topic name, value is the ARN of the topic
 	topics map[string]string
-	// key is the hashed topic name, value is the actual topic name
-	topicHash map[string]string
+	// key is the sanitized topic name, value is the actual topic name
+	topicSanitized map[string]string
 	// key is the topic name, value holds the ARN of the queue and its url
 	queues        map[string]*sqsQueueInfo
 	snsClient     *sns.SNS
@@ -93,13 +92,28 @@ func parseInt64(input string, propertyName string) (int64, error) {
 	return int64(number), nil
 }
 
-// take a name and hash it for compatibility with AWS resource names
-// the output is fixed at 64 characters
-func nameToHash(name string) string {
-	h := sha256.New()
-	h.Write([]byte(name))
+// sanitize topic/queue name to conform with:
+// https://docs.aws.amazon.com/AWSSimpleQueueService/latest/SQSDeveloperGuide/quotas-queues.html
+func nameToAWSSanitizedName(name string) string {
+	s := []byte(name)
+
+	j := 0
+	for _, b := range s {
+		if ('a' <= b && b <= 'z') ||
+			('A' <= b && b <= 'Z') ||
+			('0' <= b && b <= '9') ||
+			(b == '-') ||
+			(b == '_') {
+			s[j] = b
+			j++
+
+			if j == 80 {
+				break
+			}
+		}
+	}
 
-	return fmt.Sprintf("%x", h.Sum(nil))
+	return string(s[:j])
 }
 
 func (s *snsSqs) getSnsSqsMetatdata(metadata pubsub.Metadata) (*snsSqsMetadata, error) {
@@ -207,7 +221,7 @@ func (s *snsSqs) Init(metadata pubsub.Metadata) error {
 	// both Publish and Subscribe need reference the topic ARN
 	// track these ARNs in this map
 	s.topics = make(map[string]string)
-	s.topicHash = make(map[string]string)
+	s.topicSanitized = make(map[string]string)
 	s.queues = make(map[string]*sqsQueueInfo)
 	sess, err := aws_auth.GetClient(md.AccessKey, md.SecretKey, md.SessionToken, md.Region, md.Endpoint)
 	if err != nil {
@@ -220,16 +234,16 @@ func (s *snsSqs) Init(metadata pubsub.Metadata) error {
 }
 
 func (s *snsSqs) createTopic(topic string) (string, string, error) {
-	hashedName := nameToHash(topic)
+	sanitizedName := nameToAWSSanitizedName(topic)
 	createTopicResponse, err := s.snsClient.CreateTopic(&sns.CreateTopicInput{
-		Name: aws.String(hashedName),
+		Name: aws.String(sanitizedName),
 		Tags: []*sns.Tag{{Key: aws.String(awsSnsTopicNameKey), Value: aws.String(topic)}},
 	})
 	if err != nil {
 		return "", "", err
 	}
 
-	return *(createTopicResponse.TopicArn), hashedName, nil
+	return *(createTopicResponse.TopicArn), sanitizedName, nil
 }
 
 // get the topic ARN from the topics map. If it doesn't exist in the map, try to fetch it from AWS, if it doesn't exist
@@ -245,7 +259,7 @@ func (s *snsSqs) getOrCreateTopic(topic string) (string, error) {
 
 	s.logger.Debugf("No topic ARN found for %s\n Creating topic instead.", topic)
 
-	topicArn, hashedName, err := s.createTopic(topic)
+	topicArn, sanitizedName, err := s.createTopic(topic)
 	if err != nil {
 		s.logger.Errorf("error creating new topic %s: %v", topic, err)
 
@@ -254,14 +268,14 @@ func (s *snsSqs) getOrCreateTopic(topic string) (string, error) {
 
 	// record topic ARN
 	s.topics[topic] = topicArn
-	s.topicHash[hashedName] = topic
+	s.topicSanitized[sanitizedName] = topic
 
 	return topicArn, nil
 }
 
 func (s *snsSqs) createQueue(queueName string) (*sqsQueueInfo, error) {
 	createQueueResponse, err := s.sqsClient.CreateQueue(&sqs.CreateQueueInput{
-		QueueName: aws.String(nameToHash(queueName)),
+		QueueName: aws.String(nameToAWSSanitizedName(queueName)),
 		Tags:      map[string]*string{awsSqsQueueNameKey: aws.String(queueName)},
 	})
 	if err != nil {
@@ -397,7 +411,7 @@ func (s *snsSqs) handleMessage(message *sqs.Message, queueInfo *sqsQueueInfo, ha
 	}
 
 	topic := parseTopicArn(messageBody.TopicArn)
-	topic = s.topicHash[topic]
+	topic = s.topicSanitized[topic]
 	err = handler(context.Background(), &pubsub.NewMessage{
 		Data:  []byte(messageBody.Message),
 		Topic: topic,
@@ -491,12 +505,6 @@ func (s *snsSqs) Subscribe(req pubsub.SubscribeRequest, handler pubsub.Handler)
 }
 
 func (s *snsSqs) Close() error {
-	for _, sub := range s.subscriptions {
-		s.snsClient.Unsubscribe(&sns.UnsubscribeInput{
-			SubscriptionArn: sub,
-		})
-	}
-
 	return nil
 }
 


Test patch:
diff --git a/pubsub/aws/snssqs/snssqs_test.go b/pubsub/aws/snssqs/snssqs_test.go
index 3979df40..835100bc 100644
--- a/pubsub/aws/snssqs/snssqs_test.go
+++ b/pubsub/aws/snssqs/snssqs_test.go
@@ -1,8 +1,6 @@
 package snssqs
 
 import (
-	"fmt"
-	"strings"
 	"testing"
 
 	"github.com/dapr/components-contrib/pubsub"
@@ -236,22 +234,13 @@ func Test_parseInt64(t *testing.T) {
 	r.Error(err)
 }
 
-func Test_nameToHash(t *testing.T) {
+func Test_replaceNameToAWSSanitizedName(t *testing.T) {
 	r := require.New(t)
 
-	// This string is too long and contains invalid character for either an SQS queue or an SNS topic
-	hashedName := nameToHash(`
-		Some invalid name // for an AWS resource &*()*&&^Some invalid name // for an AWS resource &*()*&&^Some invalid 
+	s := `Some_invalid-name // for an AWS resource &*()*&&^Some invalid name // for an AWS resource &*()*&&^Some invalid 
 		name // for an AWS resource &*()*&&^Some invalid name // for an AWS resource &*()*&&^Some invalid name // for an
-		AWS resource &*()*&&^Some invalid name // for an AWS resource &*()*&&^
-	`)
-
-	r.Equal(64, len(hashedName))
-	// Output is only expected to contain lower case characters representing valid hexadecimal numerals
-	for _, c := range hashedName {
-		r.True(
-			strings.ContainsAny(
-				"abcdef0123456789", string(c)),
-			fmt.Sprintf("Invalid character %s in hashed name", string(c)))
-	}
+		AWS resource &*()*&&^Some invalid name // for an AWS resource &*()*&&^`
+	v := nameToAWSSanitizedName(s)
+	r.Equal(80, len(v))
+	r.Equal("Some_invalid-nameforanAWSresourceSomeinvalidnameforanAWSresourceSomeinvalidnamef", v)
 }