You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@ozone.apache.org by "xichen01 (via GitHub)" <gi...@apache.org> on 2023/10/12 05:17:09 UTC

[PR] HDDS-9421. Reduce the duplicate create Container/Context code for test code [ozone]

xichen01 opened a new pull request, #5429:
URL: https://github.com/apache/ozone/pull/5429

   ## What changes were proposed in this pull request?
   Reduce the duplicate create Container/Context code for test code
   
   ## What is the link to the Apache JIRA
   https://issues.apache.org/jira/browse/HDDS-9421
   
   ## How was this patch tested?
   Existing test
   


-- 
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: issues-unsubscribe@ozone.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org


Re: [PR] HDDS-9421. Reduce the duplicate create Container/Context code for test code [ozone]

Posted by "xichen01 (via GitHub)" <gi...@apache.org>.
xichen01 commented on PR #5429:
URL: https://github.com/apache/ozone/pull/5429#issuecomment-1764605529

   > Thanks @xichen01 for the patch, LGTM.
   > 
   > I found one more instance of the same mock context:
   > 
   > https://github.com/apache/ozone/blob/76c1747ac6a94693c6e3b170c982b6d6f0c270c8/hadoop-hdds/container-service/src/test/java/org/apache/hadoop/ozone/container/common/statemachine/commandhandler/TestCreatePipelineCommandHandler.java#L87-L90
   > 
   > Please check if it can be replaced.
   
   Thank for your detail check, this has been replaced 


-- 
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: issues-unsubscribe@ozone.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org


Re: [PR] HDDS-9421. Reduce the duplicate create Container/Context code for test code [ozone]

Posted by "kerneltime (via GitHub)" <gi...@apache.org>.
kerneltime commented on PR #5429:
URL: https://github.com/apache/ozone/pull/5429#issuecomment-1764840961

   @tanvipenumudy  @Galsza  can you please take a look?


-- 
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: issues-unsubscribe@ozone.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org


Re: [PR] HDDS-9421. Reduce the duplicate create Container/Context code for test code [ozone]

Posted by "xichen01 (via GitHub)" <gi...@apache.org>.
xichen01 commented on PR #5429:
URL: https://github.com/apache/ozone/pull/5429#issuecomment-1758928569

   All the tests of [e5b39cb](https://github.com/apache/ozone/pull/5429/commits/e5b39cbbdeadafdd6089ef07c5a3943152b19183) have passed : https://github.com/xichen01/ozone/actions/runs/6479407702


-- 
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: issues-unsubscribe@ozone.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org


Re: [PR] HDDS-9421. Reduce the duplicate create Container/Context code for test code [ozone]

Posted by "adoroszlai (via GitHub)" <gi...@apache.org>.
adoroszlai commented on code in PR #5429:
URL: https://github.com/apache/ozone/pull/5429#discussion_r1359263150


##########
hadoop-hdds/container-service/src/test/java/org/apache/hadoop/ozone/container/common/ContainerTestUtils.java:
##########
@@ -113,17 +113,23 @@ public static EndpointStateMachine createEndpoint(Configuration conf,
         new LegacyHadoopConfigurationSource(conf));
   }
 
-  public static OzoneContainer getOzoneContainer(
+  public static OzoneContainer getOzoneContainerWithMockContext(

Review Comment:
   I suggest keeping the original name?
   
   * reduce change
   * there is no `getOzoneContainer` (without mock context) method we need to differentiate from



##########
hadoop-hdds/container-service/src/test/java/org/apache/hadoop/ozone/container/common/ContainerTestUtils.java:
##########
@@ -113,17 +113,23 @@ public static EndpointStateMachine createEndpoint(Configuration conf,
         new LegacyHadoopConfigurationSource(conf));
   }
 
-  public static OzoneContainer getOzoneContainer(
+  public static OzoneContainer getOzoneContainerWithMockContext(

Review Comment:
   I suggest keeping the original name:
   
   * reduce change
   * there is no `getOzoneContainer` (without mock context) method we need to differentiate from



-- 
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: issues-unsubscribe@ozone.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org


Re: [PR] HDDS-9421. Reduce the duplicate create Container/Context code for test code [ozone]

Posted by "xichen01 (via GitHub)" <gi...@apache.org>.
xichen01 commented on code in PR #5429:
URL: https://github.com/apache/ozone/pull/5429#discussion_r1360452182


##########
hadoop-hdds/container-service/src/test/java/org/apache/hadoop/ozone/container/common/ContainerTestUtils.java:
##########
@@ -113,17 +113,23 @@ public static EndpointStateMachine createEndpoint(Configuration conf,
         new LegacyHadoopConfigurationSource(conf));
   }
 
-  public static OzoneContainer getOzoneContainer(
+  public static OzoneContainer getOzoneContainerWithMockContext(

Review Comment:
   Done.



-- 
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: issues-unsubscribe@ozone.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org


Re: [PR] HDDS-9421. Reduce the duplicate create Container/Context code for test code [ozone]

Posted by "adoroszlai (via GitHub)" <gi...@apache.org>.
adoroszlai merged PR #5429:
URL: https://github.com/apache/ozone/pull/5429


-- 
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: issues-unsubscribe@ozone.apache.org

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


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org