This is an automated email from the ASF dual-hosted git repository. vgalaxies pushed a commit to branch intro-commons-v2 in repository https://gitbox.apache.org/repos/asf/incubator-hugegraph.git
commit 459d4413b4de2f565498dea9e7b2db526a35b353 Merge: dc3070f45 162a104eb Author: VGalaxies <[email protected]> AuthorDate: Sat Aug 10 12:14:58 2024 +0800 Merge remote-tracking branch 'commons/migrate-commons' into intro-commons-v2 hugegraph-commons/.asf.yaml | 54 ++ hugegraph-commons/.editorconfig | 31 + hugegraph-commons/.gitattributes | 8 + .../.github/ISSUE_TEMPLATE/bug_report.yml | 96 +++ .../.github/ISSUE_TEMPLATE/config.yml | 7 + .../.github/ISSUE_TEMPLATE/feature_request.yml | 15 + .../.github/ISSUE_TEMPLATE/question_ask.yml | 94 +++ hugegraph-commons/.github/outdated/.travis.yml | 11 + hugegraph-commons/.github/outdated/cla.yml | 35 + hugegraph-commons/.github/outdated/release.yml | 39 + hugegraph-commons/.github/workflows/ci.yml | 56 ++ .../.github/workflows/codeql-analysis.yml | 66 ++ .../.github/workflows/license-checker.yml | 60 ++ hugegraph-commons/.github/workflows/stale.yml | 38 + hugegraph-commons/.gitignore | 84 ++ hugegraph-commons/.licenserc.yaml | 79 ++ hugegraph-commons/DISCLAIMER | 7 + hugegraph-commons/LICENSE | 202 +++++ hugegraph-commons/NOTICE | 7 + hugegraph-commons/README.md | 66 ++ hugegraph-commons/hugegraph-common/README.md | 23 + hugegraph-commons/hugegraph-common/build.sh | 23 + hugegraph-commons/hugegraph-common/pom.xml | 302 +++++++ .../apache/hugegraph/concurrent/AtomicLock.java | 82 ++ .../apache/hugegraph/concurrent/BarrierEvent.java | 104 +++ .../org/apache/hugegraph/concurrent/KeyLock.java | 144 ++++ .../org/apache/hugegraph/concurrent/LockGroup.java | 85 ++ .../apache/hugegraph/concurrent/LockManager.java | 71 ++ .../concurrent/PausableScheduledThreadPool.java | 78 ++ .../org/apache/hugegraph/concurrent/RowLock.java | 98 +++ .../apache/hugegraph/config/ConfigConvOption.java | 47 ++ .../apache/hugegraph/config/ConfigException.java | 39 + .../hugegraph/config/ConfigListConvOption.java | 75 ++ .../apache/hugegraph/config/ConfigListOption.java | 79 ++ .../org/apache/hugegraph/config/ConfigOption.java | 37 + .../org/apache/hugegraph/config/HugeConfig.java | 216 +++++ .../org/apache/hugegraph/config/OptionChecker.java | 83 ++ .../org/apache/hugegraph/config/OptionHolder.java | 59 ++ .../org/apache/hugegraph/config/OptionSpace.java | 120 +++ .../org/apache/hugegraph/config/TypedOption.java | 194 +++++ .../org/apache/hugegraph/date/SafeDateFormat.java | 64 ++ .../java/org/apache/hugegraph/event/Event.java | 71 ++ .../java/org/apache/hugegraph/event/EventHub.java | 197 +++++ .../org/apache/hugegraph/event/EventListener.java | 27 + .../org/apache/hugegraph/func/TriFunction.java | 23 + .../hugegraph/iterator/BatchMapperIterator.java | 104 +++ .../java/org/apache/hugegraph/iterator/CIter.java | 23 + .../hugegraph/iterator/ExtendableIterator.java | 98 +++ .../apache/hugegraph/iterator/FilterIterator.java | 51 ++ .../iterator/FlatMapperFilterIterator.java | 50 ++ .../hugegraph/iterator/FlatMapperIterator.java | 89 ++ .../apache/hugegraph/iterator/LimitIterator.java | 64 ++ .../apache/hugegraph/iterator/ListIterator.java | 78 ++ .../apache/hugegraph/iterator/MapperIterator.java | 51 ++ .../org/apache/hugegraph/iterator/Metadatable.java | 23 + .../apache/hugegraph/iterator/WrappedIterator.java | 99 +++ .../hugegraph/license/LicenseCommonParam.java | 106 +++ .../hugegraph/license/LicenseCreateParam.java | 61 ++ .../hugegraph/license/LicenseExtraParam.java | 119 +++ .../hugegraph/license/LicenseInstallParam.java | 60 ++ .../apache/hugegraph/license/LicenseManager.java | 32 + .../hugegraph/license/LicenseManagerFactory.java | 30 + .../apache/hugegraph/license/LicenseParams.java | 45 + .../org/apache/hugegraph/license/MachineInfo.java | 126 +++ .../org/apache/hugegraph/perf/LightStopwatch.java | 185 ++++ .../org/apache/hugegraph/perf/NormalStopwatch.java | 302 +++++++ .../java/org/apache/hugegraph/perf/PerfUtil.java | 687 +++++++++++++++ .../java/org/apache/hugegraph/perf/Stopwatch.java | 148 ++++ .../apache/hugegraph/rest/AbstractRestClient.java | 479 +++++++++++ .../org/apache/hugegraph/rest/ClientException.java | 35 + .../hugegraph/rest/OkHttpBasicAuthInterceptor.java | 47 ++ .../hugegraph/rest/OkHttpTokenInterceptor.java | 50 ++ .../java/org/apache/hugegraph/rest/RestClient.java | 63 ++ .../apache/hugegraph/rest/RestClientConfig.java | 53 ++ .../org/apache/hugegraph/rest/RestHeaders.java | 90 ++ .../java/org/apache/hugegraph/rest/RestResult.java | 114 +++ .../apache/hugegraph/rest/SerializeException.java | 35 + .../java/org/apache/hugegraph/testutil/Assert.java | 164 ++++ .../org/apache/hugegraph/testutil/Whitebox.java | 184 ++++ .../main/java/org/apache/hugegraph/util/Bytes.java | 103 +++ .../org/apache/hugegraph/util/CheckSocket.java | 37 + .../org/apache/hugegraph/util/CollectionUtil.java | 448 ++++++++++ .../java/org/apache/hugegraph/util/DateUtil.java | 77 ++ .../src/main/java/org/apache/hugegraph/util/E.java | 66 ++ .../org/apache/hugegraph/util/ExceptionUtil.java | 49 ++ .../org/apache/hugegraph/util/ExecutorUtil.java | 111 +++ .../java/org/apache/hugegraph/util/HashUtil.java | 44 + .../apache/hugegraph/util/InsertionOrderUtil.java | 64 ++ .../org/apache/hugegraph/util/JsonUtilCommon.java | 94 +++ .../main/java/org/apache/hugegraph/util/Log.java | 32 + .../org/apache/hugegraph/util/LongEncoding.java | 151 ++++ .../org/apache/hugegraph/util/NumericUtil.java | 372 ++++++++ .../org/apache/hugegraph/util/OrderLimitMap.java | 103 +++ .../org/apache/hugegraph/util/ReflectionUtil.java | 124 +++ .../java/org/apache/hugegraph/util/StringUtil.java | 123 +++ .../java/org/apache/hugegraph/util/TimeUtil.java | 59 ++ .../java/org/apache/hugegraph/util/UnitUtil.java | 181 ++++ .../org/apache/hugegraph/util/VersionUtil.java | 236 ++++++ .../apache/hugegraph/version/CommonVersion.java | 28 + .../org/apache/hugegraph/testutil/AssertTest.java | 444 ++++++++++ .../apache/hugegraph/testutil/WhiteboxTest.java | 258 ++++++ .../org/apache/hugegraph/unit/BaseUnitTest.java | 71 ++ .../org/apache/hugegraph/unit/UnitTestSuite.java | 125 +++ .../hugegraph/unit/concurrent/AtomicLockTest.java | 62 ++ .../unit/concurrent/BarrierEventTest.java | 288 +++++++ .../hugegraph/unit/concurrent/KeyLockTest.java | 124 +++ .../hugegraph/unit/concurrent/LockGroupTest.java | 106 +++ .../hugegraph/unit/concurrent/LockManagerTest.java | 125 +++ .../PausableScheduledThreadPoolTest.java | 93 ++ .../hugegraph/unit/concurrent/RowLockTest.java | 159 ++++ .../hugegraph/unit/config/HugeConfigTest.java | 673 +++++++++++++++ .../hugegraph/unit/config/OptionSpaceTest.java | 215 +++++ .../hugegraph/unit/config/test-check-error.conf | 1 + .../hugegraph/unit/config/test-list-error.conf | 2 + .../hugegraph/unit/config/test-type-error.conf | 1 + .../org/apache/hugegraph/unit/config/test.conf | 23 + .../hugegraph/unit/date/SafeDateFormatTest.java | 127 +++ .../apache/hugegraph/unit/event/EventHubTest.java | 462 ++++++++++ .../unit/iterator/BatchMapperIteratorTest.java | 337 ++++++++ .../unit/iterator/ExtendableIteratorTest.java | 245 ++++++ .../unit/iterator/FilterIteratorTest.java | 179 ++++ .../iterator/FlatMapperFilterIteratorTest.java | 171 ++++ .../unit/iterator/FlatMapperIteratorTest.java | 169 ++++ .../hugegraph/unit/iterator/LimitIteratorTest.java | 181 ++++ .../hugegraph/unit/iterator/ListIteratorTest.java | 232 +++++ .../unit/iterator/MapperIteratorTest.java | 154 ++++ .../unit/license/LicenseCreateParamTest.java | 103 +++ .../unit/license/LicenseExtraParamTest.java | 63 ++ .../unit/license/LicenseInstallParamTest.java | 49 ++ .../hugegraph/unit/license/LicenseParamsTest.java | 86 ++ .../hugegraph/unit/license/MachineInfoTest.java | 87 ++ .../apache/hugegraph/unit/perf/PerfUtilTest.java | 468 +++++++++++ .../apache/hugegraph/unit/perf/StopwatchTest.java | 102 +++ .../hugegraph/unit/perf/testclass/TestClass.java | 105 +++ .../unit/perf/testclass/TestLightClass.java | 50 ++ .../unit/perf/testclass/TestPerfClass.java | 72 ++ .../unit/perf/testclass/TestPerfLightClass.java | 72 ++ .../unit/perf/testclass2/TestClass4Package.java | 69 ++ .../apache/hugegraph/unit/rest/RestClientTest.java | 521 ++++++++++++ .../apache/hugegraph/unit/rest/RestResultTest.java | 141 ++++ .../org/apache/hugegraph/unit/util/BytesTest.java | 169 ++++ .../hugegraph/unit/util/CollectionUtilTest.java | 572 +++++++++++++ .../apache/hugegraph/unit/util/DateUtilTest.java | 126 +++ .../org/apache/hugegraph/unit/util/EcheckTest.java | 150 ++++ .../apache/hugegraph/unit/util/HashUtilTest.java | 120 +++ .../unit/util/InsertionOrderUtilTest.java | 173 ++++ .../org/apache/hugegraph/unit/util/LogTest.java | 42 + .../hugegraph/unit/util/LongEncodingTest.java | 684 +++++++++++++++ .../hugegraph/unit/util/NumericUtilTest.java | 475 +++++++++++ .../hugegraph/unit/util/OrderLimitMapTest.java | 208 +++++ .../hugegraph/unit/util/ReflectionUtilTest.java | 161 ++++ .../apache/hugegraph/unit/util/StringUtilTest.java | 160 ++++ .../apache/hugegraph/unit/util/TimeUtilTest.java | 89 ++ .../apache/hugegraph/unit/util/UnitUtilTest.java | 665 +++++++++++++++ .../hugegraph/unit/util/VersionUtilTest.java | 169 ++++ .../apache/hugegraph/unit/version/VersionTest.java | 36 + .../src/test/resources/META-INF/MANIFEST.MF | 9 + .../src/test/resources/create-license.json | 19 + .../hugegraph-common/src/test/resources/log4j2.xml | 42 + .../org.mockito.plugins.MockMaker | 17 + .../src/test/resources/verify-license.json | 7 + .../hugegraph-dist/release-docs/LICENSE | 338 ++++++++ .../hugegraph-dist/release-docs/NOTICE | 935 +++++++++++++++++++++ .../release-docs/licenses/LICENSE-JavaHamcrest.txt | 27 + .../licenses/LICENSE-animal-sniffer.txt | 21 + .../licenses/LICENSE-aopalliance-repackaged.txt | 362 ++++++++ .../licenses/LICENSE-api-client-staging.txt | 25 + .../release-docs/licenses/LICENSE-checker-qual.txt | 22 + .../licenses/LICENSE-commons-beanutils.txt | 202 +++++ .../licenses/LICENSE-commons-codec.txt | 202 +++++ .../licenses/LICENSE-commons-collections.txt | 202 +++++ .../licenses/LICENSE-commons-configuration.txt | 202 +++++ .../licenses/LICENSE-commons-configuration2.txt | 202 +++++ .../release-docs/licenses/LICENSE-commons-io.txt | 202 +++++ .../release-docs/licenses/LICENSE-commons-lang.txt | 202 +++++ .../licenses/LICENSE-commons-lang3.txt | 202 +++++ .../licenses/LICENSE-commons-logging.txt | 202 +++++ .../release-docs/licenses/LICENSE-commons-text.txt | 202 +++++ .../licenses/LICENSE-failureaccess.txt | 202 +++++ .../licenses/LICENSE-glassfish-hk2.txt | 277 ++++++ .../release-docs/licenses/LICENSE-grpc-java.txt | 202 +++++ .../release-docs/licenses/LICENSE-gson.txt | 202 +++++ .../release-docs/licenses/LICENSE-httpclient.txt | 202 +++++ .../release-docs/licenses/LICENSE-httpcore.txt | 202 +++++ .../release-docs/licenses/LICENSE-j2objc.txt | 232 +++++ .../LICENSE-jackson-annotations-2.14.0.txt | 202 +++++ .../licenses/LICENSE-jackson-annotations.txt | 202 +++++ .../licenses/LICENSE-jackson-core-2.14.0.txt | 202 +++++ .../release-docs/licenses/LICENSE-jackson-core.txt | 202 +++++ .../licenses/LICENSE-jackson-databind-2.14.0.txt | 202 +++++ .../licenses/LICENSE-jackson-databind.txt | 202 +++++ .../licenses/LICENSE-jackson-dataformat-yaml.txt | 8 + .../licenses/LICENSE-jackson-jaxrs-base-2.14.0.txt | 8 + .../licenses/LICENSE-jackson-jaxrs-base.txt | 8 + .../LICENSE-jackson-jaxrs-json-provider-2.14.0.txt | 8 + .../LICENSE-jackson-jaxrs-json-provider.txt | 8 + ...ENSE-jackson-module-jaxb-annotations-2.14.0.txt | 8 + .../LICENSE-jackson-module-jaxb-annotations.txt | 8 + .../release-docs/licenses/LICENSE-jaf-api.txt | 29 + .../licenses/LICENSE-jakarta.activation-api.txt | 29 + .../licenses/LICENSE-jakarta.activation.txt | 277 ++++++ .../release-docs/licenses/LICENSE-javassist.txt | 357 ++++++++ .../LICENSE-javax.activation-api-1.2.0-sources.txt | 362 ++++++++ .../release-docs/licenses/LICENSE-jaxb-ri.txt | 11 + .../release-docs/licenses/LICENSE-joda-time.txt | 202 +++++ .../release-docs/licenses/LICENSE-jsonp.txt | 362 ++++++++ .../release-docs/licenses/LICENSE-junit5.txt | 98 +++ .../release-docs/licenses/LICENSE-log4j-api.txt | 202 +++++ .../release-docs/licenses/LICENSE-log4j-core.txt | 202 +++++ .../licenses/LICENSE-log4j-slf4j-impl.txt | 202 +++++ .../release-docs/licenses/LICENSE-netty.txt | 202 +++++ .../release-docs/licenses/LICENSE-okhttp.txt | 202 +++++ .../licenses/LICENSE-opentracing-java.txt | 201 +++++ .../release-docs/licenses/LICENSE-perfmark.txt | 201 +++++ .../release-docs/licenses/LICENSE-protobuf.txt | 32 + .../release-docs/licenses/LICENSE-slf4j.txt | 23 + .../release-docs/licenses/LICENSE-sofa-bolt.txt | 201 +++++ .../release-docs/licenses/LICENSE-sofa-boot.txt | 201 +++++ .../licenses/LICENSE-sofa-common-tools.txt | 201 +++++ .../release-docs/licenses/LICENSE-sofa-hessian.txt | 201 +++++ .../release-docs/licenses/LICENSE-sofa-lookout.txt | 201 +++++ .../release-docs/licenses/LICENSE-sofa-rpc.txt | 201 +++++ .../licenses/LICENSE-swagger-annotations.txt | 11 + .../release-docs/licenses/LICENSE-swagger-core.txt | 202 +++++ .../licenses/LICENSE-swagger-models.txt | 11 + .../hugegraph-dist/scripts/apache-release.sh | 105 +++ .../scripts/dependency/check_dependencies.sh | 32 + .../scripts/dependency/known-dependencies.txt | 77 ++ .../dependency/regenerate_known_dependencies.sh | 33 + hugegraph-commons/hugegraph-rpc/README.md | 14 + hugegraph-commons/hugegraph-rpc/pom.xml | 170 ++++ .../org/apache/hugegraph/config/RpcOptions.java | 158 ++++ .../apache/hugegraph/rpc/RpcClientProvider.java | 74 ++ .../org/apache/hugegraph/rpc/RpcCommonConfig.java | 44 + .../apache/hugegraph/rpc/RpcConsumerConfig.java | 215 +++++ .../org/apache/hugegraph/rpc/RpcException.java | 39 + .../apache/hugegraph/rpc/RpcProviderConfig.java | 83 ++ .../java/org/apache/hugegraph/rpc/RpcServer.java | 147 ++++ .../hugegraph/rpc/RpcServiceConfig4Client.java | 35 + .../hugegraph/rpc/RpcServiceConfig4Server.java | 29 + .../org/apache/hugegraph/version/RpcVersion.java | 28 + .../org/apache/hugegraph/unit/BaseUnitTest.java | 56 ++ .../org/apache/hugegraph/unit/ExceptionTest.java | 56 ++ .../apache/hugegraph/unit/ServerClientTest.java | 778 +++++++++++++++++ .../org/apache/hugegraph/unit/UnitTestSuite.java | 30 + .../org/apache/hugegraph/unit/VersionTest.java | 36 + .../hugegraph-rpc/src/test/resources/log4j2.xml | 42 + .../src/test/resources/rpc-client-lb.properties | 26 + .../src/test/resources/rpc-client.properties | 26 + .../src/test/resources/rpc-client345.properties | 26 + .../src/test/resources/rpc-client346.properties | 26 + .../src/test/resources/rpc-client67.properties | 26 + .../test/resources/rpc-server-adaptive.properties | 27 + .../test/resources/rpc-server-random.properties | 26 + .../src/test/resources/rpc-server.properties | 26 + .../test/resources/rpc-server1-client.properties | 26 + .../test/resources/rpc-server2-client.properties | 26 + .../src/test/resources/rpc-server3.properties | 26 + .../src/test/resources/rpc-server4.properties | 26 + .../src/test/resources/rpc-server5.properties | 26 + hugegraph-commons/pom.xml | 343 ++++++++ hugegraph-commons/style/checkstyle.xml | 234 ++++++ 262 files changed, 35309 insertions(+)
