You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@curator.apache.org by "tisonkun (via GitHub)" <gi...@apache.org> on 2024/01/31 12:11:03 UTC

[PR] CURATOR-XXX. Upgrade ZooKeeper version to 3.9 [curator]

tisonkun opened a new pull request, #496:
URL: https://github.com/apache/curator/pull/496

   (no comment)


-- 
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: commits-unsubscribe@curator.apache.org

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


Re: [PR] CURATOR-XXX. Upgrade ZooKeeper version to 3.9 [curator]

Posted by "tisonkun (via GitHub)" <gi...@apache.org>.
tisonkun commented on PR #496:
URL: https://github.com/apache/curator/pull/496#issuecomment-1943652674

   @eolivelli Thanks for your review. I make this patch work now. Let me create the ticket and a few follow-ups to improve the case.


-- 
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: commits-unsubscribe@curator.apache.org

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


Re: [PR] CURATOR-XXX. Upgrade ZooKeeper version to 3.9 [curator]

Posted by "tisonkun (via GitHub)" <gi...@apache.org>.
tisonkun commented on PR #496:
URL: https://github.com/apache/curator/pull/496#issuecomment-1943013369

   I create a monkey patch to work around it - e23d087285edeb45d4dd925379a6af76777cb493


-- 
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: commits-unsubscribe@curator.apache.org

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


Re: [PR] CURATOR-XXX. Upgrade ZooKeeper version to 3.9 [curator]

Posted by "tisonkun (via GitHub)" <gi...@apache.org>.
tisonkun commented on code in PR #496:
URL: https://github.com/apache/curator/pull/496#discussion_r1474125212


##########
curator-recipes/src/test/java/org/apache/curator/framework/recipes/leader/ChaosMonkeyCnxnFactory.java:
##########
@@ -81,22 +79,19 @@ public void submitRequest(Request si) {
                     && si.type != ZooDefs.OpCode.ping
                     && firstError != 0
                     && remaining > 0) {
-                log.debug("Rejected : " + si.toString());
+                log.debug("Rejected : {}", si);
                 // Still reject request
                 log.debug("Still not ready for " + remaining + "ms");
                 Compatibility.serverCnxnClose(si.cnxn);
                 return;
             }
             // Submit the request to the legacy Zookeeper server
-            log.debug("Applied : " + si.toString());
+            log.debug("Applied : {}", si);
             super.submitRequest(si);
             // Raise an error if a lock is created
             if ((si.type == ZooDefs.OpCode.create) || (si.type == ZooDefs.OpCode.create2)) {
-                CreateRequest createRequest = new CreateRequest();
                 try {
-                    ByteBuffer duplicate = si.request.duplicate();
-                    duplicate.rewind();
-                    ByteBufferInputStream.byteBuffer2Record(duplicate, createRequest);
+                    CreateRequest createRequest = si.readRequestRecord(CreateRequest::new);

Review Comment:
   OK. It fails.
   
   Let me think if we should drop support <= 3.7 or add a test compatible switch.
   
   cc @kezhuw @eolivelli @cammckenzie @Randgalt 



-- 
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: commits-unsubscribe@curator.apache.org

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


Re: [PR] CURATOR-XXX. Upgrade ZooKeeper version to 3.9 [curator]

Posted by "tisonkun (via GitHub)" <gi...@apache.org>.
tisonkun commented on PR #496:
URL: https://github.com/apache/curator/pull/496#issuecomment-1921119703

   Make sense. I understand it as introducing a new test tag said `zk38OrLater` to turn on related tests only when zk 3.8+ as dep.


-- 
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: commits-unsubscribe@curator.apache.org

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


Re: [PR] CURATOR-XXX. Upgrade ZooKeeper version to 3.9 [curator]

Posted by "tisonkun (via GitHub)" <gi...@apache.org>.
tisonkun commented on PR #496:
URL: https://github.com/apache/curator/pull/496#issuecomment-1943010147

   ```
   [ERROR] Tests run: 3, Failures: 0, Errors: 3, Skipped: 0, Time elapsed: 0.44 s <<< FAILURE! - in org.apache.curator.framework.imps.TestTransactionsOld
   [ERROR] org.apache.curator.framework.imps.TestTransactionsOld.testWithCompression  Time elapsed: 0.144 s  <<< ERROR!
   java.lang.NoSuchMethodError: 'com.google.common.base.Predicate org.apache.curator.framework.api.transaction.CuratorTransactionResult.ofTypeAndPath(org.apache.curator.framework.api.transaction.OperationType, java.lang.String)'
   	at org.apache.curator.framework.imps.TestTransactionsOld.testWithCompression(TestTransactionsOld.java:165)
   ```
   
   It seems because we relocate these methods in curator-framework but not for the test-jar. I don't find a way to relocate the test jar now ..


-- 
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: commits-unsubscribe@curator.apache.org

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


Re: [PR] CURATOR-699. Upgrade ZooKeeper version to 3.9 [curator]

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


-- 
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: commits-unsubscribe@curator.apache.org

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


Re: [PR] CURATOR-XXX. Upgrade ZooKeeper version to 3.9 [curator]

Posted by "tisonkun (via GitHub)" <gi...@apache.org>.
tisonkun commented on code in PR #496:
URL: https://github.com/apache/curator/pull/496#discussion_r1472736529


##########
curator-recipes/src/test/java/org/apache/curator/framework/recipes/leader/ChaosMonkeyCnxnFactory.java:
##########
@@ -81,22 +79,19 @@ public void submitRequest(Request si) {
                     && si.type != ZooDefs.OpCode.ping
                     && firstError != 0
                     && remaining > 0) {
-                log.debug("Rejected : " + si.toString());
+                log.debug("Rejected : {}", si);
                 // Still reject request
                 log.debug("Still not ready for " + remaining + "ms");
                 Compatibility.serverCnxnClose(si.cnxn);
                 return;
             }
             // Submit the request to the legacy Zookeeper server
-            log.debug("Applied : " + si.toString());
+            log.debug("Applied : {}", si);
             super.submitRequest(si);
             // Raise an error if a lock is created
             if ((si.type == ZooDefs.OpCode.create) || (si.type == ZooDefs.OpCode.create2)) {
-                CreateRequest createRequest = new CreateRequest();
                 try {
-                    ByteBuffer duplicate = si.request.duplicate();
-                    duplicate.rewind();
-                    ByteBufferInputStream.byteBuffer2Record(duplicate, createRequest);
+                    CreateRequest createRequest = si.readRequestRecord(CreateRequest::new);

Review Comment:
   This may cause failures on early ZK versions and we need a testing compatible layer.
   
   Let the CI verify if it's the case.



-- 
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: commits-unsubscribe@curator.apache.org

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


Re: [PR] CURATOR-XXX. Upgrade ZooKeeper version to 3.9 [curator]

Posted by "eolivelli (via GitHub)" <gi...@apache.org>.
eolivelli commented on PR #496:
URL: https://github.com/apache/curator/pull/496#issuecomment-1921085363

   I think that it is fine to drop support for 3.7 in those tests


-- 
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: commits-unsubscribe@curator.apache.org

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