instance_id stringlengths 10 65 | repo stringlengths 5 59 | pr_number int64 1 313k | task_type stringclasses 1
value | base_commit stringlengths 40 40 | review_commit stringlengths 40 40 | title stringlengths 2 282 | body stringlengths 7 3k | patch stringlengths 202 204k | n_defects int64 1 72 | n_supported int64 1 65 | n_major int64 0 32 | defects stringlengths 140 18.8k | certifier_count int64 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
apache__kvrocks__1764 | apache/kvrocks | 1,764 | defect | 21984b32d194fad4aee3bb374d850c35257d8e66 | 8d237110eba834e8de8d6dc0ff666b589a9a1149 | Make BlockSplitBloomFilter a view | Besides, we supplement licenses and introduce span-lite to use std::span in c++20. | diff --git a/CMakeLists.txt b/CMakeLists.txt
index 0a2adc4000b..2112a61eca0 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -132,6 +132,7 @@ include(cmake/libevent.cmake)
include(cmake/fmt.cmake)
include(cmake/jsoncons.cmake)
include(cmake/xxhash.cmake)
+include(cmake/span.cmake)
if (ENABLE_LUAJIT)
include(c... | 4 | 1 | 0 | [{"id": "G0", "claim": "The doc comment on the pointer/string CreateBlockSplitBloomFilter overload should say \"It copies the bitset as underlying bitset when the given bitset may not satisfy the 32-byte alignment requirement\" instead of \"because ...\".", "category": "documentation", "verdict": "supported", "priority... | null |
apache__kvrocks__1776 | apache/kvrocks | 1,776 | defect | a9397f2b857e5f228082df625413704fb0010249 | 60d607b15fe663fb1791b784ece652238badc9d1 | Add the support of the namespace replication | This PR implements the namespace replication between master and slaves, the detailed design is inside #1720. We added a new configuration `repl-namespace-enabled` to turn on/off this feature and it's disabled by default.
- If `repl-namespace-enabled` is set to `no`, it behaves the same as the previous. All namespa... | diff --git a/kvrocks.conf b/kvrocks.conf
index d2b027cbb63..708133507d5 100644
--- a/kvrocks.conf
+++ b/kvrocks.conf
@@ -51,6 +51,14 @@ daemonize no
cluster-enabled no
+# By default, namespaces are stored in the configuration file and won't be replicated
+# to replicas. This option allows to change this behavior, ... | 6 | 2 | 1 | [{"id": "G0", "claim": "Storing all namespaces as one large JSON value under kNamespaceDBKey may become large and time-consuming with many namespaces; the reviewer suggests storing per-namespace key-values instead and, once such a schema exists, reading and writing namespaces directly through the RocksDB API rather tha... | null |
apache__kvrocks__1850 | apache/kvrocks | 1,850 | defect | 8b542005c6aeb5c42f8895638798e3e450f35c76 | 347dd1732daf9b7149ffce87b88ca3adf779be93 | Support for the JSON.CLEAR command | support JSON.CLEAR, this closes #1812
please review @mapleFU
[JSON.CLEAR command](https://redis.io/commands/json.clear)
| diff --git a/kvrocks.conf b/kvrocks.conf
index be4332543d8..e6886f1fc74 100644
--- a/kvrocks.conf
+++ b/kvrocks.conf
@@ -858,4 +858,4 @@ rocksdb.write_options.memtable_insert_hint_per_batch no
rocksdb.rate_limiter_auto_tuned yes
################################ NAMESPACE #####################################
-# nam... | 4 | 4 | 0 | [{"id": "G0", "claim": "The incidental change to the namespace.test line in kvrocks.conf should be reverted.", "category": "maintainability", "verdict": "supported", "priority": "P3", "scope": "introduced"}, {"id": "G1", "claim": "The changes to src/common/status.h, which come from clang-format version differences, sho... | null |
apache__kvrocks__1874 | apache/kvrocks | 1,874 | defect | 6836f2417ad08037f5cdb1f073c158dacf548d75 | 8c6316375db051cf977a9671e8224f0d3f22eb88 | Support for the JSON.ARRPOP command | This PR adds support for the JSON.ARRPOP command.
closes #1810. | diff --git a/src/commands/cmd_json.cc b/src/commands/cmd_json.cc
index 6c2d40cd53f..95bd20e9ab2 100644
--- a/src/commands/cmd_json.cc
+++ b/src/commands/cmd_json.cc
@@ -22,6 +22,7 @@
#include "commander.h"
#include "commands/command_parser.h"
+#include "error_constants.h"
#include "server/redis_reply.h"
#include ... | 1 | 1 | 1 | [{"id": "G0", "claim": "When the JSON.ARRPOP index is negative, it must be normalized to the real position counting from the end of the array instead of popping the first element.", "category": "correctness", "verdict": "supported", "priority": "P0", "scope": "introduced"}] | null |
apache__kvrocks__1882 | apache/kvrocks | 1,882 | defect | a79a386a71095b5a700c56b3d557cb79119618bb | ba023d19eee00c73d2c60dcc4de6bae7df5e6cb4 | Don't rewrite unchanged items into the configuration file | Currently, config rewrite will also add some default configurations like backup-dir, pidfile into the configuration file. Some of them are for compatible purposes and don't expect to be seen by users.
So we resolve this by ignoring the configuration items if they do not exist in the configuration file and the value ... | diff --git a/kvrocks.conf b/kvrocks.conf
index 7667511b401..fa36d96a2a6 100644
--- a/kvrocks.conf
+++ b/kvrocks.conf
@@ -68,7 +68,7 @@ repl-namespace-enabled no
# and dump the cluster nodes into the file if it was changed.
#
# Default: yes
-# persist-cluster-nodes-enabled yes
+persist-cluster-nodes-enabled yes
# ... | 1 | 1 | 0 | [{"id": "G0", "claim": "The new helper `ignoreIfNotModified` should be renamed because it has no operation about 'ignore' — it only checks whether the value equals the field's default — e.g. to `checkOptionIsDefault` (M001), with `isFieldValueSetToDefault` (M002) and `checkFieldValueIsDefault` (M004) offered as alterna... | null |
apache__kvrocks__2004 | apache/kvrocks | 2,004 | defect | ee41959e837a5a3023a9eb6aef4914567e9fdd64 | 32e3ef69e9991d41d39f01e8b28544def25c3994 | Implement an unify key-value iterator for Kvrocks | Currently, we need to iterate all keys in the database in different places like the cluster migration and kvrocks2redis, but don't have an iterator for this purpose. It's very error-prone to implement this in different places since Kvrocks may add a new column family in the future, and we must be careful to iterate all... | diff --git a/src/storage/iterator.cc b/src/storage/iterator.cc
new file mode 100644
index 00000000000..0dc8a6289e0
--- /dev/null
+++ b/src/storage/iterator.cc
@@ -0,0 +1,162 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distrib... | 8 | 5 | 2 | [{"id": "G0", "claim": "The PR should provide an interface, and an `Iterator` for incremental data should be implemented later.", "category": "design", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The iterator tests lack cases for the JSON and Sortedint types.", "category": "... | null |
apache__kvrocks__2434 | apache/kvrocks | 2,434 | defect | a2a3826a3b78e36089de1cc862d4f88e99034a82 | 4cc316a007f4278016591637f990a93f0223d44e | feat(search): Hnsw Vector Search Plan Operator & Executor | This PR is part of #2426
## Summary
- [x] "Pure" KNN Plan Operator + Executor (i.e. search on HNSW graph directly on disk)
- [x] "Pure" Range Query Plan Operator + Executor
1. KNN search to get `k` nearest candidates as a mini-batch initialization, ensuring each one of them is within the expected range
... | diff --git a/src/search/executors/hnsw_vector_field_knn_scan_executor.h b/src/search/executors/hnsw_vector_field_knn_scan_executor.h
new file mode 100644
index 00000000000..fc276a9555c
--- /dev/null
+++ b/src/search/executors/hnsw_vector_field_knn_scan_executor.h
@@ -0,0 +1,75 @@
+/*
+ * Licensed to the Apache Software... | 2 | 1 | 0 | [{"id": "G0", "claim": "HnswVectorFieldKnnScan::Content() renders the vector via kqir::MakeValue<kqir::NumericArray>(vector).ToString() and Dump() duplicates that expression instead of formatting the vector as a bracketed number list and reusing Content().", "category": "maintainability", "verdict": "supported", "prior... | null |
apache__kvrocks__2466 | apache/kvrocks | 2,466 | defect | f9d7297630ecbf342bbed492061acb31fbfa3fd2 | c14fc153c6e739d17f65a1c75589c1c956b4fc4e | feat(search): Hnsw Vector Search Optimizaton Pass | This PR is part of #2426
## Summary
- Add optimization pass to transform `sort by` to `knn search expr` for SQL query
- Use cost model to prioritize KNN search and range search
- Add vector range search in `Filter` executor in case that vector range search acts as the prefilter for KNN search
- Support prefil... | diff --git a/src/search/executors/filter_executor.h b/src/search/executors/filter_executor.h
index df14b29b80a..1b1febe842e 100644
--- a/src/search/executors/filter_executor.h
+++ b/src/search/executors/filter_executor.h
@@ -23,6 +23,7 @@
#include <variant>
#include "parse_util.h"
+#include "search/hnsw_indexer.h"
... | 4 | 3 | 2 | [{"id": "G0", "claim": "The transformation of a vector ORDER BY with a filter into `(KNN(k)) AND filter` cannot guarantee the LIMIT clause's semantics (users may get fewer than k records even when more satisfy the filter), so unless a better solution exists the PR should prohibit KNN search with a prefilter/hybrid quer... | null |
apache__kvrocks__2741 | apache/kvrocks | 2,741 | defect | 953de0e961bb54239287546a8d251c5d82cb0120 | aa24799093d73453d70ab8ed146a5aecf6e61b79 | feat(tdigest): add tdigest algorithm and storage encoding implementations | # Issue
- #2558
# Proposal
- #2542
# Proposed Changes
- add tdigest core algorithm support.
- add encoding and decoding method as designed.
- add core implementations for `create`, `add` and `quantile`.
- add basic unit tests for `create`, `add` and `quantile`.
# TODO List
- add more unit tests... | diff --git a/src/storage/redis_metadata.cc b/src/storage/redis_metadata.cc
index 9df1053262b..850cac39dc1 100644
--- a/src/storage/redis_metadata.cc
+++ b/src/storage/redis_metadata.cc
@@ -30,6 +30,7 @@
#include "cluster/redis_slot.h"
#include "encoding.h"
+#include "rocksdb/status.h"
#include "time_util.h"
// ... | 28 | 26 | 5 | [{"id": "G0", "claim": "TDigestMetadata::Decode's size check does not reserve space for the two encoded doubles, so a truncated input can pass validation and be read past its end.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "The tdigest data shoul... | null |
apache__kvrocks__2799 | apache/kvrocks | 2,799 | defect | 357510c88b8c63fe0f01b9ac9931024831370316 | 62af97f6edff1757147ad915f077db52acfc8b69 | feat(tdigest): add TDIGEST.CREATE and TDIGEST.INFO command | # Issue
Close #2791
# Proposed Changes
- implement `tdigest.add` command.
- implement `tdigest.info` command.
- add integration tests.
# Comment
1. redis `tdigest.info` has one property `Memory usage`, and kvrocks's data structure is not in memory, could you give me some suggestions on evaluating the mem... | diff --git a/src/commands/cmd_tdigest.cc b/src/commands/cmd_tdigest.cc
new file mode 100644
index 00000000000..9f8d3b4c0ae
--- /dev/null
+++ b/src/commands/cmd_tdigest.cc
@@ -0,0 +1,149 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file... | 8 | 8 | 2 | [{"id": "G0", "claim": "The args.size() != 2 check in CommandTDigestInfo::Parse is redundant (the command's registered arity already enforces the argument count) and should be removed.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The 'Memory u... | null |
apache__kvrocks__2873 | apache/kvrocks | 2,873 | defect | 077b41fae6bdaf4a1c7b8175f9450308da731e02 | 1fedc14b5b303cb0e9a5543a631952622471125f | fix(protocol): inline mode should allow the quoted string | This closes #2871. | diff --git a/src/common/string_util.cc b/src/common/string_util.cc
index c1e6f7e3ffe..7f9186a6397 100644
--- a/src/common/string_util.cc
+++ b/src/common/string_util.cc
@@ -276,6 +276,71 @@ std::pair<std::string, std::string> SplitGlob(std::string_view glob) {
return {prefix, ""};
}
+StatusOr<std::vector<std::str... | 10 | 8 | 3 | [{"id": "G0", "claim": "Add a test case such as `command \"a b\" \" c d \"` that exercises multiple quoted strings.", "category": "testing", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "Use C++ unescaped raw strings R\"(...)\" in the tests to make the cases clearer.", "catego... | null |
apache__kvrocks__3040 | apache/kvrocks | 3,040 | defect | 7250ebe999380ee4263b96cfd59c75321c7e95f9 | b1309e004ab52fde63c3721e00368b094ee0f95c | feat(config): allow to configure the rocksdb.sst_file_delete_rate_bytes_per_sec | PurgeObsoleteFiles will be called during compaction, flush, and similar operations, and it will be performed in the background threads (avoid-unnecessary-blocking-io is enabled).
Additionally, it may also be triggered when destroying an iterator in a user thread, in the case:
SST files will be deleted by backgrou... | diff --git a/kvrocks.conf b/kvrocks.conf
index 25172cb88d6..96e9b05bc3b 100644
--- a/kvrocks.conf
+++ b/kvrocks.conf
@@ -1066,5 +1066,16 @@ rocksdb.partition_filters yes
# Default: 0
rocksdb.max_compaction_bytes 0
+# Set the delete rate limit in bytes per second for SST files deletion.
+# zero means disable delete ... | 2 | 2 | 2 | [{"id": "G0", "claim": "A test case should be added in tests/gocase/unit/config/config_test.go to ensure the new rocksdb.sst_file_delete_rate_bytes_per_sec configuration.", "category": "testing", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "The expected error message when Con... | null |
apache__kvrocks__3084 | apache/kvrocks | 3,084 | defect | cc82eead4784d6143eb6315e03e0359d3b3e0d91 | 5b250e0268ceeddd2e026330363772fc0c1676eb | feat(search): add a compaction filter for search column family | Previously the compaction filter for search CF is just a placeholder, and now here we can replace them with a functional one. | diff --git a/src/storage/compact_filter.cc b/src/storage/compact_filter.cc
index 737dbf114c8..41a3d1fe835 100644
--- a/src/storage/compact_filter.cc
+++ b/src/storage/compact_filter.cc
@@ -24,7 +24,10 @@
#include <utility>
#include "db_util.h"
+#include "encoding.h"
#include "logging.h"
+#include "search/search_en... | 2 | 2 | 1 | [{"id": "G0", "claim": "The added comment in SearchFilter::Filter reads '// storage close the would delete the column family handler and DB', which is garbled and should be reworded.", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The new compactio... | null |
apache__kvrocks__3164 | apache/kvrocks | 3,164 | defect | df3735e99ba622c633dfc2ced3fc24b9f769e9c9 | 2042ea27f01a8608ef3e10fd0fa54e9938139fad | feat(ts): Add label-based indexing support and `TS.MGET` command | Part of #3048
Add a new CF for label-based indexing. The key format is as following:
```
+-----------+--------------+----------------+------------+------------------+--------------+---------+
| ns | index_type | label_key_size | label_key | label_value_size | label_value | key | => null
| (1+Xbytes... | diff --git a/src/commands/cmd_timeseries.cc b/src/commands/cmd_timeseries.cc
index 636b4110b61..83c8748e9df 100644
--- a/src/commands/cmd_timeseries.cc
+++ b/src/commands/cmd_timeseries.cc
@@ -126,6 +126,17 @@ std::string FormatCreateRuleResAsRedisReply(TSCreateRuleResult res) {
return "";
}
+std::string FormatTS... | 7 | 6 | 3 | [{"id": "G0", "claim": "The filter is used by both MGET and MRANGE, so TSMGetOption::FilterOption may not be a good name for it.", "category": "design", "verdict": "opposed", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "labels_equals {\"label\", empty set} could represent labels_not_exists, so that ... | null |
apache__kvrocks__3296 | apache/kvrocks | 3,296 | defect | 65db00a86bc9031f4d974eb0b6f1893bd126c524 | a02dc62c04895ab7a4809cafd7942b30d519fbb6 | feat(tdigest): add the support of TDIGEST.BYRANK and TDIGEST.BYREVRANK command | This PR close #3064 and #3065
1. Add TDIGEST.BYRANK and TDIGEST.BYREVRANK command implementation
2. Add Related cpp and go unit tests | diff --git a/src/commands/cmd_tdigest.cc b/src/commands/cmd_tdigest.cc
index a5479cb124b..43d74761d7b 100644
--- a/src/commands/cmd_tdigest.cc
+++ b/src/commands/cmd_tdigest.cc
@@ -238,6 +238,76 @@ class CommandTDigestRevRank : public TDigestRankCommand<true> {};
class CommandTDigestRank : public TDigestRankCommand<... | 11 | 10 | 0 | [{"id": "G0", "claim": "The second test function reuses the name \"tdigest.byrank and tdigest.byrevrank with duplicate values\" (lines 861 and 920) and should be renamed, e.g. to \"tdigest.byrank and tdigest.byrevrank with unordered duplicate values\", to match its key name.", "category": "testing", "verdict": "support... | null |
apache__kvrocks__3312 | apache/kvrocks | 3,312 | defect | a320c90205bbe7a289e197470cd380a41e81f357 | 77995249408d9d1a7929d048e08c674abef7b911 | feat(tdigest): implement TDIGEST.TRIMMED_MEAN command | Fixes #3066 | diff --git a/src/commands/cmd_tdigest.cc b/src/commands/cmd_tdigest.cc
index f839a3f7f1a..3692e2ff9c2 100644
--- a/src/commands/cmd_tdigest.cc
+++ b/src/commands/cmd_tdigest.cc
@@ -492,6 +492,57 @@ class CommandTDigestMerge : public Commander {
TDigestMergeOptions options_;
};
+class CommandTDigestTrimmedMean : p... | 8 | 7 | 3 | [{"id": "G0", "claim": "The line `auto dump_centroids = DummyCentroids(metadata, centroids);` appears to have a compile error in CI and the commit cannot pass CI, so the author should check and fix it.", "category": "correctness", "verdict": "supported", "priority": "P0", "scope": "introduced"}, {"id": "G1", "claim": "... | null |
apache__kvrocks__3318 | apache/kvrocks | 3,318 | defect | c2c5d094d4335c4951f88e7de319d78e1bf5b3b8 | 73d86e709914fa77c3d5c6b255ca1eee42886232 | feat(string): Add to Support MSETEX Command | ## Issue
closes #3307
## Description
In redis, it supports MSETEX which supports MSET with TTL options from v8.4.0.
Syntax of `MSETEX` is below.
```
MSETEX numkeys key value [key value ...] [NX | XX] [EX seconds |
PX milliseconds | EXAT unix-time-seconds |
PXAT unix-time-milliseconds | KEEPTTL]
```
Thi... | diff --git a/src/commands/cmd_string.cc b/src/commands/cmd_string.cc
index a13ca38b213..66addb2fdea 100644
--- a/src/commands/cmd_string.cc
+++ b/src/commands/cmd_string.cc
@@ -421,7 +421,7 @@ class CommandMSet : public Commander {
kvs.emplace_back(StringPair{args_[i], args_[i + 1]});
}
- auto s = stri... | 2 | 1 | 0 | [{"id": "G0", "claim": "The `flag != nullptr` check in `String::MSet` can be removed by assuming flag is always non-null.", "category": "design", "verdict": "opposed", "priority": "P3", "scope": "introduced"}, {"id": "G1", "claim": "There are duplicated IO accesses in `Exists` and `GetExpireTime`; they could be unified... | null |
apache__kvrocks__3357 | apache/kvrocks | 3,357 | defect | 4404eb7e9662e92d2d3e304ada73322f50fa84a0 | 696eaf789f7feef68425c81e53d5e1bc878805fd | fix(replication): prevent WAL exhaustion from slow consumers | The replication feed thread could block indefinitely when sending data to a slow replica. If the replica wasn't consuming data fast enough, the TCP send buffer would fill and the feed thread would block on write() with no timeout. During this time, WAL files would rotate and be pruned, leaving the replica's sequence un... | diff --git a/src/cluster/replication.cc b/src/cluster/replication.cc
index bb211095c51..3b21ef3845c 100644
--- a/src/cluster/replication.cc
+++ b/src/cluster/replication.cc
@@ -63,7 +63,9 @@ FeedSlaveThread::FeedSlaveThread(Server *srv, redis::Connection *conn, rocksdb::
next_repl_seq_(next_repl_seq),
req... | 7 | 5 | 2 | [{"id": "G0", "claim": "The new SockSendWithTimeout functions should check that timeout_ms is > 0 before using it.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "SockSendWithTimeout could reuse the existing WriteImpl helper to simplify the implement... | null |
apache__kvrocks__3412 | apache/kvrocks | 3,412 | defect | 784344e3c34db8d9df2065f42f998af46dae8d09 | 1aba8fb2c55e771c7ca1296e4b330580d92bb39a | fix(tdigest): merge into existing dest without OVERRIDE | WIP: fix TDIGEST.MERGE to match Redis behavior
Issue: #3410
When destination key already exists without OVERRIDE flag:
- Redis: merge dest + sources together
- Kvrocks (before): return error
Changes:
1. Remove error return when dest exists without OVERRIDE
2. Read dest centroids and add to merge list
3. A... | diff --git a/src/types/redis_tdigest.cc b/src/types/redis_tdigest.cc
index dcdc0f44c34..0d2f3091c33 100644
--- a/src/types/redis_tdigest.cc
+++ b/src/types/redis_tdigest.cc
@@ -437,9 +437,8 @@ rocksdb::Status TDigest::Merge(engine::Context& ctx, const Slice& dest_digest,
return status;
} else if (status.ok()) {... | 5 | 5 | 2 | [{"id": "G0", "claim": "The guard that avoids merging the destination twice when dest is also in the source list is not covered by the updated test, so add a test case like TDIGEST.MERGE dest 3 dest src1 src2 (and/or with OVERRIDE) asserting observations/quantiles are not double-counted.", "category": "testing", "verdi... | null |
apache__kvrocks__369 | apache/kvrocks | 369 | defect | 5af6c7080022e6befa5f6efed6d4ce7c4b8ec6e4 | 74f15e0955adbb4fa493f73823e92bed5e67ee5c | Implement the evalsha and script command | This PR implements the `evalsha` and `script`(except debug and kill subcommand) command, `script kill` and Lua time limit would be supported in the next one to keep the PR simple. | diff --git a/CMakeLists.txt b/CMakeLists.txt
index 9e1ee00bee3..8e92507a358 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -158,7 +158,8 @@ target_sources(kvrocks PRIVATE
src/scripting.h
src/sha1.cc
src/sha1.h
- )
+ src/rand.cc
+ src/rand.h)
# kvrocks2redis sync t... | 3 | 3 | 1 | [{"id": "G0", "claim": "The lua scripts should be stored in rocksdb as key-value pairs in the propagate column family instead of an in-memory map, because the map may cost much more memory and would let replication handle scripts without special handling.", "category": "design", "verdict": "supported", "priority": "P1"... | null |
apache__kvrocks__653 | apache/kvrocks | 653 | defect | c7299353d64ae988a44634791b229827c7e4e19b | 67ac7a5bb3e84e812c7d47b2c7ee7824a532ba83 | Fix compile warnings in kvrocks | ~~close 639~~
~~fix problem found by tsan.~~
Thanks @PragmaTwice .
Fix warning.
Add more `gitignore` (I think them also are needed by others.) | diff --git a/.gitignore b/.gitignore
index a3c4eb3cc10..c7cb269ce89 100644
--- a/.gitignore
+++ b/.gitignore
@@ -31,17 +31,21 @@
*.out
*.app
-.idea/
-cmake-build-debug
*.o
*.pyc
*.swp
*.swo
.DS_Store
-kvrocks
version.h
-Makefile.dep
-make_config.mk
+
+.idea/
.vscode
+.cache
+
+kvrocks
kvrocks2redis
+
build... | 5 | 3 | 0 | [{"id": "G0", "claim": "raiseError() is an unreturned function whose return type should reasonably be void, but the author is deliberately not handling it in this PR and defers it to a future ticket.", "category": "design", "verdict": "uncertain", "priority": "P2", "scope": "pre_existing"}, {"id": "G1", "claim": "If th... | null |
apache__kvrocks__882 | apache/kvrocks | 882 | defect | 9b3938ed0c52934b61d14b2495c246705d4f02bd | 4605365da461ad92dbb059cfb60a4ad9254507d4 | Support DISK Command | It closes #874 | diff --git a/src/redis_cmd.cc b/src/redis_cmd.cc
index 16b00e93856..11ac1d0e772 100644
--- a/src/redis_cmd.cc
+++ b/src/redis_cmd.cc
@@ -35,6 +35,7 @@
#include "redis_hash.h"
#include "redis_bitmap.h"
#include "redis_list.h"
+#include "redis_disk.h"
#include "redis_reply.h"
#include "redis_request.h"
#include "re... | 13 | 10 | 1 | [{"id": "G0", "claim": "The reviewer asks the author to reduce/eliminate the many duplicate code snippets repeated across almost every method of src/redis_disk.cc, suggesting a shared helper or implementing the type dispatch in a switch.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope"... | null |
apache__kvrocks__897 | apache/kvrocks | 897 | defect | d526d6a8333b71cdb87ef6892934f15c80c5645d | 7aa679f48e368cd08251936a573c230a50ccb2eb | Replace std::stol with ParseInt | It closes #896 | diff --git a/src/redis_cmd.cc b/src/redis_cmd.cc
index 8943dd0c7cd..735b066acf2 100644
--- a/src/redis_cmd.cc
+++ b/src/redis_cmd.cc
@@ -488,16 +488,12 @@ class CommandSet : public Commander {
if (ttl_ <= 0) return Status(Status::RedisParseErr, errInvalidExpireTime);
} else if (opt == "px" && !ttl_ && !... | 13 | 12 | 0 | [{"id": "G0", "claim": "The IsOK() checks on the ParseInt results can be written as `if (!parseResult)` using the StatusOr's operator bool.", "category": "maintainability", "verdict": "supported", "priority": "P3", "scope": "introduced"}, {"id": "G1", "claim": "The line `int64_t offset_arg = offset_arg = parseResult.Ge... | null |
apache__kylin__1555 | apache/kylin | 1,555 | defect | 76492b5b0eea24aba0665a5b9b76476abe547c40 | dfb192eb672c2238208c18f4ec10d90f5a0465ef | Fix storage clean up tool | ## Proposed changes
Describe the big picture of your changes here to communicate to the maintainers why we should accept this pull request. If it fixes a bug or resolves a feature request, be sure to link to that issue.
## Types of changes
What types of changes does your code introduce to Kylin?
_Put an `x` i... | diff --git a/server-base/src/main/java/org/apache/kylin/rest/job/StorageCleanupJob.java b/server-base/src/main/java/org/apache/kylin/rest/job/StorageCleanupJob.java
index cd7f9c554db..b3895bcb2af 100644
--- a/server-base/src/main/java/org/apache/kylin/rest/job/StorageCleanupJob.java
+++ b/server-base/src/main/java/org/... | 1 | 1 | 0 | [{"id": "G0", "claim": "The cleanup should pass a PathFilter to fs.listStatus so that 'protectedDir' entries are filtered out there instead of being skipped with an inline check.", "category": "design", "verdict": "supported", "priority": "P2", "scope": "introduced"}] | null |
apache__kylin__1585 | apache/kylin | 1,585 | defect | b428f1e1ab6a48101bec03e515d135c57af32878 | 51f1ff5c76de9df7b1a344d09dc23d080b4cb827 | KYLIN-4906 Support query/job server dynamic register and discovery in kylin4 | … kylin4
(cherry picked from commit fa37255b15bdf69e347ec747baf0731ce6634b39)
(cherry picked from commit fa37255b15bdf69e347ec747baf0731ce6634b39)
(cherry picked from commit fa37255b15bdf69e347ec747baf0731ce6634b39)
## Proposed changes
Describe the big picture of your changes here to communicate to the maint... | diff --git a/core-common/pom.xml b/core-common/pom.xml
index 093d5ce5da6..ca245c2b930 100644
--- a/core-common/pom.xml
+++ b/core-common/pom.xml
@@ -49,6 +49,12 @@
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-databind</artifactId>
</dependency>
+ <dependenc... | 1 | 1 | 0 | [{"id": "G0", "claim": "The comment 'this jar was absent from hbase lib, so compile it' in core-common/pom.xml can be deleted because kylin4 is removing the hbase dependency.", "category": "maintainability", "verdict": "supported", "priority": "P3", "scope": "introduced"}] | null |
apache__kylin__1586 | apache/kylin | 1,586 | defect | b428f1e1ab6a48101bec03e515d135c57af32878 | 140c609645124e65c97308a2fa0bf13ffacccf20 | KYLIN-4905 Support limit .. offset ... in spark query engine | ## Proposed changes
Describe the big picture of your changes here to communicate to the maintainers why we should accept this pull request. If it fixes a bug or resolves a feature request, be sure to link to that issue.
## Types of changes
What types of changes does your code introduce to Kylin?
_Put an `x` i... | diff --git a/kylin-spark-project/kylin-spark-query/src/main/scala/org/apache/kylin/query/runtime/plans/LimitPlan.scala b/kylin-spark-project/kylin-spark-query/src/main/scala/org/apache/kylin/query/runtime/plans/LimitPlan.scala
index beb4e91f788..f5ff28553d0 100644
--- a/kylin-spark-project/kylin-spark-query/src/main/sc... | 2 | 2 | 1 | [{"id": "G0", "claim": "Add a detailed comment to OLAPTableScan.java explaining why the SortProjectTransposeRule rule needs to be removed.", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "Please add a test case for this change, for example a test ca... | null |
apache__kylin__1606 | apache/kylin | 1,606 | defect | 8a79bcea033aaeba8d8115cbe0c6af7ee20b1253 | 3823cc9a7c35d838e970f2d7fcd2e9fa28612aab | KYLIN-4879 Fix the function of remove sql comments | ## Proposed changes
Describe the big picture of your changes here to communicate to the maintainers why we should accept this pull request. If it fixes a bug or resolves a feature request, be sure to link to that issue.
## Types of changes
What types of changes does your code introduce to Kylin?
_Put an `x` i... | diff --git a/pom.xml b/pom.xml
index 1b05dafd7b5..ed14a736a0b 100644
--- a/pom.xml
+++ b/pom.xml
@@ -1493,6 +1493,12 @@
<bundledSignature>jdk-deprecated</bundledSignature>
<!--<bundledSignature>jdk-non-portable</bundledSignature>-->
</bundledSignatures>
+ <e... | 2 | 2 | 0 | [{"id": "G0", "claim": "Remove the commented-out dead line '// return new SqlCommentParser(sql).removeCommentSql().trim();'.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "Use log4j (a logger) instead of e.printStackTrace() to print the e... | null |
apache__kylin__1626 | apache/kylin | 1,626 | defect | ca0801201a4a5b3a78dd6fac788cbc5bde7e2bbd | 70d06907e3067e985c0579e1992db611a733c9ca | [KYLIN-4554] validate filter condition on model saving | verify filter condition using the following login
1 select * from tableName where {filterCondition} pass calcite parse
2 all column in filter condition must be model table column
| diff --git a/core-job/src/main/java/org/apache/kylin/job/JoinedFormatter.java b/core-job/src/main/java/org/apache/kylin/job/JoinedFormatter.java
index 3f19ce966cc..20e0f475035 100644
--- a/core-job/src/main/java/org/apache/kylin/job/JoinedFormatter.java
+++ b/core-job/src/main/java/org/apache/kylin/job/JoinedFormatter.... | 4 | 4 | 4 | [{"id": "G0", "claim": "The patch should also handle the dynamic variable case, e.g. a filter like date_str>='${start_date}' and date_str<'${end_date}'.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "Adding id.names.get(0) for every SqlIdentifier ma... | null |
apache__kylin__1628 | apache/kylin | 1,628 | defect | 6153889ce1b1fad2c409364e77ec471166654551 | 4952353084da2e220eb0dc00158bc823b4287c21 | [KYLIN-4554] validate filter condition on model saving | verify filter condition using the following login
1 select * from tableName where {filterCondition} pass calcite parse
2 all column in filter condition must be model table column | diff --git a/core-job/src/main/java/org/apache/kylin/job/JoinedFormatter.java b/core-job/src/main/java/org/apache/kylin/job/JoinedFormatter.java
index 3f19ce966cc..20e0f475035 100644
--- a/core-job/src/main/java/org/apache/kylin/job/JoinedFormatter.java
+++ b/core-job/src/main/java/org/apache/kylin/job/JoinedFormatter.... | 1 | 1 | 0 | [{"id": "G0", "claim": "The method name doubleQuotaKeywordDefault misspells 'Quote' as 'Quota' and should be doubleQuoteKeywordDefault.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}] | null |
apache__kylin__1662 | apache/kylin | 1,662 | defect | c94374569a5534a92ab305898698a3943c89c7ef | 826a722f0dbe8f27649ecec726c5973e95cc2629 | KYLIN-5011 Detect and scatter skewed data in dict encoding step | ## Proposed changes
Describe the big picture of your changes here to communicate to the maintainers why we should accept this pull request. If it fixes a bug or resolves a feature request, be sure to link to that issue.
## Types of changes
What types of changes does your code introduce to Kylin?
_Put an `x` i... | diff --git a/core-common/src/main/java/org/apache/kylin/common/KylinConfigBase.java b/core-common/src/main/java/org/apache/kylin/common/KylinConfigBase.java
index 9b17dc199cd..41efa528042 100644
--- a/core-common/src/main/java/org/apache/kylin/common/KylinConfigBase.java
+++ b/core-common/src/main/java/org/apache/kylin... | 6 | 6 | 1 | [{"id": "G0", "claim": "The config key `detect.data.skew.in.dict.encoding` should be renamed to something like `kylin.dictionary.data.skew.detect.in.encoding-enabled` for a better name.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The sample-r... | null |
apache__kylin__1694 | apache/kylin | 1,694 | defect | 2e038f5314f435a0200829f6095755b84ae1cd8f | 724f119324dff060068626b1a3ad5eb61d8941eb | fix bug | This reverts commit 676efd7c
## Proposed changes
Describe the big picture of your changes here to communicate to the maintainers why we should accept this pull request. If it fixes a bug or resolves a feature request, be sure to link to that issue.
## Types of changes
What types of changes does your code in... | diff --git a/core-common/src/main/java/org/apache/kylin/common/JDBCConnectionUtils.java b/core-common/src/main/java/org/apache/kylin/common/JDBCConnectionUtils.java
new file mode 100644
index 00000000000..d5e5b6eacc9
--- /dev/null
+++ b/core-common/src/main/java/org/apache/kylin/common/JDBCConnectionUtils.java
@@ -0,0 ... | 3 | 1 | 0 | [{"id": "G0", "claim": "The new getter getJdbcAllowedSchema should instead be named getAdditionalJdbcAllowedSchema.", "category": "maintainability", "verdict": "uncertain", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The test sets kylin.jdbc.url.allowed.properties to a value that differs from Kylin... | null |
apache__kylin__1699 | apache/kylin | 1,699 | defect | 27d9ee032751aee36a1f4b6d6e615f41ac94eed2 | 92375402b9a50f80392b7d08cdfd3141ba7357a5 | Fix IT | ## Proposed changes
Describe the big picture of your changes here to communicate to the maintainers why we should accept this pull request. If it fixes a bug or resolves a feature request, be sure to link to that issue.
## Types of changes
What types of changes does your code introduce to Kylin?
_Put an `x` i... | diff --git a/kylin-spark-project/kylin-spark-common/src/main/spark31/org/apache/spark/sql/execution/KylinFileSourceScanExec.scala b/kylin-spark-project/kylin-spark-common/src/main/spark31/org/apache/spark/sql/execution/KylinFileSourceScanExec.scala
index 957944b0520..b924f3afd8e 100644
--- a/kylin-spark-project/kylin-s... | 1 | 1 | 1 | [{"id": "G0", "claim": "In CrossDateTimeUtils, daysToMillis should use DateTimeUtils.microsToMillis(DateTimeUtils.daysToMicros(days, DEFAULT_TZ_ID)) instead of dividing by 1000, and millisToDays should use DateTimeUtils.microsToDays(DateTimeUtils.millisToMicros(millis), DEFAULT_TZ_ID) instead of multiplying by 1000.", ... | null |
apache__kylin__1933 | apache/kylin | 1,933 | defect | 5ae47e18d56d1537863fadb805e069a88f780997 | 11c95dccc62f73f71ea9b4888adb9a60c62a1252 | KYLIN-5226 fix wrong name and classpath in shell in kylin5.0 | ## Proposed changes
Fix some wrong classpath in .sh file at build/bin of kylin5.0.
## Types of changes
- [x] Bugfix (non-breaking change which fixes an issue)
## Checklist
- [x] I have create an issue on [Kylin's jira](https://issues.apache.org/jira/browse/KYLIN-5226), and have described the bug there in... | diff --git a/build/bin/admin-tool.sh b/build/bin/admin-tool.sh
index 50c80dc059b..980d05e892f 100644
--- a/build/bin/admin-tool.sh
+++ b/build/bin/admin-tool.sh
@@ -45,7 +45,7 @@ if [[ "$1" == "admin-password-reset" ]]; then
exit 1
fi
- ${KYLIN_HOME}/bin/kylin.sh org.apache.kylin.tool.security.KapPas... | 1 | 1 | 0 | [{"id": "G0", "claim": "build/bin/upgrade.sh can be removed because it is useless now.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "pre_existing"}] | null |
apache__kylin__1969 | apache/kylin | 1,969 | defect | 9c8484bcc701636097918ff865857d7f3f744c89 | 3d05aa68974004c3bd72ddb4b01da00c32ca6db8 | Kylin 5256 Add a cache for the system property get by the optional config in KylinConfigBase | ## Proposed changes
Add a cache for the system property get by the optional config in KylinConfigBase
## Branch to commit
- [ ] Branch **kylin3** for v2.x to v3.x
- [ ] Branch **kylin4** for v4.x
- [x] Branch **kylin5** for v5.x
## Types of changes
What types of changes does your code introduce to Kylin?... | diff --git a/src/common-server/src/test/java/org/apache/kylin/rest/controller/NEpochControllerTest.java b/src/common-server/src/test/java/org/apache/kylin/rest/controller/NEpochControllerTest.java
index d2c70b69106..83eb177b76e 100644
--- a/src/common-server/src/test/java/org/apache/kylin/rest/controller/NEpochControll... | 6 | 3 | 3 | [{"id": "G0", "claim": "Relying on ConcurrentHashMap.put()'s default return logic is not a good idea because of the null value, and a setXXX method usually should not return something (setSystemProperty should not return the old value).", "category": "design", "verdict": "uncertain", "priority": "P2", "scope": "introdu... | null |
apache__kylin__2013 | apache/kylin | 2,013 | defect | 35e1487e57cc43bba5e592dfcb4c41a2fb1e8a8b | b1fa286a4f09faad33ae0ba2bf39d750e6cbe123 | KYLIN-5246 long running job's log staying in mem, may cause job serve… | …r oom.
## Proposed changes
long running job's log staying in mem, may cause job server oom.
## Branch to commit
- [ ] Branch **kylin3** for v2.x to v3.x
- [x] Branch **kylin4** for v4.x
- [ ] Branch **kylin5** for v5.x
## Types of changes
What types of changes does your code introduce to Kylin?
_Put... | diff --git a/core-common/src/main/java/org/apache/kylin/common/util/CliCommandExecutor.java b/core-common/src/main/java/org/apache/kylin/common/util/CliCommandExecutor.java
index 83f30ab5d3b..a10ffba73a5 100644
--- a/core-common/src/main/java/org/apache/kylin/common/util/CliCommandExecutor.java
+++ b/core-common/src/ma... | 1 | 1 | 1 | [{"id": "G0", "claim": "Replacing the returned command output with a fixed info string changes runNativeCommand's behavior and may cause more issues; add a max cap to the result buffer (e.g. the last 1K or 10K characters) instead.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduc... | null |
apache__kylin__2039 | apache/kylin | 2,039 | defect | 140f2792b9bf7ccfb4f560a52f805434800af02b | 81ec7305ed00262164bafe5ea2734752335cc034 | KYLIN-5308 add transaction timeout when epoch renew | Co-authored-by: Jiale He <jialehebo55@gmail.com>
## Proposed changes
Describe the big picture of your changes here to communicate to the maintainers why we should accept this pull request. If it fixes a bug or resolves a feature request, be sure to link to that issue.
## Branch to commit
- [ ] Branch **kylin3... | diff --git a/src/core-common/src/main/java/org/apache/kylin/common/KylinConfigBase.java b/src/core-common/src/main/java/org/apache/kylin/common/KylinConfigBase.java
index 3b94b3b0244..8498eba0e6d 100644
--- a/src/core-common/src/main/java/org/apache/kylin/common/KylinConfigBase.java
+++ b/src/core-common/src/main/java/... | 2 | 2 | 0 | [{"id": "G0", "claim": "Asks why the pull request removed the `public` modifier from FileEpochStoreTest, questioning the visibility change.", "category": "maintainability", "verdict": "supported", "priority": "P3", "scope": "introduced"}, {"id": "G1", "claim": "Asks whether AbstractEpochStoreTest is a genuinely new fil... | null |
apache__kylin__443 | apache/kylin | 443 | defect | 6bb8155cd1652e5d114d39735fd0920d0163e035 | 2d9d611e184b754e5f6ee845a15f66b00d424105 | KYLIN-3759 & KYLIN-3744 | The purpose of this PR is as following:
1. Fix a small bug in mapreduce job when lambda is enabled.
2. Add enhancement for reassign of Coordinator
3. Add unit test for for reassign of Coordinator
4. Add some javadoc | diff --git a/assembly/pom.xml b/assembly/pom.xml
index c1dcf92083a..4f4b5520867 100644
--- a/assembly/pom.xml
+++ b/assembly/pom.xml
@@ -63,6 +63,11 @@
<artifactId>kylin-engine-spark</artifactId>
</dependency>
+ <dependency>
+ <groupId>org.apache.kylin</groupId>
+ <a... | 4 | 3 | 1 | [{"id": "G0", "claim": "Coordinator.getInstance() should drop the method-level synchronized and initialization should be deferred (late initialization) so the class can be unit tested.", "category": "design", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "When needRollback is e... | null |
apache__kylin__507 | apache/kylin | 507 | defect | c0b9e5142eb185c092143b7aa05af0d51f1b2cfd | 2938ac759f273b8a1844ea2697c102ec352cb15c | KYLIN-3857 Disable quote when needed | 1. add quote for create table ddl
2. add switch for turn off quote | diff --git a/core-common/src/main/java/org/apache/kylin/common/KylinConfigBase.java b/core-common/src/main/java/org/apache/kylin/common/KylinConfigBase.java
index 81979dc4f33..e43b0393d6f 100644
--- a/core-common/src/main/java/org/apache/kylin/common/KylinConfigBase.java
+++ b/core-common/src/main/java/org/apache/kylin... | 2 | 2 | 0 | [{"id": "G0", "claim": "The config key \"kylin.source.hive.enable.quote\" should follow the project's naming convention, e.g. \"kylin.source.hive.quote-enabled\" like \"kylin.engine.spark.sanity-check-enabled\".", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G... | null |
apache__kylin__757 | apache/kylin | 757 | defect | db184be59f99b8dae7fab5f1aa857ed00d937135 | 270af01c28f5dc62be075a708e5b9c541b02f890 | KYLIN-3917: Add max segment merge span to cleanup intermediate data of cube building | See: https://issues.apache.org/jira/browse/KYLIN-3917 | diff --git a/core-common/src/main/java/org/apache/kylin/common/KylinConfigBase.java b/core-common/src/main/java/org/apache/kylin/common/KylinConfigBase.java
index 13d90001524..4741bdb7eed 100644
--- a/core-common/src/main/java/org/apache/kylin/common/KylinConfigBase.java
+++ b/core-common/src/main/java/org/apache/kylin... | 2 | 1 | 1 | [{"id": "G0", "claim": "removeMaxSpanSegment may remove an inner segment (e.g. with 20190101-20190102, 20190102-20190210, 20190110-20190211 it removes the middle one), leaving two non-adjacent segments that would then be attempted to merge.", "category": "correctness", "verdict": "opposed", "priority": "P1", "scope": "... | null |
apache__kylin__760 | apache/kylin | 760 | defect | db184be59f99b8dae7fab5f1aa857ed00d937135 | a149b737837086cd3558f6acbb700d7d3256a44e | KYLIN-4097: Throw exception when too many dict slice evictions in AppendTrieDictionary | See: https://issues.apache.org/jira/browse/KYLIN-4097 | diff --git a/core-common/src/main/java/org/apache/kylin/common/KylinConfigBase.java b/core-common/src/main/java/org/apache/kylin/common/KylinConfigBase.java
index 13d90001524..5ec2cb7190c 100644
--- a/core-common/src/main/java/org/apache/kylin/common/KylinConfigBase.java
+++ b/core-common/src/main/java/org/apache/kylin... | 2 | 2 | 1 | [{"id": "G0", "claim": "The new getDictionarySliceEvicationThreshold config getter should be located in the \"DICTIONARY & SNAPSHOT\" domain section of KylinConfigBase rather than appended after the health-check getters at the end of the file.", "category": "maintainability", "verdict": "supported", "priority": "P2", "... | null |
apache__kylin__987 | apache/kylin | 987 | defect | 4f9406edc21b8f7b6cf098780d4940e0c2893435 | 3e988efa7e388acea08a283ac7103b29dbf96aa9 | KYLIN-4294: Add http api for metrics | 1. Expose metrics through http api to facilitate the integration of some external monitoring components, such as tsdb
2. add a python script for tcollector | diff --git a/build/tcollector/kylin_tcollector_metrice.py b/build/tcollector/kylin_tcollector_metrice.py
new file mode 100644
index 00000000000..7e493a35645
--- /dev/null
+++ b/build/tcollector/kylin_tcollector_metrice.py
@@ -0,0 +1,94 @@
+#!/usr/bin/python
+#
+# Licensed to the Apache Software Foundation (ASF) under o... | 3 | 2 | 2 | [{"id": "G0", "claim": "The author should submit a doc (better with screenshots) introducing how to monitor Kylin by TimeSeries DB in the way this PR uses.", "category": "documentation", "verdict": "uncertain", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "Fetching the metrics via the Python collecto... | null |
apache__linkis__2371 | apache/linkis | 2,371 | defect | 30312966a8774e06006b3eb362d3da3df9398a53 | 525f15ad7bae0b88a4682911e0195662c991ffba | fix(linkis-rpc): messageUtils.orderIsLast bug, and refactor some code | ### What is the purpose of the change
Related issues: ##2370
### Brief change log
(for example:)
- refactor some code
- add some test for MessageUtils
### Verifying this change
This change added tests and can be verified as follows:
(example:)
- Added tests for MessageUtils
### Does this pull reques... | diff --git a/linkis-commons/linkis-common/src/main/java/org/apache/linkis/common/exception/LinkisException.java b/linkis-commons/linkis-common/src/main/java/org/apache/linkis/common/exception/LinkisException.java
index 002ce1df507..cf3b93bc635 100644
--- a/linkis-commons/linkis-common/src/main/java/org/apache/linkis/co... | 1 | 1 | 1 | [{"id": "G0", "claim": "getServiceMethod should check whether the parameters array is empty and, if empty, throw an exception instead of unconditionally reading parameters[0].", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}] | null |
apache__linkis__3473 | apache/linkis | 3,473 | defect | 8525d2d831660860064a442635e5fbe35a88a22a | aa9ac9bc588b2c9151f8db28fef732f7284622e8 | jdbc module errorcode optimization and documentation | jdbc module errorcode optimization and documentation
Related issues: https://github.com/apache/incubator-linkis/issues/3385 | diff --git a/docs/errorcode/linkis-engineplugin-jdbc.md b/docs/errorcode/linkis-engineplugin-jdbc.md
new file mode 100644
index 00000000000..50d18435d22
--- /dev/null
+++ b/docs/errorcode/linkis-engineplugin-jdbc.md
@@ -0,0 +1,9 @@
+## linkis-engineplugin-jdbc errorcode
+
+
+| 模块名(服务名) | 错误码 | 描述 | module |
+| ------... | 1 | 1 | 1 | [{"id": "G0", "claim": "The JDBCParamsIllegalException thrown in getJdbcUsername should use the errorcode enum's getErrorDesc() instead of passing a hardcoded inline message string.", "category": "design", "verdict": "supported", "priority": "P1", "scope": "introduced"}] | null |
apache__linkis__3505 | apache/linkis | 3,505 | defect | 92921e9eb03f5694253307ca0ec534b37f61ee9f | d09436e49a5e1af294f42d1d0ab555d96dcd5f56 | Add new interface for Qualitis | <!--
Thank you for sending the PR! We appreciate you spending the time to work on these changes.
You can learn more about contributing to Apache Linkis here: https://linkis.apache.org/community/how-to-contribute
Happy contributing!
-->
### What is the purpose of the change
The Qualitis wanted an interface to ... | diff --git a/linkis-public-enhancements/linkis-datasource/linkis-datasource-manager/server/src/main/java/org/apache/linkis/datasourcemanager/core/dao/DataSourceDao.java b/linkis-public-enhancements/linkis-datasource/linkis-datasource-manager/server/src/main/java/org/apache/linkis/datasourcemanager/core/dao/DataSourceDa... | 3 | 2 | 0 | [{"id": "G0", "claim": "The operation name passed to ModuleUserUtils.getOperationUser in insertJsonEnv should be \"insertJsonEnv\", not \"rollBackEnginePlugin\".", "category": "correctness", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The operation name passed to ModuleUserU... | null |
apache__linkis__3515 | apache/linkis | 3,515 | defect | 11ccae109721904a6285a3ad2eba77fb1d351b10 | d675d6182cc57b6eb98d87bdfc3edbebbdf5366b | Dev 1.3.1 linkis jobhistory test | <!--
Thank you for sending the PR! We appreciate you spending the time to work on these changes.
You can learn more about contributing to Apache Linkis here: https://linkis.apache.org/community/how-to-contribute
Happy contributing!
-->
### What is the purpose of the change
EngineConn-Core defines the the abst... | diff --git a/linkis-public-enhancements/linkis-jobhistory/src/main/java/org/apache/linkis/jobhistory/dao/impl/JobHistoryMapper.xml b/linkis-public-enhancements/linkis-jobhistory/src/main/java/org/apache/linkis/jobhistory/dao/impl/JobHistoryMapper.xml
index 7c0ea434fe1..6eb48f122e5 100644
--- a/linkis-public-enhancement... | 1 | 1 | 0 | [{"id": "G0", "claim": "The instance host 'bd078' used in the new test fixtures should be renamed to '127.0.0.1'.", "category": "correctness", "verdict": "supported", "priority": "P2", "scope": "introduced"}] | null |
apache__linkis__3688 | apache/linkis | 3,688 | defect | dcbfa964719198e1160c422fb3231d0034d3cb99 | 7ef9bc48821d89ca0773d550dfe048b4333c089e | fix bml project dao test | **Two unit test functions fail to compile**

| diff --git a/linkis-public-enhancements/linkis-bml/linkis-bml-server/src/main/java/org/apache/linkis/bml/dao/impl/BmlProjectMapper.xml b/linkis-public-enhancements/linkis-bml/linkis-bml-server/src/main/java/org/apache/linkis/bml/dao/impl/BmlProjectMapper.xml
index ff28b0a1824..83f8472a0dd 100644
--- a/linkis-public-enh... | 1 | 1 | 0 | [{"id": "G0", "claim": "The DML insert statements should be grouped together after all the DDL statements in create.sql instead of being interleaved between the CREATE TABLE statements.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}] | null |
apache__linkis__4239 | apache/linkis | 4,239 | defect | e36a2bcb037cf69dd4efe18de57c53f073a16c8e | 5c097518fc45293e27aa982218a59f4f09969d20 | Code supplement | <!--
Thank you for sending the PR! We appreciate you spending the time to work on these changes.
You can learn more about contributing to Apache Linkis here: https://linkis.apache.org/community/how-to-contribute
Happy contributing!
-->
### What is the purpose of the change
fix missing code
### Related iss... | diff --git a/linkis-commons/linkis-storage/src/main/scala/org/apache/linkis/storage/excel/StorageExcelWriter.scala b/linkis-commons/linkis-storage/src/main/scala/org/apache/linkis/storage/excel/StorageExcelWriter.scala
index 2aff4af6171..8d0f0bdde72 100644
--- a/linkis-commons/linkis-storage/src/main/scala/org/apache/l... | 1 | 1 | 0 | [{"id": "G0", "claim": "The test mains should use http://127.0.0.1 (localhost) gateway URLs instead of the hardcoded internal cluster IPs this PR put in FlinkOnceJobTest, SeatunnelOnceJobTest and SparkOnceJobTest.", "category": "correctness", "verdict": "supported", "priority": "P2", "scope": "introduced"}] | null |
apache__linkis__4263 | apache/linkis | 4,263 | defect | ee29de94374b6fb59285a0bf6b0a3710a3c6e430 | 1f3c76f7bf9b3d00745954fec4d1739103c1a9bf | [feat] upgrade hadoop\spark\hive default vertion to 3.x | ### What is the purpose of the change
we now support different hadoop.hive,spark vesion, so we can upgrade hadoop\spark\hive default vertion to 3.x to solve possible security issue
### Related issues/PRs
Related issues: #4262
Related pr:#4263
### Brief change log
- upgrade hadoop from 2.7.2 ->3.3.4
-... | diff --git a/README.md b/README.md
index 9c864cca557..c8ab09b3cc7 100644
--- a/README.md
+++ b/README.md
@@ -85,8 +85,8 @@ Since the first release of Linkis in 2019, it has accumulated more than **700**
| **Engine Name** | **Suppor Component Version<br/>(Default Dependent Version)** | **Linkis Version Requirements**... | 4 | 4 | 2 | [{"id": "G0", "claim": "The spark 2.4/hadoop profile handling added by this PR should be reworked into a global profile (named for 2.7 per the reviewer) that overwrites the global properties such as json4s, instead of the current structure.", "category": "design", "verdict": "supported", "priority": "P1", "scope": "int... | null |
apache__linkis__4349 | apache/linkis | 4,349 | defect | 4ab2670fdd4df643942ae1e3576f47238a104f89 | 45d689c4b7c33d4aab8e7143db40a238572b5e7d | [feat-4348]change the default token to a random number | change the default token to a random number
#4348 | diff --git a/linkis-computation-governance/linkis-client/linkis-cli/linkis-cli-application/src/main/java/org/apache/linkis/cli/application/operator/ujes/UJESClientFactory.java b/linkis-computation-governance/linkis-client/linkis-cli/linkis-cli-application/src/main/java/org/apache/linkis/cli/application/operator/ujes/UJ... | 5 | 4 | 4 | [{"id": "G0", "claim": "The default value of wds.linkis.bml.auth.token.value in LinkisClientApplicationTest should be set to BML-AUTH instead of \"fds\".", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "The default authTokenValue in LinkisJobBuilder s... | null |
apache__linkis__4368 | apache/linkis | 4,368 | defect | 2c5abd7a0504db7b2ef5c34a2e43257c66d783c0 | aebe8b31a660900d585fcdbbe880c1b2c438f24a | [WIP] remove json4s from linkis | ### What is the purpose of the change
use jackson to replace json4s, we can reduce the linkis dependency
### Related issues/PRs
Related issues: #4186
Related pr:#4368
### Brief change log
- replace json4s with jackson in linkis
### Checklist
- [x] I have read the [Contributing Guidelines on p... | diff --git a/linkis-commons/linkis-httpclient/pom.xml b/linkis-commons/linkis-httpclient/pom.xml
index 473b591a085..da075dd194f 100644
--- a/linkis-commons/linkis-httpclient/pom.xml
+++ b/linkis-commons/linkis-httpclient/pom.xml
@@ -42,31 +42,6 @@
<artifactId>httpmime</artifactId>
<version>${httpmime.vers... | 6 | 6 | 2 | [{"id": "G0", "claim": "setProgressInfo needlessly converts each entry with map.asScala.toMap before serializing it, and can serialize map directly instead.", "category": "performance", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The JSON round-trip in getYarnResource is use... | null |
apache__linkis__4378 | apache/linkis | 4,378 | defect | e2b44ebb7600c494a2d214ae72d310d4333894fa | f5ad68af7717f85b7d34ddae784cb0e8f154ff02 | fix some bug | Linkis 1.3.2 test bug fix
1. mongodb datasource conn error
2. jdbc datasource url format error | diff --git a/linkis-computation-governance/linkis-engineconn/linkis-engineconn-plugin-core/src/main/scala/org/apache/linkis/manager/engineplugin/common/util/NodeResourceUtils.scala b/linkis-computation-governance/linkis-engineconn/linkis-engineconn-plugin-core/src/main/scala/org/apache/linkis/manager/engineplugin/commo... | 1 | 1 | 0 | [{"id": "G0", "claim": "The mongodb datasource row's classifier should be adjusted to \"NoSQL\" instead of \"DEFAULT\".", "category": "correctness", "verdict": "supported", "priority": "P2", "scope": "introduced"}] | null |
apache__linkis__4412 | apache/linkis | 4,412 | defect | c5164494e7a837af92fec1ca7674908b13b11e51 | 89465b7cf21b56df44103661ae40b5d907a1afaf | update jdbc connect logic | 1. update jdbc engine plugin connector connection params check
2. update jdbc datasource connection params check | diff --git a/linkis-commons/linkis-common/src/main/java/org/apache/linkis/common/utils/SecurityUtils.java b/linkis-commons/linkis-common/src/main/java/org/apache/linkis/common/utils/SecurityUtils.java
index 2e77a14c0e9..bcd8ee3e534 100644
--- a/linkis-commons/linkis-common/src/main/java/org/apache/linkis/common/utils/S... | 1 | 1 | 0 | [{"id": "G0", "claim": "Remove the wds-prefixed configuration key and rename linkis.security.mysql.url.regex, with jackxu2011 proposing the name linkis.security.mysql.url.template.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}] | null |
apache__linkis__4424 | apache/linkis | 4,424 | defect | e24da00b38ba7fd04740f73cef929b16061e8882 | 7bbfc2c2798b34423df99918128d876faa93bc8a | feat : linkis-storage support OSS filesystem support write/read launch log and resultSet in OSS(#4185) | <!--
Thank you for sending the PR! We appreciate you spending the time to work on these changes.
You can learn more about contributing to Apache Linkis here: https://linkis.apache.org/community/how-to-contribute
Happy contributing!
-->
### What is the purpose of the change
1, linkis-storge support oss filesy... | diff --git a/linkis-commons/linkis-common/src/main/java/org/apache/linkis/common/io/FsPath.java b/linkis-commons/linkis-common/src/main/java/org/apache/linkis/common/io/FsPath.java
index 26c168ff0da..467bd74d347 100644
--- a/linkis-commons/linkis-common/src/main/java/org/apache/linkis/common/io/FsPath.java
+++ b/linkis... | 3 | 3 | 1 | [{"id": "G0", "claim": "Modifying FsPath.toPath() (rewritten as getUriString()) requires adding a dedicated unit test for the method.", "category": "testing", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The changed getSchemaPath() logic produces the wrong path for hdfs, whic... | null |
apache__linkis__4480 | apache/linkis | 4,480 | defect | 8dc2725203dc320979be74e50bc7a35203907326 | 9561bcb396ed2272055a66d797c5ffe77884b1ed | feat(pom): fix build with jdk17 for default profiles | <!--
Thank you for sending the PR! We appreciate you spending the time to work on these changes.
You can learn more about contributing to Apache Linkis here: https://linkis.apache.org/community/how-to-contribute
Happy contributing!
-->
### What is the purpose of the change
when build with jdk17, the test will... | diff --git a/linkis-engineconn-plugins/jdbc/pom.xml b/linkis-engineconn-plugins/jdbc/pom.xml
index 2450966e2f2..6b60b499539 100644
--- a/linkis-engineconn-plugins/jdbc/pom.xml
+++ b/linkis-engineconn-plugins/jdbc/pom.xml
@@ -80,7 +80,7 @@
<dependency>
<groupId>org.apache.hive</groupId>
<artifactId>hi... | 3 | 1 | 1 | [{"id": "G0", "claim": "Modifying third party dependencies also requires updating the content of the tool/dependencies/known-dependencies.txt file, which the PR's dependency changes (e.g. the hive-jdbc version change) had not done at S1.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "i... | null |
apache__linkis__4499 | apache/linkis | 4,499 | defect | dca07627d8ba398fad085ee42a2593e9b50f14dc | f704655abffd32c81b4efc1120d0d2ca48adbbcd | Engineplugin shell Code optimization | Engineplugin shell Code optimization
Will ShellEngineConnExecutor and ShellEngineConnConcurrentExecutor common code extraction | diff --git a/linkis-engineconn-plugins/shell/src/main/java/org/apache/linkis/manager/engineplugin/shell/executor/ShellEngineConnConcurrentExecutor.java b/linkis-engineconn-plugins/shell/src/main/java/org/apache/linkis/manager/engineplugin/shell/executor/ShellEngineConnConcurrentExecutor.java
index 3f445ddd5d7..7398bf98... | 1 | 1 | 1 | [{"id": "G0", "claim": "The `super(id)` call in the ShellEngineConnConcurrentExecutor constructor can be deleted in favour of the default (parent's default output print limit) instead of passing the executor id.", "category": "design", "verdict": "supported", "priority": "P1", "scope": "introduced"}] | null |
apache__linkis__4767 | apache/linkis | 4,767 | defect | 537f9a9519a3b5b24a4ebc42a1648922f454c0ad | ee7c170aff5d96cc3640704252f00bb0aa5a7e9e | Spark supports k8s operator submit task | Spark supports k8s operator submit task
Submit parameters as follows
{
"executionContent":{
"runType":"jar",
"code":"show databases"
},
"params":{
"configuration":{
"startup":{
"spark.executor.memory":"1g",
"spark.driver.me... | diff --git a/linkis-engineconn-plugins/spark/pom.xml b/linkis-engineconn-plugins/spark/pom.xml
index e5f8d0b05f3..add427443a8 100644
--- a/linkis-engineconn-plugins/spark/pom.xml
+++ b/linkis-engineconn-plugins/spark/pom.xml
@@ -392,6 +392,33 @@
</exclusion>
</exclusions>
</dependency>
+
+ <depe... | 4 | 2 | 2 | [{"id": "G0", "claim": "SparkJobProgressUtil#getSparkJobInfo should be adapted to the k8s-operator submitting way introduced by this pull request.", "category": "correctness", "verdict": "uncertain", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "The new spark-k8s-operator.md document needs a linkis-c... | null |
apache__linkis__4838 | apache/linkis | 4,838 | defect | ead682223d02af3aec0f6d0c18ede0753e1359f0 | 83853ccbcb855eb7e8f209d9dd936e3bfc74fc38 | [Feature] Enhanced FileSource to support more parameters feature |
### Related issues/PRs
Related issues: #4836
### Checklist
- [x] I have read the [Contributing Guidelines on pull requests](https://github.com/facebook/docusaurus/blob/main/CONTRIBUTING.md#pull-requests).
- [ ] I have explained the need for this PR and the problem it solves
- [ ] I have explaine... | diff --git a/linkis-commons/linkis-storage/src/main/java/org/apache/linkis/storage/source/AbstractFileSource.java b/linkis-commons/linkis-storage/src/main/java/org/apache/linkis/storage/source/AbstractFileSource.java
index f2eb65ed15c..a6782141856 100644
--- a/linkis-commons/linkis-storage/src/main/java/org/apache/link... | 3 | 3 | 1 | [{"id": "G0", "claim": "The new filesystem limit configuration keys should drop the legacy \"wds.\" prefix (e.g. \"wds.linkis.filesystem.limit.total.line\").", "category": "design", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "Instead of adding the new limit parameter, the ex... | null |
apache__linkis__5067 | apache/linkis | 5,067 | defect | be7b820519e593e9f0ba9c03910fe117101b7d5a | e13e1f3864255f102897201e3a600eb6f17b060e | Flink supports udf function | Flink supports udf function
Submit the flink udf task parameters
sh /appcom/Install/LinkisInstall150/bin/linkis-cli -engineType flink-1.16.2 \
-codeType sql -code "select linkis_flink_udf('test')" \
-submitUser hadoop -proxyUser hadoop
,array['abs','oda'],';') as infos
from ods.dim_ep22 ;
错误拼接:
select
id,
name,
array_join(array_intersect(map_keys(info),array['abs','oda'],' limit 5000;
;') as infos
from ods.dim_ep22 ... | diff --git a/linkis-computation-governance/linkis-entrance/src/main/scala/org/apache/linkis/entrance/interceptor/impl/Explain.scala b/linkis-computation-governance/linkis-entrance/src/main/scala/org/apache/linkis/entrance/interceptor/impl/Explain.scala
index 045cb51f885..2852f7915d9 100644
--- a/linkis-computation-gove... | 1 | 1 | 1 | [{"id": "G0", "claim": "Add test cases to verify the correctness of the changed SQL-splitting method.", "category": "testing", "verdict": "supported", "priority": "P1", "scope": "introduced"}] | null |
apache__logging-flume__276 | apache/logging-flume | 276 | defect | 41902ebc998ca31de4ddc0fb89136a2e70b236f9 | 76f8355604b238436f3e8927142efc70e68423ef | FLUME-3314 Fixed NPE in Kafka source/channel during offset migration | Kafka source/channel threw NPE when migrateOffsets() was called
on nonexistent topics.
It has been fixed by adding null check and logging a warning message
(topic not found, skipping offset migration).
After skipping the offset migration, the source/channel works the same way
as the "non offset migration" case:
... | diff --git a/flume-ng-channels/flume-kafka-channel/pom.xml b/flume-ng-channels/flume-kafka-channel/pom.xml
index 7819826d61..9bf1e27d2a 100644
--- a/flume-ng-channels/flume-kafka-channel/pom.xml
+++ b/flume-ng-channels/flume-kafka-channel/pom.xml
@@ -71,7 +71,11 @@ limitations under the License.
<artifactId>mock... | 2 | 2 | 2 | [{"id": "G0", "claim": "In KafkaChannel.getKafkaOffsets the change to return null when partitions is null will cause a NullPointerException at the offset-verification call site on line 345, which dereferences newKafkaOffsets without a null check.", "category": "correctness", "verdict": "supported", "priority": "P1", "s... | null |
apache__logging-log4j2__1419 | apache/logging-log4j2 | 1,419 | defect | 133e82ce6716d1d4a336e8ddfdc410123ece9a1d | 171234d1de1c66e0cfbc7735e66a2ffb90d5a850 | Fix `Log4jFixedFormatter` buffer length | This PR fixes #1418 .
The buffer length in `Log4jFixedFormatter` was computed base on the length of the pattern. Now it is the double of the real length of a formatted date (in the English locale).
At the same time this migrates the `FastDateFormatter` tests to JUnit 5. | diff --git a/log4j-core-test/src/test/java/org/apache/logging/log4j/core/util/datetime/FastDateParserSDFTest.java b/log4j-core-test/src/test/java/org/apache/logging/log4j/core/util/datetime/FastDateParserSDFTest.java
index 7803995ee0dc..3a274e578275 100644
--- a/log4j-core-test/src/test/java/org/apache/logging/log4j/co... | 3 | 1 | 0 | [{"id": "G0", "claim": "Given that FixedDateFormat.getLength() is now fixed to give the exact length, the char[]-size fix (doubled buffer) in InstantFormatter may no longer be needed and could perhaps be dropped.", "category": "maintainability", "verdict": "opposed", "priority": "P3", "scope": "introduced"}, {"id": "G1... | null |
apache__logging-log4j2__1787 | apache/logging-log4j2 | 1,787 | defect | 08d3e46cad99e602fd36213240e4c19e876cb069 | 666e4b8a789c424d8fcf9ed38f49a6eb1a02ab10 | Fix thread context loss if `<AsyncLogger>` in an all async context | This fixes #1786.
The `AbstractAsyncThreadContextBase` and derivative tests were modernized, so that they can run at the same time in different JVMs.
`RingBufferLogEvent#createMemento()` will now freeze the context data, which will cause a new `StringMap` instance to be created, when `clean()` is called. | diff --git a/log4j-core-test/src/test/java/org/apache/logging/log4j/core/async/AbstractAsyncThreadContextTestBase.java b/log4j-core-test/src/test/java/org/apache/logging/log4j/core/async/AbstractAsyncThreadContextTestBase.java
index 15d0ffbea6ec..807b818f1e21 100644
--- a/log4j-core-test/src/test/java/org/apache/loggin... | 1 | 1 | 1 | [{"id": "G0", "claim": "Unless certain conditions are met, the added null/frozen fallback makes ForGarbageFreeThreadContextMap.injectContextData() allocate a fresh context data map, so the method is no longer garbage-free.", "category": "performance", "verdict": "supported", "priority": "P1", "scope": "introduced"}] | null |
apache__logging-log4j2__1820 | apache/logging-log4j2 | 1,820 | defect | ef6c08578983d61a49f263fa4b0bb7883e5006a4 | 5c9f18f55832e06b6aa869baccbcc8a076f80427 | Add BND configuration for `log4j-api` | This PR performs the necessary changes to switch `log4j-api` from `maven-bundle-plugin` and a manually written `module-info.java` to `bnd-maven-plugin`.
## Before
In version 2.20.0 the OSGi descriptor had these imports/exports:
```
Import-Package
org.apache.logging.log4j.message
org.apache.loggin... | diff --git a/log4j-1.2-api/pom.xml b/log4j-1.2-api/pom.xml
index bb5caf8fa7b9..c849f4877865 100644
--- a/log4j-1.2-api/pom.xml
+++ b/log4j-1.2-api/pom.xml
@@ -20,7 +20,7 @@
<parent>
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j</artifactId>
- <version>2.21.0-SNAPSHOT</version>
+ <vers... | 6 | 2 | 2 | [{"id": "G0", "claim": "The reviewer asks whether the new OSGi manifest's import of `org.apache.logging.log4j.internal` means that internal package is exported unintentionally, and mentions `-noimport:=true` as a way to disable such self-imports.", "category": "correctness", "verdict": "opposed", "priority": "P1", "sco... | null |
apache__logging-log4j2__2021 | apache/logging-log4j2 | 2,021 | defect | 8c09c3fbd0281fa43727df6f5401be25ee4e4b32 | c03eb85bb3a453c71a625fd5d772ae1a7997dea0 | Upgrade `2.x` compiler baseline to Java 17 | *Warning!* `revision` needs to be adjusted prior to merge. | diff --git a/.github/dependabot.yaml b/.github/dependabot.yaml
index 8ec12a2f112..280a8614010 100644
--- a/.github/dependabot.yaml
+++ b/.github/dependabot.yaml
@@ -43,21 +43,12 @@ updates:
# Keep Logback version 1.2.x
- dependency-name: "ch.qos.logback:*"
update-types: ["version-update:semver-major", ... | 3 | 3 | 2 | [{"id": "G0", "claim": "Upgrading the Mockito, JUnit Pioneer, system-stubs and json-unit test dependencies must be reverted because tests are still compiled with -release 8 and must run on JRE 8, which those newer versions do not support.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "... | null |
apache__logging-log4j2__2138 | apache/logging-log4j2 | 2,138 | defect | b7478101c06289190a6a56620e3094c2dcd27a1e | 8255ffad43d0864a9a312d0deb821fd144747ea4 | Fix use of AccessController in LoaderUtil | This fixes issue #2129 where `AccessController::doPrivileged` is needlessly invoked when no `SecurityManager` is installed. | diff --git a/log4j-api/src/main/java/org/apache/logging/log4j/util/LoaderUtil.java b/log4j-api/src/main/java/org/apache/logging/log4j/util/LoaderUtil.java
index dc7fd4ee00b..1b8cc72b9f4 100644
--- a/log4j-api/src/main/java/org/apache/logging/log4j/util/LoaderUtil.java
+++ b/log4j-api/src/main/java/org/apache/logging/lo... | 4 | 3 | 2 | [{"id": "G0", "claim": "Replace the 3-parameter AccessController.doPrivileged(action, null, GET_CLASS_LOADER) call with the 1-parameter doPrivileged(action), since Android lacks the 3-param overload and the call sites are already guarded by System.getSecurityManager() != null.", "category": "design", "verdict": "suppor... | null |
apache__logging-log4j2__2256 | apache/logging-log4j2 | 2,256 | defect | 0f2bf49bd7b68721932284a1e2c77adbbbc777d0 | f83d1926738ba958e3ecce1715f5c5755b3aa6e3 | Fix regression in `JdkMapAdapterStringMap` performance | We introduce a new constructor for `JdkMapAdapterStringMap` to prevent the performance penalty of an exception if the map is immutable. The regression was introduced in #2101.
Closes #2238. | diff --git a/log4j-core-test/src/test/java/org/apache/logging/log4j/core/impl/JdkMapAdapterStringMapTest.java b/log4j-core-test/src/test/java/org/apache/logging/log4j/core/impl/JdkMapAdapterStringMapTest.java
index 65e894814d76..39953f0474cc 100644
--- a/log4j-core-test/src/test/java/org/apache/logging/log4j/core/impl/... | 5 | 3 | 1 | [{"id": "G0", "claim": "Optionally remove the test line that calls the deprecated single-argument constructor in testConstructorDisallowsNull.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "pre_existing"}, {"id": "G1", "claim": "Optionally replace the use of the deprecated single-a... | null |
apache__logging-log4j2__2259 | apache/logging-log4j2 | 2,259 | defect | 035e251056f0d2d77be7290e954c45862042e284 | 2b50e3884d1eb11453defa842a47f4b1074d8e7f | [LOG4J2-3680] Allow deserialization of arrays | The `DefaultObjectInputFilter` is too restrictive and it does not allow the deserialization of **arrays** of whitelisted classes.
Most notably `RuntimeException` can not be deserialized, since it contains an array of `StackTraceElement`s. Both classes are allowed, but deserialization of the `StackTraceElement[]` arr... | diff --git a/log4j-api-java9/src/main/java/org/apache/logging/log4j/util/internal/DefaultObjectInputFilter.java b/log4j-api-java9/src/main/java/org/apache/logging/log4j/util/internal/DefaultObjectInputFilter.java
index 1c456541688f..df62f71e5f75 100644
--- a/log4j-api-java9/src/main/java/org/apache/logging/log4j/util/i... | 2 | 2 | 1 | [{"id": "G0", "claim": "The manual offset-counting loop in stripArray(String) could be replaced with a simpler String method such as String#indexOf(char).", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "stripArray() should throw an exception on a... | null |
apache__logging-log4j2__2282 | apache/logging-log4j2 | 2,282 | defect | e87064f22d50fe46c085e2e20d5b1c80a6261e7e | cb1f19fb52d2b48d1876db8c5773bdbf03b0e8a8 | The core.Logger#setLevel method should work like | The core.Logger#setLevel method should work like Configurator#setLevel #2281
@ppkarwasz
I'm not sure how to really test this from our 1.2 module but I did install a snapshot locally and tested it with my Apache Commons Logging branch here https://github.com/garydgregory/commons-logging/tree/log4j1-log42-api
T... | diff --git a/log4j-1.2-api/src/main/java/org/apache/log4j/legacy/core/CategoryUtil.java b/log4j-1.2-api/src/main/java/org/apache/log4j/legacy/core/CategoryUtil.java
index ee31ff538021..b51b1b466fc4 100644
--- a/log4j-1.2-api/src/main/java/org/apache/log4j/legacy/core/CategoryUtil.java
+++ b/log4j-1.2-api/src/main/java/... | 4 | 3 | 0 | [{"id": "G0", "claim": "The apache-rat-plugin version bump should be made in the logging-parent (or preferably the ASF parent) POM rather than pinned in this repository.", "category": "maintainability", "verdict": "uncertain", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "Please add a test that setti... | null |
apache__logging-log4j2__2322 | apache/logging-log4j2 | 2,322 | defect | b620bcd8063af4dfa52207e5cf52e5b6c64e8c8a | 89417c77401cf5209b6b1ead1216031dfc1b9efe | Fix `StatusLogger` time-zone issues and stack overflow | This PR improves `StatusLogger` such that
1. A new `log4j2.StatusLogger.DateFormatZone` configuration property is introduced. This sets the time-zone `StatusLogger` uses to format `java.time.Instant`. Without this formatting patterns accessing to time-zone-specific fields (e.g., year-of-era) cause failures. The value ... | diff --git a/log4j-api-test/src/test/java/org/apache/logging/log4j/status/StatusLoggerDateTest.java b/log4j-api-test/src/test/java/org/apache/logging/log4j/status/StatusLoggerDateTest.java
new file mode 100644
index 00000000000..de09d6571ee
--- /dev/null
+++ b/log4j-api-test/src/test/java/org/apache/logging/log4j/statu... | 2 | 2 | 1 | [{"id": "G0", "claim": "The new property values should already use the 3.x `Component.propertyInCamelCase` style, i.e. `log4j2.StatusLogger.dateFormatZone` instead of `log4j2.StatusLogger.DateFormatZone`, and likewise `log4j2.StatusLogger.dateFormat` instead of `log4j2.StatusLogger.DateFormat`.", "category": "design", ... | null |
apache__logging-log4j2__2329 | apache/logging-log4j2 | 2,329 | defect | 64ebf0ddaacdce0c57adc52da2371a2a733df31a | 68ec2f3dba24915a57dc04d4521a59e524ac261e | Make location computation and message formatting more lazy | We move the computation of location and message formatting to the last method call executed before a message leaves the current thread.
This has several consequences:
- the refactoring of location computations should solve #1458,
- since `AbstractLogger` no longer needs to compute the location of the caller, m... | diff --git a/log4j-1.2-api/pom.xml b/log4j-1.2-api/pom.xml
index 6e38bbee4e0a..57855caba987 100644
--- a/log4j-1.2-api/pom.xml
+++ b/log4j-1.2-api/pom.xml
@@ -35,10 +35,11 @@
-->
<bnd-module-name>org.apache.log4j</bnd-module-name>
<bnd-extra-package-options>
+ <!-- External optional dependencies -... | 3 | 3 | 1 | [{"id": "G0", "claim": "The getSource() methods changed to delegate to peekSource() — LogEventWrapper.getSource() in particular — should also be annotated with @Nullable.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "mementoOfMessage returns a non-... | null |
apache__logging-log4j2__2381 | apache/logging-log4j2 | 2,381 | defect | 3242ffb790ab6e8742db35f6d6e67a06d8f89f02 | fcadb743ec08e1fc2d26482372536b55bc7d2684 | Add Logback's throwable-consuming semantics as an option | The semantics used to determine the `Throwable` attached to a log event changed in Logback 1.1.0 (in the fix to [LOGBACK-873](https://jira.qos.ch/browse/LOGBACK-873)).
When there are not enough arguments to the log call to fill both the throwable field and the placeholders contained in the message pattern, Logback 1... | diff --git a/log4j-slf4j-impl/src/main/java/org/apache/logging/slf4j/message/ThrowableConsumingMessageFactory.java b/log4j-slf4j-impl/src/main/java/org/apache/logging/slf4j/message/ThrowableConsumingMessageFactory.java
new file mode 100644
index 00000000000..cb55499c711
--- /dev/null
+++ b/log4j-slf4j-impl/src/main/jav... | 3 | 1 | 0 | [{"id": "G0", "claim": "All newly added Java source files should explicitly state that the class must stay identical to its clone in log4j-slf4j2-impl.", "category": "documentation", "verdict": "opposed", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The new semantics should be documented in migrate-... | null |
apache__logging-log4j2__2393 | apache/logging-log4j2 | 2,393 | defect | 67479ee93c94038f43b10081f3d86b742b4ef0f5 | 1220143c72e1c6f6a31f620473f2a16890bda5d4 | Fix issue #2380: Log messages with insufficient parameters should not throw exception. | Fix issue #2380: Log messages with insufficient parameters should not throw exception.
In this PR, I modified the class `org.apache.logging.log4j.message.ParameterFormatter`.
I deleted the codes about checking placeholderCount and argCount, if they weren't equal, it would throw an IllegalArgumentException.
At t... | diff --git a/log4j-api-test/src/test/java/org/apache/logging/log4j/message/ParameterFormatterTest.java b/log4j-api-test/src/test/java/org/apache/logging/log4j/message/ParameterFormatterTest.java
index e31796368b1..6fe4f2d519d 100644
--- a/log4j-api-test/src/test/java/org/apache/logging/log4j/message/ParameterFormatterT... | 5 | 4 | 3 | [{"id": "G0", "claim": "The removed fail-fast should be replaced by a StatusLogger warning whenever the number of arguments is less than the placeholder count or higher than the placeholder count plus a trailing Throwable, after which the try/catches at the call sites can be removed.", "category": "design", "verdict": ... | null |
apache__logging-log4j2__2424 | apache/logging-log4j2 | 2,424 | defect | b31919fb30cb50c5533f614a5dac66135e1afc61 | ba539356d1b555ee52ddcc7c29be11d5a862ad79 | Add logging to `PropertiesUtil` and fix `Duration` parser | Profiting from the `StatusLogger` enhancements in #2273, we add logging statement in `PropertiesUtil`.
We also add tests for the `getDurationProperty` method and fix its behavior.
Part of #2290.
Closes #1963
| diff --git a/log4j-api-test/src/test/java/org/apache/logging/log4j/util/PropertiesUtilTest.java b/log4j-api-test/src/test/java/org/apache/logging/log4j/util/PropertiesUtilTest.java
index 6e3600eafe26..07fd8c85e8b6 100644
--- a/log4j-api-test/src/test/java/org/apache/logging/log4j/util/PropertiesUtilTest.java
+++ b/log4... | 5 | 4 | 1 | [{"id": "G0", "claim": "The parseAmount method has nothing to do with TimeUnit and should be placed right after parseDuration and renamed to parseDurationAmount.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "TimeUnit#parseUnit should receive a ... | null |
apache__logging-log4j2__2481 | apache/logging-log4j2 | 2,481 | defect | de49ffff7dc30316acaea6ea5ea22d0dc9c00fe8 | 1d57bc03979e0d5a8c157c43fd5ebfed42d8b105 | Deprecate `log4j2.defaultStatusLevel` property | The Log4j system property `log4j2.defaultStatusLevel` has almost the same purpose as the `log4j2.statusLoggerLevel`:
* the `log4j2.statusLoggerLevel` property sets the level of the fallback status logger listener **before** a configuration is parsed,
* the `log4j2.defaultStatusLevel` property sets the level of the ... | diff --git a/log4j-core-test/src/test/java/org/apache/logging/log4j/core/config/xml/XmlConfigurationPropsTest.java b/log4j-core-test/src/test/java/org/apache/logging/log4j/core/config/xml/XmlConfigurationPropsTest.java
index e7a13f12edcd..3437f787b8aa 100644
--- a/log4j-core-test/src/test/java/org/apache/logging/log4j/... | 2 | 1 | 0 | [{"id": "G0", "claim": "The documentation is incorrect: the default of `log4j2.statusLoggerLevel` is `ERROR`, not the documented `WARN`.", "category": "documentation", "verdict": "supported", "priority": "P1", "scope": "pre_existing"}, {"id": "G1", "claim": "To test that `DEFAULT_` takes precedence over `LOG4J_`, the `... | null |
apache__logging-log4j2__2505 | apache/logging-log4j2 | 2,505 | defect | f0bd87818d43efa8337f56526ced2020c308d9bf | 5fc9c80beee1c6e52f5e34e10d29e264a4a45c2c | Fix handling of `log4j2.messageFactory` and `log4j2.flowMessageFactory` properties | Fixes #2379. | diff --git a/log4j-api/src/main/java/org/apache/logging/log4j/spi/AbstractLogger.java b/log4j-api/src/main/java/org/apache/logging/log4j/spi/AbstractLogger.java
index 30d0cffef02..ecc499ac586 100644
--- a/log4j-api/src/main/java/org/apache/logging/log4j/spi/AbstractLogger.java
+++ b/log4j-api/src/main/java/org/apache/l... | 1 | 1 | 0 | [{"id": "G0", "claim": "The hand-rolled property instantiation in `createInstanceFromFactoryProperty` should use `LoaderUtil#newCheckedInstanceOfProperty` instead.", "category": "design", "verdict": "supported", "priority": "P2", "scope": "introduced"}] | null |
apache__logging-log4j2__2609 | apache/logging-log4j2 | 2,609 | defect | 28268e856c52bf3d76a3d75ec23343f49f255c3c | b48af8d6e499c1bbfd7886da79944d066c32cecc | Fix empty string handling for `TruncatingBufferedWriter` | ```
ERROR StatusConsoleListener An exception occurred processing Appender console
java.lang.IndexOutOfBoundsException: invalid offset: 0
at org.apache.logging.log4j.layout.template.json.util.TruncatingBufferedWriter.write(TruncatingBufferedWriter.java:131)
at java.base/java.io.PrintWriter.write(PrintWriter.java:... | diff --git a/log4j-layout-template-json-test/src/test/java/org/apache/logging/log4j/layout/template/json/util/TruncatingBufferedWriterTest.java b/log4j-layout-template-json-test/src/test/java/org/apache/logging/log4j/layout/template/json/util/TruncatingBufferedWriterTest.java
index 24e9a072c1d..1b1355d4ec8 100644
--- a... | 2 | 2 | 1 | [{"id": "G0", "claim": "Remove the `if (end == 0)` short-circuit from `append()` because it makes the method unnecessarily more lenient, and drop the `writer.append(\"nothing\", 3, 0)` test case that asserts that lenient behavior.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduc... | null |
apache__logging-log4j2__2667 | apache/logging-log4j2 | 2,667 | defect | 4cca713d54b51304666e6dc62f89b1309cf7a066 | 5de88c8d10dcd12f24e487b2cc15bc9529e22733 | Improve layout docs on property substitution | Fixes #2666. | diff --git a/log4j-layout-template-json-test/src/test/java/org/apache/logging/log4j/layout/template/json/resolver/PatternResolverPropertySubstitutionTest.java b/log4j-layout-template-json-test/src/test/java/org/apache/logging/log4j/layout/template/json/resolver/PatternResolverPropertySubstitutionTest.java
new file mode... | 4 | 4 | 2 | [{"id": "G0", "claim": "Property substitution should not be applied to an inlined eventTemplate (only eventTemplateUri values should be substituted, possibly in a JSON-safe way); the reviewer is not convinced by the approach and proposes preventing PluginBuilder expansion of lookups and applying substitution manually i... | null |
apache__logging-log4j2__2836 | apache/logging-log4j2 | 2,836 | defect | d659fd2aea600dc9b863c560014f2def8603ae0a | b941a990935c4db0c77849904c45d8dfd62b00ca | Improve plugin descriptor warnings | This improves status logger warnings about:
* missing `Log4j2Plugin.dat` plugin descriptors,
* usage of package scanning.
The warnings are reworded in a way that they are more useful to end-users. If package scanning is enabled, linkage errors (almost exclusively due to optional dependencies) are logged at a `DE... | diff --git a/log4j-core/src/main/java/org/apache/logging/log4j/core/config/AbstractConfiguration.java b/log4j-core/src/main/java/org/apache/logging/log4j/core/config/AbstractConfiguration.java
index d7ee730c5f51..3fe9bf13b166 100644
--- a/log4j-core/src/main/java/org/apache/logging/log4j/core/config/AbstractConfigurati... | 12 | 11 | 0 | [{"id": "G0", "claim": "The enum comparison in AbstractConfiguration.start() should use `enumConstant.equals(input)` instead of `==`, as the only NPE-resilient single-statement comparison.", "category": "maintainability", "verdict": "opposed", "priority": "P3", "scope": "introduced"}, {"id": "G1", "claim": "In the pack... | null |
apache__logging-log4j2__2849 | apache/logging-log4j2 | 2,849 | defect | dd5df4be049ff14b89337a8c91aa4f05ffa3d72b | 6079776e4ed72bdfa7b52e4d6db3b0107770dc0f | Remove properties cache and token-based matching | The `PropertiesUtil` class preemptively caches lookups for all known keys from enumerable property sources.
On my Debian system a JVM has around 60 among environment variables and system properties, which causes `PropertiesUtil` to perform around 60 lookups for **each** of the 3 standard property sources. Most of thes... | diff --git a/log4j-api-test/src/test/java/org/apache/logging/log4j/util/PropertiesUtilOrderTest.java b/log4j-api-test/src/test/java/org/apache/logging/log4j/util/PropertiesUtilOrderTest.java
index 4343d9618f4c..662bfcd1cc00 100644
--- a/log4j-api-test/src/test/java/org/apache/logging/log4j/util/PropertiesUtilOrderTest.... | 3 | 1 | 0 | [{"id": "G0", "claim": "If the goal is simplification, the existing sort-on-add lines could be replaced with a single sort-while-iterating.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "pre_existing"}, {"id": "G1", "claim": "The properties `log4j2.enable.direct.encoders` and `log4... | null |
apache__logging-log4j2__2853 | apache/logging-log4j2 | 2,853 | defect | 9fded3e199fde285e0df1ebc6c64d6b61c8b28ba | 9fb04286f929e242818a0ca372367834ee692e47 | Add `useFqdn` attribute to RFC5424 Layout | Since RFC5424 specifies that the [`HOSTNAME`](https://datatracker.ietf.org/doc/html/rfc5424#section-6.2.4) field should contain the FQDN of the current host, we add a `useFqdn` configuration attribute to RFC5424 Layout that replaces the usage of `InetAddress.getHostName()` with `InetAddress.getCanonicalHostName()`.
... | diff --git a/log4j-core-test/src/test/java/org/apache/logging/log4j/core/layout/Rfc5424LayoutTest.java b/log4j-core-test/src/test/java/org/apache/logging/log4j/core/layout/Rfc5424LayoutTest.java
index ce3f8f4b29a6..8390657201c4 100644
--- a/log4j-core-test/src/test/java/org/apache/logging/log4j/core/layout/Rfc5424Layou... | 2 | 2 | 1 | [{"id": "G0", "claim": "The Javadoc of the new getCanonicalLocalHostname method should be reworded so the @return clause states that it returns {@value UNKNOWN_LOCALHOST} when the host name cannot be found.", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "cl... | null |
apache__logging-log4j2__3050 | apache/logging-log4j2 | 3,050 | defect | 38bc033443c85f9df68c9406fdacf32cb24d5143 | d54265dab6d6a561ff9b3dbf1e6589d2aa3a7010 | Fix key removal issues in Thread Context | Fixes #2946. | diff --git a/log4j-api-test/src/test/java/org/apache/logging/log4j/CloseableThreadContextTest.java b/log4j-api-test/src/test/java/org/apache/logging/log4j/CloseableThreadContextTest.java
index 56e0086a49f..5c86e713e2f 100644
--- a/log4j-api-test/src/test/java/org/apache/logging/log4j/CloseableThreadContextTest.java
+++... | 5 | 5 | 1 | [{"id": "G0", "claim": "Collecting the keys to remove with a stream inside copyAndRemoveAll creates intermediate objects and adds instructions in a performance-sensitive spot; a plain loop should be used instead.", "category": "performance", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1",... | null |
apache__logging-log4j2__3053 | apache/logging-log4j2 | 3,053 | defect | aa19816821df363049e11294dac30f84cc6ce126 | 2048b2bcf465659c9750af44f8b9a33608851b4c | Add `reachability-metadata.json` to all Log4j modules | This PR adds a plugin processor that generates a GraalVM reachability metadata file and bundles it with each Log4j module.
After this change, GraalVM will be able to handle Log4j Core without any user intervention.
**Note**: I also added a static `resource-config.json` file that specifies that all resources start... | diff --git a/log4j-core-test/pom.xml b/log4j-core-test/pom.xml
index f770ea88703..30ed7854e97 100644
--- a/log4j-core-test/pom.xml
+++ b/log4j-core-test/pom.xml
@@ -66,57 +66,69 @@
</properties>
<dependencies>
- <!-- Pull in useful test classes from API -->
+
<dependency>
<groupId>org.apache.logg... | 11 | 11 | 1 | [{"id": "G0", "claim": "The test calls `Objects.requireNonNull()` on the URL immediately after asserting it is not null, which is redundant.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The test's expected JSON should be built programmatically... | null |
apache__logging-log4j2__3080 | apache/logging-log4j2 | 3,080 | defect | 1e3223cfa7e1a474ae1cc6872a475690bd402c4f | c0b8144f491770e4a0f50ecaa80965286ccbf49c | Migrate `log4j-slf4j2-impl` to JUnit 5 | Hello 👋
We are from Neighbourhoodie, the implementation partner of the [STF](https://www.sovereigntechfund.de/programs/bug-resilience) Bug Resilience Program. This work is part of our agreed Milestone 1. Upgrade from JUnit 4 to JUnit 5. This PR migrates the tests located in `log4j-slf4j2-impl`.
⚠️ We've found ou... | diff --git a/log4j-slf4j2-impl/src/test/java/org/apache/logging/other/pkg/LoggerContextAnchorTest.java b/log4j-slf4j2-impl/src/test/java/org/apache/logging/other/pkg/LoggerContextAnchorTest.java
index 5732c205a4e1..a2b7c7f75958 100644
--- a/log4j-slf4j2-impl/src/test/java/org/apache/logging/other/pkg/LoggerContextAncho... | 4 | 4 | 1 | [{"id": "G0", "claim": "Change the assertions written as `X instanceof Y` to use the new JUnit 5 `assertInstanceOf` assertions (here: `assertTrue(ctx1 instanceof LifeCycle, ...)` in LoggerContextTest.testCleanup).", "category": "testing", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "c... | null |
apache__logging-log4j2__3085 | apache/logging-log4j2 | 3,085 | defect | 5b2bf8c8cb77922e087f14cdb294caa52770f49d | ad415e79757ece608a4a1aa64c7c2e9cd65cab54 | Avoid levels like `INFO#org.apache.log4j.Level` | If somebody (for example an external library) uses the deprecated `Priority` class there will be a custom level created even though there already exists a corresponding level. | diff --git a/log4j-1.2-api/src/main/java/org/apache/log4j/Level.java b/log4j-1.2-api/src/main/java/org/apache/log4j/Level.java
index 05852b93c5bf..7bc068a3faf4 100644
--- a/log4j-1.2-api/src/main/java/org/apache/log4j/Level.java
+++ b/log4j-1.2-api/src/main/java/org/apache/log4j/Level.java
@@ -115,8 +115,7 @@ protected... | 3 | 3 | 2 | [{"id": "G0", "claim": "`Priority.version2Level` can be null, which might lead to incorrect filtering of `Priority` instances (possibly even an NPE); add a new package-private constructor that always sets this field to a non-null value (`this.version2Level = version2Equivalent != null ? version2Equivalent : OptionConve... | null |
apache__logging-log4j2__3195 | apache/logging-log4j2 | 3,195 | defect | 89c9b9f81cb12a6a217788a71832bfbd3b6d07b2 | f61ac99919315b360d046c3d0e46d80324a352f9 | Fix(#2769): Modify the annotation processor in 2.x to give a warning if a plugin builder attribute does not have a public setter. | The following commit modifies the annotation processor in 2.x to shell out a warning if the plugin builder attribute does not have a public setter.
A ` @SuppressWarnings("log4j.public.setter")` attribute can be used to ignore this compilation warning incase it is a known issue.
## Checklist
* Base your change... | diff --git a/log4j-1.2-api/src/main/java/org/apache/log4j/builders/filter/StringMatchFilterBuilder.java b/log4j-1.2-api/src/main/java/org/apache/log4j/builders/filter/StringMatchFilterBuilder.java
index e92bf94b8856..c1adeed2e359 100644
--- a/log4j-1.2-api/src/main/java/org/apache/log4j/builders/filter/StringMatchFilte... | 8 | 8 | 1 | [{"id": "G0", "claim": "The new test should use JUnit 5 (`org.junit.jupiter.api.Test`) instead of JUnit 4, since the project's JUnit 4 tests are being rewritten to JUnit 5.", "category": "testing", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The manual `assertThat(Files.exis... | null |
apache__logging-log4j2__3212 | apache/logging-log4j2 | 3,212 | defect | 82184237ee865af33ca16a119e1f8a4dee5f16b1 | c6f43ad076df8c8664ce7bed5233b73029aa037f | Fix off-by-one in `StackTraceStringResolver` | Fixes #3194. | diff --git a/log4j-layout-template-json-test/src/test/java/org/apache/logging/log4j/layout/template/json/resolver/StackTraceStringResolverTest.java b/log4j-layout-template-json-test/src/test/java/org/apache/logging/log4j/layout/template/json/resolver/StackTraceStringResolverTest.java
index 430d6de6464..dd3b371e100 1006... | 1 | 1 | 1 | [{"id": "G0", "claim": "The fallback `return prevChar == '\\n' ? i : -1;` in `findLineStartIndex` should always return `-1`, since any index in `[startIndex, endIndex)` preceded by a newline is already returned by the loop.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}] | null |
apache__logging-log4j2__3258 | apache/logging-log4j2 | 3,258 | defect | 7fd3a1303dec3ede639dd573851143c5ac0890e1 | e6e6dddb41502edcbb89f8d23800449c142279f9 | Add `log4j.plugin.enableBndAnnotations` option to `PluginProcessor` | This adds a `log4j.plugin.enableBndAnnotations` option to the `PluginProcessor`. Its default value is inferred from the compiler classpath.
We also rename the `pluginPackage` option to a more coherent `log4j.plugin.package` option.
Fixes #3251
| diff --git a/log4j-parent/pom.xml b/log4j-parent/pom.xml
index c2b3a8e651e..0d45bf9a96f 100644
--- a/log4j-parent/pom.xml
+++ b/log4j-parent/pom.xml
@@ -865,7 +865,7 @@
<id>default-testCompile</id>
<configuration>
<compilerArgs combine.children="append">
- ... | 3 | 1 | 1 | [{"id": "G0", "claim": "isServiceConsumerClassPresent() uses Class.forName, so it looks for ServiceConsumer on the plugin processor's own classpath while it should look for it on the application classpath.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim... | null |
apache__logging-log4j2__3263 | apache/logging-log4j2 | 3,263 | defect | 11a3fc32afe8eaef75ba2730398896ebddb1ef93 | cb59a70fb55be6a9c5ef74d1f0dc207a8fdfedd0 | Hardens `PropertiesUtil` against recursive property sources | As showed in #3252, Spring's `JndiPropertySource` not only can throw exceptions, but can also perform logging calls. Such a call causes a recursive call to `PropertiesUtil.getProperty("log4j2.flowMessageFactory"`) and a `StackOverflowException` in the best scenario. The worst scenario includes a deadlock.
This PR:
... | diff --git a/log4j-api-test/src/test/java/org/apache/logging/log4j/util/PropertiesUtilTest.java b/log4j-api-test/src/test/java/org/apache/logging/log4j/util/PropertiesUtilTest.java
index a655959765c..0203eff1225 100644
--- a/log4j-api-test/src/test/java/org/apache/logging/log4j/util/PropertiesUtilTest.java
+++ b/log4j-... | 5 | 4 | 2 | [{"id": "G0", "claim": "Use @TestInfo to obtain the test method name instead of hardcoding it, in this and the other test methods.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "Moving the @SetSystemProperty annotations to class scope changes wh... | null |
apache__logging-log4j2__3265 | apache/logging-log4j2 | 3,265 | defect | be2d145999953615863f7d1795a4472614d9dd9d | 75a5b046f659c60d24ee9bfb323b773523d21cd9 | Fix(#3239) NPE, for RegexFilter creator. | fix for #3239
## Checklist
* Base your changes on `2.x` branch if you are targeting Log4j 2; use `main` otherwise
* `./mvnw verify` succeeds (if it fails due to code formatting issues reported by Spotless, simply run `./mvnw spotless:apply` and retry)
* Non-trivial changes contain an entry file in the `src/cha... | diff --git a/log4j-core/src/main/java/org/apache/logging/log4j/core/filter/RegexFilter.java b/log4j-core/src/main/java/org/apache/logging/log4j/core/filter/RegexFilter.java
index ee5997dc10f7..1944dbe835b3 100644
--- a/log4j-core/src/main/java/org/apache/logging/log4j/core/filter/RegexFilter.java
+++ b/log4j-core/src/m... | 3 | 3 | 1 | [{"id": "G0", "claim": "Comparing useRawMsg to Boolean.TRUE (Boolean.TRUE.equals(useRawMsg)) would be simpler to read than `useRawMsg != null && useRawMsg`.", "category": "maintainability", "verdict": "supported", "priority": "P3", "scope": "introduced"}, {"id": "G1", "claim": "Add a unit test checking that createFilte... | null |
apache__logging-log4j2__3338 | apache/logging-log4j2 | 3,338 | defect | 2143f8495b696337ef18d6485540ee43b720a52a | cba3b5fb1adc92231f08c4cd68351e7a3aa41479 | Use garbage-free formatter for `s` and `S` patterns | This PR improves #3139, by introducing a new `InstantPatternFormatter` for patterns of the form "ss\.S{n}". Unlike the previous formatter based on `DateTimeFormatter`, the formatter is garbage-free.
We also simplify the merging algorithm for pattern formatter factories, by moving the merging logic to the pattern for... | diff --git a/log4j-core-test/src/test/java/org/apache/logging/log4j/core/util/internal/instant/InstantPatternDynamicFormatterTest.java b/log4j-core-test/src/test/java/org/apache/logging/log4j/core/util/internal/instant/InstantPatternDynamicFormatterTest.java
index 210689fe356..2eea54bc000 100644
--- a/log4j-core-test/s... | 25 | 20 | 3 | [{"id": "G0", "claim": "The reviewer asks why the single-`S` case was removed from the `should_recognize_patterns_of_nano_precision` test.", "category": "testing", "verdict": "opposed", "priority": "P3", "scope": "introduced"}, {"id": "G1", "claim": "The reviewer asks why the `yyyy-MM-dd'T'HH:mm:ss.SXXX` case was remov... | null |
apache__logging-log4j2__3372 | apache/logging-log4j2 | 3,372 | defect | 89080925a9b74b14e6ab23e5951e4bbf60e9b652 | a23a1a8d1411848b5a7f1b8110f765735c4d9138 | Fix typo in LoggerConfig.RootLogger.Builder#withtFilter (#3369) | In LoggerConfig.RootLogger.Builder:
* Deprecated method with typo in name 'withtFilter'.
* Added correct method 'withFilter'.
| diff --git a/log4j-core/src/main/java/org/apache/logging/log4j/core/async/package-info.java b/log4j-core/src/main/java/org/apache/logging/log4j/core/async/package-info.java
index 6eed83a54e95..abf19fcd6f4b 100644
--- a/log4j-core/src/main/java/org/apache/logging/log4j/core/async/package-info.java
+++ b/log4j-core/src/m... | 6 | 6 | 1 | [{"id": "G0", "claim": "Add a changelog entry of type `added` for this change.", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "unclear"}, {"id": "G1", "claim": "The new builder method should be named `setFilter` instead of `withFilter`, since the project settled on using setters for n... | null |
apache__logging-log4j2__3454 | apache/logging-log4j2 | 3,454 | defect | c59fdd4a0e1478da3a0260ed07e07488f199e221 | cf060d41a6528086f2cb2ec36686b024d0e88faa | Only set default configuration name if none has been previously set (… | [#3431]
AbstractConfiguration#setToDefault() - only sets default configuration name if none has been previously set,
+ added test for this change
+ added changelog entry | diff --git a/log4j-core-test/src/test/java/org/apache/logging/log4j/core/config/Log4j_3431_Test.java b/log4j-core-test/src/test/java/org/apache/logging/log4j/core/config/Log4j_3431_Test.java
new file mode 100644
index 000000000000..a78f1e0f4a00
--- /dev/null
+++ b/log4j-core-test/src/test/java/org/apache/logging/log4j/... | 2 | 2 | 1 | [{"id": "G0", "claim": "The hand-rolled null/trim/isEmpty check added in setToDefault should use the existing Strings utility method instead.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "There is apparently a problem in Configurator1Test that ... | null |
apache__logging-log4j2__3469 | apache/logging-log4j2 | 3,469 | defect | c59fdd4a0e1478da3a0260ed07e07488f199e221 | 007b9831ae6c25974f5fb3ff2d7aa78d2aeffbb3 | Fix formatting of `s` pattern | The specialized `SecondPatternSequence` formatter is optimized to format the `ss.?S*` patterns, where seconds are padded. For the not padded (and uncommon) `s` pattern, we should use the usual `DynamicPatternSequence`.
This is the main reason for the failing #3468 test.
| diff --git a/log4j-core-test/src/test/java/org/apache/logging/log4j/core/util/internal/instant/InstantPatternDynamicFormatterTest.java b/log4j-core-test/src/test/java/org/apache/logging/log4j/core/util/internal/instant/InstantPatternDynamicFormatterTest.java
index 7829d234aaa..b8faab32ddf 100644
--- a/log4j-core-test/s... | 1 | 1 | 1 | [{"id": "G0", "claim": "vy suggests the garbage-free subminute behavior from #3338 can still be adhered to by adding a secondPaddingLength argument to SecondPatternSequence::new and updating SecondPatternSequence::formatSeconds, instead of the PR's special-case handling of unpadded second patterns, and is not keen on c... | null |
apache__logging-log4j2__3581 | apache/logging-log4j2 | 3,581 | defect | d25201a586d8757cc8f9a40c4b499710623ace73 | 0f31554b4bad21911cb58f33f4132db9c36eff67 | fix ShutdownDisabledTest and LoggerContext_shutdownDisable changelog | - Modify the LoggerContext_shutdownDisable.xml file to change the entry type from "added" to "fixed"
- Update the ShutdownDisabledTest.java file to fix the assertion check for shutdown callback
| diff --git a/log4j-core-test/src/test/java/org/apache/logging/log4j/core/ShutdownDisabledTest.java b/log4j-core-test/src/test/java/org/apache/logging/log4j/core/ShutdownDisabledTest.java
index fd7dbf2607b..09ca03bf500 100644
--- a/log4j-core-test/src/test/java/org/apache/logging/log4j/core/ShutdownDisabledTest.java
+++... | 1 | 1 | 0 | [{"id": "G0", "claim": "Both the old and new assertion message are redundant, so the reviewer proposes changing the assertion to assertNull(fieldValue, \"Shutdown callback\"), which yields a failure message (\"Shutdown callback ==> expected: <null> but was: <something>\") that is clear without adding \"is null\" or \"i... | null |
apache__logging-log4j2__3655 | apache/logging-log4j2 | 3,655 | defect | 3709962553ddc27774163eb77845b0a47a7b9684 | 663d64312357c927eca154529244bba5b53c7bec | Handle missing stack traces in ExtendedThreadInformation | Fix `ArrayIndexOutOfBoundsException` on invocation of `Message.getFormattedMessage()` when any thread has no stack trace, which occurs on some JVM implementations.
See issue: #3214
The mentioned method retrieves detail information about all existing threads and collects it in a result string. One of the informat... | diff --git a/log4j-core-test/src/test/java/org/apache/logging/log4j/core/message/ExtendedThreadInformationTest.java b/log4j-core-test/src/test/java/org/apache/logging/log4j/core/message/ExtendedThreadInformationTest.java
index 3dca41c498f1..95351959f819 100644
--- a/log4j-core-test/src/test/java/org/apache/logging/log4... | 1 | 1 | 1 | [{"id": "G0", "claim": "Rename the new helper to getFirstStackTraceElement, have it return null (annotated @Nullable from JSpecify) on an empty stack trace instead of a dummy StackTraceElement with magic values, and update the case WAITING and case TIMED_WAITING blocks accordingly to null-check the element.", "category... | null |
apache__logging-log4j2__3675 | apache/logging-log4j2 | 3,675 | defect | 2bc484c30d7ca52606ccd185584acf513417a755 | 4a0009ae346db1a0a450b8515e8e93e56bdd1c00 | StringMap: Generalize `equals`/`hashCode` across implementations | This change rewrites the `equals` and `hashCode` implementations in `SortedArrayStringMap` and `JdkMapAdapterStringMap` to support value-based equality between the two implementations.
Fixes #3669. | diff --git a/log4j-1.2-api/src/main/java/org/apache/log4j/bridge/LogEventWrapper.java b/log4j-1.2-api/src/main/java/org/apache/log4j/bridge/LogEventWrapper.java
index 15565aa040ce..480ac6273fe2 100644
--- a/log4j-1.2-api/src/main/java/org/apache/log4j/bridge/LogEventWrapper.java
+++ b/log4j-1.2-api/src/main/java/org/ap... | 4 | 3 | 2 | [{"id": "G0", "claim": "vy asks that the equality logic be centralized in an internal ReadOnlyStringMapUtil class providing static equals(ReadOnlyStringMap, ReadOnlyStringMap) and hashCode(ReadOnlyStringMap) methods and that all ReadOnlyStringMap implementations use it to implement their equals and hashCode.", "categor... | null |
apache__logging-log4j2__3681 | apache/logging-log4j2 | 3,681 | defect | 9176b44193b107b1a6c1ca9efda22f79fa20db3a | 8b964a0d65c71c0b384ce46d68a86c17741eb580 | Expunge stale entries in InternalLoggerRegistry | This pull request addresses issue #3430 by implementing a mechanism to expunge stale entries in `InternalLoggerRegistry`.
It builds upon PR #3474 and incorporates feedback from @vy and @ppkarwasz.
Key changes include:
* **Enabled stale entry detection via `ReferenceQueue`**: When a `Logger` is GC'd, its `Weak... | diff --git a/log4j-core-test/src/main/java/org/apache/logging/log4j/core/test/util/InternalLoggerRegistryGCTest.java b/log4j-core-test/src/main/java/org/apache/logging/log4j/core/test/util/InternalLoggerRegistryGCTest.java
new file mode 100644
index 00000000000..0888a08522c
--- /dev/null
+++ b/log4j-core-test/src/main/... | 13 | 11 | 2 | [{"id": "G0", "claim": "The test file is named InternalLoggerRegistryGCTest.java while the class inside is InternalLoggerRegistryTest, so rename the file and (nit) place the test class in the same package as InternalLoggerRegistry.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "int... | null |
apache__logging-log4j2__3691 | apache/logging-log4j2 | 3,691 | defect | 138404a4fd61df72cb53c40b85a16d007279229d | a44c32047f30849aae9d021f1a7a4129539ebaef | Enforce explicit names for global scripts and refine script id handling | This PR addresses issue #3176 by ensuring scripts defined in the global `<Scripts>` container have explicit, non-blank names. It also introduces a clearer distinction between user-defined names and internal script identifiers.
**Key Changes:**
* `AbstractScript` now provides `getName()` strictly for user-configured... | diff --git a/log4j-core-test/src/test/java/org/apache/logging/log4j/core/config/ScriptsPluginTest.java b/log4j-core-test/src/test/java/org/apache/logging/log4j/core/config/ScriptsPluginTest.java
new file mode 100644
index 00000000000..4bf53f52c9f
--- /dev/null
+++ b/log4j-core-test/src/test/java/org/apache/logging/log4... | 6 | 6 | 4 | [{"id": "G0", "claim": "Returning `scripts` when it is null will cause an NPE in AbstractConfiguration; the reviewer asks to mark the class @NullMarked, throw via Objects.requireNonNull(scripts), and keep returning the array when it is empty.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope... | null |
apache__logging-log4j2__3703 | apache/logging-log4j2 | 3,703 | defect | 96af9825f67f3dc0ba331dba67e1078fc7dd2c77 | 14aaac3136fee7cb78ebf488162f23acd8101ed7 | Add option to provide URIs to monitor in addition to the config file | This PR is an identical clone of #3501, though additionally adds commit signatures. Created this PR instead of force-pushing signatures to that PR to avoid truncating the git and GitHub conversations history. | diff --git a/log4j-core-test/src/test/java/org/apache/logging/log4j/core/MonitorResourcesTest.java b/log4j-core-test/src/test/java/org/apache/logging/log4j/core/MonitorResourcesTest.java
new file mode 100644
index 00000000000..4481ec62643
--- /dev/null
+++ b/log4j-core-test/src/test/java/org/apache/logging/log4j/core/M... | 3 | 2 | 0 | [{"id": "G0", "claim": "The test should use the default BuiltConfiguration (ConfigurationBuilderFactory.newConfigurationBuilder() with no explicit class) instead of PropertiesConfiguration.", "category": "design", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The Javadoc of th... | null |
apache__logging-log4j2__3718 | apache/logging-log4j2 | 3,718 | defect | aa0294d53acc9b8d831d5c2d070bc7b86832011d | 56be0ab56f8df126bea58514921402c1f2eb149a | Correct script resolution order dependency | This pull request resolves issue #3336 by fixing the script resolution failure that occurred when a `<ScriptRef>` element was placed before the `<Scripts>` block in a configuration file.
> [!IMPORTANT]
> Base your changes on `2.x` branch if you are targeting Log4j 2; use `main` otherwise.
## Checklist
Befor... | diff --git a/log4j-core-test/src/test/java/org/apache/logging/log4j/core/config/AbstractConfigurationTest.java b/log4j-core-test/src/test/java/org/apache/logging/log4j/core/config/AbstractConfigurationTest.java
index 91d4405edf2..64ce9ac3fc6 100644
--- a/log4j-core-test/src/test/java/org/apache/logging/log4j/core/confi... | 1 | 1 | 0 | [{"id": "G0", "claim": "The changelog description should format the `Scripts` and `ScriptRef` XML element names with backticks.", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}] | null |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.