From 8b81380ed232180e0f4093c6fa47196b9e0969bf Mon Sep 17 00:00:00 2001 From: "chen.ma" Date: Mon, 25 Apr 2022 21:57:56 +0800 Subject: [PATCH] Add open source protocols and formatting code --- .../auth/config/GlobalSecurityConfig.java | 17 +++++++ .../cn/hippo4j/auth/constant/Constants.java | 17 +++++++ .../auth/filter/JWTAuthenticationFilter.java | 20 +++++++- .../auth/filter/JWTAuthorizationFilter.java | 20 +++++++- .../hippo4j/auth/mapper/PermissionMapper.java | 17 +++++++ .../cn/hippo4j/auth/mapper/RoleMapper.java | 17 +++++++ .../cn/hippo4j/auth/mapper/UserMapper.java | 17 +++++++ .../cn/hippo4j/auth/model/PermissionInfo.java | 17 +++++++ .../java/cn/hippo4j/auth/model/RoleInfo.java | 17 +++++++ .../java/cn/hippo4j/auth/model/UserInfo.java | 17 +++++++ .../permission/PermissionQueryPageReqDTO.java | 17 +++++++ .../biz/permission/PermissionRespDTO.java | 17 +++++++ .../model/biz/role/RoleQueryPageReqDTO.java | 17 +++++++ .../auth/model/biz/role/RoleRespDTO.java | 17 +++++++ .../hippo4j/auth/model/biz/user/JwtUser.java | 17 +++++++ .../auth/model/biz/user/LoginUser.java | 17 +++++++ .../model/biz/user/UserQueryPageReqDTO.java | 17 +++++++ .../auth/model/biz/user/UserReqDTO.java | 17 +++++++ .../auth/model/biz/user/UserRespDTO.java | 17 +++++++ .../cn/hippo4j/auth/security/AuthManager.java | 17 +++++++ .../auth/security/JwtTokenManager.java | 17 +++++++ .../auth/service/PermissionService.java | 17 +++++++ .../cn/hippo4j/auth/service/RoleService.java | 17 +++++++ .../cn/hippo4j/auth/service/UserService.java | 17 +++++++ .../service/impl/PermissionServiceImpl.java | 17 +++++++ .../auth/service/impl/RoleServiceImpl.java | 17 +++++++ .../service/impl/UserDetailsServiceImpl.java | 17 +++++++ .../auth/service/impl/UserServiceImpl.java | 17 +++++++ .../cn/hippo4j/auth/toolkit/JwtTokenUtil.java | 17 +++++++ .../java/cn/hippo4j/auth/toolkit/ReturnT.java | 17 +++++++ .../common/api/ClientCloseHookExecute.java | 17 +++++++ .../cn/hippo4j/common/api/JsonFacade.java | 17 +++++++ .../common/api/NotifyConfigBuilder.java | 17 +++++++ .../hippo4j/common/api/ThreadDetailState.java | 17 +++++++ .../common/api/ThreadPoolDynamicRefresh.java | 17 +++++++ .../config/ApplicationContextHolder.java | 17 +++++++ .../cn/hippo4j/common/constant/Constants.java | 17 +++++++ .../common/design/builder/Builder.java | 17 +++++++ .../observer/AbstractSubjectCenter.java | 17 +++++++ .../common/design/observer/Observer.java | 17 +++++++ .../design/observer/ObserverMessage.java | 17 +++++++ .../java/cn/hippo4j/common/enums/DelEnum.java | 17 +++++++ .../cn/hippo4j/common/enums/EnableEnum.java | 17 +++++++ .../common/executor/ExecutorFactory.java | 17 +++++++ .../common/executor/ThreadPoolManager.java | 17 +++++++ .../cn/hippo4j/common/function/Matcher.java | 17 +++++++ .../common/function/NoArgsConsumer.java | 17 +++++++ .../common/model/GlobalRemotePoolInfo.java | 17 +++++++ .../cn/hippo4j/common/model/InstanceInfo.java | 18 ++++++- .../common/model/ManyPoolRunStateInfo.java | 17 +++++++ .../cn/hippo4j/common/model/PoolBaseInfo.java | 17 +++++++ .../hippo4j/common/model/PoolParameter.java | 17 +++++++ .../common/model/PoolParameterInfo.java | 17 +++++++ .../common/model/PoolRunStateInfo.java | 17 +++++++ .../common/model/ThreadDetailStateInfo.java | 17 +++++++ .../cn/hippo4j/common/model/TokenInfo.java | 17 +++++++ .../common/monitor/AbstractMessage.java | 17 +++++++ .../cn/hippo4j/common/monitor/Message.java | 17 +++++++ .../common/monitor/MessageRequest.java | 17 +++++++ .../common/monitor/MessageTypeEnum.java | 17 +++++++ .../common/monitor/MessageWrapper.java | 17 +++++++ .../common/monitor/RuntimeMessage.java | 17 +++++++ .../common/notify/AlarmControlDTO.java | 17 +++++++ .../common/notify/AlarmControlHandler.java | 17 +++++++ .../notify/HippoBaseSendMessageService.java | 17 +++++++ .../notify/HippoSendMessageService.java | 17 +++++++ .../common/notify/NotifyConfigDTO.java | 17 +++++++ .../common/notify/NotifyPlatformEnum.java | 17 +++++++ .../hippo4j/common/notify/NotifyTypeEnum.java | 17 +++++++ .../common/notify/SendMessageHandler.java | 17 +++++++ .../common/notify/ThreadPoolNotifyAlarm.java | 17 +++++++ .../common/notify/ThreadPoolNotifyDTO.java | 17 +++++++ .../notify/platform/DingAlarmConstants.java | 17 +++++++ .../platform/DingSendMessageHandler.java | 23 +++++++-- .../notify/platform/LarkAlarmConstants.java | 25 +++++++++- .../platform/LarkSendMessageHandler.java | 26 +++++++--- .../notify/platform/WeChatAlarmConstants.java | 17 +++++++ .../platform/WeChatSendMessageHandler.java | 23 +++++++-- .../notify/request/AlarmNotifyRequest.java | 17 +++++++ .../request/ChangeParameterNotifyRequest.java | 17 +++++++ .../request/RobotAlarmNotifyRequest.java | 17 +++++++ .../RobotChangeParameterNotifyRequest.java | 17 +++++++ .../request/ThreadPoolNotifyRequest.java | 17 +++++++ .../request/base/BaseNotifyRequest.java | 17 +++++++ .../notify/request/base/NotifyRequest.java | 17 +++++++ .../cn/hippo4j/common/toolkit/ArrayUtil.java | 21 ++++++++- .../cn/hippo4j/common/toolkit/Assert.java | 17 +++++++ .../common/toolkit/ByteConvertUtil.java | 17 +++++++ .../common/toolkit/CollectionUtil.java | 18 ++++++- .../hippo4j/common/toolkit/ConditionUtil.java | 17 +++++++ .../hippo4j/common/toolkit/ContentUtil.java | 17 +++++++ .../cn/hippo4j/common/toolkit/GroupKey.java | 17 +++++++ .../cn/hippo4j/common/toolkit/JSONUtil.java | 17 +++++++ .../common/toolkit/JacksonHandler.java | 17 +++++++ .../cn/hippo4j/common/toolkit/Md5Util.java | 17 +++++++ .../common/toolkit/MessageConvert.java | 17 +++++++ .../hippo4j/common/toolkit/ReflectUtil.java | 17 +++++++ .../cn/hippo4j/common/toolkit/StringUtil.java | 17 +++++++ .../cn/hippo4j/common/toolkit/ThreadUtil.java | 17 +++++++ .../hippo4j/common/toolkit/UserContext.java | 17 +++++++ .../cn/hippo4j/common/web/base/Result.java | 17 +++++++ .../cn/hippo4j/common/web/base/Results.java | 17 +++++++ .../web/exception/AbstractException.java | 17 +++++++ .../common/web/exception/ErrorCode.java | 17 +++++++ .../common/web/exception/ErrorCodeEnum.java | 17 +++++++ .../web/exception/ServiceException.java | 17 +++++++ .../hippo4j/config/config/CommonConfig.java | 17 +++++++ .../config/config/MyMetaObjectHandler.java | 17 +++++++ .../config/config/MybatisPlusConfig.java | 17 +++++++ .../config/ServerBootstrapProperties.java | 17 +++++++ .../config/controller/ConfigController.java | 25 ++++++++-- .../hippo4j/config/event/AbstractEvent.java | 17 +++++++ .../config/event/AbstractSlowEvent.java | 17 +++++++ .../config/event/ConfigDataChangeEvent.java | 17 +++++++ .../config/event/LocalDataChangeEvent.java | 17 +++++++ .../config/mapper/ConfigInfoMapper.java | 17 +++++++ .../config/mapper/ConfigInstanceMapper.java | 17 +++++++ .../config/mapper/DashboardMapper.java | 17 +++++++ .../config/mapper/HisRunDataMapper.java | 18 ++++++- .../hippo4j/config/mapper/ItemInfoMapper.java | 17 +++++++ .../config/mapper/LogRecordMapper.java | 17 +++++++ .../config/mapper/NotifyInfoMapper.java | 17 +++++++ .../config/mapper/TenantInfoMapper.java | 17 +++++++ .../cn/hippo4j/config/model/CacheItem.java | 17 +++++++ .../hippo4j/config/model/ConfigAllInfo.java | 17 +++++++ .../cn/hippo4j/config/model/ConfigInfo.java | 17 +++++++ .../hippo4j/config/model/ConfigInfoBase.java | 17 +++++++ .../config/model/ConfigInstanceInfo.java | 17 +++++++ .../hippo4j/config/model/HisRunDataInfo.java | 17 +++++++ .../cn/hippo4j/config/model/ItemInfo.java | 17 +++++++ .../cn/hippo4j/config/model/NotifyInfo.java | 17 +++++++ .../cn/hippo4j/config/model/TenantInfo.java | 17 +++++++ .../model/biz/item/ItemQueryReqDTO.java | 17 +++++++ .../config/model/biz/item/ItemRespDTO.java | 17 +++++++ .../config/model/biz/item/ItemSaveReqDTO.java | 18 ++++++- .../model/biz/item/ItemUpdateReqDTO.java | 17 +++++++ .../model/biz/log/LogRecordQueryReqDTO.java | 17 +++++++ .../model/biz/log/LogRecordRespDTO.java | 17 +++++++ .../biz/monitor/MonitorActiveRespDTO.java | 17 +++++++ .../model/biz/monitor/MonitorQueryReqDTO.java | 17 +++++++ .../model/biz/monitor/MonitorRespDTO.java | 17 +++++++ .../model/biz/notify/NotifyListRespDTO.java | 17 +++++++ .../model/biz/notify/NotifyQueryReqDTO.java | 17 +++++++ .../config/model/biz/notify/NotifyReqDTO.java | 17 +++++++ .../model/biz/notify/NotifyRespDTO.java | 17 +++++++ .../model/biz/tenant/TenantQueryReqDTO.java | 17 +++++++ .../model/biz/tenant/TenantRespDTO.java | 17 +++++++ .../model/biz/tenant/TenantSaveReqDTO.java | 17 +++++++ .../model/biz/tenant/TenantUpdateReqDTO.java | 17 +++++++ .../biz/threadpool/ThreadPoolDelReqDTO.java | 17 +++++++ .../biz/threadpool/ThreadPoolQueryReqDTO.java | 17 +++++++ .../biz/threadpool/ThreadPoolRespDTO.java | 17 +++++++ .../ThreadPoolSaveOrUpdateReqDTO.java | 17 +++++++ .../AbstractMonitorDataExecuteStrategy.java | 17 +++++++ .../monitor/DefaultMonitorDataResolver.java | 17 +++++++ .../monitor/QueryMonitorExecuteChoose.java | 17 +++++++ .../config/monitor/RuntimeDataResolver.java | 17 +++++++ .../monitor/TimeCleanHistoryDataTask.java | 17 +++++++ .../config/notify/DefaultPublisher.java | 21 ++++++++- .../config/notify/DefaultSharePublisher.java | 17 +++++++ .../hippo4j/config/notify/EventPublisher.java | 17 +++++++ .../hippo4j/config/notify/NotifyCenter.java | 17 +++++++ .../listener/AbstractSmartSubscriber.java | 17 +++++++ .../notify/listener/AbstractSubscriber.java | 17 +++++++ .../config/service/ConfigCacheService.java | 17 +++++++ .../config/service/ConfigChangePublisher.java | 17 +++++++ .../config/service/ConfigServletInner.java | 17 +++++++ .../config/service/LongPollingService.java | 19 +++++++- .../hippo4j/config/service/SwitchService.java | 17 +++++++ .../config/service/biz/ConfigService.java | 17 +++++++ .../config/service/biz/HisRunDataService.java | 17 +++++++ .../config/service/biz/ItemService.java | 17 +++++++ .../service/biz/LogRecordBizService.java | 17 +++++++ .../config/service/biz/NotifyService.java | 17 +++++++ .../config/service/biz/TenantService.java | 17 +++++++ .../config/service/biz/ThreadPoolService.java | 17 +++++++ .../service/biz/impl/ConfigServiceImpl.java | 30 ++++++++---- .../biz/impl/HisRunDataServiceImpl.java | 17 +++++++ .../service/biz/impl/ItemServiceImpl.java | 17 +++++++ .../biz/impl/LogRecordBizServiceImpl.java | 17 +++++++ .../biz/impl/LogRecordServiceImpl.java | 17 +++++++ .../service/biz/impl/NotifyServiceImpl.java | 17 +++++++ .../service/biz/impl/TenantServiceImpl.java | 25 +++++++--- .../biz/impl/ThreadPoolServiceImpl.java | 27 +++++++---- .../ClientCloseHookRemoveConfigCache.java | 20 +++++++- .../handler/CustomOperatorGetServiceImpl.java | 17 +++++++ .../handler/TenantIdFunctionServiceImpl.java | 17 +++++++ .../cn/hippo4j/config/toolkit/BeanUtil.java | 17 +++++++ .../cn/hippo4j/config/toolkit/ClassUtil.java | 17 +++++++ .../config/toolkit/ConfigExecutor.java | 17 +++++++ .../cn/hippo4j/config/toolkit/EnvUtil.java | 17 +++++++ .../cn/hippo4j/config/toolkit/MapUtil.java | 21 +++++++-- .../hippo4j/config/toolkit/Md5ConfigUtil.java | 18 ++++++- .../hippo4j/config/toolkit/RequestUtil.java | 17 +++++++ .../config/toolkit/SimpleReadWriteLock.java | 17 +++++++ .../config/toolkit/SingletonRepository.java | 17 +++++++ .../config/GlobalExceptionHandler.java | 17 +++++++ .../cn/hippo4j/console/config/WebConfig.java | 17 +++++++ .../controller/ClientCloseHookController.java | 17 +++++++ .../controller/DashboardController.java | 17 +++++++ .../controller/HealthCheckController.java | 17 +++++++ .../console/controller/ItemController.java | 17 +++++++ .../controller/LogRecordController.java | 17 +++++++ .../console/controller/MonitorController.java | 17 +++++++ .../console/controller/NotifyController.java | 17 +++++++ .../controller/PermissionController.java | 17 +++++++ .../console/controller/RoleController.java | 17 +++++++ .../console/controller/TenantController.java | 17 +++++++ .../controller/ThreadPoolController.java | 17 +++++++ .../console/controller/UserController.java | 17 +++++++ .../cn/hippo4j/console/model/ChartInfo.java | 17 +++++++ .../hippo4j/console/model/LineChartInfo.java | 17 +++++++ .../hippo4j/console/model/PieChartInfo.java | 17 +++++++ .../hippo4j/console/model/RankingChart.java | 17 +++++++ .../cn/hippo4j/console/model/TenantChart.java | 17 +++++++ .../console/model/ThreadPoolInstanceInfo.java | 17 +++++++ .../console/service/DashboardService.java | 17 +++++++ .../service/impl/DashboardServiceImpl.java | 20 +++++++- .../config/BootstrapPropertiesInterface.java | 17 +++++++ .../core/config/ConfigEmptyException.java | 17 +++++++ .../core/config/UtilAutoConfiguration.java | 17 +++++++ .../config/WebThreadPoolConfiguration.java | 17 +++++++ .../core/enable/BeforeCheckConfiguration.java | 35 +++++++++----- .../core/enable/EnableDynamicThreadPool.java | 17 +++++++ .../core/enable/MarkerConfiguration.java | 17 +++++++ .../core/executor/DynamicThreadPool.java | 17 +++++++ .../executor/DynamicThreadPoolExecutor.java | 17 +++++++ .../executor/DynamicThreadPoolWrapper.java | 17 +++++++ .../ThreadPoolNotifyAlarmHandler.java | 20 +++++++- .../manage/GlobalNotifyAlarmManage.java | 17 +++++++ .../manage/GlobalThreadPoolManage.java | 17 +++++++ .../state/AbstractThreadPoolRuntime.java | 17 +++++++ .../state/ThreadPoolRunStateHandler.java | 20 +++++++- .../state/ThreadPoolStatusHandler.java | 17 +++++++ .../AbstractBuildThreadPoolTemplate.java | 21 +++++++-- .../AbstractDynamicExecutorSupport.java | 21 ++++++++- .../support/CommonDynamicThreadPool.java | 17 +++++++ .../support/FastThreadPoolExecutor.java | 17 +++++++ .../core/executor/support/QueueTypeEnum.java | 20 +++++++- .../executor/support/RejectedPolicies.java | 17 +++++++ .../executor/support/RejectedTypeEnum.java | 17 +++++++ .../ResizableCapacityLinkedBlockIngQueue.java | 17 +++++++ .../core/executor/support/TaskQueue.java | 17 +++++++ .../support/ThreadFactoryBuilder.java | 17 +++++++ .../executor/support/ThreadPoolBuilder.java | 17 +++++++ .../support/ThreadPoolExecutorTemplate.java | 18 ++++++- .../web/AbstractWebThreadPoolService.java | 17 +++++++ .../web/JettyWebThreadPoolHandler.java | 20 +++++++- .../web/TomcatWebThreadPoolHandler.java | 20 +++++++- .../web/UndertowWebThreadPoolHandler.java | 23 +++++++-- .../web/WebThreadPoolHandlerChoose.java | 17 +++++++ .../web/WebThreadPoolRunStateHandler.java | 20 +++++++- .../executor/web/WebThreadPoolService.java | 17 +++++++ .../DynamicThreadPoolBannerHandler.java | 17 +++++++ .../proxy/RejectedProxyInvocationHandler.java | 17 +++++++ .../hippo4j/core/proxy/RejectedProxyUtil.java | 20 +++++++- .../hippo4j/core/spi/CustomBlockingQueue.java | 17 +++++++ .../spi/CustomRejectedExecutionHandler.java | 17 +++++++ .../spi/DynamicThreadPoolServiceLoader.java | 17 +++++++ .../ServiceLoaderInstantiationException.java | 18 ++++++- .../hippo4j/core/toolkit/CalculateUtil.java | 17 +++++++ .../cn/hippo4j/core/toolkit/IdentifyUtil.java | 23 +++++++-- .../cn/hippo4j/core/toolkit/SystemClock.java | 17 +++++++ .../core/toolkit/TraceContextUtil.java | 17 +++++++ .../inet/DynamicThreadPoolAnnotationUtil.java | 17 +++++++ .../hippo4j/core/toolkit/inet/InetUtils.java | 19 +++++++- .../toolkit/inet/InetUtilsProperties.java | 17 +++++++ .../config/RegistryConfiguration.java | 17 +++++++ .../controller/ApplicationController.java | 17 +++++++ .../discovery/core/BaseInstanceRegistry.java | 20 +++++++- .../core/ClientCloseHookRemoveNode.java | 20 +++++++- .../discovery/core/InstanceRegistry.java | 17 +++++++ .../java/cn/hippo4j/discovery/core/Lease.java | 17 +++++++ .../Hippo4jCoreApolloExampleApplication.java | 17 +++++++ ...po4jCoreApolloExampleApplicationTests.java | 17 +++++++ .../Hippo4jCoreNacosExampleApplication.java | 17 +++++++ ...ppo4jCoreNacosExampleApplicationTests.java | 17 +++++++ ...ippo4jCoreZookeeperExampleApplication.java | 17 +++++++ .../example/core/config/ThreadPoolConfig.java | 17 +++++++ .../core/constant/GlobalTestConstant.java | 17 +++++++ .../ErrorLogRejectedExecutionHandler.java | 17 +++++++ .../core/handler/TaskTraceBuilderHandler.java | 17 +++++++ .../core/inittest/AlarmSendMessageTest.java | 17 +++++++ .../core/inittest/RunStateHandlerTest.java | 17 +++++++ .../core/inittest/TaskDecoratorTest.java | 17 +++++++ .../Hippo4JServerExampleApplication.java | 17 +++++++ .../cn/hippo4j/server/ServerApplication.java | 17 +++++++ .../BaseSpringApplicationRunListener.java | 17 +++++++ .../listener/Hippo4JApplicationListener.java | 17 +++++++ .../listener/StartingApplicationListener.java | 20 +++++++- .../starter/common/ConfigFileTypeEnum.java | 17 +++++++ .../config/BootstrapCoreProperties.java | 17 +++++++ ...ynamicThreadPoolCoreAutoConfiguration.java | 17 +++++++ .../starter/config/ExecutorProperties.java | 17 +++++++ .../config/NotifyPlatformProperties.java | 17 +++++++ .../config/WebThreadPoolProperties.java | 17 +++++++ .../AbstractDynamicThreadPoolMonitor.java | 17 +++++++ .../monitor/DynamicThreadPoolMonitor.java | 17 +++++++ .../DynamicThreadPoolMonitorExecutor.java | 23 +++++++-- .../starter/monitor/LogMonitorHandler.java | 17 +++++++ .../starter/monitor/MetricMonitorHandler.java | 20 +++++++- .../starter/monitor/ThreadPoolMonitor.java | 17 +++++++ .../notify/CoreNotifyConfigBuilder.java | 20 +++++++- .../starter/parser/AbstractConfigParser.java | 17 +++++++ .../starter/parser/ConfigFileTypeEnum.java | 17 +++++++ .../core/starter/parser/ConfigParser.java | 17 +++++++ .../starter/parser/ConfigParserHandler.java | 17 +++++++ .../parser/PropertiesConfigParser.java | 17 +++++++ .../core/starter/parser/YamlConfigParser.java | 17 +++++++ .../AbstractCoreThreadPoolDynamicRefresh.java | 29 ++++++++---- .../refresher/ApolloRefresherHandler.java | 20 +++++++- .../BootstrapCorePropertiesBinderAdapt.java | 24 ++++++++-- .../refresher/NacosCloudRefresherHandler.java | 17 +++++++ .../refresher/NacosRefresherHandler.java | 20 +++++++- .../refresher/ZookeeperRefresherHandler.java | 17 +++++++ .../DynamicThreadPoolPostProcessor.java | 20 +++++++- .../support/GlobalCoreThreadPoolManage.java | 17 +++++++ .../starter/config/BootstrapProperties.java | 17 +++++++ .../config/DiscoveryConfiguration.java | 17 +++++++ .../DynamicThreadPoolAutoConfiguration.java | 19 +++++++- .../config/HttpClientConfiguration.java | 17 +++++++ .../config/MessageNotifyConfiguration.java | 17 +++++++ .../controller/PoolRunStateController.java | 17 +++++++ .../controller/WebThreadPoolController.java | 17 +++++++ .../core/BaseThreadDetailStateHandler.java | 17 +++++++ .../cn/hippo4j/starter/core/CacheData.java | 17 +++++++ .../cn/hippo4j/starter/core/ClientWorker.java | 21 +++++++-- .../starter/core/ConfigEmptyAnalyzer.java | 17 +++++++ .../hippo4j/starter/core/ConfigService.java | 17 +++++++ .../hippo4j/starter/core/DiscoveryClient.java | 20 +++++++- .../core/DynamicThreadPoolPostProcessor.java | 21 +++++++-- .../cn/hippo4j/starter/core/Listener.java | 17 +++++++ .../core/ServerThreadPoolDynamicRefresh.java | 20 +++++++- .../core/ShutdownExecuteException.java | 17 +++++++ .../starter/core/ThreadPoolConfigService.java | 17 +++++++ .../starter/core/ThreadPoolOperation.java | 17 +++++++ .../core/ThreadPoolSubscribeCallback.java | 17 +++++++ .../event/ApplicationCompleteEvent.java | 17 +++++++ .../ApplicationContentPostProcessor.java | 17 +++++++ .../starter/event/MonitorEventExecutor.java | 17 +++++++ .../monitor/ReportingEventExecutor.java | 23 +++++++-- .../starter/monitor/collect/Collector.java | 17 +++++++ .../monitor/collect/RunTimeInfoCollector.java | 17 +++++++ .../monitor/send/HttpConnectSender.java | 17 +++++++ .../starter/monitor/send/MessageSender.java | 17 +++++++ .../notify/ServerNotifyConfigBuilder.java | 23 +++++++-- .../starter/remote/AbstractHealthCheck.java | 20 +++++++- .../cn/hippo4j/starter/remote/HttpAgent.java | 17 +++++++ .../remote/HttpScheduledHealthCheck.java | 17 +++++++ .../starter/remote/ServerHealthCheck.java | 17 +++++++ .../starter/remote/ServerHttpAgent.java | 23 +++++++-- .../starter/remote/ServerListManager.java | 19 +++++++- .../starter/security/SecurityProxy.java | 17 +++++++ .../starter/toolkit/CloudCommonIdUtil.java | 17 +++++++ .../starter/toolkit/HttpClientUtil.java | 17 +++++++ .../wrapper/ManagerListenerWrapper.java | 17 +++++++ .../starter/test/MonitorPerformanceTest.java | 23 +++++++-- .../RejectedExecutionHandlerProxyTest.java | 18 ++++++- ...izableCapacityLinkedBlockIngQueueTest.java | 47 ++++++++++++------- .../tools/logrecord/annotation/LogField.java | 17 +++++++ .../tools/logrecord/annotation/LogRecord.java | 17 +++++++ .../tools/logrecord/aop/LogRecordAspect.java | 17 +++++++ .../logrecord/compare/AbstractEquator.java | 20 +++++++- .../tools/logrecord/compare/Equator.java | 17 +++++++ .../tools/logrecord/compare/FieldInfo.java | 18 ++++++- .../logrecord/compare/GetterBaseEquator.java | 19 +++++++- .../logrecord/config/LogRecordConfig.java | 18 ++++++- .../logrecord/context/LogRecordContext.java | 17 +++++++ .../logrecord/enums/LogRecordTypeEnum.java | 17 +++++++ .../tools/logrecord/model/LogRecordInfo.java | 17 +++++++ .../tools/logrecord/model/LogRecordOps.java | 17 +++++++ .../logrecord/model/MethodExecuteResult.java | 17 +++++++ .../tools/logrecord/model/Operator.java | 17 +++++++ .../parse/LogRecordEvaluationContext.java | 17 +++++++ .../parse/LogRecordExpressionEvaluator.java | 17 +++++++ .../parse/LogRecordOperationSource.java | 17 +++++++ .../logrecord/parse/LogRecordValueParser.java | 17 +++++++ .../logrecord/service/FunctionService.java | 17 +++++++ .../logrecord/service/LogRecordService.java | 17 +++++++ .../logrecord/service/OperatorGetService.java | 17 +++++++ .../logrecord/service/ParseFunction.java | 17 +++++++ .../impl/DefaultFunctionServiceImpl.java | 17 +++++++ .../impl/DefaultLogRecordServiceImpl.java | 17 +++++++ .../impl/DefaultOperatorGetServiceImpl.java | 17 +++++++ .../service/impl/DefaultParseFunction.java | 17 +++++++ .../service/impl/ParseFunctionFactory.java | 17 +++++++ 386 files changed, 6663 insertions(+), 193 deletions(-) diff --git a/hippo4j-auth/src/main/java/cn/hippo4j/auth/config/GlobalSecurityConfig.java b/hippo4j-auth/src/main/java/cn/hippo4j/auth/config/GlobalSecurityConfig.java index 25b364a1..72bb6d0e 100644 --- a/hippo4j-auth/src/main/java/cn/hippo4j/auth/config/GlobalSecurityConfig.java +++ b/hippo4j-auth/src/main/java/cn/hippo4j/auth/config/GlobalSecurityConfig.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.auth.config; import cn.hippo4j.auth.constant.Constants; diff --git a/hippo4j-auth/src/main/java/cn/hippo4j/auth/constant/Constants.java b/hippo4j-auth/src/main/java/cn/hippo4j/auth/constant/Constants.java index 739752d0..feba615e 100644 --- a/hippo4j-auth/src/main/java/cn/hippo4j/auth/constant/Constants.java +++ b/hippo4j-auth/src/main/java/cn/hippo4j/auth/constant/Constants.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.auth.constant; /** diff --git a/hippo4j-auth/src/main/java/cn/hippo4j/auth/filter/JWTAuthenticationFilter.java b/hippo4j-auth/src/main/java/cn/hippo4j/auth/filter/JWTAuthenticationFilter.java index b7d52472..220a119c 100644 --- a/hippo4j-auth/src/main/java/cn/hippo4j/auth/filter/JWTAuthenticationFilter.java +++ b/hippo4j-auth/src/main/java/cn/hippo4j/auth/filter/JWTAuthenticationFilter.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.auth.filter; import cn.hippo4j.auth.model.biz.user.JwtUser; @@ -55,8 +72,7 @@ public class JWTAuthenticationFilter extends UsernamePasswordAuthenticationFilte LoginUser loginUser = new ObjectMapper().readValue(request.getInputStream(), LoginUser.class); rememberMe.set(loginUser.getRememberMe()); return authenticationManager.authenticate( - new UsernamePasswordAuthenticationToken(loginUser.getUsername(), loginUser.getPassword(), new ArrayList()) - ); + new UsernamePasswordAuthenticationToken(loginUser.getUsername(), loginUser.getPassword(), new ArrayList())); } catch (IOException e) { logger.error("attemptAuthentication error :{}", e); return null; diff --git a/hippo4j-auth/src/main/java/cn/hippo4j/auth/filter/JWTAuthorizationFilter.java b/hippo4j-auth/src/main/java/cn/hippo4j/auth/filter/JWTAuthorizationFilter.java index a303ab6a..8123987e 100644 --- a/hippo4j-auth/src/main/java/cn/hippo4j/auth/filter/JWTAuthorizationFilter.java +++ b/hippo4j-auth/src/main/java/cn/hippo4j/auth/filter/JWTAuthorizationFilter.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.auth.filter; import cn.hippo4j.auth.security.JwtTokenManager; @@ -108,8 +125,7 @@ public class JWTAuthorizationFilter extends BasicAuthenticationFilter { String role = JwtTokenUtil.getUserRole(token); if (username != null) { return new UsernamePasswordAuthenticationToken(username, null, - Collections.singleton(new SimpleGrantedAuthority(role)) - ); + Collections.singleton(new SimpleGrantedAuthority(role))); } return null; diff --git a/hippo4j-auth/src/main/java/cn/hippo4j/auth/mapper/PermissionMapper.java b/hippo4j-auth/src/main/java/cn/hippo4j/auth/mapper/PermissionMapper.java index f0977313..da7b24c2 100644 --- a/hippo4j-auth/src/main/java/cn/hippo4j/auth/mapper/PermissionMapper.java +++ b/hippo4j-auth/src/main/java/cn/hippo4j/auth/mapper/PermissionMapper.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.auth.mapper; import com.baomidou.mybatisplus.core.mapper.BaseMapper; diff --git a/hippo4j-auth/src/main/java/cn/hippo4j/auth/mapper/RoleMapper.java b/hippo4j-auth/src/main/java/cn/hippo4j/auth/mapper/RoleMapper.java index 0286d0cc..aefd96c0 100644 --- a/hippo4j-auth/src/main/java/cn/hippo4j/auth/mapper/RoleMapper.java +++ b/hippo4j-auth/src/main/java/cn/hippo4j/auth/mapper/RoleMapper.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.auth.mapper; import com.baomidou.mybatisplus.core.mapper.BaseMapper; diff --git a/hippo4j-auth/src/main/java/cn/hippo4j/auth/mapper/UserMapper.java b/hippo4j-auth/src/main/java/cn/hippo4j/auth/mapper/UserMapper.java index 317c6023..9da875e6 100644 --- a/hippo4j-auth/src/main/java/cn/hippo4j/auth/mapper/UserMapper.java +++ b/hippo4j-auth/src/main/java/cn/hippo4j/auth/mapper/UserMapper.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.auth.mapper; import cn.hippo4j.auth.model.UserInfo; diff --git a/hippo4j-auth/src/main/java/cn/hippo4j/auth/model/PermissionInfo.java b/hippo4j-auth/src/main/java/cn/hippo4j/auth/model/PermissionInfo.java index 2c8faaaa..bf4bcd59 100644 --- a/hippo4j-auth/src/main/java/cn/hippo4j/auth/model/PermissionInfo.java +++ b/hippo4j-auth/src/main/java/cn/hippo4j/auth/model/PermissionInfo.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.auth.model; import com.baomidou.mybatisplus.annotation.*; diff --git a/hippo4j-auth/src/main/java/cn/hippo4j/auth/model/RoleInfo.java b/hippo4j-auth/src/main/java/cn/hippo4j/auth/model/RoleInfo.java index f3bca4a4..230f760b 100644 --- a/hippo4j-auth/src/main/java/cn/hippo4j/auth/model/RoleInfo.java +++ b/hippo4j-auth/src/main/java/cn/hippo4j/auth/model/RoleInfo.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.auth.model; import com.baomidou.mybatisplus.annotation.*; diff --git a/hippo4j-auth/src/main/java/cn/hippo4j/auth/model/UserInfo.java b/hippo4j-auth/src/main/java/cn/hippo4j/auth/model/UserInfo.java index 0c4cba74..890a0c7c 100644 --- a/hippo4j-auth/src/main/java/cn/hippo4j/auth/model/UserInfo.java +++ b/hippo4j-auth/src/main/java/cn/hippo4j/auth/model/UserInfo.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.auth.model; import com.baomidou.mybatisplus.annotation.*; diff --git a/hippo4j-auth/src/main/java/cn/hippo4j/auth/model/biz/permission/PermissionQueryPageReqDTO.java b/hippo4j-auth/src/main/java/cn/hippo4j/auth/model/biz/permission/PermissionQueryPageReqDTO.java index 30e0b42c..feaa2062 100644 --- a/hippo4j-auth/src/main/java/cn/hippo4j/auth/model/biz/permission/PermissionQueryPageReqDTO.java +++ b/hippo4j-auth/src/main/java/cn/hippo4j/auth/model/biz/permission/PermissionQueryPageReqDTO.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.auth.model.biz.permission; import com.baomidou.mybatisplus.extension.plugins.pagination.Page; diff --git a/hippo4j-auth/src/main/java/cn/hippo4j/auth/model/biz/permission/PermissionRespDTO.java b/hippo4j-auth/src/main/java/cn/hippo4j/auth/model/biz/permission/PermissionRespDTO.java index 4d0bc92b..b036863f 100644 --- a/hippo4j-auth/src/main/java/cn/hippo4j/auth/model/biz/permission/PermissionRespDTO.java +++ b/hippo4j-auth/src/main/java/cn/hippo4j/auth/model/biz/permission/PermissionRespDTO.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.auth.model.biz.permission; import lombok.Data; diff --git a/hippo4j-auth/src/main/java/cn/hippo4j/auth/model/biz/role/RoleQueryPageReqDTO.java b/hippo4j-auth/src/main/java/cn/hippo4j/auth/model/biz/role/RoleQueryPageReqDTO.java index ae93f7e1..24844260 100644 --- a/hippo4j-auth/src/main/java/cn/hippo4j/auth/model/biz/role/RoleQueryPageReqDTO.java +++ b/hippo4j-auth/src/main/java/cn/hippo4j/auth/model/biz/role/RoleQueryPageReqDTO.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.auth.model.biz.role; import com.baomidou.mybatisplus.extension.plugins.pagination.Page; diff --git a/hippo4j-auth/src/main/java/cn/hippo4j/auth/model/biz/role/RoleRespDTO.java b/hippo4j-auth/src/main/java/cn/hippo4j/auth/model/biz/role/RoleRespDTO.java index 2adffbcb..1c748f24 100644 --- a/hippo4j-auth/src/main/java/cn/hippo4j/auth/model/biz/role/RoleRespDTO.java +++ b/hippo4j-auth/src/main/java/cn/hippo4j/auth/model/biz/role/RoleRespDTO.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.auth.model.biz.role; import lombok.Data; diff --git a/hippo4j-auth/src/main/java/cn/hippo4j/auth/model/biz/user/JwtUser.java b/hippo4j-auth/src/main/java/cn/hippo4j/auth/model/biz/user/JwtUser.java index d2b655d2..39eadd07 100644 --- a/hippo4j-auth/src/main/java/cn/hippo4j/auth/model/biz/user/JwtUser.java +++ b/hippo4j-auth/src/main/java/cn/hippo4j/auth/model/biz/user/JwtUser.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.auth.model.biz.user; import lombok.Data; diff --git a/hippo4j-auth/src/main/java/cn/hippo4j/auth/model/biz/user/LoginUser.java b/hippo4j-auth/src/main/java/cn/hippo4j/auth/model/biz/user/LoginUser.java index ad2184a8..ac324127 100644 --- a/hippo4j-auth/src/main/java/cn/hippo4j/auth/model/biz/user/LoginUser.java +++ b/hippo4j-auth/src/main/java/cn/hippo4j/auth/model/biz/user/LoginUser.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.auth.model.biz.user; import lombok.Data; diff --git a/hippo4j-auth/src/main/java/cn/hippo4j/auth/model/biz/user/UserQueryPageReqDTO.java b/hippo4j-auth/src/main/java/cn/hippo4j/auth/model/biz/user/UserQueryPageReqDTO.java index 472e5b36..9a52e5c3 100644 --- a/hippo4j-auth/src/main/java/cn/hippo4j/auth/model/biz/user/UserQueryPageReqDTO.java +++ b/hippo4j-auth/src/main/java/cn/hippo4j/auth/model/biz/user/UserQueryPageReqDTO.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.auth.model.biz.user; import com.baomidou.mybatisplus.extension.plugins.pagination.Page; diff --git a/hippo4j-auth/src/main/java/cn/hippo4j/auth/model/biz/user/UserReqDTO.java b/hippo4j-auth/src/main/java/cn/hippo4j/auth/model/biz/user/UserReqDTO.java index b84529d7..40e28f0f 100644 --- a/hippo4j-auth/src/main/java/cn/hippo4j/auth/model/biz/user/UserReqDTO.java +++ b/hippo4j-auth/src/main/java/cn/hippo4j/auth/model/biz/user/UserReqDTO.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.auth.model.biz.user; import com.baomidou.mybatisplus.extension.plugins.pagination.Page; diff --git a/hippo4j-auth/src/main/java/cn/hippo4j/auth/model/biz/user/UserRespDTO.java b/hippo4j-auth/src/main/java/cn/hippo4j/auth/model/biz/user/UserRespDTO.java index a82f68f3..3b9b98fe 100644 --- a/hippo4j-auth/src/main/java/cn/hippo4j/auth/model/biz/user/UserRespDTO.java +++ b/hippo4j-auth/src/main/java/cn/hippo4j/auth/model/biz/user/UserRespDTO.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.auth.model.biz.user; import com.fasterxml.jackson.annotation.JsonFormat; diff --git a/hippo4j-auth/src/main/java/cn/hippo4j/auth/security/AuthManager.java b/hippo4j-auth/src/main/java/cn/hippo4j/auth/security/AuthManager.java index fdfbcdd1..a2f90f62 100644 --- a/hippo4j-auth/src/main/java/cn/hippo4j/auth/security/AuthManager.java +++ b/hippo4j-auth/src/main/java/cn/hippo4j/auth/security/AuthManager.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.auth.security; import lombok.AllArgsConstructor; diff --git a/hippo4j-auth/src/main/java/cn/hippo4j/auth/security/JwtTokenManager.java b/hippo4j-auth/src/main/java/cn/hippo4j/auth/security/JwtTokenManager.java index 157a9f66..5672c6b4 100644 --- a/hippo4j-auth/src/main/java/cn/hippo4j/auth/security/JwtTokenManager.java +++ b/hippo4j-auth/src/main/java/cn/hippo4j/auth/security/JwtTokenManager.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.auth.security; import cn.hutool.core.util.StrUtil; diff --git a/hippo4j-auth/src/main/java/cn/hippo4j/auth/service/PermissionService.java b/hippo4j-auth/src/main/java/cn/hippo4j/auth/service/PermissionService.java index 922c0576..0fa7c355 100644 --- a/hippo4j-auth/src/main/java/cn/hippo4j/auth/service/PermissionService.java +++ b/hippo4j-auth/src/main/java/cn/hippo4j/auth/service/PermissionService.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.auth.service; import cn.hippo4j.auth.model.biz.permission.PermissionRespDTO; diff --git a/hippo4j-auth/src/main/java/cn/hippo4j/auth/service/RoleService.java b/hippo4j-auth/src/main/java/cn/hippo4j/auth/service/RoleService.java index 2b212e4c..1bd9a55e 100644 --- a/hippo4j-auth/src/main/java/cn/hippo4j/auth/service/RoleService.java +++ b/hippo4j-auth/src/main/java/cn/hippo4j/auth/service/RoleService.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.auth.service; import com.baomidou.mybatisplus.core.metadata.IPage; diff --git a/hippo4j-auth/src/main/java/cn/hippo4j/auth/service/UserService.java b/hippo4j-auth/src/main/java/cn/hippo4j/auth/service/UserService.java index bbbffba5..d0d18ad5 100644 --- a/hippo4j-auth/src/main/java/cn/hippo4j/auth/service/UserService.java +++ b/hippo4j-auth/src/main/java/cn/hippo4j/auth/service/UserService.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.auth.service; import cn.hippo4j.auth.model.biz.user.UserQueryPageReqDTO; diff --git a/hippo4j-auth/src/main/java/cn/hippo4j/auth/service/impl/PermissionServiceImpl.java b/hippo4j-auth/src/main/java/cn/hippo4j/auth/service/impl/PermissionServiceImpl.java index ddbf36f4..6b29e32d 100644 --- a/hippo4j-auth/src/main/java/cn/hippo4j/auth/service/impl/PermissionServiceImpl.java +++ b/hippo4j-auth/src/main/java/cn/hippo4j/auth/service/impl/PermissionServiceImpl.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.auth.service.impl; import cn.hippo4j.auth.mapper.PermissionMapper; diff --git a/hippo4j-auth/src/main/java/cn/hippo4j/auth/service/impl/RoleServiceImpl.java b/hippo4j-auth/src/main/java/cn/hippo4j/auth/service/impl/RoleServiceImpl.java index 04b7b59a..7d29f124 100644 --- a/hippo4j-auth/src/main/java/cn/hippo4j/auth/service/impl/RoleServiceImpl.java +++ b/hippo4j-auth/src/main/java/cn/hippo4j/auth/service/impl/RoleServiceImpl.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.auth.service.impl; import cn.hippo4j.auth.mapper.RoleMapper; diff --git a/hippo4j-auth/src/main/java/cn/hippo4j/auth/service/impl/UserDetailsServiceImpl.java b/hippo4j-auth/src/main/java/cn/hippo4j/auth/service/impl/UserDetailsServiceImpl.java index 5a1c1fc9..f2784196 100644 --- a/hippo4j-auth/src/main/java/cn/hippo4j/auth/service/impl/UserDetailsServiceImpl.java +++ b/hippo4j-auth/src/main/java/cn/hippo4j/auth/service/impl/UserDetailsServiceImpl.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.auth.service.impl; import cn.hippo4j.auth.mapper.UserMapper; diff --git a/hippo4j-auth/src/main/java/cn/hippo4j/auth/service/impl/UserServiceImpl.java b/hippo4j-auth/src/main/java/cn/hippo4j/auth/service/impl/UserServiceImpl.java index 6b0470fa..8def09cc 100644 --- a/hippo4j-auth/src/main/java/cn/hippo4j/auth/service/impl/UserServiceImpl.java +++ b/hippo4j-auth/src/main/java/cn/hippo4j/auth/service/impl/UserServiceImpl.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.auth.service.impl; import cn.hippo4j.auth.mapper.UserMapper; diff --git a/hippo4j-auth/src/main/java/cn/hippo4j/auth/toolkit/JwtTokenUtil.java b/hippo4j-auth/src/main/java/cn/hippo4j/auth/toolkit/JwtTokenUtil.java index bdcaa95d..ea19f227 100644 --- a/hippo4j-auth/src/main/java/cn/hippo4j/auth/toolkit/JwtTokenUtil.java +++ b/hippo4j-auth/src/main/java/cn/hippo4j/auth/toolkit/JwtTokenUtil.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.auth.toolkit; import cn.hippo4j.auth.constant.Constants; diff --git a/hippo4j-auth/src/main/java/cn/hippo4j/auth/toolkit/ReturnT.java b/hippo4j-auth/src/main/java/cn/hippo4j/auth/toolkit/ReturnT.java index f46e4de8..ef9dfa52 100644 --- a/hippo4j-auth/src/main/java/cn/hippo4j/auth/toolkit/ReturnT.java +++ b/hippo4j-auth/src/main/java/cn/hippo4j/auth/toolkit/ReturnT.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.auth.toolkit; import lombok.Data; diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/api/ClientCloseHookExecute.java b/hippo4j-common/src/main/java/cn/hippo4j/common/api/ClientCloseHookExecute.java index 05746360..601a5ac6 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/api/ClientCloseHookExecute.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/api/ClientCloseHookExecute.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.api; import lombok.Data; diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/api/JsonFacade.java b/hippo4j-common/src/main/java/cn/hippo4j/common/api/JsonFacade.java index 566bbb71..e9347a94 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/api/JsonFacade.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/api/JsonFacade.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.api; import java.util.List; diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/api/NotifyConfigBuilder.java b/hippo4j-common/src/main/java/cn/hippo4j/common/api/NotifyConfigBuilder.java index 951b91b0..c3fc1241 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/api/NotifyConfigBuilder.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/api/NotifyConfigBuilder.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.api; import cn.hippo4j.common.notify.NotifyConfigDTO; diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/api/ThreadDetailState.java b/hippo4j-common/src/main/java/cn/hippo4j/common/api/ThreadDetailState.java index a6bb2523..a36da0e5 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/api/ThreadDetailState.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/api/ThreadDetailState.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.api; import cn.hippo4j.common.model.ThreadDetailStateInfo; diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/api/ThreadPoolDynamicRefresh.java b/hippo4j-common/src/main/java/cn/hippo4j/common/api/ThreadPoolDynamicRefresh.java index 0f2733da..2040a35b 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/api/ThreadPoolDynamicRefresh.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/api/ThreadPoolDynamicRefresh.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.api; /** diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/config/ApplicationContextHolder.java b/hippo4j-common/src/main/java/cn/hippo4j/common/config/ApplicationContextHolder.java index 574366ec..7a91b2d7 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/config/ApplicationContextHolder.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/config/ApplicationContextHolder.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.config; import org.springframework.beans.BeansException; diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/constant/Constants.java b/hippo4j-common/src/main/java/cn/hippo4j/common/constant/Constants.java index 1b482c4e..bcb81e02 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/constant/Constants.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/constant/Constants.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.constant; /** diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/design/builder/Builder.java b/hippo4j-common/src/main/java/cn/hippo4j/common/design/builder/Builder.java index d787ef53..87aee3b2 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/design/builder/Builder.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/design/builder/Builder.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.design.builder; import java.io.Serializable; diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/design/observer/AbstractSubjectCenter.java b/hippo4j-common/src/main/java/cn/hippo4j/common/design/observer/AbstractSubjectCenter.java index 7c176edb..ff25a62c 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/design/observer/AbstractSubjectCenter.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/design/observer/AbstractSubjectCenter.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.design.observer; import cn.hippo4j.common.toolkit.CollectionUtil; diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/design/observer/Observer.java b/hippo4j-common/src/main/java/cn/hippo4j/common/design/observer/Observer.java index a8dbc17f..755f6d21 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/design/observer/Observer.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/design/observer/Observer.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.design.observer; /** diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/design/observer/ObserverMessage.java b/hippo4j-common/src/main/java/cn/hippo4j/common/design/observer/ObserverMessage.java index 9e9895b5..e1ee6d39 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/design/observer/ObserverMessage.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/design/observer/ObserverMessage.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.design.observer; /** diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/enums/DelEnum.java b/hippo4j-common/src/main/java/cn/hippo4j/common/enums/DelEnum.java index 7e6848c7..975dc86b 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/enums/DelEnum.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/enums/DelEnum.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.enums; /** diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/enums/EnableEnum.java b/hippo4j-common/src/main/java/cn/hippo4j/common/enums/EnableEnum.java index 81c1b1c4..afd39855 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/enums/EnableEnum.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/enums/EnableEnum.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.enums; import java.util.Objects; diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/executor/ExecutorFactory.java b/hippo4j-common/src/main/java/cn/hippo4j/common/executor/ExecutorFactory.java index cebe8a40..0adfd088 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/executor/ExecutorFactory.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/executor/ExecutorFactory.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.executor; import java.util.concurrent.Executors; diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/executor/ThreadPoolManager.java b/hippo4j-common/src/main/java/cn/hippo4j/common/executor/ThreadPoolManager.java index 0670aa95..be3c74e1 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/executor/ThreadPoolManager.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/executor/ThreadPoolManager.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.executor; import java.util.HashMap; diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/function/Matcher.java b/hippo4j-common/src/main/java/cn/hippo4j/common/function/Matcher.java index 92810bfa..a481ad72 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/function/Matcher.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/function/Matcher.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.function; /** diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/function/NoArgsConsumer.java b/hippo4j-common/src/main/java/cn/hippo4j/common/function/NoArgsConsumer.java index c8fe64ae..d17492e7 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/function/NoArgsConsumer.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/function/NoArgsConsumer.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.function; /** diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/model/GlobalRemotePoolInfo.java b/hippo4j-common/src/main/java/cn/hippo4j/common/model/GlobalRemotePoolInfo.java index a9f64620..78fd0d0d 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/model/GlobalRemotePoolInfo.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/model/GlobalRemotePoolInfo.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.model; import lombok.Getter; diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/model/InstanceInfo.java b/hippo4j-common/src/main/java/cn/hippo4j/common/model/InstanceInfo.java index d5d7e526..018b5e2f 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/model/InstanceInfo.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/model/InstanceInfo.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.model; import lombok.Data; @@ -171,4 +188,3 @@ public class InstanceInfo { } } - diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/model/ManyPoolRunStateInfo.java b/hippo4j-common/src/main/java/cn/hippo4j/common/model/ManyPoolRunStateInfo.java index 76f205ed..c8fd6900 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/model/ManyPoolRunStateInfo.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/model/ManyPoolRunStateInfo.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.model; import lombok.Data; diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/model/PoolBaseInfo.java b/hippo4j-common/src/main/java/cn/hippo4j/common/model/PoolBaseInfo.java index 9217821a..7f6ee683 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/model/PoolBaseInfo.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/model/PoolBaseInfo.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.model; import lombok.Data; diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/model/PoolParameter.java b/hippo4j-common/src/main/java/cn/hippo4j/common/model/PoolParameter.java index c21e380d..61fcd381 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/model/PoolParameter.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/model/PoolParameter.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.model; /** diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/model/PoolParameterInfo.java b/hippo4j-common/src/main/java/cn/hippo4j/common/model/PoolParameterInfo.java index 5eaf0020..982be085 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/model/PoolParameterInfo.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/model/PoolParameterInfo.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.model; import lombok.Data; diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/model/PoolRunStateInfo.java b/hippo4j-common/src/main/java/cn/hippo4j/common/model/PoolRunStateInfo.java index b29bcb2b..23db32b3 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/model/PoolRunStateInfo.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/model/PoolRunStateInfo.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.model; import lombok.Getter; diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/model/ThreadDetailStateInfo.java b/hippo4j-common/src/main/java/cn/hippo4j/common/model/ThreadDetailStateInfo.java index 72663bd9..0c5ab6d7 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/model/ThreadDetailStateInfo.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/model/ThreadDetailStateInfo.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.model; import lombok.Data; diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/model/TokenInfo.java b/hippo4j-common/src/main/java/cn/hippo4j/common/model/TokenInfo.java index 81a2a2eb..4c88fb83 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/model/TokenInfo.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/model/TokenInfo.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.model; import lombok.AllArgsConstructor; diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/monitor/AbstractMessage.java b/hippo4j-common/src/main/java/cn/hippo4j/common/monitor/AbstractMessage.java index 201c48da..6b11784c 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/monitor/AbstractMessage.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/monitor/AbstractMessage.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.monitor; import lombok.Data; diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/monitor/Message.java b/hippo4j-common/src/main/java/cn/hippo4j/common/monitor/Message.java index 70de9bdd..91c9a8d3 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/monitor/Message.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/monitor/Message.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.monitor; import java.io.Serializable; diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/monitor/MessageRequest.java b/hippo4j-common/src/main/java/cn/hippo4j/common/monitor/MessageRequest.java index 8ca09d64..efdc9405 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/monitor/MessageRequest.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/monitor/MessageRequest.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.monitor; import java.util.List; diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/monitor/MessageTypeEnum.java b/hippo4j-common/src/main/java/cn/hippo4j/common/monitor/MessageTypeEnum.java index e4546a53..6206a8a5 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/monitor/MessageTypeEnum.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/monitor/MessageTypeEnum.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.monitor; /** diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/monitor/MessageWrapper.java b/hippo4j-common/src/main/java/cn/hippo4j/common/monitor/MessageWrapper.java index 3acb1258..03ff9ef3 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/monitor/MessageWrapper.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/monitor/MessageWrapper.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.monitor; import lombok.AllArgsConstructor; diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/monitor/RuntimeMessage.java b/hippo4j-common/src/main/java/cn/hippo4j/common/monitor/RuntimeMessage.java index 058e38db..8a61574a 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/monitor/RuntimeMessage.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/monitor/RuntimeMessage.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.monitor; import lombok.Data; diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/notify/AlarmControlDTO.java b/hippo4j-common/src/main/java/cn/hippo4j/common/notify/AlarmControlDTO.java index 3bca8893..374fae21 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/notify/AlarmControlDTO.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/notify/AlarmControlDTO.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.notify; import cn.hutool.core.util.StrUtil; diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/notify/AlarmControlHandler.java b/hippo4j-common/src/main/java/cn/hippo4j/common/notify/AlarmControlHandler.java index 019af2f9..4812a310 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/notify/AlarmControlHandler.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/notify/AlarmControlHandler.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.notify; import cn.hippo4j.common.constant.Constants; diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/notify/HippoBaseSendMessageService.java b/hippo4j-common/src/main/java/cn/hippo4j/common/notify/HippoBaseSendMessageService.java index 0eaf2012..43bc4ac2 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/notify/HippoBaseSendMessageService.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/notify/HippoBaseSendMessageService.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.notify; import cn.hippo4j.common.api.NotifyConfigBuilder; diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/notify/HippoSendMessageService.java b/hippo4j-common/src/main/java/cn/hippo4j/common/notify/HippoSendMessageService.java index 158d07fd..013b8310 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/notify/HippoSendMessageService.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/notify/HippoSendMessageService.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.notify; import cn.hippo4j.common.notify.request.AlarmNotifyRequest; diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/notify/NotifyConfigDTO.java b/hippo4j-common/src/main/java/cn/hippo4j/common/notify/NotifyConfigDTO.java index 4e96e95d..728f5a80 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/notify/NotifyConfigDTO.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/notify/NotifyConfigDTO.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.notify; import lombok.Data; diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/notify/NotifyPlatformEnum.java b/hippo4j-common/src/main/java/cn/hippo4j/common/notify/NotifyPlatformEnum.java index 3d2e65b4..0dc5a334 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/notify/NotifyPlatformEnum.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/notify/NotifyPlatformEnum.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.notify; /** diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/notify/NotifyTypeEnum.java b/hippo4j-common/src/main/java/cn/hippo4j/common/notify/NotifyTypeEnum.java index 14ce2685..004688b7 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/notify/NotifyTypeEnum.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/notify/NotifyTypeEnum.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.notify; /** diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/notify/SendMessageHandler.java b/hippo4j-common/src/main/java/cn/hippo4j/common/notify/SendMessageHandler.java index 13a8a961..b24e5f63 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/notify/SendMessageHandler.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/notify/SendMessageHandler.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.notify; import cn.hippo4j.common.notify.request.base.NotifyRequest; diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/notify/ThreadPoolNotifyAlarm.java b/hippo4j-common/src/main/java/cn/hippo4j/common/notify/ThreadPoolNotifyAlarm.java index 0936ed85..83b9355d 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/notify/ThreadPoolNotifyAlarm.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/notify/ThreadPoolNotifyAlarm.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.notify; import lombok.Data; diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/notify/ThreadPoolNotifyDTO.java b/hippo4j-common/src/main/java/cn/hippo4j/common/notify/ThreadPoolNotifyDTO.java index f864cd26..8b0bb77f 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/notify/ThreadPoolNotifyDTO.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/notify/ThreadPoolNotifyDTO.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.notify; import lombok.Data; diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/notify/platform/DingAlarmConstants.java b/hippo4j-common/src/main/java/cn/hippo4j/common/notify/platform/DingAlarmConstants.java index 380d4b9a..334b920c 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/notify/platform/DingAlarmConstants.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/notify/platform/DingAlarmConstants.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.notify.platform; /** diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/notify/platform/DingSendMessageHandler.java b/hippo4j-common/src/main/java/cn/hippo4j/common/notify/platform/DingSendMessageHandler.java index a780688b..498e006d 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/notify/platform/DingSendMessageHandler.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/notify/platform/DingSendMessageHandler.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.notify.platform; import cn.hippo4j.common.notify.NotifyConfigDTO; @@ -107,8 +124,7 @@ public class DingSendMessageHandler implements SendMessageHandler StrUtil.startWith(receive, LARK_OPENID_PREFIX) ? - String.format(LARK_AT_FORMAT_OPENID, receive) : String.format(LARK_AT_FORMAT_USERNAME, receive)) + .map(receive -> StrUtil.startWith(receive, LARK_OPENID_PREFIX) ? String.format(LARK_AT_FORMAT_OPENID, receive) : String.format(LARK_AT_FORMAT_USERNAME, receive)) .collect(Collectors.joining(" ")); } diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/notify/platform/WeChatAlarmConstants.java b/hippo4j-common/src/main/java/cn/hippo4j/common/notify/platform/WeChatAlarmConstants.java index c5f60646..2839c7a6 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/notify/platform/WeChatAlarmConstants.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/notify/platform/WeChatAlarmConstants.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.notify.platform; /** diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/notify/platform/WeChatSendMessageHandler.java b/hippo4j-common/src/main/java/cn/hippo4j/common/notify/platform/WeChatSendMessageHandler.java index 3260a4f1..72c7ed20 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/notify/platform/WeChatSendMessageHandler.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/notify/platform/WeChatSendMessageHandler.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.notify.platform; import cn.hippo4j.common.notify.*; @@ -94,8 +111,7 @@ public class WeChatSendMessageHandler implements SendMessageHandler type1 = array1.getClass().getComponentType(); - @SuppressWarnings("unchecked") final T[] joinedArray = (T[]) Array.newInstance(type1, array1.length + array2.length); + @SuppressWarnings("unchecked") + final T[] joinedArray = (T[]) Array.newInstance(type1, array1.length + array2.length); System.arraycopy(array1, 0, joinedArray, 0, array1.length); try { System.arraycopy(array2, 0, joinedArray, array1.length, array2.length); diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/toolkit/Assert.java b/hippo4j-common/src/main/java/cn/hippo4j/common/toolkit/Assert.java index 5ce48ec9..1e6cb025 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/toolkit/Assert.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/toolkit/Assert.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.toolkit; import org.springframework.util.CollectionUtils; diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/toolkit/ByteConvertUtil.java b/hippo4j-common/src/main/java/cn/hippo4j/common/toolkit/ByteConvertUtil.java index 117cbcba..8079bf31 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/toolkit/ByteConvertUtil.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/toolkit/ByteConvertUtil.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.toolkit; /** diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/toolkit/CollectionUtil.java b/hippo4j-common/src/main/java/cn/hippo4j/common/toolkit/CollectionUtil.java index a43c3452..05af9a8b 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/toolkit/CollectionUtil.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/toolkit/CollectionUtil.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.toolkit; import java.util.Collection; @@ -49,7 +66,6 @@ public class CollectionUtil { return !isEmpty(list); } - /** * Is empty. * diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/toolkit/ConditionUtil.java b/hippo4j-common/src/main/java/cn/hippo4j/common/toolkit/ConditionUtil.java index da44380a..78af4b16 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/toolkit/ConditionUtil.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/toolkit/ConditionUtil.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.toolkit; import cn.hippo4j.common.function.NoArgsConsumer; diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/toolkit/ContentUtil.java b/hippo4j-common/src/main/java/cn/hippo4j/common/toolkit/ContentUtil.java index 4120ca56..a40cd458 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/toolkit/ContentUtil.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/toolkit/ContentUtil.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.toolkit; import cn.hippo4j.common.constant.Constants; diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/toolkit/GroupKey.java b/hippo4j-common/src/main/java/cn/hippo4j/common/toolkit/GroupKey.java index 1d3ceb20..f0e530d1 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/toolkit/GroupKey.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/toolkit/GroupKey.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.toolkit; import cn.hippo4j.common.constant.Constants; diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/toolkit/JSONUtil.java b/hippo4j-common/src/main/java/cn/hippo4j/common/toolkit/JSONUtil.java index c576851a..62a9c5f9 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/toolkit/JSONUtil.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/toolkit/JSONUtil.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.toolkit; import cn.hippo4j.common.api.JsonFacade; diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/toolkit/JacksonHandler.java b/hippo4j-common/src/main/java/cn/hippo4j/common/toolkit/JacksonHandler.java index a230a72f..5c859f23 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/toolkit/JacksonHandler.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/toolkit/JacksonHandler.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.toolkit; import cn.hippo4j.common.api.JsonFacade; diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/toolkit/Md5Util.java b/hippo4j-common/src/main/java/cn/hippo4j/common/toolkit/Md5Util.java index e263e822..22770b0e 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/toolkit/Md5Util.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/toolkit/Md5Util.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.toolkit; import cn.hippo4j.common.constant.Constants; diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/toolkit/MessageConvert.java b/hippo4j-common/src/main/java/cn/hippo4j/common/toolkit/MessageConvert.java index ae7d85e9..f6736daf 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/toolkit/MessageConvert.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/toolkit/MessageConvert.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.toolkit; import cn.hippo4j.common.monitor.AbstractMessage; diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/toolkit/ReflectUtil.java b/hippo4j-common/src/main/java/cn/hippo4j/common/toolkit/ReflectUtil.java index 3de7caf2..329a8ec0 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/toolkit/ReflectUtil.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/toolkit/ReflectUtil.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.toolkit; import java.lang.reflect.AccessibleObject; diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/toolkit/StringUtil.java b/hippo4j-common/src/main/java/cn/hippo4j/common/toolkit/StringUtil.java index 2d1e5074..e5e8bbf0 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/toolkit/StringUtil.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/toolkit/StringUtil.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.toolkit; /** diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/toolkit/ThreadUtil.java b/hippo4j-common/src/main/java/cn/hippo4j/common/toolkit/ThreadUtil.java index 0c524ee2..d2c227e4 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/toolkit/ThreadUtil.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/toolkit/ThreadUtil.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.toolkit; /** diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/toolkit/UserContext.java b/hippo4j-common/src/main/java/cn/hippo4j/common/toolkit/UserContext.java index f4f2bd01..8cb03ecd 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/toolkit/UserContext.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/toolkit/UserContext.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.toolkit; import lombok.AllArgsConstructor; diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/web/base/Result.java b/hippo4j-common/src/main/java/cn/hippo4j/common/web/base/Result.java index 5b3383c1..b4071b35 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/web/base/Result.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/web/base/Result.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.web.base; import lombok.Data; diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/web/base/Results.java b/hippo4j-common/src/main/java/cn/hippo4j/common/web/base/Results.java index 1bee4c2c..c4ba8499 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/web/base/Results.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/web/base/Results.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.web.base; import cn.hippo4j.common.web.exception.AbstractException; diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/web/exception/AbstractException.java b/hippo4j-common/src/main/java/cn/hippo4j/common/web/exception/AbstractException.java index fe8cdf35..057f6afd 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/web/exception/AbstractException.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/web/exception/AbstractException.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.web.exception; import lombok.Getter; diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/web/exception/ErrorCode.java b/hippo4j-common/src/main/java/cn/hippo4j/common/web/exception/ErrorCode.java index aeddd28e..4d9685ce 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/web/exception/ErrorCode.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/web/exception/ErrorCode.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.web.exception; /** diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/web/exception/ErrorCodeEnum.java b/hippo4j-common/src/main/java/cn/hippo4j/common/web/exception/ErrorCodeEnum.java index a14573c2..d36ae1fb 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/web/exception/ErrorCodeEnum.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/web/exception/ErrorCodeEnum.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.web.exception; /** diff --git a/hippo4j-common/src/main/java/cn/hippo4j/common/web/exception/ServiceException.java b/hippo4j-common/src/main/java/cn/hippo4j/common/web/exception/ServiceException.java index c6e77d88..60c1c49c 100644 --- a/hippo4j-common/src/main/java/cn/hippo4j/common/web/exception/ServiceException.java +++ b/hippo4j-common/src/main/java/cn/hippo4j/common/web/exception/ServiceException.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.common.web.exception; import lombok.EqualsAndHashCode; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/config/CommonConfig.java b/hippo4j-config/src/main/java/cn/hippo4j/config/config/CommonConfig.java index 8ccd178f..6b58669b 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/config/CommonConfig.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/config/CommonConfig.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.config; import cn.hippo4j.common.config.ApplicationContextHolder; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/config/MyMetaObjectHandler.java b/hippo4j-config/src/main/java/cn/hippo4j/config/config/MyMetaObjectHandler.java index bbecb097..8e612bec 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/config/MyMetaObjectHandler.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/config/MyMetaObjectHandler.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.config; import cn.hippo4j.common.enums.DelEnum; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/config/MybatisPlusConfig.java b/hippo4j-config/src/main/java/cn/hippo4j/config/config/MybatisPlusConfig.java index 2e7c5b92..d4ed3313 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/config/MybatisPlusConfig.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/config/MybatisPlusConfig.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.config; import com.baomidou.mybatisplus.annotation.DbType; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/config/ServerBootstrapProperties.java b/hippo4j-config/src/main/java/cn/hippo4j/config/config/ServerBootstrapProperties.java index 3e6db115..18488871 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/config/ServerBootstrapProperties.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/config/ServerBootstrapProperties.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.config; import lombok.Getter; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/controller/ConfigController.java b/hippo4j-config/src/main/java/cn/hippo4j/config/controller/ConfigController.java index 8c62fc48..0aaf9a84 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/controller/ConfigController.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/controller/ConfigController.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.controller; import cn.hippo4j.config.model.ConfigAllInfo; @@ -37,10 +54,10 @@ public class ConfigController { @GetMapping public Result detailConfigInfo( - @RequestParam("tpId") String tpId, - @RequestParam("itemId") String itemId, - @RequestParam("namespace") String namespace, - @RequestParam(value = "instanceId", required = false) String instanceId) { + @RequestParam("tpId") String tpId, + @RequestParam("itemId") String itemId, + @RequestParam("namespace") String namespace, + @RequestParam(value = "instanceId", required = false) String instanceId) { ConfigAllInfo configAllInfo = configService.findConfigRecentInfo(tpId, itemId, namespace, instanceId); return Results.success(configAllInfo); } diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/event/AbstractEvent.java b/hippo4j-config/src/main/java/cn/hippo4j/config/event/AbstractEvent.java index 7684d5d4..baf065b4 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/event/AbstractEvent.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/event/AbstractEvent.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.event; import java.io.Serializable; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/event/AbstractSlowEvent.java b/hippo4j-config/src/main/java/cn/hippo4j/config/event/AbstractSlowEvent.java index 9334adb5..a79a0116 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/event/AbstractSlowEvent.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/event/AbstractSlowEvent.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.event; /** diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/event/ConfigDataChangeEvent.java b/hippo4j-config/src/main/java/cn/hippo4j/config/event/ConfigDataChangeEvent.java index 23ed93cf..6ba10e23 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/event/ConfigDataChangeEvent.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/event/ConfigDataChangeEvent.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.event; import org.springframework.util.StringUtils; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/event/LocalDataChangeEvent.java b/hippo4j-config/src/main/java/cn/hippo4j/config/event/LocalDataChangeEvent.java index 03bcb6f3..f4487e11 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/event/LocalDataChangeEvent.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/event/LocalDataChangeEvent.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.event; /** diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/mapper/ConfigInfoMapper.java b/hippo4j-config/src/main/java/cn/hippo4j/config/mapper/ConfigInfoMapper.java index 7a319c85..e74fe5e1 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/mapper/ConfigInfoMapper.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/mapper/ConfigInfoMapper.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.mapper; import cn.hippo4j.config.model.ConfigAllInfo; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/mapper/ConfigInstanceMapper.java b/hippo4j-config/src/main/java/cn/hippo4j/config/mapper/ConfigInstanceMapper.java index bc9c38c6..658e7873 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/mapper/ConfigInstanceMapper.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/mapper/ConfigInstanceMapper.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.mapper; import cn.hippo4j.config.model.ConfigInstanceInfo; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/mapper/DashboardMapper.java b/hippo4j-config/src/main/java/cn/hippo4j/config/mapper/DashboardMapper.java index cf3ee996..06e1f810 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/mapper/DashboardMapper.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/mapper/DashboardMapper.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.mapper; import org.apache.ibatis.annotations.Mapper; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/mapper/HisRunDataMapper.java b/hippo4j-config/src/main/java/cn/hippo4j/config/mapper/HisRunDataMapper.java index 573992cc..e9a9675c 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/mapper/HisRunDataMapper.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/mapper/HisRunDataMapper.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.mapper; import cn.hippo4j.config.model.HisRunDataInfo; @@ -50,7 +67,6 @@ public interface HisRunDataMapper extends BaseMapper { "limit 4") List queryThreadPoolMaxRanking(@Param("startTime") Long startTime, @Param("endTime") Long endTime); - @Data class ThreadPoolTaskRanking { diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/mapper/ItemInfoMapper.java b/hippo4j-config/src/main/java/cn/hippo4j/config/mapper/ItemInfoMapper.java index b8915728..8ba7d774 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/mapper/ItemInfoMapper.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/mapper/ItemInfoMapper.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.mapper; import com.baomidou.mybatisplus.core.mapper.BaseMapper; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/mapper/LogRecordMapper.java b/hippo4j-config/src/main/java/cn/hippo4j/config/mapper/LogRecordMapper.java index e64d6749..32b302b4 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/mapper/LogRecordMapper.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/mapper/LogRecordMapper.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.mapper; import com.baomidou.mybatisplus.core.mapper.BaseMapper; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/mapper/NotifyInfoMapper.java b/hippo4j-config/src/main/java/cn/hippo4j/config/mapper/NotifyInfoMapper.java index a683848b..c415923b 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/mapper/NotifyInfoMapper.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/mapper/NotifyInfoMapper.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.mapper; import cn.hippo4j.config.model.NotifyInfo; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/mapper/TenantInfoMapper.java b/hippo4j-config/src/main/java/cn/hippo4j/config/mapper/TenantInfoMapper.java index ff3cb1e7..6b39ec6b 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/mapper/TenantInfoMapper.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/mapper/TenantInfoMapper.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.mapper; import com.baomidou.mybatisplus.core.mapper.BaseMapper; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/model/CacheItem.java b/hippo4j-config/src/main/java/cn/hippo4j/config/model/CacheItem.java index 8f7af161..c79f5f97 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/model/CacheItem.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/model/CacheItem.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.model; import cn.hippo4j.common.toolkit.Md5Util; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/model/ConfigAllInfo.java b/hippo4j-config/src/main/java/cn/hippo4j/config/model/ConfigAllInfo.java index 970e5ce2..a2dee181 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/model/ConfigAllInfo.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/model/ConfigAllInfo.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.model; import cn.hippo4j.common.model.PoolParameter; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/model/ConfigInfo.java b/hippo4j-config/src/main/java/cn/hippo4j/config/model/ConfigInfo.java index df96539e..e19521ef 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/model/ConfigInfo.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/model/ConfigInfo.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.model; import lombok.Data; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/model/ConfigInfoBase.java b/hippo4j-config/src/main/java/cn/hippo4j/config/model/ConfigInfoBase.java index f52eaecb..479ed7c7 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/model/ConfigInfoBase.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/model/ConfigInfoBase.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.model; import com.baomidou.mybatisplus.annotation.IdType; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/model/ConfigInstanceInfo.java b/hippo4j-config/src/main/java/cn/hippo4j/config/model/ConfigInstanceInfo.java index d0318c19..2d0c15b3 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/model/ConfigInstanceInfo.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/model/ConfigInstanceInfo.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.model; import com.baomidou.mybatisplus.annotation.*; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/model/HisRunDataInfo.java b/hippo4j-config/src/main/java/cn/hippo4j/config/model/HisRunDataInfo.java index 88ea0f39..998ffeb6 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/model/HisRunDataInfo.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/model/HisRunDataInfo.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.model; import com.baomidou.mybatisplus.annotation.*; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/model/ItemInfo.java b/hippo4j-config/src/main/java/cn/hippo4j/config/model/ItemInfo.java index cedb767e..fa821d51 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/model/ItemInfo.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/model/ItemInfo.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.model; import com.baomidou.mybatisplus.annotation.*; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/model/NotifyInfo.java b/hippo4j-config/src/main/java/cn/hippo4j/config/model/NotifyInfo.java index 69ef6912..996286fb 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/model/NotifyInfo.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/model/NotifyInfo.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.model; import com.baomidou.mybatisplus.annotation.*; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/model/TenantInfo.java b/hippo4j-config/src/main/java/cn/hippo4j/config/model/TenantInfo.java index 077df416..7b30d79b 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/model/TenantInfo.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/model/TenantInfo.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.model; import com.baomidou.mybatisplus.annotation.*; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/item/ItemQueryReqDTO.java b/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/item/ItemQueryReqDTO.java index bec92e4a..550dc122 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/item/ItemQueryReqDTO.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/item/ItemQueryReqDTO.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.model.biz.item; import com.baomidou.mybatisplus.extension.plugins.pagination.Page; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/item/ItemRespDTO.java b/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/item/ItemRespDTO.java index 303db8ee..0c0efaf4 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/item/ItemRespDTO.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/item/ItemRespDTO.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.model.biz.item; import com.fasterxml.jackson.annotation.JsonFormat; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/item/ItemSaveReqDTO.java b/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/item/ItemSaveReqDTO.java index 03edf4dc..b4b9bd32 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/item/ItemSaveReqDTO.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/item/ItemSaveReqDTO.java @@ -1,10 +1,26 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.model.biz.item; import lombok.Data; import javax.validation.constraints.Pattern; - /** * Item save req dto. * diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/item/ItemUpdateReqDTO.java b/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/item/ItemUpdateReqDTO.java index 455c44d2..c961ddfc 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/item/ItemUpdateReqDTO.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/item/ItemUpdateReqDTO.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.model.biz.item; import lombok.Data; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/log/LogRecordQueryReqDTO.java b/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/log/LogRecordQueryReqDTO.java index 2bbb7518..4d90757e 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/log/LogRecordQueryReqDTO.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/log/LogRecordQueryReqDTO.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.model.biz.log; import com.baomidou.mybatisplus.extension.plugins.pagination.Page; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/log/LogRecordRespDTO.java b/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/log/LogRecordRespDTO.java index c904b893..13473a4f 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/log/LogRecordRespDTO.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/log/LogRecordRespDTO.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.model.biz.log; import com.fasterxml.jackson.annotation.JsonFormat; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/monitor/MonitorActiveRespDTO.java b/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/monitor/MonitorActiveRespDTO.java index 1a509bce..794cb3bd 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/monitor/MonitorActiveRespDTO.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/monitor/MonitorActiveRespDTO.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.model.biz.monitor; import lombok.AllArgsConstructor; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/monitor/MonitorQueryReqDTO.java b/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/monitor/MonitorQueryReqDTO.java index 60eea99d..c0b65e4b 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/monitor/MonitorQueryReqDTO.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/monitor/MonitorQueryReqDTO.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.model.biz.monitor; import lombok.Data; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/monitor/MonitorRespDTO.java b/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/monitor/MonitorRespDTO.java index 54359c5f..5575e387 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/monitor/MonitorRespDTO.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/monitor/MonitorRespDTO.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.model.biz.monitor; import lombok.Data; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/notify/NotifyListRespDTO.java b/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/notify/NotifyListRespDTO.java index ce34d053..314952ae 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/notify/NotifyListRespDTO.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/notify/NotifyListRespDTO.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.model.biz.notify; import cn.hippo4j.config.model.NotifyInfo; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/notify/NotifyQueryReqDTO.java b/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/notify/NotifyQueryReqDTO.java index c9b14954..e32e7b9a 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/notify/NotifyQueryReqDTO.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/notify/NotifyQueryReqDTO.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.model.biz.notify; import com.baomidou.mybatisplus.extension.plugins.pagination.Page; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/notify/NotifyReqDTO.java b/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/notify/NotifyReqDTO.java index f97aa15e..d734ba0e 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/notify/NotifyReqDTO.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/notify/NotifyReqDTO.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.model.biz.notify; import lombok.Data; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/notify/NotifyRespDTO.java b/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/notify/NotifyRespDTO.java index c3cf7771..bc94f66b 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/notify/NotifyRespDTO.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/notify/NotifyRespDTO.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.model.biz.notify; import lombok.Data; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/tenant/TenantQueryReqDTO.java b/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/tenant/TenantQueryReqDTO.java index bd76dc6c..126cd9b5 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/tenant/TenantQueryReqDTO.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/tenant/TenantQueryReqDTO.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.model.biz.tenant; import com.baomidou.mybatisplus.extension.plugins.pagination.Page; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/tenant/TenantRespDTO.java b/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/tenant/TenantRespDTO.java index 0c9982c7..57cccb9b 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/tenant/TenantRespDTO.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/tenant/TenantRespDTO.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.model.biz.tenant; import com.fasterxml.jackson.annotation.JsonFormat; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/tenant/TenantSaveReqDTO.java b/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/tenant/TenantSaveReqDTO.java index 47a682d7..cf3d8da9 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/tenant/TenantSaveReqDTO.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/tenant/TenantSaveReqDTO.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.model.biz.tenant; import lombok.Data; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/tenant/TenantUpdateReqDTO.java b/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/tenant/TenantUpdateReqDTO.java index e4bc3a77..7e79abee 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/tenant/TenantUpdateReqDTO.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/tenant/TenantUpdateReqDTO.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.model.biz.tenant; import cn.hippo4j.common.toolkit.JSONUtil; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/threadpool/ThreadPoolDelReqDTO.java b/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/threadpool/ThreadPoolDelReqDTO.java index b4e8b18e..769b58db 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/threadpool/ThreadPoolDelReqDTO.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/threadpool/ThreadPoolDelReqDTO.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.model.biz.threadpool; import lombok.Data; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/threadpool/ThreadPoolQueryReqDTO.java b/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/threadpool/ThreadPoolQueryReqDTO.java index 19027869..a5007305 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/threadpool/ThreadPoolQueryReqDTO.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/threadpool/ThreadPoolQueryReqDTO.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.model.biz.threadpool; import com.baomidou.mybatisplus.extension.plugins.pagination.Page; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/threadpool/ThreadPoolRespDTO.java b/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/threadpool/ThreadPoolRespDTO.java index 031c4745..4cfd5305 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/threadpool/ThreadPoolRespDTO.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/threadpool/ThreadPoolRespDTO.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.model.biz.threadpool; import com.fasterxml.jackson.annotation.JsonFormat; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/threadpool/ThreadPoolSaveOrUpdateReqDTO.java b/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/threadpool/ThreadPoolSaveOrUpdateReqDTO.java index 831a9930..a6705b49 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/threadpool/ThreadPoolSaveOrUpdateReqDTO.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/model/biz/threadpool/ThreadPoolSaveOrUpdateReqDTO.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.model.biz.threadpool; import lombok.Data; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/monitor/AbstractMonitorDataExecuteStrategy.java b/hippo4j-config/src/main/java/cn/hippo4j/config/monitor/AbstractMonitorDataExecuteStrategy.java index 159acbd5..f838732c 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/monitor/AbstractMonitorDataExecuteStrategy.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/monitor/AbstractMonitorDataExecuteStrategy.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.monitor; import cn.hippo4j.common.monitor.Message; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/monitor/DefaultMonitorDataResolver.java b/hippo4j-config/src/main/java/cn/hippo4j/config/monitor/DefaultMonitorDataResolver.java index 0e80b421..313916bf 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/monitor/DefaultMonitorDataResolver.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/monitor/DefaultMonitorDataResolver.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.monitor; import cn.hippo4j.common.monitor.Message; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/monitor/QueryMonitorExecuteChoose.java b/hippo4j-config/src/main/java/cn/hippo4j/config/monitor/QueryMonitorExecuteChoose.java index 357fb722..f17511ff 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/monitor/QueryMonitorExecuteChoose.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/monitor/QueryMonitorExecuteChoose.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.monitor; import cn.hippo4j.common.config.ApplicationContextHolder; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/monitor/RuntimeDataResolver.java b/hippo4j-config/src/main/java/cn/hippo4j/config/monitor/RuntimeDataResolver.java index b2dc7804..29afc0f9 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/monitor/RuntimeDataResolver.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/monitor/RuntimeDataResolver.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.monitor; import cn.hippo4j.common.monitor.MessageTypeEnum; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/monitor/TimeCleanHistoryDataTask.java b/hippo4j-config/src/main/java/cn/hippo4j/config/monitor/TimeCleanHistoryDataTask.java index 94816ef9..7df83e52 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/monitor/TimeCleanHistoryDataTask.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/monitor/TimeCleanHistoryDataTask.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.monitor; import cn.hippo4j.common.executor.ExecutorFactory; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/notify/DefaultPublisher.java b/hippo4j-config/src/main/java/cn/hippo4j/config/notify/DefaultPublisher.java index 39a052dd..542616e0 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/notify/DefaultPublisher.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/notify/DefaultPublisher.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.notify; import cn.hippo4j.config.event.AbstractEvent; @@ -64,7 +81,7 @@ public class DefaultPublisher extends Thread implements EventPublisher { private void openEventHandler() { try { int waitTimes = 60; - for (; ; ) { + for (;;) { if (shutdown || hasSubscriber() || waitTimes <= 0) { break; } @@ -76,7 +93,7 @@ public class DefaultPublisher extends Thread implements EventPublisher { waitTimes--; } - for (; ; ) { + for (;;) { if (shutdown) { break; } diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/notify/DefaultSharePublisher.java b/hippo4j-config/src/main/java/cn/hippo4j/config/notify/DefaultSharePublisher.java index ad408343..e5ad4fe8 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/notify/DefaultSharePublisher.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/notify/DefaultSharePublisher.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.notify; import cn.hippo4j.config.event.AbstractEvent; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/notify/EventPublisher.java b/hippo4j-config/src/main/java/cn/hippo4j/config/notify/EventPublisher.java index 927cc37f..02e1afa2 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/notify/EventPublisher.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/notify/EventPublisher.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.notify; import cn.hippo4j.config.event.AbstractEvent; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/notify/NotifyCenter.java b/hippo4j-config/src/main/java/cn/hippo4j/config/notify/NotifyCenter.java index e4a98982..d4aed4ba 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/notify/NotifyCenter.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/notify/NotifyCenter.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.notify; import cn.hippo4j.config.event.AbstractEvent; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/notify/listener/AbstractSmartSubscriber.java b/hippo4j-config/src/main/java/cn/hippo4j/config/notify/listener/AbstractSmartSubscriber.java index 1bcb3990..be5e7476 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/notify/listener/AbstractSmartSubscriber.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/notify/listener/AbstractSmartSubscriber.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.notify.listener; import cn.hippo4j.config.event.AbstractEvent; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/notify/listener/AbstractSubscriber.java b/hippo4j-config/src/main/java/cn/hippo4j/config/notify/listener/AbstractSubscriber.java index d746341e..afeca271 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/notify/listener/AbstractSubscriber.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/notify/listener/AbstractSubscriber.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.notify.listener; import cn.hippo4j.config.event.AbstractEvent; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/service/ConfigCacheService.java b/hippo4j-config/src/main/java/cn/hippo4j/config/service/ConfigCacheService.java index 5744399d..f28bffb5 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/service/ConfigCacheService.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/service/ConfigCacheService.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.service; import cn.hippo4j.common.config.ApplicationContextHolder; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/service/ConfigChangePublisher.java b/hippo4j-config/src/main/java/cn/hippo4j/config/service/ConfigChangePublisher.java index e65a7282..3b85ab3a 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/service/ConfigChangePublisher.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/service/ConfigChangePublisher.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.service; import cn.hippo4j.config.notify.NotifyCenter; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/service/ConfigServletInner.java b/hippo4j-config/src/main/java/cn/hippo4j/config/service/ConfigServletInner.java index fcd3606d..e967a118 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/service/ConfigServletInner.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/service/ConfigServletInner.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.service; import com.google.common.cache.Cache; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/service/LongPollingService.java b/hippo4j-config/src/main/java/cn/hippo4j/config/service/LongPollingService.java index 14fcb070..2e69fbe5 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/service/LongPollingService.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/service/LongPollingService.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.service; import cn.hippo4j.common.toolkit.JSONUtil; @@ -103,7 +120,7 @@ public class LongPollingService { @Override public void run() { try { - for (Iterator iter = allSubs.iterator(); iter.hasNext(); ) { + for (Iterator iter = allSubs.iterator(); iter.hasNext();) { ClientLongPolling clientSub = iter.next(); String identity = groupKey + GROUP_KEY_DELIMITER + identify; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/service/SwitchService.java b/hippo4j-config/src/main/java/cn/hippo4j/config/service/SwitchService.java index d12c240a..82df5757 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/service/SwitchService.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/service/SwitchService.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.service; import lombok.extern.slf4j.Slf4j; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/ConfigService.java b/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/ConfigService.java index 11421384..1d41253c 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/ConfigService.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/ConfigService.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.service.biz; import cn.hippo4j.config.model.ConfigAllInfo; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/HisRunDataService.java b/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/HisRunDataService.java index c90afb67..408f2b40 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/HisRunDataService.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/HisRunDataService.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.service.biz; import cn.hippo4j.common.monitor.Message; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/ItemService.java b/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/ItemService.java index e6c411e5..c11ce694 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/ItemService.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/ItemService.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.service.biz; import cn.hippo4j.config.model.biz.item.ItemRespDTO; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/LogRecordBizService.java b/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/LogRecordBizService.java index ca0bae9c..f7eccea5 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/LogRecordBizService.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/LogRecordBizService.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.service.biz; import cn.hippo4j.config.model.biz.log.LogRecordQueryReqDTO; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/NotifyService.java b/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/NotifyService.java index c2fa944c..08d6e1e4 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/NotifyService.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/NotifyService.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.service.biz; import cn.hippo4j.config.model.biz.notify.NotifyListRespDTO; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/TenantService.java b/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/TenantService.java index d586b118..d115675f 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/TenantService.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/TenantService.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.service.biz; import cn.hippo4j.config.model.biz.tenant.TenantQueryReqDTO; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/ThreadPoolService.java b/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/ThreadPoolService.java index 55002e09..644410a5 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/ThreadPoolService.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/ThreadPoolService.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.service.biz; import cn.hippo4j.config.model.biz.threadpool.ThreadPoolQueryReqDTO; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/impl/ConfigServiceImpl.java b/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/impl/ConfigServiceImpl.java index 7de44cd7..e0247925 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/impl/ConfigServiceImpl.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/impl/ConfigServiceImpl.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.service.biz.impl; import cn.hippo4j.common.config.ApplicationContextHolder; @@ -118,8 +135,7 @@ public class ConfigServiceImpl implements ConfigService { .condition( existConfig == null, () -> configService.addConfigInfo(configInfo), - () -> configService.updateConfigInfo(identify, configInfo) - ); + () -> configService.updateConfigInfo(identify, configInfo)); ConfigChangePublisher.notifyConfigChange(new LocalDataChangeEvent(identify, ContentUtil.getGroupKey(configInfo))); } @@ -141,8 +157,7 @@ public class ConfigServiceImpl implements ConfigService { ConfigAllInfo configAllInfo = configInfoMapper.selectOne( Wrappers.lambdaQuery(ConfigAllInfo.class) .eq(ConfigAllInfo::getTpId, config.getTpId()) - .eq(ConfigAllInfo::getDelFlag, DelEnum.NORMAL.getIntCode()) - ); + .eq(ConfigAllInfo::getDelFlag, DelEnum.NORMAL.getIntCode())); Assert.isNull(configAllInfo, "线程池配置已存在."); if (SqlHelper.retBool(configInfoMapper.insert(config))) { @@ -157,12 +172,7 @@ public class ConfigServiceImpl implements ConfigService { return null; } - @LogRecord( - bizNo = "{{#config.itemId}}_{{#config.tpId}}", - category = "THREAD_POOL_UPDATE", - success = "核心线程: {{#config.coreSize}}, 最大线程: {{#config.maxSize}}, 队列类型: {{#config.queueType}}, 队列容量: {{#config.capacity}}, 拒绝策略: {{#config.rejectedType}}", - detail = "{{#config.toString()}}" - ) + @LogRecord(bizNo = "{{#config.itemId}}_{{#config.tpId}}", category = "THREAD_POOL_UPDATE", success = "核心线程: {{#config.coreSize}}, 最大线程: {{#config.maxSize}}, 队列类型: {{#config.queueType}}, 队列容量: {{#config.capacity}}, 拒绝策略: {{#config.rejectedType}}", detail = "{{#config.toString()}}") public void updateConfigInfo(String identify, ConfigAllInfo config) { LambdaUpdateWrapper wrapper = Wrappers.lambdaUpdate(ConfigAllInfo.class) .eq(ConfigAllInfo::getTpId, config.getTpId()) diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/impl/HisRunDataServiceImpl.java b/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/impl/HisRunDataServiceImpl.java index bedd43b1..f530ce43 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/impl/HisRunDataServiceImpl.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/impl/HisRunDataServiceImpl.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.service.biz.impl; import cn.hippo4j.common.monitor.Message; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/impl/ItemServiceImpl.java b/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/impl/ItemServiceImpl.java index b2a43e85..5bc0b0a8 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/impl/ItemServiceImpl.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/impl/ItemServiceImpl.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.service.biz.impl; import cn.hippo4j.common.toolkit.Assert; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/impl/LogRecordBizServiceImpl.java b/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/impl/LogRecordBizServiceImpl.java index 553bc84b..760eb5d5 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/impl/LogRecordBizServiceImpl.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/impl/LogRecordBizServiceImpl.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.service.biz.impl; import cn.hippo4j.config.mapper.LogRecordMapper; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/impl/LogRecordServiceImpl.java b/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/impl/LogRecordServiceImpl.java index 5e8a8158..d0f1d405 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/impl/LogRecordServiceImpl.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/impl/LogRecordServiceImpl.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.service.biz.impl; import cn.hippo4j.config.mapper.LogRecordMapper; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/impl/NotifyServiceImpl.java b/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/impl/NotifyServiceImpl.java index 4a9d405f..685a2107 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/impl/NotifyServiceImpl.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/impl/NotifyServiceImpl.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.service.biz.impl; import cn.hippo4j.common.toolkit.GroupKey; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/impl/TenantServiceImpl.java b/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/impl/TenantServiceImpl.java index 91472d6d..04238bc0 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/impl/TenantServiceImpl.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/impl/TenantServiceImpl.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.service.biz.impl; import cn.hippo4j.common.toolkit.Assert; @@ -87,13 +104,7 @@ public class TenantServiceImpl implements TenantService { } @Override - @LogRecord( - prefix = "item", - bizNo = "{{#reqDTO.tenantId}}_{{#reqDTO.tenantName}}", - category = "TENANT_UPDATE", - success = "更新租户, ID :: {{#reqDTO.id}}, 租户名称由 :: {TENANT{#reqDTO.id}} -> {{#reqDTO.tenantName}}", - detail = "{{#reqDTO.toString()}}" - ) + @LogRecord(prefix = "item", bizNo = "{{#reqDTO.tenantId}}_{{#reqDTO.tenantName}}", category = "TENANT_UPDATE", success = "更新租户, ID :: {{#reqDTO.id}}, 租户名称由 :: {TENANT{#reqDTO.id}} -> {{#reqDTO.tenantName}}", detail = "{{#reqDTO.toString()}}") public void updateTenant(TenantUpdateReqDTO reqDTO) { TenantInfo tenantInfo = BeanUtil.convert(reqDTO, TenantInfo.class); int updateResult = tenantInfoMapper.update(tenantInfo, Wrappers diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/impl/ThreadPoolServiceImpl.java b/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/impl/ThreadPoolServiceImpl.java index 01a13017..456faf28 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/impl/ThreadPoolServiceImpl.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/service/biz/impl/ThreadPoolServiceImpl.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.service.biz.impl; import cn.hippo4j.common.enums.DelEnum; @@ -66,20 +83,14 @@ public class ThreadPoolServiceImpl implements ThreadPoolService { configService.insertOrUpdate(identify, BeanUtil.convert(reqDTO, ConfigAllInfo.class)); } - @LogRecord( - bizNo = "{{#reqDTO.itemId}}_{{#reqDTO.tpId}}", - category = "THREAD_POOL_DELETE", - success = "删除线程池: {{#reqDTO.tpId}}", - detail = "{{#reqDTO.toString()}}" - ) + @LogRecord(bizNo = "{{#reqDTO.itemId}}_{{#reqDTO.tpId}}", category = "THREAD_POOL_DELETE", success = "删除线程池: {{#reqDTO.tpId}}", detail = "{{#reqDTO.toString()}}") @Override public void deletePool(ThreadPoolDelReqDTO reqDTO) { configInfoMapper.delete( Wrappers.lambdaUpdate(ConfigAllInfo.class) .eq(ConfigAllInfo::getTenantId, reqDTO.getTenantId()) .eq(ConfigAllInfo::getItemId, reqDTO.getItemId()) - .eq(ConfigAllInfo::getTpId, reqDTO.getTpId()) - ); + .eq(ConfigAllInfo::getTpId, reqDTO.getTpId())); } @Override diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/service/handler/ClientCloseHookRemoveConfigCache.java b/hippo4j-config/src/main/java/cn/hippo4j/config/service/handler/ClientCloseHookRemoveConfigCache.java index 2ab54a67..3c8dda3a 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/service/handler/ClientCloseHookRemoveConfigCache.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/service/handler/ClientCloseHookRemoveConfigCache.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.service.handler; import cn.hippo4j.common.api.ClientCloseHookExecute; @@ -21,8 +38,7 @@ public class ClientCloseHookRemoveConfigCache implements ClientCloseHookExecute public void closeHook(ClientCloseHookReq req) { log.info( "Remove Config Cache, Execute client hook function. Req :: {}", - JSONUtil.toJSONString(req) - ); + JSONUtil.toJSONString(req)); try { String groupKey = req.getGroupKey(); diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/service/handler/CustomOperatorGetServiceImpl.java b/hippo4j-config/src/main/java/cn/hippo4j/config/service/handler/CustomOperatorGetServiceImpl.java index 56f8edef..86cb7835 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/service/handler/CustomOperatorGetServiceImpl.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/service/handler/CustomOperatorGetServiceImpl.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.service.handler; import cn.hippo4j.common.toolkit.StringUtil; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/service/handler/TenantIdFunctionServiceImpl.java b/hippo4j-config/src/main/java/cn/hippo4j/config/service/handler/TenantIdFunctionServiceImpl.java index bff1cdb4..e9073dfe 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/service/handler/TenantIdFunctionServiceImpl.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/service/handler/TenantIdFunctionServiceImpl.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.service.handler; import cn.hippo4j.config.model.biz.tenant.TenantRespDTO; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/toolkit/BeanUtil.java b/hippo4j-config/src/main/java/cn/hippo4j/config/toolkit/BeanUtil.java index 4e67e579..467171fe 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/toolkit/BeanUtil.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/toolkit/BeanUtil.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.toolkit; import com.github.dozermapper.core.DozerBeanMapperBuilder; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/toolkit/ClassUtil.java b/hippo4j-config/src/main/java/cn/hippo4j/config/toolkit/ClassUtil.java index e38019b5..740d1893 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/toolkit/ClassUtil.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/toolkit/ClassUtil.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.toolkit; import java.util.Objects; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/toolkit/ConfigExecutor.java b/hippo4j-config/src/main/java/cn/hippo4j/config/toolkit/ConfigExecutor.java index 88840e08..223566f5 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/toolkit/ConfigExecutor.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/toolkit/ConfigExecutor.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.toolkit; import cn.hippo4j.common.executor.ExecutorFactory; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/toolkit/EnvUtil.java b/hippo4j-config/src/main/java/cn/hippo4j/config/toolkit/EnvUtil.java index ba98053f..9a471d86 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/toolkit/EnvUtil.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/toolkit/EnvUtil.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.toolkit; import org.apache.commons.lang3.StringUtils; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/toolkit/MapUtil.java b/hippo4j-config/src/main/java/cn/hippo4j/config/toolkit/MapUtil.java index d153ffa0..a3993a00 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/toolkit/MapUtil.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/toolkit/MapUtil.java @@ -1,15 +1,29 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.toolkit; import cn.hutool.core.collection.CollUtil; import com.google.common.collect.Lists; -import com.google.common.collect.Maps; import java.util.List; import java.util.Map; import java.util.Objects; -import java.util.Optional; import java.util.function.BiFunction; -import java.util.stream.Collectors; /** * Map util. @@ -35,7 +49,6 @@ public class MapUtil { return val; } - /** * 根据 Key 进行模糊匹配. * diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/toolkit/Md5ConfigUtil.java b/hippo4j-config/src/main/java/cn/hippo4j/config/toolkit/Md5ConfigUtil.java index b0d47329..f2227c75 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/toolkit/Md5ConfigUtil.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/toolkit/Md5ConfigUtil.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.toolkit; import cn.hippo4j.common.toolkit.GroupKey; @@ -17,7 +34,6 @@ import java.util.Map; import static cn.hippo4j.common.constant.Constants.LINE_SEPARATOR; import static cn.hippo4j.common.constant.Constants.WORD_SEPARATOR; - /** * Md5 config util. * diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/toolkit/RequestUtil.java b/hippo4j-config/src/main/java/cn/hippo4j/config/toolkit/RequestUtil.java index 26b3b51b..f829fc12 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/toolkit/RequestUtil.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/toolkit/RequestUtil.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.toolkit; import cn.hutool.core.util.StrUtil; diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/toolkit/SimpleReadWriteLock.java b/hippo4j-config/src/main/java/cn/hippo4j/config/toolkit/SimpleReadWriteLock.java index 7b69a0fc..bd990288 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/toolkit/SimpleReadWriteLock.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/toolkit/SimpleReadWriteLock.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.toolkit; /** diff --git a/hippo4j-config/src/main/java/cn/hippo4j/config/toolkit/SingletonRepository.java b/hippo4j-config/src/main/java/cn/hippo4j/config/toolkit/SingletonRepository.java index 4f82e85b..8e2ed565 100644 --- a/hippo4j-config/src/main/java/cn/hippo4j/config/toolkit/SingletonRepository.java +++ b/hippo4j-config/src/main/java/cn/hippo4j/config/toolkit/SingletonRepository.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.config.toolkit; import java.util.concurrent.ConcurrentHashMap; diff --git a/hippo4j-console/src/main/java/cn/hippo4j/console/config/GlobalExceptionHandler.java b/hippo4j-console/src/main/java/cn/hippo4j/console/config/GlobalExceptionHandler.java index 1fee2ec0..f3647f43 100644 --- a/hippo4j-console/src/main/java/cn/hippo4j/console/config/GlobalExceptionHandler.java +++ b/hippo4j-console/src/main/java/cn/hippo4j/console/config/GlobalExceptionHandler.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.console.config; import cn.hippo4j.common.toolkit.CollectionUtil; diff --git a/hippo4j-console/src/main/java/cn/hippo4j/console/config/WebConfig.java b/hippo4j-console/src/main/java/cn/hippo4j/console/config/WebConfig.java index fe9296b0..bece5431 100644 --- a/hippo4j-console/src/main/java/cn/hippo4j/console/config/WebConfig.java +++ b/hippo4j-console/src/main/java/cn/hippo4j/console/config/WebConfig.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.console.config; import org.springframework.context.annotation.Configuration; diff --git a/hippo4j-console/src/main/java/cn/hippo4j/console/controller/ClientCloseHookController.java b/hippo4j-console/src/main/java/cn/hippo4j/console/controller/ClientCloseHookController.java index 9785c160..374471a4 100644 --- a/hippo4j-console/src/main/java/cn/hippo4j/console/controller/ClientCloseHookController.java +++ b/hippo4j-console/src/main/java/cn/hippo4j/console/controller/ClientCloseHookController.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.console.controller; import cn.hippo4j.common.api.ClientCloseHookExecute; diff --git a/hippo4j-console/src/main/java/cn/hippo4j/console/controller/DashboardController.java b/hippo4j-console/src/main/java/cn/hippo4j/console/controller/DashboardController.java index e76d758e..56dba31e 100644 --- a/hippo4j-console/src/main/java/cn/hippo4j/console/controller/DashboardController.java +++ b/hippo4j-console/src/main/java/cn/hippo4j/console/controller/DashboardController.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.console.controller; import cn.hippo4j.common.constant.Constants; diff --git a/hippo4j-console/src/main/java/cn/hippo4j/console/controller/HealthCheckController.java b/hippo4j-console/src/main/java/cn/hippo4j/console/controller/HealthCheckController.java index 6aa75fef..6a3cb2a0 100644 --- a/hippo4j-console/src/main/java/cn/hippo4j/console/controller/HealthCheckController.java +++ b/hippo4j-console/src/main/java/cn/hippo4j/console/controller/HealthCheckController.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.console.controller; import cn.hippo4j.common.constant.Constants; diff --git a/hippo4j-console/src/main/java/cn/hippo4j/console/controller/ItemController.java b/hippo4j-console/src/main/java/cn/hippo4j/console/controller/ItemController.java index 9d5d2948..6e473b1f 100644 --- a/hippo4j-console/src/main/java/cn/hippo4j/console/controller/ItemController.java +++ b/hippo4j-console/src/main/java/cn/hippo4j/console/controller/ItemController.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.console.controller; import cn.hippo4j.common.constant.Constants; diff --git a/hippo4j-console/src/main/java/cn/hippo4j/console/controller/LogRecordController.java b/hippo4j-console/src/main/java/cn/hippo4j/console/controller/LogRecordController.java index 62825a1d..3aca892f 100644 --- a/hippo4j-console/src/main/java/cn/hippo4j/console/controller/LogRecordController.java +++ b/hippo4j-console/src/main/java/cn/hippo4j/console/controller/LogRecordController.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.console.controller; import cn.hippo4j.common.constant.Constants; diff --git a/hippo4j-console/src/main/java/cn/hippo4j/console/controller/MonitorController.java b/hippo4j-console/src/main/java/cn/hippo4j/console/controller/MonitorController.java index 3ee3198b..05e95073 100644 --- a/hippo4j-console/src/main/java/cn/hippo4j/console/controller/MonitorController.java +++ b/hippo4j-console/src/main/java/cn/hippo4j/console/controller/MonitorController.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.console.controller; import cn.hippo4j.common.constant.Constants; diff --git a/hippo4j-console/src/main/java/cn/hippo4j/console/controller/NotifyController.java b/hippo4j-console/src/main/java/cn/hippo4j/console/controller/NotifyController.java index 8b82b5f5..9856f382 100644 --- a/hippo4j-console/src/main/java/cn/hippo4j/console/controller/NotifyController.java +++ b/hippo4j-console/src/main/java/cn/hippo4j/console/controller/NotifyController.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.console.controller; import cn.hippo4j.common.constant.Constants; diff --git a/hippo4j-console/src/main/java/cn/hippo4j/console/controller/PermissionController.java b/hippo4j-console/src/main/java/cn/hippo4j/console/controller/PermissionController.java index 94a19bfb..adb4f7cf 100644 --- a/hippo4j-console/src/main/java/cn/hippo4j/console/controller/PermissionController.java +++ b/hippo4j-console/src/main/java/cn/hippo4j/console/controller/PermissionController.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.console.controller; import com.baomidou.mybatisplus.core.metadata.IPage; diff --git a/hippo4j-console/src/main/java/cn/hippo4j/console/controller/RoleController.java b/hippo4j-console/src/main/java/cn/hippo4j/console/controller/RoleController.java index 06648324..4a073d3d 100644 --- a/hippo4j-console/src/main/java/cn/hippo4j/console/controller/RoleController.java +++ b/hippo4j-console/src/main/java/cn/hippo4j/console/controller/RoleController.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.console.controller; import com.baomidou.mybatisplus.core.metadata.IPage; diff --git a/hippo4j-console/src/main/java/cn/hippo4j/console/controller/TenantController.java b/hippo4j-console/src/main/java/cn/hippo4j/console/controller/TenantController.java index 9082a384..56dad4f8 100644 --- a/hippo4j-console/src/main/java/cn/hippo4j/console/controller/TenantController.java +++ b/hippo4j-console/src/main/java/cn/hippo4j/console/controller/TenantController.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.console.controller; import cn.hippo4j.common.constant.Constants; diff --git a/hippo4j-console/src/main/java/cn/hippo4j/console/controller/ThreadPoolController.java b/hippo4j-console/src/main/java/cn/hippo4j/console/controller/ThreadPoolController.java index 590373a7..4fede7e8 100644 --- a/hippo4j-console/src/main/java/cn/hippo4j/console/controller/ThreadPoolController.java +++ b/hippo4j-console/src/main/java/cn/hippo4j/console/controller/ThreadPoolController.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.console.controller; import cn.hippo4j.common.constant.Constants; diff --git a/hippo4j-console/src/main/java/cn/hippo4j/console/controller/UserController.java b/hippo4j-console/src/main/java/cn/hippo4j/console/controller/UserController.java index 04091505..2b07bd33 100644 --- a/hippo4j-console/src/main/java/cn/hippo4j/console/controller/UserController.java +++ b/hippo4j-console/src/main/java/cn/hippo4j/console/controller/UserController.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.console.controller; import cn.hippo4j.auth.model.UserInfo; diff --git a/hippo4j-console/src/main/java/cn/hippo4j/console/model/ChartInfo.java b/hippo4j-console/src/main/java/cn/hippo4j/console/model/ChartInfo.java index cba5cefc..e2f641e4 100644 --- a/hippo4j-console/src/main/java/cn/hippo4j/console/model/ChartInfo.java +++ b/hippo4j-console/src/main/java/cn/hippo4j/console/model/ChartInfo.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.console.model; import lombok.Data; diff --git a/hippo4j-console/src/main/java/cn/hippo4j/console/model/LineChartInfo.java b/hippo4j-console/src/main/java/cn/hippo4j/console/model/LineChartInfo.java index 452bc719..eedc5bed 100644 --- a/hippo4j-console/src/main/java/cn/hippo4j/console/model/LineChartInfo.java +++ b/hippo4j-console/src/main/java/cn/hippo4j/console/model/LineChartInfo.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.console.model; import lombok.AllArgsConstructor; diff --git a/hippo4j-console/src/main/java/cn/hippo4j/console/model/PieChartInfo.java b/hippo4j-console/src/main/java/cn/hippo4j/console/model/PieChartInfo.java index 08cbd9a7..f72f9780 100644 --- a/hippo4j-console/src/main/java/cn/hippo4j/console/model/PieChartInfo.java +++ b/hippo4j-console/src/main/java/cn/hippo4j/console/model/PieChartInfo.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.console.model; import lombok.AllArgsConstructor; diff --git a/hippo4j-console/src/main/java/cn/hippo4j/console/model/RankingChart.java b/hippo4j-console/src/main/java/cn/hippo4j/console/model/RankingChart.java index 9e51abf9..d698c9c5 100644 --- a/hippo4j-console/src/main/java/cn/hippo4j/console/model/RankingChart.java +++ b/hippo4j-console/src/main/java/cn/hippo4j/console/model/RankingChart.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.console.model; import lombok.AllArgsConstructor; diff --git a/hippo4j-console/src/main/java/cn/hippo4j/console/model/TenantChart.java b/hippo4j-console/src/main/java/cn/hippo4j/console/model/TenantChart.java index fec46bbf..c0ca013d 100644 --- a/hippo4j-console/src/main/java/cn/hippo4j/console/model/TenantChart.java +++ b/hippo4j-console/src/main/java/cn/hippo4j/console/model/TenantChart.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.console.model; import lombok.AllArgsConstructor; diff --git a/hippo4j-console/src/main/java/cn/hippo4j/console/model/ThreadPoolInstanceInfo.java b/hippo4j-console/src/main/java/cn/hippo4j/console/model/ThreadPoolInstanceInfo.java index cc58d6c3..25aa5e7c 100644 --- a/hippo4j-console/src/main/java/cn/hippo4j/console/model/ThreadPoolInstanceInfo.java +++ b/hippo4j-console/src/main/java/cn/hippo4j/console/model/ThreadPoolInstanceInfo.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.console.model; import cn.hippo4j.config.model.ConfigAllInfo; diff --git a/hippo4j-console/src/main/java/cn/hippo4j/console/service/DashboardService.java b/hippo4j-console/src/main/java/cn/hippo4j/console/service/DashboardService.java index a873addd..5deab50b 100644 --- a/hippo4j-console/src/main/java/cn/hippo4j/console/service/DashboardService.java +++ b/hippo4j-console/src/main/java/cn/hippo4j/console/service/DashboardService.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.console.service; import cn.hippo4j.console.model.*; diff --git a/hippo4j-console/src/main/java/cn/hippo4j/console/service/impl/DashboardServiceImpl.java b/hippo4j-console/src/main/java/cn/hippo4j/console/service/impl/DashboardServiceImpl.java index f43e1554..60c775c1 100644 --- a/hippo4j-console/src/main/java/cn/hippo4j/console/service/impl/DashboardServiceImpl.java +++ b/hippo4j-console/src/main/java/cn/hippo4j/console/service/impl/DashboardServiceImpl.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.console.service.impl; import cn.hippo4j.common.model.InstanceInfo; @@ -99,7 +116,8 @@ public class DashboardServiceImpl implements DashboardService { List tenantInfos = tenantInfoMapper.selectList(Wrappers.lambdaQuery(TenantInfo.class).eq(TenantInfo::getDelFlag, DelEnum.NORMAL)); for (TenantInfo tenant : tenantInfos) { int tenantThreadPoolNum = 0; - LambdaQueryWrapper itemQueryWrapper = Wrappers.lambdaQuery(ItemInfo.class).eq(ItemInfo::getTenantId, tenant.getTenantId()).eq(ItemInfo::getDelFlag, DelEnum.NORMAL).select(ItemInfo::getItemId); + LambdaQueryWrapper itemQueryWrapper = + Wrappers.lambdaQuery(ItemInfo.class).eq(ItemInfo::getTenantId, tenant.getTenantId()).eq(ItemInfo::getDelFlag, DelEnum.NORMAL).select(ItemInfo::getItemId); List itemInfos = itemInfoMapper.selectList(itemQueryWrapper); for (ItemInfo item : itemInfos) { LambdaQueryWrapper threadPoolQueryWrapper = Wrappers.lambdaQuery(ConfigAllInfo.class) diff --git a/hippo4j-core/src/main/java/cn/hippo4j/core/config/BootstrapPropertiesInterface.java b/hippo4j-core/src/main/java/cn/hippo4j/core/config/BootstrapPropertiesInterface.java index e468d07d..d70d24ce 100644 --- a/hippo4j-core/src/main/java/cn/hippo4j/core/config/BootstrapPropertiesInterface.java +++ b/hippo4j-core/src/main/java/cn/hippo4j/core/config/BootstrapPropertiesInterface.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.config; /** diff --git a/hippo4j-core/src/main/java/cn/hippo4j/core/config/ConfigEmptyException.java b/hippo4j-core/src/main/java/cn/hippo4j/core/config/ConfigEmptyException.java index abe84448..0e596d0a 100644 --- a/hippo4j-core/src/main/java/cn/hippo4j/core/config/ConfigEmptyException.java +++ b/hippo4j-core/src/main/java/cn/hippo4j/core/config/ConfigEmptyException.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.config; import lombok.AllArgsConstructor; diff --git a/hippo4j-core/src/main/java/cn/hippo4j/core/config/UtilAutoConfiguration.java b/hippo4j-core/src/main/java/cn/hippo4j/core/config/UtilAutoConfiguration.java index 45724025..596704f8 100644 --- a/hippo4j-core/src/main/java/cn/hippo4j/core/config/UtilAutoConfiguration.java +++ b/hippo4j-core/src/main/java/cn/hippo4j/core/config/UtilAutoConfiguration.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.config; import cn.hippo4j.core.toolkit.inet.InetUtils; diff --git a/hippo4j-core/src/main/java/cn/hippo4j/core/config/WebThreadPoolConfiguration.java b/hippo4j-core/src/main/java/cn/hippo4j/core/config/WebThreadPoolConfiguration.java index 87a014e4..cb181388 100644 --- a/hippo4j-core/src/main/java/cn/hippo4j/core/config/WebThreadPoolConfiguration.java +++ b/hippo4j-core/src/main/java/cn/hippo4j/core/config/WebThreadPoolConfiguration.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.config; import cn.hippo4j.core.executor.state.ThreadPoolRunStateHandler; diff --git a/hippo4j-core/src/main/java/cn/hippo4j/core/enable/BeforeCheckConfiguration.java b/hippo4j-core/src/main/java/cn/hippo4j/core/enable/BeforeCheckConfiguration.java index 865e4593..91ed0a8c 100644 --- a/hippo4j-core/src/main/java/cn/hippo4j/core/enable/BeforeCheckConfiguration.java +++ b/hippo4j-core/src/main/java/cn/hippo4j/core/enable/BeforeCheckConfiguration.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.enable; import cn.hippo4j.common.toolkit.StringUtil; @@ -32,48 +49,42 @@ public class BeforeCheckConfiguration { if (StringUtil.isBlank(username)) { throw new ConfigEmptyException( "Web server failed to start. The dynamic thread pool username is empty.", - "Please check whether the [spring.dynamic.thread-pool.username] configuration is empty or an empty string." - ); + "Please check whether the [spring.dynamic.thread-pool.username] configuration is empty or an empty string."); } String password = properties.getPassword(); if (StringUtil.isBlank(password)) { throw new ConfigEmptyException( "Web server failed to start. The dynamic thread pool password is empty.", - "Please check whether the [spring.dynamic.thread-pool.password] configuration is empty or an empty string." - ); + "Please check whether the [spring.dynamic.thread-pool.password] configuration is empty or an empty string."); } String namespace = properties.getNamespace(); if (StringUtil.isBlank(namespace)) { throw new ConfigEmptyException( "Web server failed to start. The dynamic thread pool namespace is empty.", - "Please check whether the [spring.dynamic.thread-pool.namespace] configuration is empty or an empty string." - ); + "Please check whether the [spring.dynamic.thread-pool.namespace] configuration is empty or an empty string."); } String itemId = properties.getItemId(); if (StringUtil.isBlank(itemId)) { throw new ConfigEmptyException( "Web server failed to start. The dynamic thread pool item id is empty.", - "Please check whether the [spring.dynamic.thread-pool.item-id] configuration is empty or an empty string." - ); + "Please check whether the [spring.dynamic.thread-pool.item-id] configuration is empty or an empty string."); } String serverAddr = properties.getServerAddr(); if (StringUtil.isBlank(serverAddr)) { throw new ConfigEmptyException( "Web server failed to start. The dynamic thread pool server addr is empty.", - "Please check whether the [spring.dynamic.thread-pool.server-addr] configuration is empty or an empty string." - ); + "Please check whether the [spring.dynamic.thread-pool.server-addr] configuration is empty or an empty string."); } String applicationName = environment.getProperty("spring.application.name"); if (StringUtil.isBlank(applicationName)) { throw new ConfigEmptyException( "Web server failed to start. The dynamic thread pool application name is empty.", - "Please check whether the [spring.application.name] configuration is empty or an empty string." - ); + "Please check whether the [spring.application.name] configuration is empty or an empty string."); } } diff --git a/hippo4j-core/src/main/java/cn/hippo4j/core/enable/EnableDynamicThreadPool.java b/hippo4j-core/src/main/java/cn/hippo4j/core/enable/EnableDynamicThreadPool.java index a892a23a..9f3c492d 100644 --- a/hippo4j-core/src/main/java/cn/hippo4j/core/enable/EnableDynamicThreadPool.java +++ b/hippo4j-core/src/main/java/cn/hippo4j/core/enable/EnableDynamicThreadPool.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.enable; import org.springframework.context.annotation.Import; diff --git a/hippo4j-core/src/main/java/cn/hippo4j/core/enable/MarkerConfiguration.java b/hippo4j-core/src/main/java/cn/hippo4j/core/enable/MarkerConfiguration.java index 2daee96d..8ca7f74c 100644 --- a/hippo4j-core/src/main/java/cn/hippo4j/core/enable/MarkerConfiguration.java +++ b/hippo4j-core/src/main/java/cn/hippo4j/core/enable/MarkerConfiguration.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.enable; import org.springframework.context.annotation.Bean; diff --git a/hippo4j-core/src/main/java/cn/hippo4j/core/executor/DynamicThreadPool.java b/hippo4j-core/src/main/java/cn/hippo4j/core/executor/DynamicThreadPool.java index 34529adc..5bf69441 100644 --- a/hippo4j-core/src/main/java/cn/hippo4j/core/executor/DynamicThreadPool.java +++ b/hippo4j-core/src/main/java/cn/hippo4j/core/executor/DynamicThreadPool.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.executor; import java.lang.annotation.ElementType; diff --git a/hippo4j-core/src/main/java/cn/hippo4j/core/executor/DynamicThreadPoolExecutor.java b/hippo4j-core/src/main/java/cn/hippo4j/core/executor/DynamicThreadPoolExecutor.java index 9056c877..d8f96d8a 100644 --- a/hippo4j-core/src/main/java/cn/hippo4j/core/executor/DynamicThreadPoolExecutor.java +++ b/hippo4j-core/src/main/java/cn/hippo4j/core/executor/DynamicThreadPoolExecutor.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.executor; import cn.hippo4j.common.config.ApplicationContextHolder; diff --git a/hippo4j-core/src/main/java/cn/hippo4j/core/executor/DynamicThreadPoolWrapper.java b/hippo4j-core/src/main/java/cn/hippo4j/core/executor/DynamicThreadPoolWrapper.java index dda8ed69..456e0b26 100644 --- a/hippo4j-core/src/main/java/cn/hippo4j/core/executor/DynamicThreadPoolWrapper.java +++ b/hippo4j-core/src/main/java/cn/hippo4j/core/executor/DynamicThreadPoolWrapper.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.executor; import cn.hippo4j.core.executor.support.AbstractDynamicExecutorSupport; diff --git a/hippo4j-core/src/main/java/cn/hippo4j/core/executor/ThreadPoolNotifyAlarmHandler.java b/hippo4j-core/src/main/java/cn/hippo4j/core/executor/ThreadPoolNotifyAlarmHandler.java index e4fb1c11..02305e20 100644 --- a/hippo4j-core/src/main/java/cn/hippo4j/core/executor/ThreadPoolNotifyAlarmHandler.java +++ b/hippo4j-core/src/main/java/cn/hippo4j/core/executor/ThreadPoolNotifyAlarmHandler.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.executor; import cn.hippo4j.common.notify.HippoSendMessageService; @@ -50,8 +67,7 @@ public class ThreadPoolNotifyAlarmHandler implements Runnable, CommandLineRunner private final ScheduledExecutorService ALARM_NOTIFY_EXECUTOR = new ScheduledThreadPoolExecutor( 1, - r -> new Thread(r, "client.alarm.notify") - ); + r -> new Thread(r, "client.alarm.notify")); private final ExecutorService EXECUTE_TIMEOUT_EXECUTOR = ThreadPoolBuilder.builder() .poolThreadSize(2, 4) diff --git a/hippo4j-core/src/main/java/cn/hippo4j/core/executor/manage/GlobalNotifyAlarmManage.java b/hippo4j-core/src/main/java/cn/hippo4j/core/executor/manage/GlobalNotifyAlarmManage.java index b9d26972..1d1c15d6 100644 --- a/hippo4j-core/src/main/java/cn/hippo4j/core/executor/manage/GlobalNotifyAlarmManage.java +++ b/hippo4j-core/src/main/java/cn/hippo4j/core/executor/manage/GlobalNotifyAlarmManage.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.executor.manage; import cn.hippo4j.common.notify.ThreadPoolNotifyAlarm; diff --git a/hippo4j-core/src/main/java/cn/hippo4j/core/executor/manage/GlobalThreadPoolManage.java b/hippo4j-core/src/main/java/cn/hippo4j/core/executor/manage/GlobalThreadPoolManage.java index 2f8574b0..885d775d 100644 --- a/hippo4j-core/src/main/java/cn/hippo4j/core/executor/manage/GlobalThreadPoolManage.java +++ b/hippo4j-core/src/main/java/cn/hippo4j/core/executor/manage/GlobalThreadPoolManage.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.executor.manage; import cn.hippo4j.common.model.PoolParameter; diff --git a/hippo4j-core/src/main/java/cn/hippo4j/core/executor/state/AbstractThreadPoolRuntime.java b/hippo4j-core/src/main/java/cn/hippo4j/core/executor/state/AbstractThreadPoolRuntime.java index 40e890f4..5eb2162e 100644 --- a/hippo4j-core/src/main/java/cn/hippo4j/core/executor/state/AbstractThreadPoolRuntime.java +++ b/hippo4j-core/src/main/java/cn/hippo4j/core/executor/state/AbstractThreadPoolRuntime.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.executor.state; import cn.hippo4j.common.model.PoolRunStateInfo; diff --git a/hippo4j-core/src/main/java/cn/hippo4j/core/executor/state/ThreadPoolRunStateHandler.java b/hippo4j-core/src/main/java/cn/hippo4j/core/executor/state/ThreadPoolRunStateHandler.java index 2c812631..b3f78493 100644 --- a/hippo4j-core/src/main/java/cn/hippo4j/core/executor/state/ThreadPoolRunStateHandler.java +++ b/hippo4j-core/src/main/java/cn/hippo4j/core/executor/state/ThreadPoolRunStateHandler.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.executor.state; import cn.hippo4j.common.model.ManyPoolRunStateInfo; @@ -41,8 +58,7 @@ public class ThreadPoolRunStateHandler extends AbstractThreadPoolRuntime { "已分配: ", ByteConvertUtil.getPrintSize(runtimeInfo.getTotalMemory()), " / 最大可用: ", - ByteConvertUtil.getPrintSize(runtimeInfo.getMaxMemory()) - ).toString(); + ByteConvertUtil.getPrintSize(runtimeInfo.getMaxMemory())).toString(); poolRunStateInfo.setCurrentLoad(poolRunStateInfo.getCurrentLoad() + "%"); poolRunStateInfo.setPeakLoad(poolRunStateInfo.getPeakLoad() + "%"); diff --git a/hippo4j-core/src/main/java/cn/hippo4j/core/executor/state/ThreadPoolStatusHandler.java b/hippo4j-core/src/main/java/cn/hippo4j/core/executor/state/ThreadPoolStatusHandler.java index 3f6354b5..58c4a3bd 100644 --- a/hippo4j-core/src/main/java/cn/hippo4j/core/executor/state/ThreadPoolStatusHandler.java +++ b/hippo4j-core/src/main/java/cn/hippo4j/core/executor/state/ThreadPoolStatusHandler.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.executor.state; import cn.hutool.core.util.ReflectUtil; diff --git a/hippo4j-core/src/main/java/cn/hippo4j/core/executor/support/AbstractBuildThreadPoolTemplate.java b/hippo4j-core/src/main/java/cn/hippo4j/core/executor/support/AbstractBuildThreadPoolTemplate.java index b5a23509..032ebb57 100644 --- a/hippo4j-core/src/main/java/cn/hippo4j/core/executor/support/AbstractBuildThreadPoolTemplate.java +++ b/hippo4j-core/src/main/java/cn/hippo4j/core/executor/support/AbstractBuildThreadPoolTemplate.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.executor.support; import cn.hippo4j.common.toolkit.Assert; @@ -121,8 +138,7 @@ public class AbstractBuildThreadPoolTemplate { initParam.getWorkQueue(), initParam.getThreadPoolId(), initParam.getThreadFactory(), - initParam.getRejectedExecutionHandler() - ); + initParam.getRejectedExecutionHandler()); } catch (IllegalArgumentException ex) { throw new IllegalArgumentException(String.format("Error creating thread pool parameter. threadPool id :: %s", initParam.getThreadPoolId()), ex); } @@ -216,4 +232,3 @@ public class AbstractBuildThreadPoolTemplate { } } - diff --git a/hippo4j-core/src/main/java/cn/hippo4j/core/executor/support/AbstractDynamicExecutorSupport.java b/hippo4j-core/src/main/java/cn/hippo4j/core/executor/support/AbstractDynamicExecutorSupport.java index 2c265bda..cc28f860 100644 --- a/hippo4j-core/src/main/java/cn/hippo4j/core/executor/support/AbstractDynamicExecutorSupport.java +++ b/hippo4j-core/src/main/java/cn/hippo4j/core/executor/support/AbstractDynamicExecutorSupport.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.executor.support; import lombok.extern.slf4j.Slf4j; @@ -14,7 +31,9 @@ import java.util.concurrent.*; */ @Slf4j public abstract class AbstractDynamicExecutorSupport extends ThreadPoolExecutor - implements InitializingBean, DisposableBean { + implements + InitializingBean, + DisposableBean { private String threadPoolId; diff --git a/hippo4j-core/src/main/java/cn/hippo4j/core/executor/support/CommonDynamicThreadPool.java b/hippo4j-core/src/main/java/cn/hippo4j/core/executor/support/CommonDynamicThreadPool.java index 1ba4a6ae..1c8d25fa 100644 --- a/hippo4j-core/src/main/java/cn/hippo4j/core/executor/support/CommonDynamicThreadPool.java +++ b/hippo4j-core/src/main/java/cn/hippo4j/core/executor/support/CommonDynamicThreadPool.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.executor.support; import cn.hippo4j.core.executor.DynamicThreadPoolExecutor; diff --git a/hippo4j-core/src/main/java/cn/hippo4j/core/executor/support/FastThreadPoolExecutor.java b/hippo4j-core/src/main/java/cn/hippo4j/core/executor/support/FastThreadPoolExecutor.java index 200769d7..6f87b0a4 100644 --- a/hippo4j-core/src/main/java/cn/hippo4j/core/executor/support/FastThreadPoolExecutor.java +++ b/hippo4j-core/src/main/java/cn/hippo4j/core/executor/support/FastThreadPoolExecutor.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.executor.support; import lombok.extern.slf4j.Slf4j; diff --git a/hippo4j-core/src/main/java/cn/hippo4j/core/executor/support/QueueTypeEnum.java b/hippo4j-core/src/main/java/cn/hippo4j/core/executor/support/QueueTypeEnum.java index 389b3fb9..c07db712 100644 --- a/hippo4j-core/src/main/java/cn/hippo4j/core/executor/support/QueueTypeEnum.java +++ b/hippo4j-core/src/main/java/cn/hippo4j/core/executor/support/QueueTypeEnum.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.executor.support; import cn.hippo4j.core.spi.CustomBlockingQueue; @@ -102,8 +119,7 @@ public enum QueueTypeEnum { } return new LinkedBlockingQueue(temCapacity); - }) - ); + })); return blockingQueue; } diff --git a/hippo4j-core/src/main/java/cn/hippo4j/core/executor/support/RejectedPolicies.java b/hippo4j-core/src/main/java/cn/hippo4j/core/executor/support/RejectedPolicies.java index 8ed4c5e8..d1612876 100644 --- a/hippo4j-core/src/main/java/cn/hippo4j/core/executor/support/RejectedPolicies.java +++ b/hippo4j-core/src/main/java/cn/hippo4j/core/executor/support/RejectedPolicies.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.executor.support; import lombok.extern.slf4j.Slf4j; diff --git a/hippo4j-core/src/main/java/cn/hippo4j/core/executor/support/RejectedTypeEnum.java b/hippo4j-core/src/main/java/cn/hippo4j/core/executor/support/RejectedTypeEnum.java index f8e995d8..c457e171 100644 --- a/hippo4j-core/src/main/java/cn/hippo4j/core/executor/support/RejectedTypeEnum.java +++ b/hippo4j-core/src/main/java/cn/hippo4j/core/executor/support/RejectedTypeEnum.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.executor.support; import cn.hippo4j.core.spi.CustomRejectedExecutionHandler; diff --git a/hippo4j-core/src/main/java/cn/hippo4j/core/executor/support/ResizableCapacityLinkedBlockIngQueue.java b/hippo4j-core/src/main/java/cn/hippo4j/core/executor/support/ResizableCapacityLinkedBlockIngQueue.java index ff900969..f59bc7ff 100644 --- a/hippo4j-core/src/main/java/cn/hippo4j/core/executor/support/ResizableCapacityLinkedBlockIngQueue.java +++ b/hippo4j-core/src/main/java/cn/hippo4j/core/executor/support/ResizableCapacityLinkedBlockIngQueue.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.executor.support; import cn.hutool.core.util.ReflectUtil; diff --git a/hippo4j-core/src/main/java/cn/hippo4j/core/executor/support/TaskQueue.java b/hippo4j-core/src/main/java/cn/hippo4j/core/executor/support/TaskQueue.java index 7bfd78ad..fb43108e 100644 --- a/hippo4j-core/src/main/java/cn/hippo4j/core/executor/support/TaskQueue.java +++ b/hippo4j-core/src/main/java/cn/hippo4j/core/executor/support/TaskQueue.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.executor.support; import java.util.concurrent.LinkedBlockingQueue; diff --git a/hippo4j-core/src/main/java/cn/hippo4j/core/executor/support/ThreadFactoryBuilder.java b/hippo4j-core/src/main/java/cn/hippo4j/core/executor/support/ThreadFactoryBuilder.java index 4a395f77..f5e6e037 100644 --- a/hippo4j-core/src/main/java/cn/hippo4j/core/executor/support/ThreadFactoryBuilder.java +++ b/hippo4j-core/src/main/java/cn/hippo4j/core/executor/support/ThreadFactoryBuilder.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.executor.support; import cn.hippo4j.common.design.builder.Builder; diff --git a/hippo4j-core/src/main/java/cn/hippo4j/core/executor/support/ThreadPoolBuilder.java b/hippo4j-core/src/main/java/cn/hippo4j/core/executor/support/ThreadPoolBuilder.java index 7d3517b1..c9376519 100644 --- a/hippo4j-core/src/main/java/cn/hippo4j/core/executor/support/ThreadPoolBuilder.java +++ b/hippo4j-core/src/main/java/cn/hippo4j/core/executor/support/ThreadPoolBuilder.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.executor.support; import cn.hippo4j.common.design.builder.Builder; diff --git a/hippo4j-core/src/main/java/cn/hippo4j/core/executor/support/ThreadPoolExecutorTemplate.java b/hippo4j-core/src/main/java/cn/hippo4j/core/executor/support/ThreadPoolExecutorTemplate.java index 6810b57d..4564a2a5 100644 --- a/hippo4j-core/src/main/java/cn/hippo4j/core/executor/support/ThreadPoolExecutorTemplate.java +++ b/hippo4j-core/src/main/java/cn/hippo4j/core/executor/support/ThreadPoolExecutorTemplate.java @@ -1,5 +1,21 @@ -package cn.hippo4j.core.executor.support; +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package cn.hippo4j.core.executor.support; import cn.hippo4j.common.toolkit.ArrayUtil; diff --git a/hippo4j-core/src/main/java/cn/hippo4j/core/executor/web/AbstractWebThreadPoolService.java b/hippo4j-core/src/main/java/cn/hippo4j/core/executor/web/AbstractWebThreadPoolService.java index bb9fa7b0..2f257c8c 100644 --- a/hippo4j-core/src/main/java/cn/hippo4j/core/executor/web/AbstractWebThreadPoolService.java +++ b/hippo4j-core/src/main/java/cn/hippo4j/core/executor/web/AbstractWebThreadPoolService.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.executor.web; import cn.hippo4j.common.config.ApplicationContextHolder; diff --git a/hippo4j-core/src/main/java/cn/hippo4j/core/executor/web/JettyWebThreadPoolHandler.java b/hippo4j-core/src/main/java/cn/hippo4j/core/executor/web/JettyWebThreadPoolHandler.java index 5c2a6cbd..617eb496 100644 --- a/hippo4j-core/src/main/java/cn/hippo4j/core/executor/web/JettyWebThreadPoolHandler.java +++ b/hippo4j-core/src/main/java/cn/hippo4j/core/executor/web/JettyWebThreadPoolHandler.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.executor.web; import cn.hippo4j.common.model.PoolBaseInfo; @@ -87,8 +104,7 @@ public class JettyWebThreadPoolHandler extends AbstractWebThreadPoolService { "\n coreSize :: [{}]" + "\n maxSize :: [{}]", String.format("%s => %s", minThreads, jettyExecutor.getMinThreads()), - String.format("%s => %s", maxThreads, jettyExecutor.getMaxThreads()) - ); + String.format("%s => %s", maxThreads, jettyExecutor.getMaxThreads())); } catch (Exception ex) { log.error("Failed to modify the jetty thread pool parameter.", ex); } diff --git a/hippo4j-core/src/main/java/cn/hippo4j/core/executor/web/TomcatWebThreadPoolHandler.java b/hippo4j-core/src/main/java/cn/hippo4j/core/executor/web/TomcatWebThreadPoolHandler.java index 107de214..1852a8a4 100644 --- a/hippo4j-core/src/main/java/cn/hippo4j/core/executor/web/TomcatWebThreadPoolHandler.java +++ b/hippo4j-core/src/main/java/cn/hippo4j/core/executor/web/TomcatWebThreadPoolHandler.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.executor.web; import cn.hippo4j.common.model.PoolBaseInfo; @@ -119,8 +136,7 @@ public class TomcatWebThreadPoolHandler extends AbstractWebThreadPoolService { "\n keepAliveTime :: [{}]", String.format("%s => %s", originalCoreSize, poolParameterInfo.getCoreSize()), String.format("%s => %s", originalMaximumPoolSize, poolParameterInfo.getMaxSize()), - String.format("%s => %s", originalKeepAliveTime, poolParameterInfo.getKeepAliveTime()) - ); + String.format("%s => %s", originalKeepAliveTime, poolParameterInfo.getKeepAliveTime())); } catch (Exception ex) { log.error("Failed to modify the Tomcat thread pool parameter.", ex); } diff --git a/hippo4j-core/src/main/java/cn/hippo4j/core/executor/web/UndertowWebThreadPoolHandler.java b/hippo4j-core/src/main/java/cn/hippo4j/core/executor/web/UndertowWebThreadPoolHandler.java index d3d41ff9..dab8f7f8 100644 --- a/hippo4j-core/src/main/java/cn/hippo4j/core/executor/web/UndertowWebThreadPoolHandler.java +++ b/hippo4j-core/src/main/java/cn/hippo4j/core/executor/web/UndertowWebThreadPoolHandler.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.executor.web; import cn.hippo4j.common.model.PoolBaseInfo; @@ -124,7 +141,8 @@ public class UndertowWebThreadPoolHandler extends AbstractWebThreadPoolService { stateInfo.setPeakLoad(peakLoad); long rejectCount = fieldObject instanceof DynamicThreadPoolExecutor - ? ((DynamicThreadPoolExecutor) fieldObject).getRejectCountNum() : -1L; + ? ((DynamicThreadPoolExecutor) fieldObject).getRejectCountNum() + : -1L; stateInfo.setRejectCount(rejectCount); stateInfo.setClientLastRefreshTime(DateUtil.formatDateTime(new Date())); stateInfo.setTimestamp(System.currentTimeMillis()); @@ -154,8 +172,7 @@ public class UndertowWebThreadPoolHandler extends AbstractWebThreadPoolService { "\n keepAliveTime :: [{}]", String.format("%s => %s", originalCoreSize, coreSize), String.format("%s => %s", originalMaximumPoolSize, maxSize), - String.format("%s => %s", originalKeepAliveTime, keepAliveTime) - ); + String.format("%s => %s", originalKeepAliveTime, keepAliveTime)); } catch (Exception ex) { log.error("Failed to modify the undertow thread pool parameter.", ex); diff --git a/hippo4j-core/src/main/java/cn/hippo4j/core/executor/web/WebThreadPoolHandlerChoose.java b/hippo4j-core/src/main/java/cn/hippo4j/core/executor/web/WebThreadPoolHandlerChoose.java index a5195c14..d1a60fa9 100644 --- a/hippo4j-core/src/main/java/cn/hippo4j/core/executor/web/WebThreadPoolHandlerChoose.java +++ b/hippo4j-core/src/main/java/cn/hippo4j/core/executor/web/WebThreadPoolHandlerChoose.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.executor.web; import cn.hippo4j.common.config.ApplicationContextHolder; diff --git a/hippo4j-core/src/main/java/cn/hippo4j/core/executor/web/WebThreadPoolRunStateHandler.java b/hippo4j-core/src/main/java/cn/hippo4j/core/executor/web/WebThreadPoolRunStateHandler.java index b6978dd8..88c3caff 100644 --- a/hippo4j-core/src/main/java/cn/hippo4j/core/executor/web/WebThreadPoolRunStateHandler.java +++ b/hippo4j-core/src/main/java/cn/hippo4j/core/executor/web/WebThreadPoolRunStateHandler.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.executor.web; import cn.hippo4j.common.model.PoolRunStateInfo; @@ -24,8 +41,7 @@ public class WebThreadPoolRunStateHandler extends AbstractThreadPoolRuntime { "已分配: ", ByteConvertUtil.getPrintSize(runtimeInfo.getTotalMemory()), " / 最大可用: ", - ByteConvertUtil.getPrintSize(runtimeInfo.getMaxMemory()) - ).toString(); + ByteConvertUtil.getPrintSize(runtimeInfo.getMaxMemory())).toString(); poolRunStateInfo.setCurrentLoad(poolRunStateInfo.getCurrentLoad() + "%"); poolRunStateInfo.setPeakLoad(poolRunStateInfo.getPeakLoad() + "%"); diff --git a/hippo4j-core/src/main/java/cn/hippo4j/core/executor/web/WebThreadPoolService.java b/hippo4j-core/src/main/java/cn/hippo4j/core/executor/web/WebThreadPoolService.java index 2f09faed..99e39ec3 100644 --- a/hippo4j-core/src/main/java/cn/hippo4j/core/executor/web/WebThreadPoolService.java +++ b/hippo4j-core/src/main/java/cn/hippo4j/core/executor/web/WebThreadPoolService.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.executor.web; import cn.hippo4j.common.model.PoolBaseInfo; diff --git a/hippo4j-core/src/main/java/cn/hippo4j/core/handler/DynamicThreadPoolBannerHandler.java b/hippo4j-core/src/main/java/cn/hippo4j/core/handler/DynamicThreadPoolBannerHandler.java index a5cbd1a4..a7f80daa 100644 --- a/hippo4j-core/src/main/java/cn/hippo4j/core/handler/DynamicThreadPoolBannerHandler.java +++ b/hippo4j-core/src/main/java/cn/hippo4j/core/handler/DynamicThreadPoolBannerHandler.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.handler; import cn.hippo4j.core.config.BootstrapPropertiesInterface; diff --git a/hippo4j-core/src/main/java/cn/hippo4j/core/proxy/RejectedProxyInvocationHandler.java b/hippo4j-core/src/main/java/cn/hippo4j/core/proxy/RejectedProxyInvocationHandler.java index 65794502..9466a63e 100644 --- a/hippo4j-core/src/main/java/cn/hippo4j/core/proxy/RejectedProxyInvocationHandler.java +++ b/hippo4j-core/src/main/java/cn/hippo4j/core/proxy/RejectedProxyInvocationHandler.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.proxy; import cn.hippo4j.common.config.ApplicationContextHolder; diff --git a/hippo4j-core/src/main/java/cn/hippo4j/core/proxy/RejectedProxyUtil.java b/hippo4j-core/src/main/java/cn/hippo4j/core/proxy/RejectedProxyUtil.java index 745e6d06..8becab3c 100644 --- a/hippo4j-core/src/main/java/cn/hippo4j/core/proxy/RejectedProxyUtil.java +++ b/hippo4j-core/src/main/java/cn/hippo4j/core/proxy/RejectedProxyUtil.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.proxy; import java.lang.reflect.Proxy; @@ -25,8 +42,7 @@ public class RejectedProxyUtil { .newProxyInstance( rejectedExecutionHandler.getClass().getClassLoader(), new Class[]{RejectedExecutionHandler.class}, - new RejectedProxyInvocationHandler(rejectedExecutionHandler, threadPoolId, rejectedNum) - ); + new RejectedProxyInvocationHandler(rejectedExecutionHandler, threadPoolId, rejectedNum)); return rejectedProxy; } diff --git a/hippo4j-core/src/main/java/cn/hippo4j/core/spi/CustomBlockingQueue.java b/hippo4j-core/src/main/java/cn/hippo4j/core/spi/CustomBlockingQueue.java index 96186138..8a42bde8 100644 --- a/hippo4j-core/src/main/java/cn/hippo4j/core/spi/CustomBlockingQueue.java +++ b/hippo4j-core/src/main/java/cn/hippo4j/core/spi/CustomBlockingQueue.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.spi; import java.util.concurrent.BlockingQueue; diff --git a/hippo4j-core/src/main/java/cn/hippo4j/core/spi/CustomRejectedExecutionHandler.java b/hippo4j-core/src/main/java/cn/hippo4j/core/spi/CustomRejectedExecutionHandler.java index 62e4e42c..d2d73105 100644 --- a/hippo4j-core/src/main/java/cn/hippo4j/core/spi/CustomRejectedExecutionHandler.java +++ b/hippo4j-core/src/main/java/cn/hippo4j/core/spi/CustomRejectedExecutionHandler.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.spi; import java.util.concurrent.RejectedExecutionHandler; diff --git a/hippo4j-core/src/main/java/cn/hippo4j/core/spi/DynamicThreadPoolServiceLoader.java b/hippo4j-core/src/main/java/cn/hippo4j/core/spi/DynamicThreadPoolServiceLoader.java index c9d6ab86..c78607a0 100644 --- a/hippo4j-core/src/main/java/cn/hippo4j/core/spi/DynamicThreadPoolServiceLoader.java +++ b/hippo4j-core/src/main/java/cn/hippo4j/core/spi/DynamicThreadPoolServiceLoader.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.spi; import java.util.*; diff --git a/hippo4j-core/src/main/java/cn/hippo4j/core/spi/ServiceLoaderInstantiationException.java b/hippo4j-core/src/main/java/cn/hippo4j/core/spi/ServiceLoaderInstantiationException.java index 9d50d42c..5bf3059e 100644 --- a/hippo4j-core/src/main/java/cn/hippo4j/core/spi/ServiceLoaderInstantiationException.java +++ b/hippo4j-core/src/main/java/cn/hippo4j/core/spi/ServiceLoaderInstantiationException.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.spi; /** @@ -13,4 +30,3 @@ public class ServiceLoaderInstantiationException extends RuntimeException { } } - diff --git a/hippo4j-core/src/main/java/cn/hippo4j/core/toolkit/CalculateUtil.java b/hippo4j-core/src/main/java/cn/hippo4j/core/toolkit/CalculateUtil.java index a61c55fc..024f0d28 100644 --- a/hippo4j-core/src/main/java/cn/hippo4j/core/toolkit/CalculateUtil.java +++ b/hippo4j-core/src/main/java/cn/hippo4j/core/toolkit/CalculateUtil.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.toolkit; /** diff --git a/hippo4j-core/src/main/java/cn/hippo4j/core/toolkit/IdentifyUtil.java b/hippo4j-core/src/main/java/cn/hippo4j/core/toolkit/IdentifyUtil.java index 19ca5d31..101b3d50 100644 --- a/hippo4j-core/src/main/java/cn/hippo4j/core/toolkit/IdentifyUtil.java +++ b/hippo4j-core/src/main/java/cn/hippo4j/core/toolkit/IdentifyUtil.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.toolkit; import cn.hippo4j.common.config.ApplicationContextHolder; @@ -43,8 +60,7 @@ public class IdentifyUtil { ":", port, IDENTIFY_SLICER_SYMBOL, - CLIENT_IDENTIFICATION_VALUE - ).toString(); + CLIENT_IDENTIFICATION_VALUE).toString(); IDENTIFY = identification; return identification; @@ -82,8 +98,7 @@ public class IdentifyUtil { */ public static String getThreadPoolIdentify(String threadPoolId, String itemId, String namespace) { ArrayList params = Lists.newArrayList( - threadPoolId, itemId, namespace, getIdentify() - ); + threadPoolId, itemId, namespace, getIdentify()); return Joiner.on(GROUP_KEY_DELIMITER).join(params); } diff --git a/hippo4j-core/src/main/java/cn/hippo4j/core/toolkit/SystemClock.java b/hippo4j-core/src/main/java/cn/hippo4j/core/toolkit/SystemClock.java index fb2a4790..54416d4f 100644 --- a/hippo4j-core/src/main/java/cn/hippo4j/core/toolkit/SystemClock.java +++ b/hippo4j-core/src/main/java/cn/hippo4j/core/toolkit/SystemClock.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.toolkit; import java.util.concurrent.ScheduledThreadPoolExecutor; diff --git a/hippo4j-core/src/main/java/cn/hippo4j/core/toolkit/TraceContextUtil.java b/hippo4j-core/src/main/java/cn/hippo4j/core/toolkit/TraceContextUtil.java index 101865fe..75d79225 100644 --- a/hippo4j-core/src/main/java/cn/hippo4j/core/toolkit/TraceContextUtil.java +++ b/hippo4j-core/src/main/java/cn/hippo4j/core/toolkit/TraceContextUtil.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.toolkit; import org.slf4j.MDC; diff --git a/hippo4j-core/src/main/java/cn/hippo4j/core/toolkit/inet/DynamicThreadPoolAnnotationUtil.java b/hippo4j-core/src/main/java/cn/hippo4j/core/toolkit/inet/DynamicThreadPoolAnnotationUtil.java index b5f48631..5bdf0f58 100644 --- a/hippo4j-core/src/main/java/cn/hippo4j/core/toolkit/inet/DynamicThreadPoolAnnotationUtil.java +++ b/hippo4j-core/src/main/java/cn/hippo4j/core/toolkit/inet/DynamicThreadPoolAnnotationUtil.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.toolkit.inet; import cn.hippo4j.common.config.ApplicationContextHolder; diff --git a/hippo4j-core/src/main/java/cn/hippo4j/core/toolkit/inet/InetUtils.java b/hippo4j-core/src/main/java/cn/hippo4j/core/toolkit/inet/InetUtils.java index b65204c6..e767f87e 100644 --- a/hippo4j-core/src/main/java/cn/hippo4j/core/toolkit/inet/InetUtils.java +++ b/hippo4j-core/src/main/java/cn/hippo4j/core/toolkit/inet/InetUtils.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.toolkit.inet; import cn.hippo4j.core.executor.support.ThreadPoolBuilder; @@ -60,7 +77,7 @@ public class InetUtils implements Closeable { try { int lowest = Integer.MAX_VALUE; for (Enumeration nics = NetworkInterface - .getNetworkInterfaces(); nics.hasMoreElements(); ) { + .getNetworkInterfaces(); nics.hasMoreElements();) { NetworkInterface ifc = nics.nextElement(); if (ifc.isUp()) { this.log.trace("Testing interface: " + ifc.getDisplayName()); diff --git a/hippo4j-core/src/main/java/cn/hippo4j/core/toolkit/inet/InetUtilsProperties.java b/hippo4j-core/src/main/java/cn/hippo4j/core/toolkit/inet/InetUtilsProperties.java index 569d0bc6..e4fed7ee 100644 --- a/hippo4j-core/src/main/java/cn/hippo4j/core/toolkit/inet/InetUtilsProperties.java +++ b/hippo4j-core/src/main/java/cn/hippo4j/core/toolkit/inet/InetUtilsProperties.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.toolkit.inet; import org.springframework.beans.factory.annotation.Value; diff --git a/hippo4j-discovery/src/main/java/cn/hippo4j/discovery/config/RegistryConfiguration.java b/hippo4j-discovery/src/main/java/cn/hippo4j/discovery/config/RegistryConfiguration.java index 5e86c336..b23f0982 100644 --- a/hippo4j-discovery/src/main/java/cn/hippo4j/discovery/config/RegistryConfiguration.java +++ b/hippo4j-discovery/src/main/java/cn/hippo4j/discovery/config/RegistryConfiguration.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.discovery.config; import cn.hippo4j.discovery.core.BaseInstanceRegistry; diff --git a/hippo4j-discovery/src/main/java/cn/hippo4j/discovery/controller/ApplicationController.java b/hippo4j-discovery/src/main/java/cn/hippo4j/discovery/controller/ApplicationController.java index 1cdd72f3..6ee7c475 100644 --- a/hippo4j-discovery/src/main/java/cn/hippo4j/discovery/controller/ApplicationController.java +++ b/hippo4j-discovery/src/main/java/cn/hippo4j/discovery/controller/ApplicationController.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.discovery.controller; import cn.hippo4j.common.model.InstanceInfo; diff --git a/hippo4j-discovery/src/main/java/cn/hippo4j/discovery/core/BaseInstanceRegistry.java b/hippo4j-discovery/src/main/java/cn/hippo4j/discovery/core/BaseInstanceRegistry.java index 71a61236..97f277b1 100644 --- a/hippo4j-discovery/src/main/java/cn/hippo4j/discovery/core/BaseInstanceRegistry.java +++ b/hippo4j-discovery/src/main/java/cn/hippo4j/discovery/core/BaseInstanceRegistry.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.discovery.core; import cn.hippo4j.common.design.observer.AbstractSubjectCenter; @@ -195,8 +212,7 @@ public class BaseInstanceRegistry implements InstanceRegistry { new ThreadFactoryBuilder() .setNameFormat("registry-eviction") .setDaemon(true) - .build() - ); + .build()); private final AtomicReference evictionTaskRef = new AtomicReference(); diff --git a/hippo4j-discovery/src/main/java/cn/hippo4j/discovery/core/ClientCloseHookRemoveNode.java b/hippo4j-discovery/src/main/java/cn/hippo4j/discovery/core/ClientCloseHookRemoveNode.java index 2278dfc4..c8282bae 100644 --- a/hippo4j-discovery/src/main/java/cn/hippo4j/discovery/core/ClientCloseHookRemoveNode.java +++ b/hippo4j-discovery/src/main/java/cn/hippo4j/discovery/core/ClientCloseHookRemoveNode.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.discovery.core; import cn.hippo4j.common.api.ClientCloseHookExecute; @@ -24,8 +41,7 @@ public class ClientCloseHookRemoveNode implements ClientCloseHookExecute { public void closeHook(ClientCloseHookReq req) { log.info( "Remove Node, Execute client hook function. Req :: {}", - JSONUtil.toJSONString(req) - ); + JSONUtil.toJSONString(req)); try { InstanceInfo instanceInfo = new InstanceInfo(); diff --git a/hippo4j-discovery/src/main/java/cn/hippo4j/discovery/core/InstanceRegistry.java b/hippo4j-discovery/src/main/java/cn/hippo4j/discovery/core/InstanceRegistry.java index dc2f75af..6b56682f 100644 --- a/hippo4j-discovery/src/main/java/cn/hippo4j/discovery/core/InstanceRegistry.java +++ b/hippo4j-discovery/src/main/java/cn/hippo4j/discovery/core/InstanceRegistry.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.discovery.core; import cn.hippo4j.common.model.InstanceInfo; diff --git a/hippo4j-discovery/src/main/java/cn/hippo4j/discovery/core/Lease.java b/hippo4j-discovery/src/main/java/cn/hippo4j/discovery/core/Lease.java index eaf75fbe..a372ea9b 100644 --- a/hippo4j-discovery/src/main/java/cn/hippo4j/discovery/core/Lease.java +++ b/hippo4j-discovery/src/main/java/cn/hippo4j/discovery/core/Lease.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.discovery.core; /** diff --git a/hippo4j-example/hippo4j-core-apollo-spring-boot-starter-example/src/main/java/cn/hippo4j/example/core/apollo/Hippo4jCoreApolloExampleApplication.java b/hippo4j-example/hippo4j-core-apollo-spring-boot-starter-example/src/main/java/cn/hippo4j/example/core/apollo/Hippo4jCoreApolloExampleApplication.java index dc803a2a..45fd972c 100644 --- a/hippo4j-example/hippo4j-core-apollo-spring-boot-starter-example/src/main/java/cn/hippo4j/example/core/apollo/Hippo4jCoreApolloExampleApplication.java +++ b/hippo4j-example/hippo4j-core-apollo-spring-boot-starter-example/src/main/java/cn/hippo4j/example/core/apollo/Hippo4jCoreApolloExampleApplication.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.example.core.apollo; import cn.hippo4j.core.enable.EnableDynamicThreadPool; diff --git a/hippo4j-example/hippo4j-core-apollo-spring-boot-starter-example/src/test/java/cn/hippo4j/example/core/apollo/Hippo4jCoreApolloExampleApplicationTests.java b/hippo4j-example/hippo4j-core-apollo-spring-boot-starter-example/src/test/java/cn/hippo4j/example/core/apollo/Hippo4jCoreApolloExampleApplicationTests.java index 198e3253..e351fa49 100644 --- a/hippo4j-example/hippo4j-core-apollo-spring-boot-starter-example/src/test/java/cn/hippo4j/example/core/apollo/Hippo4jCoreApolloExampleApplicationTests.java +++ b/hippo4j-example/hippo4j-core-apollo-spring-boot-starter-example/src/test/java/cn/hippo4j/example/core/apollo/Hippo4jCoreApolloExampleApplicationTests.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.example.core.apollo; import org.junit.jupiter.api.Test; diff --git a/hippo4j-example/hippo4j-core-nacos-spring-boot-starter-example/src/main/java/cn/hippo4j/example/core/nacos/Hippo4jCoreNacosExampleApplication.java b/hippo4j-example/hippo4j-core-nacos-spring-boot-starter-example/src/main/java/cn/hippo4j/example/core/nacos/Hippo4jCoreNacosExampleApplication.java index e1b92587..d6ca7941 100644 --- a/hippo4j-example/hippo4j-core-nacos-spring-boot-starter-example/src/main/java/cn/hippo4j/example/core/nacos/Hippo4jCoreNacosExampleApplication.java +++ b/hippo4j-example/hippo4j-core-nacos-spring-boot-starter-example/src/main/java/cn/hippo4j/example/core/nacos/Hippo4jCoreNacosExampleApplication.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.example.core.nacos; import cn.hippo4j.core.enable.EnableDynamicThreadPool; diff --git a/hippo4j-example/hippo4j-core-nacos-spring-boot-starter-example/src/test/java/cn/hippo4j/example/core/nacos/Hippo4jCoreNacosExampleApplicationTests.java b/hippo4j-example/hippo4j-core-nacos-spring-boot-starter-example/src/test/java/cn/hippo4j/example/core/nacos/Hippo4jCoreNacosExampleApplicationTests.java index c4ffe606..61fd23d3 100644 --- a/hippo4j-example/hippo4j-core-nacos-spring-boot-starter-example/src/test/java/cn/hippo4j/example/core/nacos/Hippo4jCoreNacosExampleApplicationTests.java +++ b/hippo4j-example/hippo4j-core-nacos-spring-boot-starter-example/src/test/java/cn/hippo4j/example/core/nacos/Hippo4jCoreNacosExampleApplicationTests.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.example.core.nacos; import org.junit.jupiter.api.Test; diff --git a/hippo4j-example/hippo4j-core-zookeeper-spring-boot-starter-example/src/main/java/cn/hippo4j/example/core/zookeeper/Hippo4jCoreZookeeperExampleApplication.java b/hippo4j-example/hippo4j-core-zookeeper-spring-boot-starter-example/src/main/java/cn/hippo4j/example/core/zookeeper/Hippo4jCoreZookeeperExampleApplication.java index a1c7561b..4f843676 100644 --- a/hippo4j-example/hippo4j-core-zookeeper-spring-boot-starter-example/src/main/java/cn/hippo4j/example/core/zookeeper/Hippo4jCoreZookeeperExampleApplication.java +++ b/hippo4j-example/hippo4j-core-zookeeper-spring-boot-starter-example/src/main/java/cn/hippo4j/example/core/zookeeper/Hippo4jCoreZookeeperExampleApplication.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.example.core.zookeeper; import cn.hippo4j.core.enable.EnableDynamicThreadPool; diff --git a/hippo4j-example/hippo4j-example-core/src/main/java/cn/hippo4j/example/core/config/ThreadPoolConfig.java b/hippo4j-example/hippo4j-example-core/src/main/java/cn/hippo4j/example/core/config/ThreadPoolConfig.java index f369f417..5be38c3b 100644 --- a/hippo4j-example/hippo4j-example-core/src/main/java/cn/hippo4j/example/core/config/ThreadPoolConfig.java +++ b/hippo4j-example/hippo4j-example-core/src/main/java/cn/hippo4j/example/core/config/ThreadPoolConfig.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.example.core.config; import cn.hippo4j.core.executor.DynamicThreadPool; diff --git a/hippo4j-example/hippo4j-example-core/src/main/java/cn/hippo4j/example/core/constant/GlobalTestConstant.java b/hippo4j-example/hippo4j-example-core/src/main/java/cn/hippo4j/example/core/constant/GlobalTestConstant.java index de007535..f7137460 100644 --- a/hippo4j-example/hippo4j-example-core/src/main/java/cn/hippo4j/example/core/constant/GlobalTestConstant.java +++ b/hippo4j-example/hippo4j-example-core/src/main/java/cn/hippo4j/example/core/constant/GlobalTestConstant.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.example.core.constant; /** diff --git a/hippo4j-example/hippo4j-example-core/src/main/java/cn/hippo4j/example/core/handler/ErrorLogRejectedExecutionHandler.java b/hippo4j-example/hippo4j-example-core/src/main/java/cn/hippo4j/example/core/handler/ErrorLogRejectedExecutionHandler.java index fc30872b..3b31204d 100644 --- a/hippo4j-example/hippo4j-example-core/src/main/java/cn/hippo4j/example/core/handler/ErrorLogRejectedExecutionHandler.java +++ b/hippo4j-example/hippo4j-example-core/src/main/java/cn/hippo4j/example/core/handler/ErrorLogRejectedExecutionHandler.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.example.core.handler; import cn.hippo4j.core.spi.CustomRejectedExecutionHandler; diff --git a/hippo4j-example/hippo4j-example-core/src/main/java/cn/hippo4j/example/core/handler/TaskTraceBuilderHandler.java b/hippo4j-example/hippo4j-example-core/src/main/java/cn/hippo4j/example/core/handler/TaskTraceBuilderHandler.java index 79050a0c..21b7ac15 100644 --- a/hippo4j-example/hippo4j-example-core/src/main/java/cn/hippo4j/example/core/handler/TaskTraceBuilderHandler.java +++ b/hippo4j-example/hippo4j-example-core/src/main/java/cn/hippo4j/example/core/handler/TaskTraceBuilderHandler.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.example.core.handler; import cn.hippo4j.common.toolkit.StringUtil; diff --git a/hippo4j-example/hippo4j-example-core/src/main/java/cn/hippo4j/example/core/inittest/AlarmSendMessageTest.java b/hippo4j-example/hippo4j-example-core/src/main/java/cn/hippo4j/example/core/inittest/AlarmSendMessageTest.java index 17c11dde..c01f4098 100644 --- a/hippo4j-example/hippo4j-example-core/src/main/java/cn/hippo4j/example/core/inittest/AlarmSendMessageTest.java +++ b/hippo4j-example/hippo4j-example-core/src/main/java/cn/hippo4j/example/core/inittest/AlarmSendMessageTest.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.example.core.inittest; import cn.hippo4j.example.core.constant.GlobalTestConstant; diff --git a/hippo4j-example/hippo4j-example-core/src/main/java/cn/hippo4j/example/core/inittest/RunStateHandlerTest.java b/hippo4j-example/hippo4j-example-core/src/main/java/cn/hippo4j/example/core/inittest/RunStateHandlerTest.java index 973696af..14132171 100644 --- a/hippo4j-example/hippo4j-example-core/src/main/java/cn/hippo4j/example/core/inittest/RunStateHandlerTest.java +++ b/hippo4j-example/hippo4j-example-core/src/main/java/cn/hippo4j/example/core/inittest/RunStateHandlerTest.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.example.core.inittest; import cn.hutool.core.thread.ThreadUtil; diff --git a/hippo4j-example/hippo4j-example-core/src/main/java/cn/hippo4j/example/core/inittest/TaskDecoratorTest.java b/hippo4j-example/hippo4j-example-core/src/main/java/cn/hippo4j/example/core/inittest/TaskDecoratorTest.java index 900a0edc..c8f3a820 100644 --- a/hippo4j-example/hippo4j-example-core/src/main/java/cn/hippo4j/example/core/inittest/TaskDecoratorTest.java +++ b/hippo4j-example/hippo4j-example-core/src/main/java/cn/hippo4j/example/core/inittest/TaskDecoratorTest.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.example.core.inittest; import cn.hippo4j.example.core.constant.GlobalTestConstant; diff --git a/hippo4j-example/hippo4j-spring-boot-starter-example/src/main/java/cn/hippo4j/example/server/Hippo4JServerExampleApplication.java b/hippo4j-example/hippo4j-spring-boot-starter-example/src/main/java/cn/hippo4j/example/server/Hippo4JServerExampleApplication.java index 5f5f22de..7c1b061d 100644 --- a/hippo4j-example/hippo4j-spring-boot-starter-example/src/main/java/cn/hippo4j/example/server/Hippo4JServerExampleApplication.java +++ b/hippo4j-example/hippo4j-spring-boot-starter-example/src/main/java/cn/hippo4j/example/server/Hippo4JServerExampleApplication.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.example.server; import cn.hippo4j.core.enable.EnableDynamicThreadPool; diff --git a/hippo4j-server/src/main/java/cn/hippo4j/server/ServerApplication.java b/hippo4j-server/src/main/java/cn/hippo4j/server/ServerApplication.java index 74f676cd..eae0e15c 100644 --- a/hippo4j-server/src/main/java/cn/hippo4j/server/ServerApplication.java +++ b/hippo4j-server/src/main/java/cn/hippo4j/server/ServerApplication.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.server; import org.mybatis.spring.annotation.MapperScan; diff --git a/hippo4j-server/src/main/java/cn/hippo4j/server/listener/BaseSpringApplicationRunListener.java b/hippo4j-server/src/main/java/cn/hippo4j/server/listener/BaseSpringApplicationRunListener.java index be143e31..08b8610d 100644 --- a/hippo4j-server/src/main/java/cn/hippo4j/server/listener/BaseSpringApplicationRunListener.java +++ b/hippo4j-server/src/main/java/cn/hippo4j/server/listener/BaseSpringApplicationRunListener.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.server.listener; import org.springframework.boot.SpringApplication; diff --git a/hippo4j-server/src/main/java/cn/hippo4j/server/listener/Hippo4JApplicationListener.java b/hippo4j-server/src/main/java/cn/hippo4j/server/listener/Hippo4JApplicationListener.java index 232cb809..1847ad1d 100644 --- a/hippo4j-server/src/main/java/cn/hippo4j/server/listener/Hippo4JApplicationListener.java +++ b/hippo4j-server/src/main/java/cn/hippo4j/server/listener/Hippo4JApplicationListener.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.server.listener; import org.springframework.context.ConfigurableApplicationContext; diff --git a/hippo4j-server/src/main/java/cn/hippo4j/server/listener/StartingApplicationListener.java b/hippo4j-server/src/main/java/cn/hippo4j/server/listener/StartingApplicationListener.java index 102935df..6d68e6bb 100644 --- a/hippo4j-server/src/main/java/cn/hippo4j/server/listener/StartingApplicationListener.java +++ b/hippo4j-server/src/main/java/cn/hippo4j/server/listener/StartingApplicationListener.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.server.listener; import cn.hippo4j.config.toolkit.EnvUtil; @@ -36,8 +53,7 @@ public class StartingApplicationListener implements Hippo4JApplicationListener { Thread thread = new Thread(r); thread.setName("server.hippo4j-starting"); return thread; - } - ); + }); scheduledExecutorService.scheduleWithFixedDelay(() -> { if (starting) { diff --git a/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/common/ConfigFileTypeEnum.java b/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/common/ConfigFileTypeEnum.java index 8d228651..915ce04d 100644 --- a/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/common/ConfigFileTypeEnum.java +++ b/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/common/ConfigFileTypeEnum.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.starter.common; /** diff --git a/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/config/BootstrapCoreProperties.java b/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/config/BootstrapCoreProperties.java index 972cefd4..cca0aec5 100644 --- a/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/config/BootstrapCoreProperties.java +++ b/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/config/BootstrapCoreProperties.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.starter.config; import cn.hippo4j.core.config.BootstrapPropertiesInterface; diff --git a/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/config/DynamicThreadPoolCoreAutoConfiguration.java b/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/config/DynamicThreadPoolCoreAutoConfiguration.java index 553c1ed2..1ac2976c 100644 --- a/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/config/DynamicThreadPoolCoreAutoConfiguration.java +++ b/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/config/DynamicThreadPoolCoreAutoConfiguration.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.starter.config; import cn.hippo4j.common.api.NotifyConfigBuilder; diff --git a/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/config/ExecutorProperties.java b/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/config/ExecutorProperties.java index 5704ca1a..003b5a92 100644 --- a/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/config/ExecutorProperties.java +++ b/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/config/ExecutorProperties.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.starter.config; import cn.hippo4j.common.notify.ThreadPoolNotifyAlarm; diff --git a/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/config/NotifyPlatformProperties.java b/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/config/NotifyPlatformProperties.java index 06976848..7cdd2084 100644 --- a/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/config/NotifyPlatformProperties.java +++ b/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/config/NotifyPlatformProperties.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.starter.config; import lombok.Data; diff --git a/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/config/WebThreadPoolProperties.java b/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/config/WebThreadPoolProperties.java index 8794863c..4f2c17d1 100644 --- a/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/config/WebThreadPoolProperties.java +++ b/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/config/WebThreadPoolProperties.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.starter.config; import lombok.Data; diff --git a/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/monitor/AbstractDynamicThreadPoolMonitor.java b/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/monitor/AbstractDynamicThreadPoolMonitor.java index 2c7e2680..36ae954c 100644 --- a/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/monitor/AbstractDynamicThreadPoolMonitor.java +++ b/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/monitor/AbstractDynamicThreadPoolMonitor.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.starter.monitor; import cn.hippo4j.common.model.PoolRunStateInfo; diff --git a/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/monitor/DynamicThreadPoolMonitor.java b/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/monitor/DynamicThreadPoolMonitor.java index f97a0fc1..2b0321c4 100644 --- a/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/monitor/DynamicThreadPoolMonitor.java +++ b/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/monitor/DynamicThreadPoolMonitor.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.starter.monitor; /** diff --git a/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/monitor/DynamicThreadPoolMonitorExecutor.java b/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/monitor/DynamicThreadPoolMonitorExecutor.java index da5f5c20..4000c226 100644 --- a/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/monitor/DynamicThreadPoolMonitorExecutor.java +++ b/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/monitor/DynamicThreadPoolMonitorExecutor.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.starter.monitor; import cn.hippo4j.common.config.ApplicationContextHolder; @@ -46,8 +63,7 @@ public class DynamicThreadPoolMonitorExecutor implements ApplicationRunner { String collectTaskName = "client.scheduled.collect.data"; collectExecutor = new ScheduledThreadPoolExecutor( new Integer(1), - ThreadFactoryBuilder.builder().daemon(true).prefix(collectTaskName).build() - ); + ThreadFactoryBuilder.builder().daemon(true).prefix(collectTaskName).build()); // Get dynamic thread pool monitoring component. List collectTypes = Arrays.asList(collectType.split(",")); @@ -66,8 +82,7 @@ public class DynamicThreadPoolMonitorExecutor implements ApplicationRunner { () -> scheduleRunnable(), properties.getInitialDelay(), properties.getCollectInterval(), - TimeUnit.MILLISECONDS - ); + TimeUnit.MILLISECONDS); } private void scheduleRunnable() { diff --git a/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/monitor/LogMonitorHandler.java b/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/monitor/LogMonitorHandler.java index 74101241..627c105c 100644 --- a/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/monitor/LogMonitorHandler.java +++ b/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/monitor/LogMonitorHandler.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.starter.monitor; import cn.hippo4j.common.model.PoolRunStateInfo; diff --git a/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/monitor/MetricMonitorHandler.java b/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/monitor/MetricMonitorHandler.java index 5c72592b..d67915c4 100644 --- a/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/monitor/MetricMonitorHandler.java +++ b/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/monitor/MetricMonitorHandler.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.starter.monitor; import cn.hippo4j.common.config.ApplicationContextHolder; @@ -45,8 +62,7 @@ public class MetricMonitorHandler extends AbstractDynamicThreadPoolMonitor { String applicationName = environment.getProperty("spring.application.name", "application"); Iterable tags = Lists.newArrayList( Tag.of(DYNAMIC_THREAD_POOL_ID_TAG, poolRunStateInfo.getTpId()), - Tag.of(APPLICATION_NAME_TAG, applicationName) - ); + Tag.of(APPLICATION_NAME_TAG, applicationName)); // load Metrics.gauge(metricName("current.load"), tags, poolRunStateInfo, PoolRunStateInfo::getSimpleCurrentLoad); diff --git a/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/monitor/ThreadPoolMonitor.java b/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/monitor/ThreadPoolMonitor.java index 0bc00ddb..ec30b283 100644 --- a/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/monitor/ThreadPoolMonitor.java +++ b/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/monitor/ThreadPoolMonitor.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.starter.monitor; /** diff --git a/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/notify/CoreNotifyConfigBuilder.java b/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/notify/CoreNotifyConfigBuilder.java index 65b528bd..302d9e77 100644 --- a/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/notify/CoreNotifyConfigBuilder.java +++ b/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/notify/CoreNotifyConfigBuilder.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.starter.notify; import cn.hippo4j.common.api.NotifyConfigBuilder; @@ -90,8 +107,7 @@ public class CoreNotifyConfigBuilder implements NotifyConfigBuilder { resultMap.forEach( (key, val) -> val.stream() .filter(each -> StrUtil.equals("ALARM", each.getType())) - .forEach(each -> alarmControlHandler.initCacheAndLock(each.getTpId(), each.getPlatform(), each.getInterval())) - ); + .forEach(each -> alarmControlHandler.initCacheAndLock(each.getTpId(), each.getPlatform(), each.getInterval()))); return resultMap; } diff --git a/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/parser/AbstractConfigParser.java b/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/parser/AbstractConfigParser.java index cc59920c..1b4f6f7b 100644 --- a/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/parser/AbstractConfigParser.java +++ b/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/parser/AbstractConfigParser.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.starter.parser; /** diff --git a/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/parser/ConfigFileTypeEnum.java b/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/parser/ConfigFileTypeEnum.java index a6249430..1cef19f3 100644 --- a/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/parser/ConfigFileTypeEnum.java +++ b/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/parser/ConfigFileTypeEnum.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.starter.parser; import lombok.Getter; diff --git a/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/parser/ConfigParser.java b/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/parser/ConfigParser.java index eb4e0a8f..6aaff703 100644 --- a/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/parser/ConfigParser.java +++ b/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/parser/ConfigParser.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.starter.parser; import java.io.IOException; diff --git a/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/parser/ConfigParserHandler.java b/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/parser/ConfigParserHandler.java index b349f556..f0f2cefa 100644 --- a/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/parser/ConfigParserHandler.java +++ b/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/parser/ConfigParserHandler.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.starter.parser; import com.google.common.collect.Lists; diff --git a/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/parser/PropertiesConfigParser.java b/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/parser/PropertiesConfigParser.java index aed1b724..b76678ce 100644 --- a/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/parser/PropertiesConfigParser.java +++ b/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/parser/PropertiesConfigParser.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.starter.parser; import com.google.common.collect.Lists; diff --git a/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/parser/YamlConfigParser.java b/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/parser/YamlConfigParser.java index 5ae8f54b..d1d57daf 100644 --- a/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/parser/YamlConfigParser.java +++ b/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/parser/YamlConfigParser.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.starter.parser; import com.google.common.collect.Lists; diff --git a/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/refresher/AbstractCoreThreadPoolDynamicRefresh.java b/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/refresher/AbstractCoreThreadPoolDynamicRefresh.java index ade2c2d9..06d5fff5 100644 --- a/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/refresher/AbstractCoreThreadPoolDynamicRefresh.java +++ b/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/refresher/AbstractCoreThreadPoolDynamicRefresh.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.starter.refresher; import cn.hippo4j.common.api.ThreadPoolDynamicRefresh; @@ -84,8 +101,7 @@ public abstract class AbstractCoreThreadPoolDynamicRefresh implements ThreadPool ThreadPoolNotifyAlarm threadPoolNotifyAlarm = new ThreadPoolNotifyAlarm( executorProperties.getNotify().getIsAlarm(), executorProperties.getNotify().getCapacityAlarm(), - executorProperties.getNotify().getActiveAlarm() - ); + executorProperties.getNotify().getActiveAlarm()); threadPoolNotifyAlarm.setInterval(executorProperties.getNotify().getInterval()); threadPoolNotifyAlarm.setReceives(executorProperties.receives()); GlobalNotifyAlarmManage.put(executorProperties.getThreadPoolId(), threadPoolNotifyAlarm); @@ -178,8 +194,7 @@ public abstract class AbstractCoreThreadPoolDynamicRefresh implements ThreadPool String.format("%s => %s", beforeProperties.getKeepAliveTime(), properties.getKeepAliveTime()), String.format("%s => %s", beforeProperties.getExecuteTimeOut(), properties.getExecuteTimeOut()), String.format("%s => %s", beforeProperties.getRejectedHandler(), properties.getRejectedHandler()), - String.format("%s => %s", beforeProperties.getAllowCoreThreadTimeOut(), properties.getAllowCoreThreadTimeOut()) - ); + String.format("%s => %s", beforeProperties.getAllowCoreThreadTimeOut(), properties.getAllowCoreThreadTimeOut())); try { threadPoolNotifyAlarmHandler.sendPoolConfigChange(newChangeRequest(beforeProperties, properties)); @@ -234,10 +249,8 @@ public abstract class AbstractCoreThreadPoolDynamicRefresh implements ThreadPool || !Objects.equals(beforeProperties.getKeepAliveTime(), properties.getKeepAliveTime()) || !Objects.equals(beforeProperties.getRejectedHandler(), properties.getRejectedHandler()) || - ( - !Objects.equals(beforeProperties.getQueueCapacity(), properties.getQueueCapacity()) - && Objects.equals(QueueTypeEnum.RESIZABLE_LINKED_BLOCKING_QUEUE.name, executor.getQueue().getClass().getSimpleName()) - ); + (!Objects.equals(beforeProperties.getQueueCapacity(), properties.getQueueCapacity()) + && Objects.equals(QueueTypeEnum.RESIZABLE_LINKED_BLOCKING_QUEUE.name, executor.getQueue().getClass().getSimpleName())); return result; } diff --git a/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/refresher/ApolloRefresherHandler.java b/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/refresher/ApolloRefresherHandler.java index 258d95a2..167ad7d6 100644 --- a/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/refresher/ApolloRefresherHandler.java +++ b/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/refresher/ApolloRefresherHandler.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.starter.refresher; import cn.hippo4j.core.executor.ThreadPoolNotifyAlarmHandler; @@ -36,8 +53,7 @@ public class ApolloRefresherHandler extends AbstractCoreThreadPoolDynamicRefresh ConfigChangeListener configChangeListener = configChangeEvent -> { ConfigFile configFile = ConfigService.getConfigFile( this.namespace.replaceAll("." + bootstrapCoreProperties.getConfigFileType().getValue(), ""), - ConfigFileFormat.fromString(bootstrapCoreProperties.getConfigFileType().getValue()) - ); + ConfigFileFormat.fromString(bootstrapCoreProperties.getConfigFileType().getValue())); String configInfo = configFile.getContent(); dynamicRefresh(configInfo); diff --git a/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/refresher/BootstrapCorePropertiesBinderAdapt.java b/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/refresher/BootstrapCorePropertiesBinderAdapt.java index dfdfc98d..2b38723d 100644 --- a/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/refresher/BootstrapCorePropertiesBinderAdapt.java +++ b/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/refresher/BootstrapCorePropertiesBinderAdapt.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.starter.refresher; import cn.hippo4j.common.notify.NotifyPlatformEnum; @@ -68,11 +85,9 @@ public class BootstrapCorePropertiesBinderAdapt { configInfo.forEach((key, val) -> { boolean containFlag = key != null && StringUtil.isNotBlank((String) key) - && ( - ((String) key).indexOf(PREFIX + ".executors") != -1 + && (((String) key).indexOf(PREFIX + ".executors") != -1 || ((String) key).indexOf(PREFIX + ".notify-platforms") != -1 - || ((String) key).indexOf(PREFIX + ".notifyPlatforms") != -1 - ); + || ((String) key).indexOf(PREFIX + ".notifyPlatforms") != -1); if (containFlag) { String targetKey = key.toString().replace(PREFIX + ".", ""); targetMap.put(targetKey, val); @@ -109,7 +124,6 @@ public class BootstrapCorePropertiesBinderAdapt { } } - if (key.indexOf("notify-platforms[" + i + "].") != -1 || key.indexOf("notifyPlatforms[" + i + "].") != -1) { if (key.indexOf("notify-platforms[" + i + "].") != -1) { key = key.replace("notify-platforms[" + i + "].", ""); diff --git a/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/refresher/NacosCloudRefresherHandler.java b/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/refresher/NacosCloudRefresherHandler.java index 1a3fd991..6f4314df 100644 --- a/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/refresher/NacosCloudRefresherHandler.java +++ b/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/refresher/NacosCloudRefresherHandler.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.starter.refresher; import cn.hippo4j.common.config.ApplicationContextHolder; diff --git a/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/refresher/NacosRefresherHandler.java b/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/refresher/NacosRefresherHandler.java index 62e8007f..7f46c31f 100644 --- a/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/refresher/NacosRefresherHandler.java +++ b/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/refresher/NacosRefresherHandler.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.starter.refresher; import cn.hippo4j.common.config.ApplicationContextHolder; @@ -42,8 +59,7 @@ public class NacosRefresherHandler extends AbstractCoreThreadPoolDynamicRefresh public void receiveConfigInfo(String configInfo) { dynamicRefresh(configInfo); } - } - ); + }); } } diff --git a/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/refresher/ZookeeperRefresherHandler.java b/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/refresher/ZookeeperRefresherHandler.java index 5653c128..6f8feb08 100644 --- a/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/refresher/ZookeeperRefresherHandler.java +++ b/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/refresher/ZookeeperRefresherHandler.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.starter.refresher; import cn.hippo4j.core.executor.ThreadPoolNotifyAlarmHandler; diff --git a/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/support/DynamicThreadPoolPostProcessor.java b/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/support/DynamicThreadPoolPostProcessor.java index c8409e5a..3272a38d 100644 --- a/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/support/DynamicThreadPoolPostProcessor.java +++ b/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/support/DynamicThreadPoolPostProcessor.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.starter.support; import cn.hippo4j.common.config.ApplicationContextHolder; @@ -161,8 +178,7 @@ public final class DynamicThreadPoolPostProcessor implements BeanPostProcessor { threadPoolId, executorProperties == null ? buildExecutorProperties(threadPoolId, newDynamicPoolExecutor) - : executorProperties - ); + : executorProperties); return newDynamicPoolExecutor; } diff --git a/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/support/GlobalCoreThreadPoolManage.java b/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/support/GlobalCoreThreadPoolManage.java index e388485c..1e694fc4 100644 --- a/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/support/GlobalCoreThreadPoolManage.java +++ b/hippo4j-spring-boot/hippo4j-core-spring-boot-starter/src/main/java/cn/hippo4j/core/starter/support/GlobalCoreThreadPoolManage.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.core.starter.support; import cn.hippo4j.core.starter.config.ExecutorProperties; diff --git a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/config/BootstrapProperties.java b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/config/BootstrapProperties.java index bd5b5c09..4bff3fef 100644 --- a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/config/BootstrapProperties.java +++ b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/config/BootstrapProperties.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.starter.config; import cn.hippo4j.core.config.BootstrapPropertiesInterface; diff --git a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/config/DiscoveryConfiguration.java b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/config/DiscoveryConfiguration.java index b6ce9505..4ca92810 100644 --- a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/config/DiscoveryConfiguration.java +++ b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/config/DiscoveryConfiguration.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.starter.config; import cn.hippo4j.common.model.InstanceInfo; diff --git a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/config/DynamicThreadPoolAutoConfiguration.java b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/config/DynamicThreadPoolAutoConfiguration.java index e0581d2e..a5ae6da5 100644 --- a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/config/DynamicThreadPoolAutoConfiguration.java +++ b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/config/DynamicThreadPoolAutoConfiguration.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.starter.config; import cn.hippo4j.common.api.ThreadDetailState; @@ -129,5 +146,3 @@ public class DynamicThreadPoolAutoConfiguration { } } - - diff --git a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/config/HttpClientConfiguration.java b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/config/HttpClientConfiguration.java index f48635b8..8c563700 100644 --- a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/config/HttpClientConfiguration.java +++ b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/config/HttpClientConfiguration.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.starter.config; import cn.hippo4j.starter.remote.HttpAgent; diff --git a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/config/MessageNotifyConfiguration.java b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/config/MessageNotifyConfiguration.java index 93940f9f..7be2cc6b 100644 --- a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/config/MessageNotifyConfiguration.java +++ b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/config/MessageNotifyConfiguration.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.starter.config; import cn.hippo4j.common.api.NotifyConfigBuilder; diff --git a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/controller/PoolRunStateController.java b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/controller/PoolRunStateController.java index 41249864..b210a9f8 100644 --- a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/controller/PoolRunStateController.java +++ b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/controller/PoolRunStateController.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.starter.controller; import cn.hippo4j.common.api.ThreadDetailState; diff --git a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/controller/WebThreadPoolController.java b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/controller/WebThreadPoolController.java index b8fdd27d..f356ebfe 100644 --- a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/controller/WebThreadPoolController.java +++ b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/controller/WebThreadPoolController.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.starter.controller; import cn.hippo4j.common.model.PoolBaseInfo; diff --git a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/core/BaseThreadDetailStateHandler.java b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/core/BaseThreadDetailStateHandler.java index 8d928c4a..17b06aa5 100644 --- a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/core/BaseThreadDetailStateHandler.java +++ b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/core/BaseThreadDetailStateHandler.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.starter.core; import cn.hippo4j.common.api.ThreadDetailState; diff --git a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/core/CacheData.java b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/core/CacheData.java index 3ec96337..df8b1391 100644 --- a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/core/CacheData.java +++ b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/core/CacheData.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.starter.core; import cn.hippo4j.core.executor.manage.GlobalThreadPoolManage; diff --git a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/core/ClientWorker.java b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/core/ClientWorker.java index 70f8016a..6278d9b3 100644 --- a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/core/ClientWorker.java +++ b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/core/ClientWorker.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.starter.core; import cn.hippo4j.common.model.PoolParameterInfo; @@ -61,8 +78,7 @@ public class ClientWorker { }); this.executorService = Executors.newSingleThreadScheduledExecutor( - ThreadFactoryBuilder.builder().prefix("client.long.polling.executor").daemon(true).build() - ); + ThreadFactoryBuilder.builder().prefix("client.long.polling.executor").daemon(true).build()); log.info("Client identity :: {}", identification); @@ -214,7 +230,6 @@ public class ClientWorker { log.error("Polling resp decode modifiedDataIdsString error.", e); } - List updateList = new LinkedList(); for (String dataIdAndGroup : response.split(LINE_SEPARATOR)) { if (!StringUtils.isEmpty(dataIdAndGroup)) { diff --git a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/core/ConfigEmptyAnalyzer.java b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/core/ConfigEmptyAnalyzer.java index 55b9c47b..5fcfecbc 100644 --- a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/core/ConfigEmptyAnalyzer.java +++ b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/core/ConfigEmptyAnalyzer.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.starter.core; import cn.hippo4j.core.config.ConfigEmptyException; diff --git a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/core/ConfigService.java b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/core/ConfigService.java index b1bc1d07..1907263b 100644 --- a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/core/ConfigService.java +++ b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/core/ConfigService.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.starter.core; /** diff --git a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/core/DiscoveryClient.java b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/core/DiscoveryClient.java index ed8e965f..0cce70ca 100644 --- a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/core/DiscoveryClient.java +++ b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/core/DiscoveryClient.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.starter.core; import cn.hippo4j.common.api.ClientCloseHookExecute; @@ -47,8 +64,7 @@ public class DiscoveryClient implements DisposableBean { this.scheduler = new ScheduledThreadPoolExecutor( new Integer(1), - ThreadFactoryBuilder.builder().daemon(true).prefix("client.discovery.scheduler").build() - ); + ThreadFactoryBuilder.builder().daemon(true).prefix("client.discovery.scheduler").build()); register(); diff --git a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/core/DynamicThreadPoolPostProcessor.java b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/core/DynamicThreadPoolPostProcessor.java index 62a71f16..587265ed 100644 --- a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/core/DynamicThreadPoolPostProcessor.java +++ b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/core/DynamicThreadPoolPostProcessor.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.starter.core; import cn.hippo4j.common.config.ApplicationContextHolder; @@ -151,8 +168,7 @@ public final class DynamicThreadPoolPostProcessor implements BeanPostProcessor { ThreadPoolNotifyAlarm threadPoolNotifyAlarm = new ThreadPoolNotifyAlarm( BooleanUtil.toBoolean(ppi.getIsAlarm().toString()), ppi.getCapacityAlarm(), - ppi.getLivenessAlarm() - ); + ppi.getLivenessAlarm()); GlobalNotifyAlarmManage.put(tpId, threadPoolNotifyAlarm); TaskDecorator taskDecorator = ((DynamicThreadPoolExecutor) dynamicThreadPoolWrap.getExecutor()).getTaskDecorator(); @@ -169,7 +185,6 @@ public final class DynamicThreadPoolPostProcessor implements BeanPostProcessor { dynamicThreadPoolWrap.setExecutor(newDynamicPoolExecutor); isSubscribe = true; - } } } catch (Exception ex) { diff --git a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/core/Listener.java b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/core/Listener.java index 043703b2..de616281 100644 --- a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/core/Listener.java +++ b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/core/Listener.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.starter.core; import java.util.concurrent.Executor; diff --git a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/core/ServerThreadPoolDynamicRefresh.java b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/core/ServerThreadPoolDynamicRefresh.java index dcd967bd..38792de9 100644 --- a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/core/ServerThreadPoolDynamicRefresh.java +++ b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/core/ServerThreadPoolDynamicRefresh.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.starter.core; import cn.hippo4j.common.enums.EnableEnum; @@ -112,8 +129,7 @@ public class ServerThreadPoolDynamicRefresh implements ThreadPoolDynamicRefresh String.format("%s => %s", originalKeepAliveTime, afterExecutor.getKeepAliveTime(TimeUnit.SECONDS)), String.format("%s => %s", originalExecuteTimeOut, originalExecuteTimeOut), String.format("%s => %s", originalRejected, RejectedTypeEnum.getRejectedNameByType(parameter.getRejectedType())), - String.format("%s => %s", originalAllowCoreThreadTimeOut, EnableEnum.getBool(parameter.getAllowCoreThreadTimeOut())) - ); + String.format("%s => %s", originalAllowCoreThreadTimeOut, EnableEnum.getBool(parameter.getAllowCoreThreadTimeOut()))); } /** diff --git a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/core/ShutdownExecuteException.java b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/core/ShutdownExecuteException.java index bbe7232a..233a7a82 100644 --- a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/core/ShutdownExecuteException.java +++ b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/core/ShutdownExecuteException.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.starter.core; /** diff --git a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/core/ThreadPoolConfigService.java b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/core/ThreadPoolConfigService.java index 82d07f63..5e765958 100644 --- a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/core/ThreadPoolConfigService.java +++ b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/core/ThreadPoolConfigService.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.starter.core; import cn.hippo4j.starter.event.ApplicationCompleteEvent; diff --git a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/core/ThreadPoolOperation.java b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/core/ThreadPoolOperation.java index c6f771d5..273a8711 100644 --- a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/core/ThreadPoolOperation.java +++ b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/core/ThreadPoolOperation.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.starter.core; import cn.hippo4j.starter.config.BootstrapProperties; diff --git a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/core/ThreadPoolSubscribeCallback.java b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/core/ThreadPoolSubscribeCallback.java index d6b08e4c..851d3b0f 100644 --- a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/core/ThreadPoolSubscribeCallback.java +++ b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/core/ThreadPoolSubscribeCallback.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.starter.core; /** diff --git a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/event/ApplicationCompleteEvent.java b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/event/ApplicationCompleteEvent.java index d3ae2b65..4ce0c121 100644 --- a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/event/ApplicationCompleteEvent.java +++ b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/event/ApplicationCompleteEvent.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.starter.event; import org.springframework.context.ApplicationEvent; diff --git a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/event/ApplicationContentPostProcessor.java b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/event/ApplicationContentPostProcessor.java index f766e45e..2265be21 100644 --- a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/event/ApplicationContentPostProcessor.java +++ b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/event/ApplicationContentPostProcessor.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.starter.event; import org.springframework.boot.context.event.ApplicationReadyEvent; diff --git a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/event/MonitorEventExecutor.java b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/event/MonitorEventExecutor.java index 2648cec4..4f809d31 100644 --- a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/event/MonitorEventExecutor.java +++ b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/event/MonitorEventExecutor.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.starter.event; import cn.hippo4j.common.function.NoArgsConsumer; diff --git a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/monitor/ReportingEventExecutor.java b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/monitor/ReportingEventExecutor.java index cb2e4564..5f679c45 100644 --- a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/monitor/ReportingEventExecutor.java +++ b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/monitor/ReportingEventExecutor.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.starter.monitor; import cn.hippo4j.common.config.ApplicationContextHolder; @@ -83,16 +100,14 @@ public class ReportingEventExecutor implements Runnable, CommandLineRunner, Disp String collectVesselTaskName = "client.scheduled.collect.data"; collectVesselExecutor = new ScheduledThreadPoolExecutor( new Integer(1), - ThreadFactoryBuilder.builder().daemon(true).prefix(collectVesselTaskName).build() - ); + ThreadFactoryBuilder.builder().daemon(true).prefix(collectVesselTaskName).build()); // 延迟 initialDelay 后循环调用. scheduleWithFixedDelay 每次执行时间为上一次任务结束时, 向后推一个时间间隔 collectVesselExecutor.scheduleWithFixedDelay( () -> runTimeGatherTask(), properties.getInitialDelay(), properties.getCollectInterval(), - TimeUnit.MILLISECONDS - ); + TimeUnit.MILLISECONDS); // 启动上报监控数据线程 String reportingTaskName = "client.thread.reporting.task"; diff --git a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/monitor/collect/Collector.java b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/monitor/collect/Collector.java index eba657e0..991100f8 100644 --- a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/monitor/collect/Collector.java +++ b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/monitor/collect/Collector.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.starter.monitor.collect; import cn.hippo4j.common.monitor.Message; diff --git a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/monitor/collect/RunTimeInfoCollector.java b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/monitor/collect/RunTimeInfoCollector.java index 9562e64b..1096df8b 100644 --- a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/monitor/collect/RunTimeInfoCollector.java +++ b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/monitor/collect/RunTimeInfoCollector.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.starter.monitor.collect; import cn.hippo4j.common.model.PoolRunStateInfo; diff --git a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/monitor/send/HttpConnectSender.java b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/monitor/send/HttpConnectSender.java index a2a5064e..9568af4f 100644 --- a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/monitor/send/HttpConnectSender.java +++ b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/monitor/send/HttpConnectSender.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.starter.monitor.send; import cn.hippo4j.common.monitor.Message; diff --git a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/monitor/send/MessageSender.java b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/monitor/send/MessageSender.java index 03cce85d..65afb2fe 100644 --- a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/monitor/send/MessageSender.java +++ b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/monitor/send/MessageSender.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.starter.monitor.send; import cn.hippo4j.common.monitor.Message; diff --git a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/notify/ServerNotifyConfigBuilder.java b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/notify/ServerNotifyConfigBuilder.java index aa89727d..3090ed73 100644 --- a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/notify/ServerNotifyConfigBuilder.java +++ b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/notify/ServerNotifyConfigBuilder.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.starter.notify; import cn.hippo4j.common.notify.AlarmControlHandler; @@ -66,10 +83,8 @@ public class ServerNotifyConfigBuilder implements NotifyConfigBuilder { List resultData = JSONUtil.parseArray(resultDataStr, ThreadPoolNotifyDTO.class); resultData.forEach(each -> resultMap.put(each.getNotifyKey(), each.getNotifyList())); - resultMap.forEach((key, val) -> - val.stream().filter(each -> StrUtil.equals("ALARM", each.getType())) - .forEach(each -> alarmControlHandler.initCacheAndLock(each.getTpId(), each.getPlatform(), each.getInterval())) - ); + resultMap.forEach((key, val) -> val.stream().filter(each -> StrUtil.equals("ALARM", each.getType())) + .forEach(each -> alarmControlHandler.initCacheAndLock(each.getTpId(), each.getPlatform(), each.getInterval()))); } return resultMap; diff --git a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/remote/AbstractHealthCheck.java b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/remote/AbstractHealthCheck.java index e218dd72..61c61586 100644 --- a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/remote/AbstractHealthCheck.java +++ b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/remote/AbstractHealthCheck.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.starter.remote; import cn.hippo4j.starter.core.ShutdownExecuteException; @@ -55,8 +72,7 @@ public abstract class AbstractHealthCheck implements ServerHealthCheck, Initiali */ private final ScheduledThreadPoolExecutor healthCheckExecutor = new ScheduledThreadPoolExecutor( new Integer(1), - ThreadFactoryBuilder.builder().daemon(true).prefix("client.scheduled.health.check").build() - ); + ThreadFactoryBuilder.builder().daemon(true).prefix("client.scheduled.health.check").build()); /** * Send health check. diff --git a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/remote/HttpAgent.java b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/remote/HttpAgent.java index 11c9156f..19f0ccca 100644 --- a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/remote/HttpAgent.java +++ b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/remote/HttpAgent.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.starter.remote; import cn.hippo4j.common.web.base.Result; diff --git a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/remote/HttpScheduledHealthCheck.java b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/remote/HttpScheduledHealthCheck.java index 0d59b3d4..e8933bc3 100644 --- a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/remote/HttpScheduledHealthCheck.java +++ b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/remote/HttpScheduledHealthCheck.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.starter.remote; import cn.hippo4j.common.web.base.Result; diff --git a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/remote/ServerHealthCheck.java b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/remote/ServerHealthCheck.java index d6be233d..f87e47bf 100644 --- a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/remote/ServerHealthCheck.java +++ b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/remote/ServerHealthCheck.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.starter.remote; /** diff --git a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/remote/ServerHttpAgent.java b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/remote/ServerHttpAgent.java index fa83be85..6cffc3c1 100644 --- a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/remote/ServerHttpAgent.java +++ b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/remote/ServerHttpAgent.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.starter.remote; import cn.hippo4j.common.config.ApplicationContextHolder; @@ -46,15 +63,13 @@ public class ServerHttpAgent implements HttpAgent { this.securityProxy.applyToken(this.serverListManager.getServerUrls()); this.executorService = new ScheduledThreadPoolExecutor( new Integer(1), - ThreadFactoryBuilder.builder().daemon(true).prefix("client.scheduled.token.security.updater").build() - ); + ThreadFactoryBuilder.builder().daemon(true).prefix("client.scheduled.token.security.updater").build()); this.executorService.scheduleWithFixedDelay( () -> securityProxy.applyToken(serverListManager.getServerUrls()), 0, securityInfoRefreshIntervalMills, - TimeUnit.MILLISECONDS - ); + TimeUnit.MILLISECONDS); } @Override diff --git a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/remote/ServerListManager.java b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/remote/ServerListManager.java index 60f8edb4..3fb8bd97 100644 --- a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/remote/ServerListManager.java +++ b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/remote/ServerListManager.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.starter.remote; import cn.hippo4j.starter.config.BootstrapProperties; @@ -106,7 +123,7 @@ public class ServerListManager { try { this.serverIp = ip; /* - change random scope from 32 to Integer.MAX_VALUE to fix load balance issue + * change random scope from 32 to Integer.MAX_VALUE to fix load balance issue */ this.seed = random.nextInt(Integer.MAX_VALUE); } catch (Exception e) { diff --git a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/security/SecurityProxy.java b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/security/SecurityProxy.java index f0ec7fef..d8bd7c0e 100644 --- a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/security/SecurityProxy.java +++ b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/security/SecurityProxy.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.starter.security; import cn.hippo4j.common.constant.Constants; diff --git a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/toolkit/CloudCommonIdUtil.java b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/toolkit/CloudCommonIdUtil.java index bbe1f515..d6a7dfff 100644 --- a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/toolkit/CloudCommonIdUtil.java +++ b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/toolkit/CloudCommonIdUtil.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.starter.toolkit; import cn.hippo4j.core.toolkit.inet.InetUtils; diff --git a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/toolkit/HttpClientUtil.java b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/toolkit/HttpClientUtil.java index f156a6a7..ad11ee21 100644 --- a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/toolkit/HttpClientUtil.java +++ b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/toolkit/HttpClientUtil.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.starter.toolkit; import cn.hippo4j.common.toolkit.JSONUtil; diff --git a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/wrapper/ManagerListenerWrapper.java b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/wrapper/ManagerListenerWrapper.java index 6ec9b9d8..3d2c8739 100644 --- a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/wrapper/ManagerListenerWrapper.java +++ b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/main/java/cn/hippo4j/starter/wrapper/ManagerListenerWrapper.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.starter.wrapper; import cn.hippo4j.starter.core.Listener; diff --git a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/test/java/cn/hippo4j/starter/test/MonitorPerformanceTest.java b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/test/java/cn/hippo4j/starter/test/MonitorPerformanceTest.java index a4b18134..4a066bdc 100644 --- a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/test/java/cn/hippo4j/starter/test/MonitorPerformanceTest.java +++ b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/test/java/cn/hippo4j/starter/test/MonitorPerformanceTest.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.starter.test; import cn.hippo4j.common.model.PoolRunStateInfo; @@ -48,8 +65,7 @@ public class MonitorPerformanceTest { private static final ScheduledThreadPoolExecutor COLLECT_VESSEL_EXECUTOR = new ScheduledThreadPoolExecutor( new Integer(1), - ThreadFactoryBuilder.builder().daemon(true).prefix("client.scheduled.collect.dat").build() - ); + ThreadFactoryBuilder.builder().daemon(true).prefix("client.scheduled.collect.dat").build()); static { DynamicThreadPoolWrapper wrapper = new DynamicThreadPoolWrapper(TEST_FLAG, DYNAMIC_EXECUTOR); @@ -71,8 +87,7 @@ public class MonitorPerformanceTest { }, 1000, 1000, - TimeUnit.MILLISECONDS - ); + TimeUnit.MILLISECONDS); log.info("测试带有监控线程池, 执行时长 :: {}", testExecutorTime(MONITOR_DYNAMIC_EXECUTOR)); diff --git a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/test/java/cn/hippo4j/starter/test/RejectedExecutionHandlerProxyTest.java b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/test/java/cn/hippo4j/starter/test/RejectedExecutionHandlerProxyTest.java index ce54ece6..cb4d46cc 100644 --- a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/test/java/cn/hippo4j/starter/test/RejectedExecutionHandlerProxyTest.java +++ b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/test/java/cn/hippo4j/starter/test/RejectedExecutionHandlerProxyTest.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.starter.test; import cn.hippo4j.core.executor.DynamicThreadPoolExecutor; @@ -32,7 +49,6 @@ public class RejectedExecutionHandlerProxyTest { .dynamicPool() .build(); - for (int i = 0; i < 300; i++) { try { executor.execute(() -> ThreadUtil.sleep(Integer.MAX_VALUE)); diff --git a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/test/java/cn/hippo4j/starter/test/ResizableCapacityLinkedBlockIngQueueTest.java b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/test/java/cn/hippo4j/starter/test/ResizableCapacityLinkedBlockIngQueueTest.java index 466c2259..44931905 100644 --- a/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/test/java/cn/hippo4j/starter/test/ResizableCapacityLinkedBlockIngQueueTest.java +++ b/hippo4j-spring-boot/hippo4j-spring-boot-starter/src/test/java/cn/hippo4j/starter/test/ResizableCapacityLinkedBlockIngQueueTest.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.starter.test; import cn.hippo4j.core.executor.support.ResizableCapacityLinkedBlockIngQueue; @@ -24,15 +41,11 @@ public class ResizableCapacityLinkedBlockIngQueueTest { TimeUnit.SECONDS, blockIngQueue); - /*Runnable runnable = new Runnable() { - @SneakyThrows - public void run() { - Thread.sleep(10000); - } - }; - for (int i = 0; i <; i++) { - threadPoolExecutor.execute(runnable); - }*/ + /* + * Runnable runnable = new Runnable() { + * + * @SneakyThrows public void run() { Thread.sleep(10000); } }; for (int i = 0; i <; i++) { threadPoolExecutor.execute(runnable); } + */ print(threadPoolExecutor); @@ -46,14 +59,14 @@ public class ResizableCapacityLinkedBlockIngQueueTest { LinkedBlockingQueue queue = (LinkedBlockingQueue) executor.getQueue(); log.info("核心线程数 :: {}," + - " 活动线程数 :: {}," + - " 最大线程数 :: {}," + - " 线程池活跃度 :: {}," + - " 任务完成数 :: {}," + - " 队列大小 :: {}," + - " 当前排队线程数 :: {}," + - " 队列剩余大小 :: {}," + - " 队列使用度 :: {}", + " 活动线程数 :: {}," + + " 最大线程数 :: {}," + + " 线程池活跃度 :: {}," + + " 任务完成数 :: {}," + + " 队列大小 :: {}," + + " 当前排队线程数 :: {}," + + " 队列剩余大小 :: {}," + + " 队列使用度 :: {}", executor.getCorePoolSize(), executor.getActiveCount(), executor.getMaximumPoolSize(), diff --git a/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/annotation/LogField.java b/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/annotation/LogField.java index 9953bf43..c0b63726 100644 --- a/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/annotation/LogField.java +++ b/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/annotation/LogField.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.tools.logrecord.annotation; /** diff --git a/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/annotation/LogRecord.java b/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/annotation/LogRecord.java index 489e1af7..7a30ee1f 100644 --- a/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/annotation/LogRecord.java +++ b/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/annotation/LogRecord.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.tools.logrecord.annotation; import cn.hippo4j.tools.logrecord.enums.LogRecordTypeEnum; diff --git a/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/aop/LogRecordAspect.java b/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/aop/LogRecordAspect.java index 8f7d4feb..510dfad2 100644 --- a/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/aop/LogRecordAspect.java +++ b/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/aop/LogRecordAspect.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.tools.logrecord.aop; import cn.hippo4j.tools.logrecord.annotation.LogRecord; diff --git a/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/compare/AbstractEquator.java b/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/compare/AbstractEquator.java index 727a5890..9c17b7ff 100644 --- a/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/compare/AbstractEquator.java +++ b/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/compare/AbstractEquator.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.tools.logrecord.compare; import java.util.*; @@ -22,8 +39,7 @@ public class AbstractEquator implements Equator { Double.class, Character.class, Boolean.class, - String.class - ); + String.class); private List includeFields; diff --git a/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/compare/Equator.java b/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/compare/Equator.java index 9b5a627a..d8345e12 100644 --- a/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/compare/Equator.java +++ b/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/compare/Equator.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.tools.logrecord.compare; import java.util.List; diff --git a/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/compare/FieldInfo.java b/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/compare/FieldInfo.java index e7cafca4..89624745 100644 --- a/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/compare/FieldInfo.java +++ b/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/compare/FieldInfo.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.tools.logrecord.compare; import lombok.AllArgsConstructor; @@ -76,5 +93,4 @@ public class FieldInfo { return Objects.hash(fieldName, firstFieldType, secondFieldType, firstVal, secondVal); } - } diff --git a/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/compare/GetterBaseEquator.java b/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/compare/GetterBaseEquator.java index ee82f600..c218e87d 100644 --- a/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/compare/GetterBaseEquator.java +++ b/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/compare/GetterBaseEquator.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.tools.logrecord.compare; import lombok.NoArgsConstructor; @@ -133,7 +150,7 @@ public class GetterBaseEquator extends AbstractEquator { final int[] newCodePoints = new int[strLen]; int outOffset = 0; newCodePoints[outOffset++] = newCodePoint; - for (int inOffset = Character.charCount(firstCodepoint); inOffset < strLen; ) { + for (int inOffset = Character.charCount(firstCodepoint); inOffset < strLen;) { final int codepoint = str.codePointAt(inOffset); newCodePoints[outOffset++] = codepoint; inOffset += Character.charCount(codepoint); diff --git a/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/config/LogRecordConfig.java b/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/config/LogRecordConfig.java index c20f6f3a..ff09136c 100644 --- a/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/config/LogRecordConfig.java +++ b/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/config/LogRecordConfig.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.tools.logrecord.config; import cn.hippo4j.tools.logrecord.parse.LogRecordOperationSource; @@ -31,7 +48,6 @@ public class LogRecordConfig { return new DefaultParseFunction(); } - @Bean public ParseFunctionFactory parseFunctionFactory(@Autowired List parseFunctions) { return new ParseFunctionFactory(parseFunctions); diff --git a/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/context/LogRecordContext.java b/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/context/LogRecordContext.java index 4f6e1356..07b819d5 100644 --- a/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/context/LogRecordContext.java +++ b/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/context/LogRecordContext.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.tools.logrecord.context; import com.alibaba.ttl.TransmittableThreadLocal; diff --git a/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/enums/LogRecordTypeEnum.java b/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/enums/LogRecordTypeEnum.java index 8a9525dc..b59af750 100644 --- a/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/enums/LogRecordTypeEnum.java +++ b/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/enums/LogRecordTypeEnum.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.tools.logrecord.enums; /** diff --git a/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/model/LogRecordInfo.java b/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/model/LogRecordInfo.java index a89c93e3..bfec0d2f 100644 --- a/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/model/LogRecordInfo.java +++ b/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/model/LogRecordInfo.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.tools.logrecord.model; import lombok.AllArgsConstructor; diff --git a/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/model/LogRecordOps.java b/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/model/LogRecordOps.java index b6d13bbb..82983b8a 100644 --- a/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/model/LogRecordOps.java +++ b/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/model/LogRecordOps.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.tools.logrecord.model; import lombok.Builder; diff --git a/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/model/MethodExecuteResult.java b/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/model/MethodExecuteResult.java index 0cfdb60b..41664fd1 100644 --- a/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/model/MethodExecuteResult.java +++ b/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/model/MethodExecuteResult.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.tools.logrecord.model; import lombok.*; diff --git a/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/model/Operator.java b/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/model/Operator.java index aeb8d3e5..02a7c232 100644 --- a/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/model/Operator.java +++ b/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/model/Operator.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.tools.logrecord.model; import lombok.AllArgsConstructor; diff --git a/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/parse/LogRecordEvaluationContext.java b/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/parse/LogRecordEvaluationContext.java index da09b7d5..ff9d87de 100644 --- a/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/parse/LogRecordEvaluationContext.java +++ b/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/parse/LogRecordEvaluationContext.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.tools.logrecord.parse; import cn.hippo4j.tools.logrecord.context.LogRecordContext; diff --git a/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/parse/LogRecordExpressionEvaluator.java b/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/parse/LogRecordExpressionEvaluator.java index 0815e0f7..dddcba54 100644 --- a/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/parse/LogRecordExpressionEvaluator.java +++ b/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/parse/LogRecordExpressionEvaluator.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.tools.logrecord.parse; import com.google.common.collect.Maps; diff --git a/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/parse/LogRecordOperationSource.java b/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/parse/LogRecordOperationSource.java index 7af1b981..2e8837b2 100644 --- a/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/parse/LogRecordOperationSource.java +++ b/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/parse/LogRecordOperationSource.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.tools.logrecord.parse; import cn.hippo4j.tools.logrecord.annotation.LogRecord; diff --git a/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/parse/LogRecordValueParser.java b/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/parse/LogRecordValueParser.java index aeaf8ce4..a6ddee5c 100644 --- a/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/parse/LogRecordValueParser.java +++ b/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/parse/LogRecordValueParser.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.tools.logrecord.parse; import cn.hippo4j.tools.logrecord.service.FunctionService; diff --git a/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/service/FunctionService.java b/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/service/FunctionService.java index fe7e689f..f2e0d5ad 100644 --- a/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/service/FunctionService.java +++ b/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/service/FunctionService.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.tools.logrecord.service; /** diff --git a/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/service/LogRecordService.java b/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/service/LogRecordService.java index 09f1c833..8d12f6ff 100644 --- a/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/service/LogRecordService.java +++ b/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/service/LogRecordService.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.tools.logrecord.service; import cn.hippo4j.tools.logrecord.model.LogRecordInfo; diff --git a/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/service/OperatorGetService.java b/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/service/OperatorGetService.java index eac2ba57..592b48d1 100644 --- a/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/service/OperatorGetService.java +++ b/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/service/OperatorGetService.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.tools.logrecord.service; import cn.hippo4j.tools.logrecord.model.Operator; diff --git a/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/service/ParseFunction.java b/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/service/ParseFunction.java index ffa09675..bff082f2 100644 --- a/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/service/ParseFunction.java +++ b/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/service/ParseFunction.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.tools.logrecord.service; /** diff --git a/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/service/impl/DefaultFunctionServiceImpl.java b/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/service/impl/DefaultFunctionServiceImpl.java index 79b03935..59069211 100644 --- a/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/service/impl/DefaultFunctionServiceImpl.java +++ b/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/service/impl/DefaultFunctionServiceImpl.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.tools.logrecord.service.impl; import cn.hippo4j.tools.logrecord.service.FunctionService; diff --git a/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/service/impl/DefaultLogRecordServiceImpl.java b/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/service/impl/DefaultLogRecordServiceImpl.java index a0e77bcb..e37c0b9a 100644 --- a/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/service/impl/DefaultLogRecordServiceImpl.java +++ b/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/service/impl/DefaultLogRecordServiceImpl.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.tools.logrecord.service.impl; import cn.hippo4j.tools.logrecord.model.LogRecordInfo; diff --git a/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/service/impl/DefaultOperatorGetServiceImpl.java b/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/service/impl/DefaultOperatorGetServiceImpl.java index 866a0686..313823e5 100644 --- a/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/service/impl/DefaultOperatorGetServiceImpl.java +++ b/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/service/impl/DefaultOperatorGetServiceImpl.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.tools.logrecord.service.impl; import cn.hippo4j.tools.logrecord.model.Operator; diff --git a/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/service/impl/DefaultParseFunction.java b/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/service/impl/DefaultParseFunction.java index b6fb80a3..9334083e 100644 --- a/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/service/impl/DefaultParseFunction.java +++ b/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/service/impl/DefaultParseFunction.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.tools.logrecord.service.impl; import cn.hippo4j.tools.logrecord.service.ParseFunction; diff --git a/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/service/impl/ParseFunctionFactory.java b/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/service/impl/ParseFunctionFactory.java index 0ea4dfd7..64067aa8 100644 --- a/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/service/impl/ParseFunctionFactory.java +++ b/hippo4j-tools/log-record-tool/src/main/java/cn/hippo4j/tools/logrecord/service/impl/ParseFunctionFactory.java @@ -1,3 +1,20 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + package cn.hippo4j.tools.logrecord.service.impl; import cn.hippo4j.tools.logrecord.service.ParseFunction;