You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@iotdb.apache.org by GitBox <gi...@apache.org> on 2021/11/18 12:20:03 UTC

[GitHub] [iotdb] xinzhongtianxia opened a new pull request #4425: [IOTDB-2016][metric] Fix ClassCastException when create new metric types

xinzhongtianxia opened a new pull request #4425:
URL: https://github.com/apache/iotdb/pull/4425


   ## Description
   1. Create Gauge with metric name = 'a' and tags = ['b' = 'c']
   2. Create Timer with metric name = 'a' and tags = ['b' = 'c']
   3. Then we will get a ClassCastException
   
   I fixed it like dropwizard or micrometer does:
   1. If IMetric exist in the map, check if it instanceof the right metric type.
   2. If not, throw an IllegalArgumentException to test user the name and tags are already used for a different type of metric
   
   jira:
   https://issues.apache.org/jira/browse/IOTDB-2016


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: reviews-unsubscribe@iotdb.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [iotdb] SteveYurongSu commented on pull request #4425: [IOTDB-2016][metric] Fix ClassCastException when create new metric types

Posted by GitBox <gi...@apache.org>.
SteveYurongSu commented on pull request #4425:
URL: https://github.com/apache/iotdb/pull/4425#issuecomment-973890955


   Thanks for the contribution! Please take a look at the failed tests.
   
   @stormbroken PTAL :D


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: reviews-unsubscribe@iotdb.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [iotdb] stormbroken commented on pull request #4425: [IOTDB-2016][metric] Fix ClassCastException when create new metric types

Posted by GitBox <gi...@apache.org>.
stormbroken commented on pull request #4425:
URL: https://github.com/apache/iotdb/pull/4425#issuecomment-974084877


   Thanks for your contribution! I think you need to fix related test at the same time. Example id as follows:
   ![image](https://user-images.githubusercontent.com/46039728/142632478-5bc157b8-588b-489b-9181-dc42ac46c873.png)
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: reviews-unsubscribe@iotdb.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [iotdb] stormbroken commented on pull request #4425: [IOTDB-2016][metric] Fix ClassCastException when create new metric types

Posted by GitBox <gi...@apache.org>.
stormbroken commented on pull request #4425:
URL: https://github.com/apache/iotdb/pull/4425#issuecomment-975604695


   Thank you for your continued attention! From my respective,  LGTM @SteveYurongSu 


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: reviews-unsubscribe@iotdb.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [iotdb] SteveYurongSu merged pull request #4425: [IOTDB-2016][metric] Fix ClassCastException when create new metric types

Posted by GitBox <gi...@apache.org>.
SteveYurongSu merged pull request #4425:
URL: https://github.com/apache/iotdb/pull/4425


   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: reviews-unsubscribe@iotdb.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org