Repository: edgexfoundry/device-sdk-go
Pull request #1399 (2023-03-22 01:55:56)

fix!: Modify the numeric data type in Value Properties to pointer
BREAKING CHANGE:
- update mask,shift,base,scale,offset to pointer
- update maximum and minimum data type from string to float64 pointer

related to https://github.com/edgexfoundry/go-mod-core-contracts/pull/823

<!-- Expected Commit Message Description (imported automatically by GitHub) -->
<!-- Must conform to [conventional commits guidelines](https://github.com/edgexfoundry/device-sdk-go/blob/main/.github/Contributing.md) -->
<!-- Expected Commit message must contain Closes/Fixes #IssueNumber statement when there is a related issue -->

<!-- Add additional detailed description of need for change if no related issue -->

**If your build fails** due to your commit message not passing the build checks, please review the guidelines here: https://github.com/edgexfoundry/device-sdk-go/blob/main/.github/Contributing.md

## PR Checklist
Please check if your PR fulfills the following requirements:

- [ ] I am not introducing a breaking change (if you are, flag in conventional commit message with `BREAKING CHANGE:` describing the break)
- [x] I am not introducing a new dependency (add notes below if you are)
- [ ] I have added unit tests for the new feature or bug fix (if not, why?) updated
- [ ] I have fully tested (add details below) this the new feature or bug fix (if not, why?)
- [x] I have opened a PR for the related docs change (if not, why?)
https://github.com/edgexfoundry/edgex-docs/pull/989

## Testing Instructions
<!-- How can the reviewers test your change? -->

## New Dependency Instructions (If applicable)
<!-- Please follow [vetting instructions](https://wiki.edgexfoundry.org/display/FA/Vetting+Process+for+3rd+Party+Dependencies) and place results here -->

codecov-commenter: ## [Codecov](https://codecov.io/gh/edgexfoundry/device-sdk-go/pull/1399?src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=edgexfoundry) Report
> Merging [#1399](https://codecov.io/gh/edgexfoundry/device-sdk-go/pull/1399?src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=edgexfoundry) (70e7d19) into [main](https://codecov.io/gh/edgexfoundry/device-sdk-go/commit/c61610bbbff1187c8ac68f5c7e0a10add7b75ddb?el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=edgexfoundry) (c61610b) will **increase** coverage by `0.72%`.
> The diff coverage is `52.38%`.

> :exclamation: Current head 70e7d19 differs from pull request most recent head eddc5e6. Consider uploading reports for the commit eddc5e6 to get more accurate results

:mega: This organization is not using Codecov’s [GitHub App Integration](https://github.com/apps/codecov). We recommend you install it so Codecov can continue to function properly for your repositories. [Learn more](https://about.codecov.io/blog/codecov-is-updating-its-github-integration/?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=edgexfoundry)

```diff
@@            Coverage Diff             @@
##             main    #1399      +/-   ##
==========================================
+ Coverage   47.74%   48.46%   +0.72%     
==========================================
  Files          27       27              
  Lines        2593     2513      -80     
==========================================
- Hits         1238     1218      -20     
+ Misses       1253     1213      -40     
+ Partials      102       82      -20     
```


| [Impacted Files](https://codecov.io/gh/edgexfoundry/device-sdk-go/pull/1399?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=edgexfoundry) | Coverage Δ | |
|---|---|---|
| [internal/transformer/transformresult.go](https://codecov.io/gh/edgexfoundry/device-sdk-go/pull/1399?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=edgexfoundry#diff-aW50ZXJuYWwvdHJhbnNmb3JtZXIvdHJhbnNmb3JtcmVzdWx0Lmdv) | `66.03% <0.00%> (ø)` | |
| [internal/transformer/transformparam.go](https://codecov.io/gh/edgexfoundry/device-sdk-go/pull/1399?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=edgexfoundry#diff-aW50ZXJuYWwvdHJhbnNmb3JtZXIvdHJhbnNmb3JtcGFyYW0uZ28=) | `74.13% <68.75%> (+20.05%)` | :arrow_up: |

Help us with your feedback. Take ten seconds to tell us [how you rate us](https://about.codecov.io/nps?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=edgexfoundry). Have a feature suggestion? [Share it here.](https://app.codecov.io/gh/feedback/?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=edgexfoundry)


Patch:
diff --git a/go.mod b/go.mod
index 629a6525..c847e16c 100644
--- a/go.mod
+++ b/go.mod
@@ -5,7 +5,7 @@ go 1.20
 require (
 	github.com/OneOfOne/xxhash v1.2.8
 	github.com/edgexfoundry/go-mod-bootstrap/v3 v3.0.0-dev.54
-	github.com/edgexfoundry/go-mod-core-contracts/v3 v3.0.0-dev.30
+	github.com/edgexfoundry/go-mod-core-contracts/v3 v3.0.0-dev.32
 	github.com/edgexfoundry/go-mod-messaging/v3 v3.0.0-dev.18
 	github.com/google/uuid v1.3.0
 	github.com/gorilla/mux v1.8.0
@@ -29,7 +29,7 @@ require (
 	github.com/go-logfmt/logfmt v0.5.1 // indirect
 	github.com/go-playground/locales v0.14.1 // indirect
 	github.com/go-playground/universal-translator v0.18.1 // indirect
-	github.com/go-playground/validator/v10 v10.11.2 // indirect
+	github.com/go-playground/validator/v10 v10.12.0 // indirect
 	github.com/go-redis/redis/v7 v7.3.0 // indirect
 	github.com/golang/protobuf v1.5.2 // indirect
 	github.com/gorilla/websocket v1.4.2 // indirect
@@ -42,7 +42,7 @@ require (
 	github.com/hashicorp/go-rootcerts v1.0.2 // indirect
 	github.com/hashicorp/golang-lru v0.5.4 // indirect
 	github.com/hashicorp/serf v0.10.1 // indirect
-	github.com/leodido/go-urn v1.2.1 // indirect
+	github.com/leodido/go-urn v1.2.2 // indirect
 	github.com/mattn/go-colorable v0.1.12 // indirect
 	github.com/mattn/go-isatty v0.0.14 // indirect
 	github.com/mitchellh/consulstructure v0.0.0-20190329231841-56fdc4d2da54 // indirect
@@ -59,13 +59,13 @@ require (
 	github.com/stretchr/objx v0.5.0 // indirect
 	github.com/x448/float16 v0.8.4 // indirect
 	github.com/zeebo/errs v1.3.0 // indirect
-	golang.org/x/crypto v0.6.0 // indirect
-	golang.org/x/mod v0.7.0 // indirect
-	golang.org/x/net v0.7.0 // indirect
+	golang.org/x/crypto v0.7.0 // indirect
+	golang.org/x/mod v0.8.0 // indirect
+	golang.org/x/net v0.8.0 // indirect
 	golang.org/x/sync v0.1.0 // indirect
-	golang.org/x/sys v0.5.0 // indirect
-	golang.org/x/text v0.7.0 // indirect
-	golang.org/x/tools v0.5.0 // indirect
+	golang.org/x/sys v0.6.0 // indirect
+	golang.org/x/text v0.8.0 // indirect
+	golang.org/x/tools v0.6.0 // indirect
 	google.golang.org/genproto v0.0.0-20230109162033-3c3c17ce83e6 // indirect
 	google.golang.org/grpc v1.51.0 // indirect
 	google.golang.org/protobuf v1.28.1 // indirect
diff --git a/go.sum b/go.sum
index fb3c4161..0eec0dad 100644
--- a/go.sum
+++ b/go.sum
@@ -31,8 +31,8 @@ github.com/edgexfoundry/go-mod-bootstrap/v3 v3.0.0-dev.54 h1:zbM6LjlXgnvZ1d1WZUi
 github.com/edgexfoundry/go-mod-bootstrap/v3 v3.0.0-dev.54/go.mod h1:aKaljiCzEaRb+QO/LP7gyRSrhXs1YVsh02kagZlmi80=
 github.com/edgexfoundry/go-mod-configuration/v3 v3.0.0-dev.9 h1:DznnG2F4E+9jHAA+iXsaDaQxYJ+oWS3SddvvdEfQayE=
 github.com/edgexfoundry/go-mod-configuration/v3 v3.0.0-dev.9/go.mod h1:ljWfa029h+677rS+khaXWR+8Hv8965UfbMjaxZ4C9QI=
-github.com/edgexfoundry/go-mod-core-contracts/v3 v3.0.0-dev.30 h1:diarfNbfUeSYD7Hq8pOqHzxMtIbaPO6W8nWq34W8X6g=
-github.com/edgexfoundry/go-mod-core-contracts/v3 v3.0.0-dev.30/go.mod h1:SYoD+tmUP/zwWuuIySmsQSjPx6MHP+2w9FsLgm0IR7A=
+github.com/edgexfoundry/go-mod-core-contracts/v3 v3.0.0-dev.32 h1:f3ciHdQorXqLdBI1V2UF4mGQwFdXoBuELWUU6Nw1xTQ=
+github.com/edgexfoundry/go-mod-core-contracts/v3 v3.0.0-dev.32/go.mod h1:1YS2J5NfPCd7TYBk0alu+RR5EBzBb+bnG0KF1qNRQYY=
 github.com/edgexfoundry/go-mod-messaging/v3 v3.0.0-dev.18 h1:8empqTOIVhKzebC3gnP9C0LGQvwXtHLJF8x8AqlTGLM=
 github.com/edgexfoundry/go-mod-messaging/v3 v3.0.0-dev.18/go.mod h1:Sf7lvKtICWRy0Tmvw+bV6L1wdXKRaTSmKmJKw4Caxe4=
 github.com/edgexfoundry/go-mod-registry/v3 v3.0.0-dev.7 h1:sje0agoLi8ayEFxGO3xtN7P/IXwjZUUxpC8G2fCTu44=
@@ -58,8 +58,8 @@ github.com/go-playground/locales v0.14.1 h1:EWaQ/wswjilfKLTECiXz7Rh+3BjFhfDFKv/o
 github.com/go-playground/locales v0.14.1/go.mod h1:hxrqLVvrK65+Rwrd5Fc6F2O76J/NuW9t0sjnWqG1slY=
 github.com/go-playground/universal-translator v0.18.1 h1:Bcnm0ZwsGyWbCzImXv+pAJnYK9S473LQFuzCbDbfSFY=
 github.com/go-playground/universal-translator v0.18.1/go.mod h1:xekY+UJKNuX9WP91TpwSH2VMlDf28Uj24BCp08ZFTUY=
-github.com/go-playground/validator/v10 v10.11.2 h1:q3SHpufmypg+erIExEKUmsgmhDTyhcJ38oeKGACXohU=
-github.com/go-playground/validator/v10 v10.11.2/go.mod h1:NieE624vt4SCTJtD87arVLvdmjPAeV8BQlHtMnw9D7s=
+github.com/go-playground/validator/v10 v10.12.0 h1:E4gtWgxWxp8YSxExrQFv5BpCahla0PVF2oTTEYaWQGI=
+github.com/go-playground/validator/v10 v10.12.0/go.mod h1:hCAPuzYvKdP33pxWa+2+6AIKXEKqjIUyqsNCtbsSJrA=
 github.com/go-redis/redis/v7 v7.3.0 h1:3oHqd0W7f/VLKBxeYTEpqdMUsmMectngjM9OtoRoIgg=
 github.com/go-redis/redis/v7 v7.3.0/go.mod h1:JDNMw23GTyLNC4GZu9njt15ctBQVn7xjRfnwdHj/Dcg=
 github.com/go-stack/stack v1.8.0/go.mod h1:v0f6uXyyMGvRgIKkXu+yp6POWl0qKG85gN/melR3HDY=
@@ -130,12 +130,12 @@ github.com/klauspost/compress v1.16.0 h1:iULayQNOReoYUe+1qtKOqw9CwJv3aNQu8ivo7lw
 github.com/konsorten/go-windows-terminal-sequences v1.0.1/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ=
 github.com/kr/logfmt v0.0.0-20140226030751-b84e30acd515/go.mod h1:+0opPa2QZZtGFBFZlji/RkVcI2GknAs/DXo4wKdlNEc=
 github.com/kr/pretty v0.1.0/go.mod h1:dAy3ld7l9f0ibDNOQOHHMYYIIbhfbHSm3C4ZsoJORNo=
-github.com/kr/pretty v0.3.0 h1:WgNl7dwNpEZ6jJ9k1snq4pZsg7DOEN8hP9Xw0Tsjwk0=
+github.com/kr/pretty v0.2.1 h1:Fmg33tUaq4/8ym9TJN1x7sLJnHVwhP33CNkpYV/7rwI=
 github.com/kr/pty v1.1.1/go.mod h1:pFQYn66WHrOpPYNljwOMqo10TkYh1fy3cYio2l3bCsQ=
 github.com/kr/text v0.1.0/go.mod h1:4Jbv+DJW3UT/LiOwJeYQe1efqtUx/iVham/4vfdArNI=
 github.com/kr/text v0.2.0 h1:5Nx0Ya0ZqY2ygV366QzturHI13Jq95ApcVaJBhpS+AY=
-github.com/leodido/go-urn v1.2.1 h1:BqpAaACuzVSgi/VLzGZIobT2z4v53pjosyNd9Yv6n/w=
-github.com/leodido/go-urn v1.2.1/go.mod h1:zt4jvISO2HfUBqxjfIshjdMTYS56ZS/qv49ictyFfxY=
+github.com/leodido/go-urn v1.2.2 h1:7z68G0FCGvDk646jz1AelTYNYWrTNm0bEcFAo147wt4=
+github.com/leodido/go-urn v1.2.2/go.mod h1:kUaIbLZWttglzwNuG0pgsh5vuV6u2YcGBYz1hIPjtOQ=
 github.com/mattn/go-colorable v0.0.9/go.mod h1:9vuHe8Xs5qXnSaW/c/ABM9alt+Vo+STaOChaDxuIBZU=
 github.com/mattn/go-colorable v0.1.4/go.mod h1:U0ppj6V5qS13XJ6of8GYAs25YV2eR4EVcfRqFIhoBtE=
 github.com/mattn/go-colorable v0.1.6/go.mod h1:u6P/XSegPjTcexA+o6vUJrdnUu04hMope9wVRipJSqc=
@@ -208,7 +208,7 @@ github.com/prometheus/procfs v0.0.2/go.mod h1:TjEm7ze935MbeOT/UhFTIMYKhuLP4wbCsT
 github.com/prometheus/procfs v0.0.8/go.mod h1:7Qr8sr6344vo1JqZ6HhLceV9o3AJ1Ff+GxbHq6oeK9A=
 github.com/rcrowley/go-metrics v0.0.0-20201227073835-cf1acfcdf475 h1:N/ElC8H3+5XpJzTSTfLsJV/mx9Q9g7kxmchpfZyxgzM=
 github.com/rcrowley/go-metrics v0.0.0-20201227073835-cf1acfcdf475/go.mod h1:bCqnVzQkZxMG4s8nGwiZ5l3QUCyqpo9Y+/ZMZ9VjZe4=
-github.com/rogpeppe/go-internal v1.8.0 h1:FCbCCtXNOY3UtUuHUYaghJg4y7Fd14rXifAYUAtL9R8=
+github.com/rwtodd/Go.Sed v0.0.0-20210816025313-55464686f9ef/go.mod h1:8AEUvGVi2uQ5b24BIhcr0GCcpd/RNAFWaN2CJFrWIIQ=
 github.com/ryanuber/columnize v0.0.0-20160712163229-9b3edd62028f/go.mod h1:sm1tb6uqfes/u+d4ooFouqFdy9/2g9QGwK3SQygK0Ts=
 github.com/sean-/seed v0.0.0-20170313163322-e2103e2c3529 h1:nn5Wsu0esKSJiIVhscUtVbo7ada43DJhG55ua/hjS5I=
 github.com/sean-/seed v0.0.0-20170313163322-e2103e2c3529/go.mod h1:DxrIzT+xaE7yg65j358z/aeFdxmN0P9QXhEzd20vsDc=
@@ -224,7 +224,6 @@ github.com/stretchr/objx v0.5.0/go.mod h1:Yh+to48EsGEfYuaHDzXPcE3xhTkx73EhmCGUpE
 github.com/stretchr/testify v1.2.2/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs=
 github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI=
 github.com/stretchr/testify v1.4.0/go.mod h1:j7eGeouHqKxXV5pUuKE4zz7dFj8WfuZ+81PSLYec5m4=
-github.com/stretchr/testify v1.6.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg=
 github.com/stretchr/testify v1.7.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg=
 github.com/stretchr/testify v1.8.0/go.mod h1:yNjHg4UonilssWZ8iaSj1OCr/vHnekPRkoO+kdMU+MU=
 github.com/stretchr/testify v1.8.2 h1:+h33VjcLVPDHtOdpUCuF+7gSuG3yGIftsP1YvFihtJ8=
@@ -238,10 +237,10 @@ golang.org/x/crypto v0.0.0-20180904163835-0709b304e793/go.mod h1:6SG95UA2DQfeDnf
 golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w=
 golang.org/x/crypto v0.0.0-20190923035154-9ee001bba392/go.mod h1:/lpIB1dKB+9EgE3H3cr1v9wB50oz8l4C4h62xy7jSTY=
 golang.org/x/crypto v0.0.0-20210314154223-e6e6c4f2bb5b/go.mod h1:T9bdIzuCu7OtxOm1hfPfRQxPLYneinmdGuTeoZ9dtd4=
-golang.org/x/crypto v0.6.0 h1:qfktjS5LUO+fFKeJXZ+ikTRijMmljikvG68fpMMruSc=
-golang.org/x/crypto v0.6.0/go.mod h1:OFC/31mSvZgRz0V1QTNCzfAI1aIRzbiufJtkMIlEp58=
-golang.org/x/mod v0.7.0 h1:LapD9S96VoQRhi/GrNTqeBJFrUjs5UHCAtTlgwA5oZA=
-golang.org/x/mod v0.7.0/go.mod h1:iBbtSCu2XBx23ZKBPSOrRkjjQPZFPuis4dIYUhu/chs=
+golang.org/x/crypto v0.7.0 h1:AvwMYaRytfdeVt3u6mLaxYtErKYjxA2OXjJ1HHq6t3A=
+golang.org/x/crypto v0.7.0/go.mod h1:pYwdfH91IfpZVANVyUOhSIPZaFoJGxTFbZhFTx+dXZU=
+golang.org/x/mod v0.8.0 h1:LUYupSeNrTNCGzR/hVBk2NHZO4hXcVaW1k4Qx7rjPx8=
+golang.org/x/mod v0.8.0/go.mod h1:iBbtSCu2XBx23ZKBPSOrRkjjQPZFPuis4dIYUhu/chs=
 golang.org/x/net v0.0.0-20180906233101-161cd47e91fd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
 golang.org/x/net v0.0.0-20181114220301-adae6a3d119a/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
 golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg=
@@ -251,8 +250,8 @@ golang.org/x/net v0.0.0-20190923162816-aa69164e4478/go.mod h1:z5CRVTTTmAJ677TzLL
 golang.org/x/net v0.0.0-20200425230154-ff2c4b7c35a0/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A=
 golang.org/x/net v0.0.0-20210226172049-e18ecbb05110/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg=
 golang.org/x/net v0.0.0-20210410081132-afb366fc7cd1/go.mod h1:9tjilg8BloeKEkVJvy7fQ90B1CfIiPueXVOjqfkSzI8=
-golang.org/x/net v0.7.0 h1:rJrUqqhjsgNp7KqAIc25s9pZnjU7TUcSY7HcVZjdn1g=
-golang.org/x/net v0.7.0/go.mod h1:2Tu9+aMcznHK/AK1HMvgo6xiTLG5rD5rZLDS+rp2Bjs=
+golang.org/x/net v0.8.0 h1:Zrh2ngAOFYneWTAIAPethzeaQLuHwhuBkuV6ZiRnUaQ=
+golang.org/x/net v0.8.0/go.mod h1:QVkue5JL9kW//ek3r6jTKnTFis1tRmNAW2P1shuFdJc=
 golang.org/x/sync v0.0.0-20180314180146-1d60e4601c6f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
 golang.org/x/sync v0.0.0-20181108010431-42b317875d0f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
 golang.org/x/sync v0.0.0-20181221193216-37e7f081c4d4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
@@ -283,20 +282,20 @@ golang.org/x/sys v0.0.0-20210330210617-4fbd30eecc44/go.mod h1:h1NjWce9XRLGQEsW7w
 golang.org/x/sys v0.0.0-20210630005230-0f9fa26af87c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
 golang.org/x/sys v0.0.0-20210927094055-39ccf1dd6fa6/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
 golang.org/x/sys v0.0.0-20220728004956-3c1f35247d10/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
-golang.org/x/sys v0.5.0 h1:MUK/U/4lj1t1oPg0HfuXDN/Z1wv31ZJ/YcPiGccS4DU=
-golang.org/x/sys v0.5.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
+golang.org/x/sys v0.6.0 h1:MVltZSvRTcU2ljQOhs94SXPftV6DCNnZViHeQps87pQ=
+golang.org/x/sys v0.6.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
 golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo=
 golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
 golang.org/x/text v0.3.2/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk=
 golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ=
 golang.org/x/text v0.3.6/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ=
-golang.org/x/text v0.7.0 h1:4BRB4x83lYWy72KwLD/qYDuTu7q9PjSagHvijDw7cLo=
-golang.org/x/text v0.7.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8=
+golang.org/x/text v0.8.0 h1:57P1ETyNKtuIjB4SRd15iJxuhj8Gc416Y78H3qgMh68=
+golang.org/x/text v0.8.0/go.mod h1:e1OnstbJyHTd6l/uOt8jFFHp6TRDWZR/bV3emEE/zU8=
 golang.org/x/time v0.3.0 h1:rg5rLMjNzMS1RkNLzCG38eapWhnYLFYXDXj2gOlr8j4=
 golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ=
 golang.org/x/tools v0.0.0-20190907020128-2ca718005c18/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo=
-golang.org/x/tools v0.5.0 h1:+bSpV5HIeWkuvgaMfI3UmKRThoTA5ODJTUd8T17NO+4=
-golang.org/x/tools v0.5.0/go.mod h1:N+Kgy78s5I24c24dU8OfWNEotWjutIs8SnJvn5IDq+k=
+golang.org/x/tools v0.6.0 h1:BOw41kyTf3PuCW1pVQf8+Cyg8pMlkYB1oo9iJ6D/lKM=
+golang.org/x/tools v0.6.0/go.mod h1:Xwgl3UAJ/d3gWutnCtw505GrjyAbvKui8lOU390QaIU=
 golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
 golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0=
 google.golang.org/genproto v0.0.0-20230109162033-3c3c17ce83e6 h1:uUn6GsgKK2eCI0bWeRMgRCcqDaQXYDuB+5tXA5Xeg/8=
@@ -309,8 +308,8 @@ google.golang.org/protobuf v1.28.1 h1:d0NfwRgPtno5B1Wa6L2DAG+KivqkdutMf1UhdNx175
 google.golang.org/protobuf v1.28.1/go.mod h1:HV8QOd/L58Z+nl8r43ehVNZIU/HEI6OcFqwMG9pJV4I=
 gopkg.in/alecthomas/kingpin.v2 v2.2.6/go.mod h1:FMv+mEhP44yOT+4EoQTLFTRgOQ1FBLkstjWtayDeSgw=
 gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
+gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15 h1:YR8cESwS4TdDjEe65xsg0ogRM/Nc3DYOhEAlW+xobZo=
 gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
-gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c h1:Hei/4ADfdWqJk1ZMxUNpqntNwaWcugrBjAiHlqqRiVk=
 gopkg.in/fsnotify.v1 v1.4.7 h1:xOHLXZwVvI9hhs+cLKq5+I5onOuwQLhQwiu63xxlHs4=
 gopkg.in/fsnotify.v1 v1.4.7/go.mod h1:Tz8NjZHkW78fSQdbUxIjBTcgA1z1m8ZHf0WmKUhAMys=
 gopkg.in/square/go-jose.v2 v2.6.0 h1:NGk74WTnPKBNUhNzQX7PYcTLUjoq7mzKk2OKbvwk2iI=
diff --git a/internal/transformer/transformparam.go b/internal/transformer/transformparam.go
index b0d78772..9ad1a56f 100644
--- a/internal/transformer/transformparam.go
+++ b/internal/transformer/transformparam.go
@@ -8,8 +8,6 @@ package transformer
 
 import (
 	"fmt"
-	"strconv"
-
 	"github.com/edgexfoundry/go-mod-core-contracts/v3/errors"
 	"github.com/edgexfoundry/go-mod-core-contracts/v3/models"
 
@@ -27,32 +25,32 @@ func TransformWriteParameter(cv *dsModels.CommandValue, pv models.ResourceProper
 	}
 	newValue := value
 
-	if pv.Maximum != "" {
-		err = validateWriteMaximum(value, pv.Maximum)
+	if pv.Maximum != nil {
+		err = validateWriteMaximum(value, *pv.Maximum)
 		if err != nil {
 			return errors.NewCommonEdgeXWrapper(err)
 		}
 	}
-	if pv.Minimum != "" {
-		err = validateWriteMinimum(value, pv.Minimum)
+	if pv.Minimum != nil {
+		err = validateWriteMinimum(value, *pv.Minimum)
 		if err != nil {
 			return errors.NewCommonEdgeXWrapper(err)
 		}
 	}
-	if pv.Offset != 0 && pv.Offset != defaultOffset {
-		newValue, err = transformOffset(newValue, pv.Offset, false)
+	if pv.Offset != nil && *pv.Offset != defaultOffset {
+		newValue, err = transformOffset(newValue, *pv.Offset, false)
 		if err != nil {
 			return errors.NewCommonEdgeXWrapper(err)
 		}
 	}
-	if pv.Scale != 0 && pv.Scale != defaultScale {
-		newValue, err = transformScale(newValue, pv.Scale, false)
+	if pv.Scale != nil && *pv.Scale != defaultScale {
+		newValue, err = transformScale(newValue, *pv.Scale, false)
 		if err != nil {
 			return errors.NewCommonEdgeXWrapper(err)
 		}
 	}
-	if pv.Base != 0 && pv.Base != defaultBase {
-		newValue, err = transformBase(newValue, pv.Base, false)
+	if pv.Base != nil && *pv.Base != defaultBase {
+		newValue, err = transformBase(newValue, *pv.Base, false)
 		if err != nil {
 			return errors.NewCommonEdgeXWrapper(err)
 		}
@@ -64,105 +62,56 @@ func TransformWriteParameter(cv *dsModels.CommandValue, pv models.ResourceProper
 	return nil
 }
 
-func validateWriteMaximum(value interface{}, maximum string) errors.EdgeX {
+func validateWriteMaximum(value any, maximum float64) errors.EdgeX {
+
 	switch v := value.(type) {
 	case uint8:
-		max, err := strconv.ParseUint(maximum, 10, 8)
-		if err != nil {
-			errMsg := fmt.Sprintf("the maximum value %s in PropertyValue cannot be parsed to %T", maximum, v)
-			return errors.NewCommonEdgeX(errors.KindServerError, errMsg, err)
-		}
-		if v > uint8(max) {
+		if v > uint8(maximum) {
 			errMsg := fmt.Sprintf("set command parameter out of maximum value %v", maximum)
 			return errors.NewCommonEdgeX(errors.KindContractInvalid, errMsg, nil)
 		}
 	case uint16:
-		max, err := strconv.ParseUint(maximum, 10, 16)
-		if err != nil {
-			errMsg := fmt.Sprintf("the maximum value %s in PropertyValue cannot be parsed to %T", maximum, v)
-			return errors.NewCommonEdgeX(errors.KindServerError, errMsg, err)
-		}
-		if v > uint16(max) {
+		if v > uint16(maximum) {
 			errMsg := fmt.Sprintf("set command parameter out of maximum value %v", maximum)
 			return errors.NewCommonEdgeX(errors.KindContractInvalid, errMsg, nil)
 		}
 	case uint32:
-		max, err := strconv.ParseUint(maximum, 10, 32)
-		if err != nil {
-			errMsg := fmt.Sprintf("the maximum value %s in PropertyValue cannot be parsed to %T", maximum, v)
-			return errors.NewCommonEdgeX(errors.KindServerError, errMsg, err)
-		}
-		if v > uint32(max) {
+		if v > uint32(maximum) {
 			errMsg := fmt.Sprintf("set command parameter out of maximum value %v", maximum)
 			return errors.NewCommonEdgeX(errors.KindContractInvalid, errMsg, nil)
 		}
 	case uint64:
-		max, err := strconv.ParseUint(maximum, 10, 64)
-		if err != nil {
-			errMsg := fmt.Sprintf("the maximum value %s in PropertyValue cannot be parsed to %T", maximum, v)
-			return errors.NewCommonEdgeX(errors.KindServerError, errMsg, err)
-		}
-		if v > max {
+		if v > uint64(maximum) {
 			errMsg := fmt.Sprintf("set command parameter out of maximum value %v", maximum)
 			return errors.NewCommonEdgeX(errors.KindContractInvalid, errMsg, nil)
 		}
 	case int8:
-		max, err := strconv.ParseInt(maximum, 10, 8)
-		if err != nil {
-			errMsg := fmt.Sprintf("the maximum value %s in PropertyValue cannot be parsed to %T", maximum, v)
-			return errors.NewCommonEdgeX(errors.KindServerError, errMsg, err)
-		}
-		if v > int8(max) {
+		if v > int8(maximum) {
 			errMsg := fmt.Sprintf("set command parameter out of maximum value %v", maximum)
 			return errors.NewCommonEdgeX(errors.KindContractInvalid, errMsg, nil)
 		}
 	case int16:
-		max, err := strconv.ParseInt(maximum, 10, 16)
-		if err != nil {
-			errMsg := fmt.Sprintf("the maximum value %s in PropertyValue cannot be parsed to %T", maximum, v)
-			return errors.NewCommonEdgeX(errors.KindServerError, errMsg, err)
-		}
-		if v > int16(max) {
+		if v > int16(maximum) {
 			errMsg := fmt.Sprintf("set command parameter out of maximum value %v", maximum)
 			return errors.NewCommonEdgeX(errors.KindContractInvalid, errMsg, nil)
 		}
 	case int32:
-		max, err := strconv.ParseInt(maximum, 10, 32)
-		if err != nil {
-			errMsg := fmt.Sprintf("the maximum value %s in PropertyValue cannot be parsed to %T", maximum, v)
-			return errors.NewCommonEdgeX(errors.KindServerError, errMsg, err)
-		}
-		if v > int32(max) {
+		if v > int32(maximum) {
 			errMsg := fmt.Sprintf("set command parameter out of maximum value %v", maximum)
 			return errors.NewCommonEdgeX(errors.KindContractInvalid, errMsg, nil)
 		}
 	case int64:
-		max, err := strconv.ParseInt(maximum, 10, 64)
-		if err != nil {
-			errMsg := fmt.Sprintf("the maximum value %s in PropertyValue cannot be parsed to %T", maximum, v)
-			return errors.NewCommonEdgeX(errors.KindServerError, errMsg, err)
-		}
-		if v > max {
+		if v > int64(maximum) {
 			errMsg := fmt.Sprintf("set command parameter out of maximum value %v", maximum)
 			return errors.NewCommonEdgeX(errors.KindContractInvalid, errMsg, nil)
 		}
 	case float32:
-		max, err := strconv.ParseFloat(maximum, 32)
-		if err != nil {
-			errMsg := fmt.Sprintf("the maximum value %s in PropertyValue cannot be parsed to %T", maximum, v)
-			return errors.NewCommonEdgeX(errors.KindServerError, errMsg, err)
-		}
-		if v > float32(max) {
+		if v > float32(maximum) {
 			errMsg := fmt.Sprintf("set command parameter out of maximum value %v", maximum)
 			return errors.NewCommonEdgeX(errors.KindContractInvalid, errMsg, nil)
 		}
 	case float64:
-		max, err := strconv.ParseFloat(maximum, 64)
-		if err != nil {
-			errMsg := fmt.Sprintf("the maximum value %s in PropertyValue cannot be parsed to %T", maximum, v)
-			return errors.NewCommonEdgeX(errors.KindServerError, errMsg, err)
-		}
-		if v > max {
+		if v > maximum {
 			errMsg := fmt.Sprintf("set command parameter out of maximum value %v", maximum)
 			return errors.NewCommonEdgeX(errors.KindContractInvalid, errMsg, nil)
 		}
@@ -170,105 +119,55 @@ func validateWriteMaximum(value interface{}, maximum string) errors.EdgeX {
 	return nil
 }
 
-func validateWriteMinimum(value interface{}, minimum string) errors.EdgeX {
+func validateWriteMinimum(value any, minimum float64) errors.EdgeX {
 	switch v := value.(type) {
 	case uint8:
-		min, err := strconv.ParseUint(minimum, 10, 8)
-		if err != nil {
-			errMsg := fmt.Sprintf("the minimum value %s in PropertyValue cannot be parsed to %T", minimum, v)
-			return errors.NewCommonEdgeX(errors.KindServerError, errMsg, err)
-		}
-		if v < uint8(min) {
+		if v < uint8(minimum) {
 			errMsg := fmt.Sprintf("set command parameter out of minimum value %v", minimum)
 			return errors.NewCommonEdgeX(errors.KindContractInvalid, errMsg, nil)
 		}
 	case uint16:
-		min, err := strconv.ParseUint(minimum, 10, 16)
-		if err != nil {
-			errMsg := fmt.Sprintf("the minimum value %s in PropertyValue cannot be parsed to %T", minimum, v)
-			return errors.NewCommonEdgeX(errors.KindServerError, errMsg, err)
-		}
-		if v < uint16(min) {
+		if v < uint16(minimum) {
 			errMsg := fmt.Sprintf("set command parameter out of minimum value %v", minimum)
 			return errors.NewCommonEdgeX(errors.KindContractInvalid, errMsg, nil)
 		}
 	case uint32:
-		min, err := strconv.ParseUint(minimum, 10, 32)
-		if err != nil {
-			errMsg := fmt.Sprintf("the minimum value %s in PropertyValue cannot be parsed to %T", minimum, v)
-			return errors.NewCommonEdgeX(errors.KindServerError, errMsg, err)
-		}
-		if v < uint32(min) {
+		if v < uint32(minimum) {
 			errMsg := fmt.Sprintf("set command parameter out of minimum value %v", minimum)
 			return errors.NewCommonEdgeX(errors.KindContractInvalid, errMsg, nil)
 		}
 	case uint64:
-		min, err := strconv.ParseUint(minimum, 10, 64)
-		if err != nil {
-			errMsg := fmt.Sprintf("the minimum value %s in PropertyValue cannot be parsed to %T", minimum, v)
-			return errors.NewCommonEdgeX(errors.KindServerError, errMsg, err)
-		}
-		if v < min {
+		if v < uint64(minimum) {
 			errMsg := fmt.Sprintf("set command parameter out of minimum value %v", minimum)
 			return errors.NewCommonEdgeX(errors.KindContractInvalid, errMsg, nil)
 		}
 	case int8:
-		min, err := strconv.ParseInt(minimum, 10, 8)
-		if err != nil {
-			errMsg := fmt.Sprintf("the minimum value %s in PropertyValue cannot be parsed to %T", minimum, v)
-			return errors.NewCommonEdgeX(errors.KindServerError, errMsg, err)
-		}
-		if v < int8(min) {
+		if v < int8(minimum) {
 			errMsg := fmt.Sprintf("set command parameter out of minimum value %v", minimum)
 			return errors.NewCommonEdgeX(errors.KindContractInvalid, errMsg, nil)
 		}
 	case int16:
-		min, err := strconv.ParseInt(minimum, 10, 16)
-		if err != nil {
-			errMsg := fmt.Sprintf("the minimum value %s in PropertyValue cannot be parsed to %T", minimum, v)
-			return errors.NewCommonEdgeX(errors.KindServerError, errMsg, err)
-		}
-		if v < int16(min) {
+		if v < int16(minimum) {
 			errMsg := fmt.Sprintf("set command parameter out of minimum value %v", minimum)
 			return errors.NewCommonEdgeX(errors.KindContractInvalid, errMsg, nil)
 		}
 	case int32:
-		min, err := strconv.ParseInt(minimum, 10, 32)
-		if err != nil {
-			errMsg := fmt.Sprintf("the minimum value %s in PropertyValue cannot be parsed to %T", minimum, v)
-			return errors.NewCommonEdgeX(errors.KindServerError, errMsg, err)
-		}
-		if v < int32(min) {
+		if v < int32(minimum) {
 			errMsg := fmt.Sprintf("set command parameter out of minimum value %v", minimum)
 			return errors.NewCommonEdgeX(errors.KindContractInvalid, errMsg, nil)
 		}
 	case int64:
-		min, err := strconv.ParseInt(minimum, 10, 64)
-		if err != nil {
-			errMsg := fmt.Sprintf("the minimum value %s in PropertyValue cannot be parsed to %T", minimum, v)
-			return errors.NewCommonEdgeX(errors.KindServerError, errMsg, err)
-		}
-		if v < min {
+		if v < int64(minimum) {
 			errMsg := fmt.Sprintf("set command parameter out of minimum value %v", minimum)
 			return errors.NewCommonEdgeX(errors.KindContractInvalid, errMsg, nil)
 		}
 	case float32:
-		min, err := strconv.ParseFloat(minimum, 32)
-		if err != nil {
-			errMsg := fmt.Sprintf("the minimum value %s in PropertyValue cannot be parsed to %T", minimum, v)
-			return errors.NewCommonEdgeX(errors.KindServerError, errMsg, err)
-		}
-		if v < float32(min) {
+		if v < float32(minimum) {
 			errMsg := fmt.Sprintf("set command parameter out of minimum value %v", minimum)
 			return errors.NewCommonEdgeX(errors.KindContractInvalid, errMsg, nil)
 		}
 	case float64:
-		min, err := strconv.ParseFloat(minimum, 64)
-		if err != nil {
-			errMsg := fmt.Sprintf("the minimum value %s in PropertyValue cannot be parsed to %T", minimum, v)
-			return errors.NewCommonEdgeX(errors.KindServerError, errMsg, err)
-		}
-		if v < min {
+		if v < minimum {
 			errMsg := fmt.Sprintf("set command parameter out of minimum value %v", minimum)
 			return errors.NewCommonEdgeX(errors.KindContractInvalid, errMsg, nil)
 		}
diff --git a/internal/transformer/transformresult.go b/internal/transformer/transformresult.go
index 337a3217..5a025b9e 100644
--- a/internal/transformer/transformresult.go
+++ b/internal/transformer/transformresult.go
@@ -49,34 +49,34 @@ func TransformReadResult(cv *sdkModels.CommandValue, pv models.ResourcePropertie
 	}
 	newValue := value
 
-	if pv.Mask != 0 && pv.Mask != defaultMask &&
+	if pv.Mask != nil && *pv.Mask != defaultMask &&
 		(cv.Type == common.ValueTypeUint8 || cv.Type == common.ValueTypeUint16 || cv.Type == common.ValueTypeUint32 || cv.Type == common.ValueTypeUint64) {
-		newValue, err = transformReadMask(newValue, pv.Mask)
+		newValue, err = transformReadMask(newValue, *pv.Mask)
 		if err != nil {
 			return errors.NewCommonEdgeXWrapper(err)
 		}
 	}
-	if pv.Shift != 0 && pv.Shift != defaultShift &&
+	if pv.Shift != nil && *pv.Shift != defaultShift &&
 		(cv.Type == common.ValueTypeUint8 || cv.Type == common.ValueTypeUint16 || cv.Type == common.ValueTypeUint32 || cv.Type == common.ValueTypeUint64) {
-		newValue, err = transformReadShift(newValue, pv.Shift)
+		newValue, err = transformReadShift(newValue, *pv.Shift)
 		if err != nil {
 			return errors.NewCommonEdgeXWrapper(err)
 		}
 	}
-	if pv.Base != 0 && pv.Base != defaultBase {
-		newValue, err = transformBase(newValue, pv.Base, true)
+	if pv.Base != nil && *pv.Base != defaultBase {
+		newValue, err = transformBase(newValue, *pv.Base, true)
 		if err != nil {
 			return errors.NewCommonEdgeXWrapper(err)
 		}
 	}
-	if pv.Scale != 0 && pv.Scale != defaultScale {
-		newValue, err = transformScale(newValue, pv.Scale, true)
+	if pv.Scale != nil && *pv.Scale != defaultScale {
+		newValue, err = transformScale(newValue, *pv.Scale, true)
 		if err != nil {
 			return errors.NewCommonEdgeXWrapper(err)
 		}
 	}
-	if pv.Offset != 0 && pv.Offset != defaultOffset {
-		newValue, err = transformOffset(newValue, pv.Offset, true)
+	if pv.Offset != nil && *pv.Offset != defaultOffset {
+		newValue, err = transformOffset(newValue, *pv.Offset, true)
 		if err != nil {
 			return errors.NewCommonEdgeXWrapper(err)
 		}


Test patch:
diff --git a/internal/transformer/transformparam_test.go b/internal/transformer/transformparam_test.go
index 9f223f93..d1efc322 100644
--- a/internal/transformer/transformparam_test.go
+++ b/internal/transformer/transformparam_test.go
@@ -1,12 +1,11 @@
 //
-// Copyright (C) 2021 IOTech Ltd
+// Copyright (C) 2021-2023 IOTech Ltd
 //
 // SPDX-License-Identifier: Apache-2.0
 
 package transformer
 
 import (
-	"fmt"
 	"math"
 	"testing"
 
@@ -17,29 +16,29 @@ func Test_validateWriteMaximum(t *testing.T) {
 	tests := []struct {
 		name        string
 		value       interface{}
-		max         string
+		max         float64
 		expectedErr bool
 	}{
-		{"valid - uint8 compare succeed", uint8(math.MaxUint8 - 1), fmt.Sprintf("%v", math.MaxUint8), false},
-		{"invalid - uint8 compare failed", uint8(math.MaxUint8), fmt.Sprintf("%v", math.MaxUint8-1), true},
-		{"valid - uint16 compare succeed", uint16(math.MaxUint16 - 1), fmt.Sprintf("%v", math.MaxUint16), false},
-		{"invalid - uint16 compare failed", uint16(math.MaxUint16), fmt.Sprintf("%v", math.MaxUint16-1), true},
-		{"valid - uint32 compare succeed", uint32(math.MaxUint32 - 1), fmt.Sprintf("%v", math.MaxUint32), false},
-		{"invalid - uint32 compare failed", uint32(math.MaxUint32), fmt.Sprintf("%v", math.MaxUint32-1), true},
-		{"valid - uint64 compare succeed", uint64(1000000000), "1000000001", false},
-		{"invalid - uint64 compare failed", uint64(1000000001), "1000000000", true},
-		{"valid - int8 compare succeed", int8(math.MaxInt8 - 1), fmt.Sprintf("%v", math.MaxInt8), false},
-		{"invalid - int8 compare failed", int8(math.MaxInt8), fmt.Sprintf("%v", math.MaxInt8-1), true},
-		{"valid - int16 compare succeed", int16(math.MaxInt16 - 1), fmt.Sprintf("%v", math.MaxInt16), false},
-		{"invalid - int16 compare failed", int16(math.MaxInt16), fmt.Sprintf("%v", math.MaxInt16-1), true},
-		{"valid - int32 compare succeed", int32(math.MaxInt32 - 1), fmt.Sprintf("%v", math.MaxInt32), false},
-		{"invalid - int32 compare failed", int32(math.MaxInt32), fmt.Sprintf("%v", math.MaxInt32-1), true},
-		{"valid - int64 compare succeed", int64(1000000000), "1000000001", false},
-		{"invalid - int64 compare failed", int64(1000000001), "1000000000", true},
-		{"valid - float32 compare succeed", float32(12345.6789), "123456.789", false},
-		{"invalid - float32 compare failed", float32(123456.789), "12345.6789", true},
-		{"valid - float64 compare succeed", float64(12345.6789), "123456.789", false},
-		{"invalid - float64 compare failed", float64(123456.789), "12345.6789", true},
+		{"valid - uint8 compare succeed", uint8(math.MaxUint8 - 1), float64(math.MaxUint8), false},
+		{"invalid - uint8 compare failed", uint8(math.MaxUint8), float64(math.MaxUint8 - 1), true},
+		{"valid - uint16 compare succeed", uint16(math.MaxUint16 - 1), float64(math.MaxUint16), false},
+		{"invalid - uint16 compare failed", uint16(math.MaxUint16), float64(math.MaxUint16 - 1), true},
+		{"valid - uint32 compare succeed", uint32(math.MaxUint32 - 1), float64(math.MaxUint32), false},
+		{"invalid - uint32 compare failed", uint32(math.MaxUint32), float64(math.MaxUint32 - 1), true},
+		{"valid - uint64 compare succeed", uint64(1000000000), float64(1000000001), false},
+		{"invalid - uint64 compare failed", uint64(1000000001), float64(1000000000), true},
+		{"valid - int8 compare succeed", int8(math.MaxInt8 - 1), float64(math.MaxInt8), false},
+		{"invalid - int8 compare failed", int8(math.MaxInt8), float64(math.MaxInt8 - 1), true},
+		{"valid - int16 compare succeed", int16(math.MaxInt16 - 1), float64(math.MaxInt16), false},
+		{"invalid - int16 compare failed", int16(math.MaxInt16), float64(math.MaxInt16 - 1), true},
+		{"valid - int32 compare succeed", int32(math.MaxInt32 - 1), float64(math.MaxInt32), false},
+		{"invalid - int32 compare failed", int32(math.MaxInt32), float64(math.MaxInt32 - 1), true},
+		{"valid - int64 compare succeed", int64(1000000000), float64(1000000001), false},
+		{"invalid - int64 compare failed", int64(1000000001), float64(1000000000), true},
+		{"valid - float32 compare succeed", float32(12345.6789), float64(123456.789), false},
+		{"invalid - float32 compare failed", float32(123456.789), float64(12345.6789), true},
+		{"valid - float64 compare succeed", float64(12345.6789), float64(123456.789), false},
+		{"invalid - float64 compare failed", float64(123456.789), float64(12345.6789), true},
 	}
 	for _, tt := range tests {
 		t.Run(tt.name, func(t *testing.T) {
@@ -57,29 +56,29 @@ func Test_validateWriteMinimum(t *testing.T) {
 	tests := []struct {
 		name        string
 		value       interface{}
-		min         string
+		min         float64
 		expectedErr bool
 	}{
-		{"valid - uint8 compare succeed", uint8(1), "0", false},
-		{"invalid - uint8 compare failed", uint8(0), "1", true},
-		{"valid - uint16 compare succeed", uint16(1), "0", false},
-		{"invalid - uint16 compare failed", uint16(0), "1", true},
-		{"valid - uint32 compare succeed", uint32(1), "0", false},
-		{"invalid - uint32 compare failed", uint32(0), "1", true},
-		{"valid - uint64 compare succeed", uint64(1), "0", false},
-		{"invalid - uint64 compare failed", uint64(0), "1", true},
-		{"valid - int8 compare succeed", int8(math.MinInt8 + 1), fmt.Sprintf("%v", math.MinInt8), false},
-		{"invalid - int8 compare failed", int8(math.MinInt8), fmt.Sprintf("%v", math.MinInt8+1), true},
-		{"valid - int16 compare succeed", int16(math.MinInt16 + 1), fmt.Sprintf("%v", math.MinInt16), false},
-		{"invalid - int16 compare failed", int16(math.MinInt16), fmt.Sprintf("%v", math.MinInt16+1), true},
-		{"valid - int32 compare succeed", int32(math.MinInt32 + 1), fmt.Sprintf("%v", math.MinInt32), false},
-		{"invalid - int32 compare failed", int32(math.MinInt32), fmt.Sprintf("%v", math.MinInt32+1), true},
-		{"valid - int64 compare succeed", int64(math.MinInt64 + 1), fmt.Sprintf("%v", math.MinInt64), false},
-		{"invalid - int64 compare failed", int64(math.MinInt64), fmt.Sprintf("%v", math.MinInt64+1), true},
-		{"valid - float32 compare succeed", float32(123456.789), "12345.6789", false},
-		{"invalid - float32 compare failed", float32(12345.6789), "123456.789", true},
-		{"valid - float64 compare succeed", float64(123456.789), "12345.6789", false},
-		{"invalid - float64 compare failed", float64(12345.6789), "123456.789", true},
+		{"valid - uint8 compare succeed", uint8(1), float64(0), false},
+		{"invalid - uint8 compare failed", uint8(0), float64(1), true},
+		{"valid - uint16 compare succeed", uint16(1), float64(0), false},
+		{"invalid - uint16 compare failed", uint16(0), float64(1), true},
+		{"valid - uint32 compare succeed", uint32(1), float64(0), false},
+		{"invalid - uint32 compare failed", uint32(0), float64(1), true},
+		{"valid - uint64 compare succeed", uint64(1), float64(0), false},
+		{"invalid - uint64 compare failed", uint64(0), float64(1), true},
+		{"valid - int8 compare succeed", int8(math.MinInt8 + 1), float64(math.MinInt8), false},
+		{"invalid - int8 compare failed", int8(math.MinInt8), float64(math.MinInt8 + 1), true},
+		{"valid - int16 compare succeed", int16(math.MinInt16 + 1), float64(math.MinInt16), false},
+		{"invalid - int16 compare failed", int16(math.MinInt16), float64(math.MinInt16 + 1), true},
+		{"valid - int32 compare succeed", int32(math.MinInt32 + 1), float64(math.MinInt32), false},
+		{"invalid - int32 compare failed", int32(math.MinInt32), float64(math.MinInt32 + 1), true},
+		{"valid - int64 compare succeed", int64(math.MinInt64 + 1), float64(math.MinInt64), false},
+		{"invalid - int64 compare failed", int64(-1000000001), float64(-1000000000), true},
+		{"valid - float32 compare succeed", float32(123456.789), float64(12345.6789), false},
+		{"invalid - float32 compare failed", float32(12345.6789), float64(123456.789), true},
+		{"valid - float64 compare succeed", float64(123456.789), float64(12345.6789), false},
+		{"invalid - float64 compare failed", float64(12345.6789), float64(123456.789), true},
 	}
 	for _, tt := range tests {
 		t.Run(tt.name, func(t *testing.T) {