You are viewing a plain text version of this content. The canonical link for it is here.
Posted to pr@cassandra.apache.org by GitBox <gi...@apache.org> on 2022/03/07 23:36:46 UTC

[GitHub] [cassandra] ekaterinadimitrova2 commented on a change in pull request #1335: CASSANDRA-17166 - switched to jackson for property definition

ekaterinadimitrova2 commented on a change in pull request #1335:
URL: https://github.com/apache/cassandra/pull/1335#discussion_r821196005



##########
File path: test/unit/org/apache/cassandra/config/ConfigCompatabilityTest.java
##########
@@ -0,0 +1,369 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.cassandra.config;
+
+import java.io.File;
+import java.io.IOException;
+import java.util.Collections;
+import java.util.HashMap;
+import java.util.HashSet;
+import java.util.Iterator;
+import java.util.Map;
+import java.util.Objects;
+import java.util.Set;
+import java.util.SortedMap;
+import java.util.TreeMap;
+import java.util.TreeSet;
+import java.util.stream.Collectors;
+
+import com.google.common.collect.ImmutableSet;
+import com.google.common.collect.Sets;
+import org.junit.Test;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+import com.fasterxml.jackson.annotation.JsonValue;
+import com.fasterxml.jackson.core.JsonGenerator;
+import com.fasterxml.jackson.core.JsonParser;
+import com.fasterxml.jackson.core.JsonProcessingException;
+import com.fasterxml.jackson.core.TreeNode;
+import com.fasterxml.jackson.databind.DeserializationContext;
+import com.fasterxml.jackson.databind.ObjectMapper;
+import com.fasterxml.jackson.databind.SerializerProvider;
+import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
+import com.fasterxml.jackson.databind.annotation.JsonSerialize;
+import com.fasterxml.jackson.databind.deser.std.StdDeserializer;
+import com.fasterxml.jackson.databind.node.TextNode;
+import com.fasterxml.jackson.databind.ser.std.StdSerializer;
+import com.fasterxml.jackson.dataformat.yaml.YAMLFactory;
+import org.checkerframework.checker.units.qual.K;
+import org.yaml.snakeyaml.introspector.Property;
+
+/**
+ * To create the test files used by this class, run {@link org.apache.cassandra.distributed.upgrade.ConfigCompatabilityTestGenerate}.
+ */
+public class ConfigCompatabilityTest
+{
+    private static final Logger logger = LoggerFactory.getLogger(ConfigCompatabilityTest.class);
+
+    public static final String TEST_DIR = "test/data/config";
+
+    // see CASSANDRA-11115
+    private static final Set<String> THRIFT = ImmutableSet.of("rpc_server_type",
+                                                              "rpc_port",
+                                                              "rpc_listen_backlog",
+                                                              "start_rpc",
+                                                              "thrift_max_message_length_in_mb",
+                                                              "rpc_max_threads",
+                                                              "rpc_min_threads",
+                                                              "rpc_recv_buff_size_in_bytes",
+                                                              "rpc_send_buff_size_in_bytes",
+                                                              "thrift_framed_transport_size_in_mb",
+                                                              "thrift_prepared_statements_cache_size_mb",
+                                                              "request_scheduler",
+                                                              "request_scheduler_id",
+                                                              "request_scheduler_options");
+    // see // CASSANDRA-16956
+    private static final Set<String> WINDOWS = ImmutableSet.of("windows_timer_interval");
+    /**
+     * Breaking Change: These properties were dead code but removed in a minor (4.0.2).  This broke our deprecation rules
+     * as they should have been removed in 5.0 as previously agreed..

Review comment:
       Handled already




-- 
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: pr-unsubscribe@cassandra.apache.org

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



---------------------------------------------------------------------
To unsubscribe, e-mail: pr-unsubscribe@cassandra.apache.org
For additional commands, e-mail: pr-help@cassandra.apache.org