├── .circleci └── config.yml ├── .github └── workflows │ └── codeql-analysis.yml ├── .gitignore ├── Harrier_3.0_部署使用说明书.pdf ├── LICENSE ├── README.md ├── harrier-alarm ├── .classpath ├── .gitignore ├── .project ├── .settings │ ├── org.eclipse.core.resources.prefs │ ├── org.eclipse.jdt.core.prefs │ └── org.eclipse.m2e.core.prefs ├── pom.xml └── src │ └── main │ ├── java │ └── cn │ │ └── spdb │ │ └── harrier │ │ └── alarm │ │ ├── AlarmManger.java │ │ ├── AlarmSendManger.java │ │ ├── AlarmServer.java │ │ ├── config │ │ └── AlarmConfig.java │ │ ├── enums │ │ └── SendType.java │ │ ├── rpc │ │ ├── AlarmRpc.java │ │ └── transport │ │ │ ├── AlarmTransportServerInterfasce.java │ │ │ └── AlarmTransportService.java │ │ ├── send │ │ ├── AlarmProcess.java │ │ ├── email │ │ │ ├── EmailAlarmProcess.java │ │ │ ├── EmailConstants.java │ │ │ ├── EmailSender.java │ │ │ └── exception │ │ │ │ └── AlertEmailException.java │ │ ├── http │ │ │ ├── HttpAlarmProcess.java │ │ │ └── HttpSender.java │ │ ├── modle │ │ │ ├── AlarmData.java │ │ │ ├── AlarmInfo.java │ │ │ └── AlarmResult.java │ │ └── wechat │ │ │ ├── WeChatAlertConstants.java │ │ │ ├── WeChatSender.java │ │ │ ├── WechatAlarmProcess.java │ │ │ └── exception │ │ │ └── WeChatAlertException.java │ │ └── utils │ │ └── AlarmUtils.java │ └── resources │ └── logback.xml ├── harrier-api ├── .classpath ├── .gitignore ├── .project ├── .settings │ ├── org.eclipse.core.resources.prefs │ ├── org.eclipse.jdt.core.prefs │ └── org.eclipse.m2e.core.prefs ├── pom.xml └── src │ ├── main │ ├── java │ │ └── cn │ │ │ └── spdb │ │ │ └── harrier │ │ │ └── api │ │ │ ├── ApiServer.java │ │ │ ├── MonitorApplication.java │ │ │ ├── aspect │ │ │ ├── AccessLogAnnotation.java │ │ │ ├── AccessLogAspect.java │ │ │ ├── DataScope.java │ │ │ └── DataScopeAspect.java │ │ │ ├── cache │ │ │ ├── LoginTreeMenuCahece.java │ │ │ └── TreeMenuCahece.java │ │ │ ├── config │ │ │ ├── DruidMonitorConfig.java │ │ │ ├── MonitorConfig.java │ │ │ └── WebConfiguration.java │ │ │ ├── controller │ │ │ ├── alarm │ │ │ │ ├── MAlarmConfigController.java │ │ │ │ ├── MAlarmController.java │ │ │ │ ├── MAlarmMsgController.java │ │ │ │ ├── MAlarmSendQueueController.java │ │ │ │ └── MAlarmUserGroupController.java │ │ │ ├── complement │ │ │ │ ├── UdsComplementController.java │ │ │ │ └── UdsJobComplementController.java │ │ │ ├── develop │ │ │ │ ├── JobArrangeController.java │ │ │ │ ├── JobAttributesController.java │ │ │ │ ├── JobDevelopController.java │ │ │ │ └── package-info.java │ │ │ ├── firstpage │ │ │ │ └── FirstPageStatsController.java │ │ │ ├── job │ │ │ │ ├── CustomSqlController.java │ │ │ │ ├── UdsJobConfigController.java │ │ │ │ ├── UdsJobController.java │ │ │ │ ├── UdsJobDateFrequencyController.java │ │ │ │ ├── UdsJobDependencyController.java │ │ │ │ ├── UdsJobRecordController.java │ │ │ │ ├── UdsJobSourceController.java │ │ │ │ ├── UdsJobStepController.java │ │ │ │ ├── UdsJobStepRecordController.java │ │ │ │ ├── UdsJobTimeTriggerController.java │ │ │ │ ├── UdsJobWeightController.java │ │ │ │ ├── UdsJobWeightLimitController.java │ │ │ │ ├── UdsServerController.java │ │ │ │ └── UdsSystemController.java │ │ │ └── system │ │ │ │ ├── MDictionaryController.java │ │ │ │ ├── MOperatLogController.java │ │ │ │ ├── SysFileController.java │ │ │ │ ├── SysIndexController.java │ │ │ │ ├── SysLoginController.java │ │ │ │ ├── SysMenuController.java │ │ │ │ ├── SysRegisterController.java │ │ │ │ ├── SysRoleController.java │ │ │ │ └── SysUserController.java │ │ │ ├── enums │ │ │ ├── AlarmOper.java │ │ │ ├── ExecuteType.java │ │ │ ├── PermissionStatus.java │ │ │ └── Status.java │ │ │ ├── exceptions │ │ │ ├── ApiException.java │ │ │ ├── ApiExceptionHandler.java │ │ │ └── ServiceException.java │ │ │ ├── interceptor │ │ │ ├── LocaleChangeInterceptor.java │ │ │ ├── LoginHandlerInterceptor.java │ │ │ ├── RateLimitInterceptor.java │ │ │ ├── RepeatSubmit.java │ │ │ └── RepeatSubmitInterceptor.java │ │ │ ├── model │ │ │ ├── JobDepRelations.java │ │ │ ├── JobStepConfig.java │ │ │ ├── JobYamlObject.java │ │ │ ├── LoginBody.java │ │ │ ├── LoginMenu.java │ │ │ ├── LoginMenuMeta.java │ │ │ ├── LoginUser.java │ │ │ ├── RegisterBody.java │ │ │ ├── TreeJobNode.java │ │ │ ├── TreeMenuNode.java │ │ │ └── TreeMenuNodeAttribute.java │ │ │ ├── rpc │ │ │ ├── MoniterRpc.java │ │ │ └── transport │ │ │ │ ├── MasterTransportServerInterfasce.java │ │ │ │ └── WorkTransportServerInterface.java │ │ │ ├── security │ │ │ ├── config │ │ │ │ └── SecurityConfig.java │ │ │ ├── filter │ │ │ │ └── JwtAuthenticationTokenFilter.java │ │ │ └── handle │ │ │ │ ├── AuthenticationEntryPointImpl.java │ │ │ │ ├── AuthenticationFailureHandlerImpl.java │ │ │ │ └── LogoutSuccessHandlerImpl.java │ │ │ ├── service │ │ │ ├── alarm │ │ │ │ ├── MAlarmConfigService.java │ │ │ │ ├── MAlarmMsgService.java │ │ │ │ ├── MAlarmSendQueueService.java │ │ │ │ ├── MAlarmService.java │ │ │ │ ├── MAlarmUserGroupService.java │ │ │ │ └── impl │ │ │ │ │ ├── MAlarmConfigServiceImpl.java │ │ │ │ │ ├── MAlarmMsgServiceImpl.java │ │ │ │ │ ├── MAlarmSendQueueServiceImpl.java │ │ │ │ │ ├── MAlarmServiceImpl.java │ │ │ │ │ └── MAlarmUserGroupServiceImpl.java │ │ │ ├── complement │ │ │ │ ├── UdsComplementService.java │ │ │ │ ├── UdsJobComplementService.java │ │ │ │ └── impl │ │ │ │ │ ├── UdsComplementServiceImpl.java │ │ │ │ │ └── UdsJobComplementServiceImpl.java │ │ │ ├── develop │ │ │ │ ├── IDeployScriptService.java │ │ │ │ ├── IDeploySqlCreate.java │ │ │ │ ├── IDeploySqlService.java │ │ │ │ ├── IJobArrangeService.java │ │ │ │ ├── IJobAttributesService.java │ │ │ │ ├── IJobConfigChangeService.java │ │ │ │ ├── IYamlManagerService.java │ │ │ │ └── impl │ │ │ │ │ ├── DeployScriptServiceImpl.java │ │ │ │ │ ├── DeploySqlCreateServiceImpl.java │ │ │ │ │ ├── DepploySqlServiceImpl.java │ │ │ │ │ ├── JobArrangeServiceImpl.java │ │ │ │ │ ├── JobAttributesServiceImpl.java │ │ │ │ │ ├── JobConfigChangeServiceImpl.java │ │ │ │ │ └── YamlManagerServiceImpl.java │ │ │ ├── firstpage │ │ │ │ ├── Stats.java │ │ │ │ └── impl │ │ │ │ │ └── StatsImpl.java │ │ │ ├── job │ │ │ │ ├── CustomSqlService.java │ │ │ │ ├── UdsJobConfigService.java │ │ │ │ ├── UdsJobDateFrequencyService.java │ │ │ │ ├── UdsJobDependencyService.java │ │ │ │ ├── UdsJobRecordService.java │ │ │ │ ├── UdsJobService.java │ │ │ │ ├── UdsJobSourceService.java │ │ │ │ ├── UdsJobStepRecordService.java │ │ │ │ ├── UdsJobStepService.java │ │ │ │ ├── UdsJobTimeTriggerService.java │ │ │ │ ├── UdsJobWeightLimitService.java │ │ │ │ ├── UdsJobWeightService.java │ │ │ │ ├── UdsServerService.java │ │ │ │ ├── UdsSystemService.java │ │ │ │ └── impl │ │ │ │ │ ├── CustomSqlServiceImpl.java │ │ │ │ │ ├── UdsJobConfigServiceImpl.java │ │ │ │ │ ├── UdsJobDateFrequencyServiceImpl.java │ │ │ │ │ ├── UdsJobDependencyServiceImpl.java │ │ │ │ │ ├── UdsJobRecordServiceImpl.java │ │ │ │ │ ├── UdsJobServiceImpl.java │ │ │ │ │ ├── UdsJobSourceServiceImpl.java │ │ │ │ │ ├── UdsJobStepRecordServiceImpl.java │ │ │ │ │ ├── UdsJobStepServiceImpl.java │ │ │ │ │ ├── UdsJobTimeTriggerServiceImpl.java │ │ │ │ │ ├── UdsJobWeightLimitServiceImpl.java │ │ │ │ │ ├── UdsJobWeightServiceImpl.java │ │ │ │ │ ├── UdsServerServiceImpl.java │ │ │ │ │ └── UdsSystemServiceImpl.java │ │ │ └── system │ │ │ │ ├── FileDisposeService.java │ │ │ │ ├── ISysConfigService.java │ │ │ │ ├── ISysMenuService.java │ │ │ │ ├── ISysRoleService.java │ │ │ │ ├── ISysUserService.java │ │ │ │ ├── MDictionaryService.java │ │ │ │ ├── MOperatLogService.java │ │ │ │ ├── SysLoginService.java │ │ │ │ ├── SysPermissionService.java │ │ │ │ ├── SysRegisterService.java │ │ │ │ ├── SysTokenService.java │ │ │ │ └── impl │ │ │ │ ├── FileDisposeServiceImpl.java │ │ │ │ ├── MDictionaryServiceImpl.java │ │ │ │ ├── MOperatLogServiceImpl.java │ │ │ │ ├── MenuServiceImpl.java │ │ │ │ ├── RoleServiceImpl.java │ │ │ │ ├── SysConfigServiceImpl.java │ │ │ │ ├── SysUserServiceImpl.java │ │ │ │ └── UserDetailsServiceImpl.java │ │ │ └── utils │ │ │ ├── Convert.java │ │ │ ├── FileUtils.java │ │ │ ├── FourLetterWordMain.java │ │ │ ├── HTMLFilter.java │ │ │ ├── HttpHelper.java │ │ │ ├── ImageUtils.java │ │ │ ├── JobDeployPath.java │ │ │ ├── JobDeployStatus.java │ │ │ ├── LRUCache.java │ │ │ ├── RegexUtils.java │ │ │ ├── Result.java │ │ │ ├── SecurityUtils.java │ │ │ └── ServletUtils.java │ └── resources │ │ ├── application.properties │ │ ├── i18n │ │ ├── messages.properties │ │ ├── messages_en_US.properties │ │ └── messages_zh_CN.properties │ │ └── logback.xml │ └── test │ └── java │ └── cn │ └── spdb │ └── harrier │ └── api │ ├── AbstractControllerTest.java │ ├── AbstractHttpClientTest.java │ ├── develop │ └── YamlManagerTest.java │ ├── http │ └── HttpClientTest.java │ └── mock │ ├── MAlarmConfigControllerTest.java │ └── SysMenuControllerTest.java ├── harrier-common ├── .classpath ├── .gitignore ├── .project ├── .settings │ ├── org.eclipse.core.resources.prefs │ ├── org.eclipse.jdt.core.prefs │ └── org.eclipse.m2e.core.prefs ├── pom.xml └── src │ ├── main │ └── java │ │ └── cn │ │ └── spdb │ │ └── harrier │ │ └── common │ │ ├── Application.java │ │ ├── CommandConstant.java │ │ ├── Constants.java │ │ ├── cache │ │ ├── HarrierCache.java │ │ └── HarrierCacheImpl.java │ │ ├── constants │ │ └── alarm │ │ │ ├── EmailParamsConstants.java │ │ │ ├── HttpAlertConstants.java │ │ │ └── WeChatAlertParamsConstants.java │ │ ├── dynamicjava │ │ ├── CharSequenceJavaFileObject.java │ │ ├── ClassFileManager.java │ │ ├── DynamicClassEngine.java │ │ ├── DynamicClassLoader.java │ │ ├── DynamicClassManager.java │ │ └── JavaClassObject.java │ │ ├── enmus │ │ ├── DownLoadResourceProtocol.java │ │ ├── ExecutionStatus.java │ │ ├── Message.java │ │ ├── RegistryState.java │ │ ├── StreamType.java │ │ ├── UdsJobType.java │ │ └── alarm │ │ │ ├── AlarmCode.java │ │ │ ├── AlarmLevel.java │ │ │ ├── AlarmStatus.java │ │ │ ├── SendStatus.java │ │ │ ├── SendTypeResource.java │ │ │ └── ShowType.java │ │ ├── log │ │ ├── AlarmLogFilter.java │ │ ├── ApplicationLogFilter.java │ │ ├── LogbackPrintStream.java │ │ ├── MasterLogFilter.java │ │ ├── MonitorLogFilter.java │ │ ├── OtherLogFilter.java │ │ ├── TaskLogDiscriminator.java │ │ ├── TaskLogFilter.java │ │ └── WorkerLogFilter.java │ │ ├── model │ │ ├── DAG.java │ │ └── JobSignal.java │ │ ├── script │ │ ├── InstallScript.java │ │ └── UdsSqlScriptRunner.java │ │ └── utils │ │ ├── ClassUtils.java │ │ ├── CollectionUtils.java │ │ ├── DateUtils.java │ │ ├── ExcelUtils.java │ │ ├── FileUtils.java │ │ ├── Host.java │ │ ├── HttpUtils.java │ │ ├── IOUtils.java │ │ ├── IPUtils.java │ │ ├── IceKey.java │ │ ├── JSONUtils.java │ │ ├── LoggerUtils.java │ │ ├── NameThreadFactory.java │ │ ├── OSUtils.java │ │ ├── ObjectUtils.java │ │ ├── PropertyUtils.java │ │ ├── SnowFlakeBuidID.java │ │ ├── SshUtils.java │ │ ├── Stopper.java │ │ ├── StringUtils.java │ │ ├── Symbol.java │ │ ├── ThreadUtils.java │ │ ├── URI.java │ │ ├── UUID.java │ │ └── ZipUtils.java │ └── test │ └── java │ └── cn │ └── spdb │ └── harrier │ └── common │ └── test │ ├── DagTest.java │ ├── DynamicTest.java │ └── Test.java ├── harrier-dao ├── .classpath ├── .gitignore ├── .project ├── .settings │ ├── org.eclipse.core.resources.prefs │ ├── org.eclipse.jdt.core.prefs │ └── org.eclipse.m2e.core.prefs ├── pom.xml └── src │ └── main │ ├── java │ └── cn │ │ └── spdb │ │ └── harrier │ │ └── dao │ │ ├── Application.java │ │ ├── cache │ │ ├── DictionaryCache.java │ │ └── SystemCache.java │ │ ├── datasource │ │ ├── PaginationInnerInterceptorByMybatis3.java │ │ └── SpringDruidFactory.java │ │ ├── entity │ │ ├── DyJobArrange.java │ │ ├── DyJobAttributes.java │ │ ├── MAlarm.java │ │ ├── MAlarmConfig.java │ │ ├── MAlarmMsg.java │ │ ├── MAlarmSendQueue.java │ │ ├── MAlarmUserGroup.java │ │ ├── MDictionary.java │ │ ├── MMenu.java │ │ ├── MOperatLog.java │ │ ├── MRole.java │ │ ├── MRoleMenu.java │ │ ├── MUser.java │ │ ├── MUserRole.java │ │ ├── MUserSystems.java │ │ ├── UdsComplement.java │ │ ├── UdsJob.java │ │ ├── UdsJobComplement.java │ │ ├── UdsJobConfig.java │ │ ├── UdsJobDateFrequency.java │ │ ├── UdsJobDependency.java │ │ ├── UdsJobMenu.java │ │ ├── UdsJobRecord.java │ │ ├── UdsJobSelfSignal.java │ │ ├── UdsJobSource.java │ │ ├── UdsJobStep.java │ │ ├── UdsJobStepRecord.java │ │ ├── UdsJobTimeTrigger.java │ │ ├── UdsJobWeight.java │ │ ├── UdsJobWeightLimit.java │ │ ├── UdsServer.java │ │ ├── UdsSystem.java │ │ └── UserSystemPermiss.java │ │ ├── mapper │ │ ├── CustomSqlMapper.java │ │ ├── DyJobArrangeDynamicSqlSupport.java │ │ ├── DyJobArrangeMapper.java │ │ ├── DyJobAttributesDynamicSqlSupport.java │ │ ├── DyJobAttributesMapper.java │ │ ├── FirstPageStats.java │ │ ├── MAlarmConfigDynamicSqlSupport.java │ │ ├── MAlarmConfigMapper.java │ │ ├── MAlarmDynamicSqlSupport.java │ │ ├── MAlarmMapper.java │ │ ├── MAlarmMsgDynamicSqlSupport.java │ │ ├── MAlarmMsgMapper.java │ │ ├── MAlarmSendQueueDynamicSqlSupport.java │ │ ├── MAlarmSendQueueMapper.java │ │ ├── MAlarmUserGroupDynamicSqlSupport.java │ │ ├── MAlarmUserGroupMapper.java │ │ ├── MDictionaryDynamicSqlSupport.java │ │ ├── MDictionaryMapper.java │ │ ├── MMenuDynamicSqlSupport.java │ │ ├── MMenuMapper.java │ │ ├── MOperatLogDynamicSqlSupport.java │ │ ├── MOperatLogMapper.java │ │ ├── MRoleDynamicSqlSupport.java │ │ ├── MRoleMapper.java │ │ ├── MRoleMenuDynamicSqlSupport.java │ │ ├── MRoleMenuMapper.java │ │ ├── MUserDynamicSqlSupport.java │ │ ├── MUserMapper.java │ │ ├── MUserRoleDynamicSqlSupport.java │ │ ├── MUserRoleMapper.java │ │ ├── MUserSystemsDynamicSqlSupport.java │ │ ├── MUserSystemsMapper.java │ │ ├── UdsComplementDynamicSqlSupport.java │ │ ├── UdsComplementMapper.java │ │ ├── UdsJobComplementDynamicSqlSupport.java │ │ ├── UdsJobComplementMapper.java │ │ ├── UdsJobConfigDynamicSqlSupport.java │ │ ├── UdsJobConfigMapper.java │ │ ├── UdsJobDateFrequencyDynamicSqlSupport.java │ │ ├── UdsJobDateFrequencyMapper.java │ │ ├── UdsJobDependencyDynamicSqlSupport.java │ │ ├── UdsJobDependencyMapper.java │ │ ├── UdsJobDynamicSqlSupport.java │ │ ├── UdsJobMapper.java │ │ ├── UdsJobMenuMapper.java │ │ ├── UdsJobRecordDynamicSqlSupport.java │ │ ├── UdsJobRecordMapper.java │ │ ├── UdsJobSelfSignalDynamicSqlSupport.java │ │ ├── UdsJobSelfSignalMapper.java │ │ ├── UdsJobSourceDynamicSqlSupport.java │ │ ├── UdsJobSourceMapper.java │ │ ├── UdsJobStepDynamicSqlSupport.java │ │ ├── UdsJobStepMapper.java │ │ ├── UdsJobStepRecordDynamicSqlSupport.java │ │ ├── UdsJobStepRecordMapper.java │ │ ├── UdsJobTimeTriggerDynamicSqlSupport.java │ │ ├── UdsJobTimeTriggerMapper.java │ │ ├── UdsJobWeightDynamicSqlSupport.java │ │ ├── UdsJobWeightLimitDynamicSqlSupport.java │ │ ├── UdsJobWeightLimitMapper.java │ │ ├── UdsJobWeightMapper.java │ │ ├── UdsServerDynamicSqlSupport.java │ │ ├── UdsServerMapper.java │ │ ├── UdsSystemDynamicSqlSupport.java │ │ └── UdsSystemMapper.java │ │ └── utils │ │ └── BeanContext.java │ └── resources │ ├── datasource.properties │ └── redis.properties ├── harrier-rpc ├── .classpath ├── .gitignore ├── .project ├── .settings │ ├── org.eclipse.core.resources.prefs │ ├── org.eclipse.jdt.core.prefs │ └── org.eclipse.m2e.core.prefs ├── pom.xml └── src │ └── main │ └── java │ └── cn │ └── spdb │ └── harrier │ └── rpc │ ├── Application.java │ ├── client │ ├── ConsumerConfig.java │ ├── ConsumerConfigCache.java │ ├── ConsumerInterceptor.java │ ├── InterfaceRpcClient.java │ ├── RpcClient.java │ ├── RpcFuture.java │ ├── RpcRequestCache.java │ └── RpcRequestTable.java │ ├── code │ ├── NettyDecoder.java │ └── NettyEncoder.java │ ├── common │ ├── ConsumerConfigConstant.java │ ├── DefaultRpcCallBack.java │ ├── HttpMapProtocol.java │ ├── InterfaceRpcCallBack.java │ ├── RequestEventType.java │ ├── ResponseEventType.java │ ├── RpcHandler.java │ ├── RpcMethod.java │ ├── RpcRequest.java │ ├── RpcResponse.java │ ├── RpcServiceHandler.java │ └── ThreadPoolManager.java │ ├── compress │ ├── Compress.java │ ├── CompressEnum.java │ ├── GZipCompress.java │ └── SnappyCompress.java │ ├── config │ ├── NettyClientConfig.java │ └── NettyServerConfig.java │ ├── protocol │ ├── ProtocolEventType.java │ ├── ProtocolHeader.java │ ├── RpcProtocol.java │ └── RpcProtocolConstants.java │ ├── remote │ ├── NettyChooseSelectHandler.java │ ├── NettyClient.java │ ├── NettyClientHandler.java │ ├── NettyEventLoopFactory.java │ ├── NettyServer.java │ └── NettyServerHandler.java │ ├── serializer │ ├── FastJsonSerializer.java │ ├── ProtoStuffSerializer.java │ ├── SerializeEnum.java │ └── Serializer.java │ └── transport │ ├── File │ ├── FileAtt.java │ ├── FileFuture.java │ ├── FileManager.java │ ├── FileMessage.java │ ├── FileStatus.java │ ├── IRpcFileService.java │ ├── RpcFileLoadCallBack.java │ ├── RpcFileService.java │ └── RpcFileUploadCallBack.java │ ├── RpcServiceTransportBean.java │ ├── http │ ├── AbstractHttpGetWorkerHandler.java │ ├── AbstractHttpHandler.java │ ├── AbstractHttpPostWorkerHandler.java │ ├── AbstractHttpWorkerHandler.java │ ├── HttpServiceTransportBean.java │ ├── InterfaceHttpHandler.java │ └── handler │ │ └── TestHandler.java │ └── script │ ├── IRpcScriptService.java │ ├── InterfaceCommand.java │ └── RpcScriptService.java ├── harrier-server ├── .classpath ├── .gitignore ├── .project ├── .settings │ ├── org.eclipse.core.resources.prefs │ ├── org.eclipse.jdt.core.prefs │ └── org.eclipse.m2e.core.prefs ├── pom.xml └── src │ └── main │ ├── java │ └── cn │ │ └── spdb │ │ └── harrier │ │ └── server │ │ ├── Application.java │ │ ├── entity │ │ ├── ComplementIns.java │ │ ├── JobExecutionContext.java │ │ ├── JobStepBean.java │ │ └── WorkingInfo.java │ │ ├── master │ │ ├── MasterManagerService.java │ │ ├── UdsMasterServer.java │ │ ├── cache │ │ │ └── MasterMangerWorker.java │ │ ├── complement │ │ │ └── ComplementService.java │ │ ├── conf │ │ │ └── MasterConfig.java │ │ ├── deal │ │ │ ├── Deal.java │ │ │ ├── DepStreamJobDeal.java │ │ │ ├── DispatcherDeal.java │ │ │ ├── PendingDeal.java │ │ │ ├── PlatformDealExecutor.java │ │ │ └── SelfStreamJobDeal.java │ │ ├── dispath │ │ │ ├── SelectManger.java │ │ │ └── select │ │ │ │ ├── AbstractSelector.java │ │ │ │ ├── HostWeight.java │ │ │ │ ├── LowerWeightRoundRobin.java │ │ │ │ ├── RandomSelector.java │ │ │ │ ├── RoundWeightSelector.java │ │ │ │ └── Selector.java │ │ ├── rpc │ │ │ ├── MasterRpc.java │ │ │ └── transport │ │ │ │ ├── AlarmTransportServerInterfasce.java │ │ │ │ ├── MasterTransportServer.java │ │ │ │ └── MasterTransportServerInterfasce.java │ │ ├── stream │ │ │ └── SignalManager.java │ │ └── weight │ │ │ └── WeightManger.java │ │ ├── script │ │ └── command │ │ │ ├── Command.java │ │ │ ├── InterfaceCommand.java │ │ │ └── handle │ │ │ └── LoadSystem.java │ │ ├── utils │ │ ├── AlarmSendUtils.java │ │ └── ResourceDownUtils.java │ │ └── worker │ │ ├── UdsWorkerServer.java │ │ ├── WorkerManagerThread.java │ │ ├── cache │ │ ├── ComplementContextCacheManager.java │ │ ├── TaskExecutionContextCacheManager.java │ │ └── TaskExecutionContextCacheManagerImpl.java │ │ ├── conf │ │ └── WorkerConfig.java │ │ ├── exec │ │ ├── ComplementExecuteRunnable.java │ │ ├── ComplementRunable.java │ │ ├── ExecuteRunable.java │ │ ├── TaskExecuteResult.java │ │ ├── TaskExecuteRunnable.java │ │ └── UdsSqlScriptRunner.java │ │ ├── rpc │ │ ├── WorkerRpc.java │ │ └── transport │ │ │ ├── WorkTransportServer.java │ │ │ └── WorkTransportServerInterface.java │ │ └── task │ │ ├── AbstractTask.java │ │ ├── ClassTask.java │ │ ├── CommandTask.java │ │ ├── HttpTask.java │ │ ├── SqlTask.java │ │ └── TaskManager.java │ └── resources │ ├── application.properties │ └── logback.xml ├── harrier-service ├── .classpath ├── .gitignore ├── .project ├── .settings │ ├── org.eclipse.core.resources.prefs │ ├── org.eclipse.jdt.core.prefs │ └── org.eclipse.m2e.core.prefs ├── pom.xml └── src │ └── main │ └── java │ └── cn │ └── spdb │ └── harrier │ └── service │ ├── Application.java │ ├── aws │ ├── AwsOperator.java │ ├── AwsUtils.java │ └── config │ │ └── AwsConfiguration.java │ ├── db │ ├── DbRegistryService.java │ ├── SubscribeListener.java │ └── WatchEvent.java │ ├── email │ ├── EmailOperator.java │ └── config │ │ └── EmailConfiguration.java │ ├── etcd │ ├── AbstractEtcdConfig.java │ ├── AbstractEtcdRegistry.java │ ├── EtcdDistributionQueue.java │ ├── EtcdLock.java │ ├── EtcdOperator.java │ ├── config │ │ └── DefaultEtcdConfig.java │ └── registry │ │ └── DefaultEtcdRegistry.java │ └── registry │ ├── HarrierRegistry.java │ ├── SubscribeListener.java │ └── WatchEvent.java ├── harrier-standalone-server ├── .classpath ├── .gitignore ├── .project ├── .settings │ ├── org.eclipse.core.resources.prefs │ ├── org.eclipse.jdt.core.prefs │ └── org.eclipse.m2e.core.prefs ├── pom.xml └── src │ └── main │ ├── java │ └── cn │ │ └── spdb │ │ └── harrier │ │ └── standalone │ │ └── StandaloneServer.java │ └── resources │ ├── application.properties │ └── logback.xml ├── harrier-ui ├── .babelrc ├── .classpath ├── .editorconfig ├── .eslintignore ├── .eslintrc.js ├── .gitignore ├── .postcssrc.js ├── .project ├── .settings │ ├── org.eclipse.core.resources.prefs │ ├── org.eclipse.jdt.core.prefs │ └── org.eclipse.m2e.core.prefs ├── .travis.yml ├── .vscode │ └── settings.json ├── cypress.json ├── package-lock.json ├── package.json ├── pom.xml ├── public │ ├── harrier.ico │ └── index.html ├── src │ ├── App.vue │ ├── api │ │ ├── data.js │ │ ├── routers.js │ │ └── user.js │ ├── assets │ │ ├── css │ │ │ └── monitor.css │ │ ├── icons │ │ │ ├── demo.css │ │ │ ├── demo_index.html │ │ │ ├── iconfont.css │ │ │ ├── iconfont.js │ │ │ ├── iconfont.json │ │ │ ├── iconfont.ttf │ │ │ ├── iconfont.woff │ │ │ ├── iconfont.woff2 │ │ │ ├── jobC.png │ │ │ ├── platformC.png │ │ │ ├── systemC.png │ │ │ ├── unJobC.png │ │ │ ├── unPlatformC.png │ │ │ └── unSystemC.png │ │ ├── images │ │ │ ├── corn.png │ │ │ ├── error-page │ │ │ │ ├── error-401.svg │ │ │ │ ├── error-404.svg │ │ │ │ └── error-500.svg │ │ │ ├── icon-qr-qq-wechat.png │ │ │ ├── icon-social-bilibili.svg │ │ │ ├── icon-social-juejin.svg │ │ │ ├── icon-social-twitter.svg │ │ │ ├── icon-social-zhihu.svg │ │ │ ├── login-bg.jpg │ │ │ ├── login_background.png │ │ │ ├── login_bg01.jpg │ │ │ ├── logo-min.jpg │ │ │ ├── logo.jpg │ │ │ ├── logoBig.png │ │ │ ├── logoSmall.png │ │ │ ├── talkingdata.png │ │ │ └── workflow │ │ │ │ ├── CMD.png │ │ │ │ ├── DELETE.png │ │ │ │ ├── GET.png │ │ │ │ ├── HEAD.png │ │ │ │ ├── JAVA.png │ │ │ │ ├── PERL.png │ │ │ │ ├── POST.png │ │ │ │ ├── PUT.png │ │ │ │ ├── PYTHON2.png │ │ │ │ ├── PYTHON3.png │ │ │ │ ├── SHELL.png │ │ │ │ └── SQL.png │ │ └── jobimg │ │ │ ├── basic.png │ │ │ ├── bg1.png │ │ │ ├── bj.png │ │ │ ├── brain1.gif │ │ │ ├── emergy.png │ │ │ ├── influ.png │ │ │ ├── life.png │ │ │ ├── radar.png │ │ │ ├── time.png │ │ │ └── xueyuan.png │ ├── common │ │ ├── ajax.js │ │ └── utils.js │ ├── components │ │ ├── charts │ │ │ ├── bar.vue │ │ │ ├── index.js │ │ │ ├── pie.vue │ │ │ └── theme.json │ │ ├── common-icon │ │ │ ├── common-icon.vue │ │ │ └── index.js │ │ ├── common │ │ │ ├── common.less │ │ │ └── util.js │ │ ├── count-to │ │ │ ├── count-to.vue │ │ │ ├── index.js │ │ │ └── index.less │ │ ├── cropper │ │ │ ├── index.js │ │ │ ├── index.less │ │ │ └── index.vue │ │ ├── drag-drawer │ │ │ ├── drag-drawer-trigger.vue │ │ │ ├── drag-drawer.vue │ │ │ ├── index.js │ │ │ ├── index.less │ │ │ └── mixin.js │ │ ├── drag-list │ │ │ ├── drag-list.vue │ │ │ └── index.js │ │ ├── editor │ │ │ ├── editor.vue │ │ │ └── index.js │ │ ├── icons │ │ │ ├── icons.vue │ │ │ └── index.js │ │ ├── info-card-new │ │ │ ├── index.js │ │ │ └── infor-card-new.vue │ │ ├── info-card │ │ │ ├── index.js │ │ │ └── infor-card.vue │ │ ├── info-circle │ │ │ ├── index.js │ │ │ └── info-circle.vue │ │ ├── login-form │ │ │ ├── index.js │ │ │ └── login-form.vue │ │ ├── main │ │ │ ├── components │ │ │ │ ├── a-back-top │ │ │ │ │ ├── index.js │ │ │ │ │ └── index.vue │ │ │ │ ├── error-store │ │ │ │ │ ├── error-store.vue │ │ │ │ │ └── index.js │ │ │ │ ├── fullscreen │ │ │ │ │ ├── fullscreen.vue │ │ │ │ │ └── index.js │ │ │ │ ├── header-bar │ │ │ │ │ ├── custom-bread-crumb │ │ │ │ │ │ ├── custom-bread-crumb.less │ │ │ │ │ │ ├── custom-bread-crumb.vue │ │ │ │ │ │ └── index.js │ │ │ │ │ ├── header-bar.less │ │ │ │ │ ├── header-bar.vue │ │ │ │ │ ├── index.js │ │ │ │ │ └── sider-trigger │ │ │ │ │ │ ├── index.js │ │ │ │ │ │ ├── sider-trigger.less │ │ │ │ │ │ └── sider-trigger.vue │ │ │ │ ├── help │ │ │ │ │ ├── help.less │ │ │ │ │ ├── help.vue │ │ │ │ │ └── index.js │ │ │ │ ├── language │ │ │ │ │ ├── index.js │ │ │ │ │ └── language.vue │ │ │ │ ├── side-menu │ │ │ │ │ ├── collapsed-menu.vue │ │ │ │ │ ├── index.js │ │ │ │ │ ├── item-mixin.js │ │ │ │ │ ├── mixin.js │ │ │ │ │ ├── side-menu-item.vue │ │ │ │ │ ├── side-menu.less │ │ │ │ │ └── side-menu.vue │ │ │ │ ├── tags-nav │ │ │ │ │ ├── index.js │ │ │ │ │ ├── tags-nav.less │ │ │ │ │ └── tags-nav.vue │ │ │ │ └── user │ │ │ │ │ ├── index.js │ │ │ │ │ ├── old_user.less │ │ │ │ │ ├── old_user.vue │ │ │ │ │ ├── user.less │ │ │ │ │ └── user.vue │ │ │ ├── index.js │ │ │ ├── main.less │ │ │ ├── main.vue │ │ │ ├── old_main.less │ │ │ └── old_main.vue │ │ ├── markdown │ │ │ ├── index.js │ │ │ └── markdown.vue │ │ ├── parent-view │ │ │ ├── index.js │ │ │ └── parent-view.vue │ │ ├── paste-editor │ │ │ ├── index.js │ │ │ ├── paste-editor.less │ │ │ ├── paste-editor.vue │ │ │ └── plugins │ │ │ │ └── placeholder.js │ │ ├── s-auth-button │ │ │ ├── authUtil.js │ │ │ ├── index.js │ │ │ └── s-auth-button.vue │ │ ├── s-tree-table │ │ │ ├── CalFooter.vue │ │ │ ├── cell.vue │ │ │ ├── expand.js │ │ │ ├── export-csv.js │ │ │ ├── header.js │ │ │ ├── index.js │ │ │ ├── mixin.js │ │ │ ├── s-tree-table.vue │ │ │ ├── table-body.vue │ │ │ ├── table-head.vue │ │ │ ├── table-tr.vue │ │ │ └── total.vue │ │ ├── tables │ │ │ ├── edit.vue │ │ │ ├── handle-btns.js │ │ │ ├── index.js │ │ │ ├── index.less │ │ │ └── tables.vue │ │ └── tree-select │ │ │ ├── index.js │ │ │ ├── tree-select-tree.vue │ │ │ └── tree-select.vue │ ├── config │ │ └── index.js │ ├── directive │ │ ├── directives.js │ │ ├── index.js │ │ └── module │ │ │ ├── clipboard.js │ │ │ └── draggable.js │ ├── index.less │ ├── libs │ │ ├── api.request.js │ │ ├── axios.js │ │ ├── excel.js │ │ ├── render-dom.js │ │ ├── router-util.js │ │ ├── tools.js │ │ └── util.js │ ├── locale │ │ ├── index.js │ │ └── lang │ │ │ ├── en-US.js │ │ │ ├── zh-CN.js │ │ │ └── zh-TW.js │ ├── main.js │ ├── mixins │ │ └── common.js │ ├── mock │ │ ├── data.js │ │ ├── data │ │ │ ├── org-data.js │ │ │ └── tree-select.js │ │ ├── index.js │ │ ├── login.js │ │ └── user.js │ ├── plugin │ │ ├── error-store │ │ │ └── index.js │ │ └── index.js │ ├── router │ │ ├── before-close.js │ │ ├── index.js │ │ └── routers.js │ ├── store │ │ ├── index.js │ │ └── module │ │ │ ├── app.js │ │ │ └── user.js │ └── view │ │ ├── app │ │ ├── alarm │ │ │ ├── alarmconfig │ │ │ │ ├── Form.vue │ │ │ │ ├── Index.vue │ │ │ │ └── Table.vue │ │ │ ├── alarmjobconfig │ │ │ │ ├── Form.vue │ │ │ │ ├── Index.vue │ │ │ │ └── Table.vue │ │ │ ├── alarmmsg │ │ │ │ ├── Form.vue │ │ │ │ ├── Index.vue │ │ │ │ └── Table.vue │ │ │ ├── alarmsendqueue │ │ │ │ ├── Form.vue │ │ │ │ ├── Index.vue │ │ │ │ └── Table.vue │ │ │ ├── alarmusergroup │ │ │ │ ├── Form.vue │ │ │ │ ├── Index.vue │ │ │ │ └── Table.vue │ │ │ └── opjobsummary │ │ │ │ ├── Alarmdetail.vue │ │ │ │ ├── Errorlist.vue │ │ │ │ ├── Form.vue │ │ │ │ └── Index.vue │ │ └── workflow │ │ │ ├── newworkflow │ │ │ ├── Index.vue │ │ │ └── Table.vue │ │ │ ├── updateworkflow │ │ │ ├── Form.vue │ │ │ ├── Index.vue │ │ │ └── Table.vue │ │ │ └── workflowmanage │ │ │ ├── Form.vue │ │ │ ├── Index.vue │ │ │ └── Table.vue │ │ ├── argu-page │ │ ├── params.vue │ │ └── query.vue │ │ ├── components │ │ ├── count-to │ │ │ └── count-to.vue │ │ ├── cropper │ │ │ └── cropper.vue │ │ ├── drag-drawer │ │ │ └── index.vue │ │ ├── drag-list │ │ │ └── drag-list.vue │ │ ├── editor │ │ │ └── editor.vue │ │ ├── icons │ │ │ └── icons.vue │ │ ├── markdown │ │ │ └── markdown.vue │ │ ├── org-tree │ │ │ ├── components │ │ │ │ ├── org-view.vue │ │ │ │ └── zoom-controller.vue │ │ │ ├── index.less │ │ │ └── index.vue │ │ ├── tables │ │ │ └── tables.vue │ │ ├── tree-select │ │ │ └── index.vue │ │ └── tree-table │ │ │ └── index.vue │ │ ├── directive │ │ └── directive.vue │ │ ├── error-page │ │ ├── 401.vue │ │ ├── 404.vue │ │ ├── 500.vue │ │ ├── back-btn-group.vue │ │ ├── error-content.vue │ │ └── error.less │ │ ├── error-store │ │ └── error-store.vue │ │ ├── excel │ │ ├── common.less │ │ ├── export-excel.vue │ │ └── upload-excel.vue │ │ ├── i18n │ │ └── i18n-page.vue │ │ ├── join-page.vue │ │ ├── login │ │ ├── Register.vue │ │ ├── ResetPasswords.vue │ │ ├── login.less │ │ ├── login.vue │ │ ├── old_login.less │ │ └── old_login.vue │ │ ├── multilevel │ │ ├── level-2-1.vue │ │ ├── level-2-2 │ │ │ ├── level-2-2-1.vue │ │ │ └── level-2-2-2.vue │ │ └── level-2-3.vue │ │ ├── single-page │ │ ├── error-logger.vue │ │ ├── home │ │ │ ├── example.vue │ │ │ ├── home.vue │ │ │ └── index.js │ │ └── message │ │ │ └── index.vue │ │ ├── spdb │ │ ├── authority │ │ │ ├── menu │ │ │ │ ├── Form.vue │ │ │ │ ├── Index.vue │ │ │ │ └── Table.vue │ │ │ ├── role │ │ │ │ ├── Form.vue │ │ │ │ ├── Index.vue │ │ │ │ └── Table.vue │ │ │ └── user │ │ │ │ ├── Form.vue │ │ │ │ ├── Index.vue │ │ │ │ └── Table.vue │ │ ├── job │ │ │ ├── jobComplement │ │ │ │ ├── Index.vue │ │ │ │ ├── JobComplement.vue │ │ │ │ └── Table.vue │ │ │ ├── jobList │ │ │ │ ├── Attr.vue │ │ │ │ ├── Dep.vue │ │ │ │ ├── Downjobs.vue │ │ │ │ ├── Forcestart.vue │ │ │ │ ├── Form.vue │ │ │ │ ├── Frequency.vue │ │ │ │ ├── Index.vue │ │ │ │ ├── Invoke.vue │ │ │ │ ├── JobRecord.vue │ │ │ │ ├── Jobdetail.vue │ │ │ │ ├── Jobimg.vue │ │ │ │ ├── Killjob.vue │ │ │ │ ├── Log.vue │ │ │ │ ├── Script.vue │ │ │ │ ├── Status.vue │ │ │ │ ├── Stream.vue │ │ │ │ ├── Table.vue │ │ │ │ ├── Trigger.vue │ │ │ │ ├── Upjobs.vue │ │ │ │ └── jobimgs │ │ │ │ │ ├── jobRate.vue │ │ │ │ │ ├── lineage.vue │ │ │ │ │ ├── radar.vue │ │ │ │ │ ├── resource.vue │ │ │ │ │ └── timeLevel.vue │ │ │ └── sqlQuery │ │ │ │ ├── Form.vue │ │ │ │ ├── Index.vue │ │ │ │ └── Table.vue │ │ └── systemsetting │ │ │ ├── dictionary │ │ │ ├── Form.vue │ │ │ ├── Index.vue │ │ │ └── Table.vue │ │ │ ├── fileManage │ │ │ ├── Form.vue │ │ │ ├── Index.vue │ │ │ └── Table.vue │ │ │ ├── jobWeight │ │ │ ├── Form.vue │ │ │ ├── Index.vue │ │ │ └── Table.vue │ │ │ ├── operatLog │ │ │ ├── Index.vue │ │ │ └── Table.vue │ │ │ ├── platformConfig │ │ │ ├── Form.vue │ │ │ ├── Index.vue │ │ │ └── Table.vue │ │ │ ├── serverManage │ │ │ ├── Form.vue │ │ │ ├── Index.vue │ │ │ ├── Loglist.vue │ │ │ └── Table.vue │ │ │ └── weightType │ │ │ ├── Form.vue │ │ │ ├── Index.vue │ │ │ └── Table.vue │ │ ├── tools-methods │ │ └── tools-methods.vue │ │ └── update │ │ ├── update-paste.vue │ │ └── update-table.vue ├── tests │ ├── e2e │ │ ├── .eslintrc │ │ ├── plugins │ │ │ └── index.js │ │ ├── specs │ │ │ └── test.js │ │ └── support │ │ │ ├── commands.js │ │ │ └── index.js │ └── unit │ │ ├── .eslintrc.js │ │ └── HelloWorld.spec.js └── vue.config.js ├── harrier部署包.zip ├── k8s ├── docker │ └── Dockerfile └── harrier-k8s.yaml └── pom.xml /.gitignore: -------------------------------------------------------------------------------- 1 | /harrier-api/logs 2 | /harrier-server/logs 3 | logs 4 | static 5 | dist 6 | /target/ 7 | -------------------------------------------------------------------------------- /Harrier_3.0_部署使用说明书.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/spdb-opensource/harrier/eba49fc7869498e5ffd7981fc84c17ca2e932633/Harrier_3.0_部署使用说明书.pdf -------------------------------------------------------------------------------- /harrier-alarm/.gitignore: -------------------------------------------------------------------------------- 1 | /target/ 2 | -------------------------------------------------------------------------------- /harrier-alarm/.project: -------------------------------------------------------------------------------- 1 | 2 | 3 | harrier-alarm 4 | 5 | 6 | 7 | 8 | 9 | org.eclipse.jdt.core.javabuilder 10 | 11 | 12 | 13 | 14 | org.eclipse.m2e.core.maven2Builder 15 | 16 | 17 | 18 | 19 | 20 | org.eclipse.jdt.core.javanature 21 | org.eclipse.m2e.core.maven2Nature 22 | 23 | 24 | -------------------------------------------------------------------------------- /harrier-alarm/.settings/org.eclipse.core.resources.prefs: -------------------------------------------------------------------------------- 1 | eclipse.preferences.version=1 2 | encoding//src/main/java=UTF-8 3 | encoding//src/main/resources=UTF-8 4 | encoding//src/test/java=UTF-8 5 | encoding//src/test/resources=UTF-8 6 | encoding/=UTF-8 7 | -------------------------------------------------------------------------------- /harrier-alarm/.settings/org.eclipse.jdt.core.prefs: -------------------------------------------------------------------------------- 1 | eclipse.preferences.version=1 2 | org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.8 3 | org.eclipse.jdt.core.compiler.compliance=1.8 4 | org.eclipse.jdt.core.compiler.problem.enablePreviewFeatures=disabled 5 | org.eclipse.jdt.core.compiler.problem.forbiddenReference=warning 6 | org.eclipse.jdt.core.compiler.problem.reportPreviewFeatures=ignore 7 | org.eclipse.jdt.core.compiler.release=disabled 8 | org.eclipse.jdt.core.compiler.source=1.8 9 | -------------------------------------------------------------------------------- /harrier-alarm/.settings/org.eclipse.m2e.core.prefs: -------------------------------------------------------------------------------- 1 | activeProfiles= 2 | eclipse.preferences.version=1 3 | resolveWorkspaceProjects=true 4 | version=1 5 | -------------------------------------------------------------------------------- /harrier-alarm/src/main/java/cn/spdb/harrier/alarm/AlarmServer.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.alarm; 2 | 3 | import org.springframework.boot.WebApplicationType; 4 | import org.springframework.boot.autoconfigure.SpringBootApplication; 5 | import org.springframework.boot.builder.SpringApplicationBuilder; 6 | import org.springframework.context.annotation.Bean; 7 | 8 | import cn.spdb.harrier.common.cache.HarrierCache; 9 | import cn.spdb.harrier.common.cache.HarrierCacheImpl; 10 | 11 | 12 | @SpringBootApplication(scanBasePackages = { "cn.spdb.harrier.alarm", "cn.spdb.harrier.dao", 13 | "cn.spdb.harrier.service" }) 14 | public class AlarmServer { 15 | 16 | @Bean("alarm_cache") 17 | public HarrierCache addHarrierCache() { 18 | return new HarrierCacheImpl(); 19 | } 20 | 21 | public static void main(String[] args) { 22 | new SpringApplicationBuilder(AlarmServer.class).web(WebApplicationType.NONE).run(args); 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /harrier-alarm/src/main/java/cn/spdb/harrier/alarm/rpc/transport/AlarmTransportServerInterfasce.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.alarm.rpc.transport; 2 | 3 | import cn.spdb.harrier.dao.entity.MAlarm; 4 | import cn.spdb.harrier.dao.entity.MAlarmSendQueue; 5 | import cn.spdb.harrier.rpc.common.RpcHandler; 6 | import cn.spdb.harrier.rpc.common.RpcMethod; 7 | 8 | @RpcHandler("AlarmTransportServerInterfasce") 9 | public interface AlarmTransportServerInterfasce { 10 | 11 | @RpcMethod 12 | Boolean createAlarm(MAlarm alarm); 13 | 14 | @RpcMethod 15 | Boolean create(MAlarmSendQueue alarmSendQueue); 16 | 17 | } -------------------------------------------------------------------------------- /harrier-alarm/src/main/java/cn/spdb/harrier/alarm/rpc/transport/AlarmTransportService.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.alarm.rpc.transport; 2 | 3 | import cn.spdb.harrier.alarm.AlarmManger; 4 | import cn.spdb.harrier.alarm.AlarmSendManger; 5 | import cn.spdb.harrier.dao.entity.MAlarm; 6 | import cn.spdb.harrier.dao.entity.MAlarmSendQueue; 7 | import cn.spdb.harrier.dao.utils.BeanContext; 8 | import cn.spdb.harrier.rpc.common.RpcServiceHandler; 9 | 10 | @RpcServiceHandler("AlarmTransportServerInterfasce") 11 | public class AlarmTransportService implements AlarmTransportServerInterfasce { 12 | 13 | private static AlarmManger alarmManger = BeanContext.getBean(AlarmManger.class); 14 | private static AlarmSendManger alarmSendManger = BeanContext.getBean(AlarmSendManger.class); 15 | 16 | @Override 17 | public Boolean createAlarm(MAlarm alarm) { 18 | return alarmManger.addAlarm(alarm); 19 | } 20 | 21 | @Override 22 | public Boolean create(MAlarmSendQueue alarmSendQueue) { 23 | alarmSendManger.inserMalarmSend(alarmSendQueue); 24 | return true; 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /harrier-alarm/src/main/java/cn/spdb/harrier/alarm/send/AlarmProcess.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.alarm.send; 2 | 3 | import cn.spdb.harrier.alarm.send.modle.AlarmInfo; 4 | import cn.spdb.harrier.alarm.send.modle.AlarmResult; 5 | 6 | public interface AlarmProcess { 7 | 8 | AlarmResult process(AlarmInfo info); 9 | 10 | 11 | } 12 | -------------------------------------------------------------------------------- /harrier-alarm/src/main/java/cn/spdb/harrier/alarm/send/email/EmailAlarmProcess.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.alarm.send.email; 2 | 3 | import java.util.Map; 4 | 5 | import cn.spdb.harrier.alarm.send.AlarmProcess; 6 | import cn.spdb.harrier.alarm.send.modle.AlarmData; 7 | import cn.spdb.harrier.alarm.send.modle.AlarmInfo; 8 | import cn.spdb.harrier.alarm.send.modle.AlarmResult; 9 | import cn.spdb.harrier.common.enmus.alarm.SendStatus; 10 | 11 | public class EmailAlarmProcess implements AlarmProcess { 12 | 13 | @Override 14 | public AlarmResult process(AlarmInfo info) { 15 | AlarmData alert = info.getAlarmData(); 16 | Map paramsMap = info.getAlertParams(); 17 | if (null == paramsMap) { 18 | return new AlarmResult(SendStatus.FAIL.name(), "mail params is null"); 19 | } 20 | return new EmailSender(paramsMap).sendMails(alert.getTitle(), alert.getContent()); 21 | } 22 | 23 | } 24 | -------------------------------------------------------------------------------- /harrier-alarm/src/main/java/cn/spdb/harrier/alarm/send/email/exception/AlertEmailException.java: -------------------------------------------------------------------------------- 1 | 2 | 3 | package cn.spdb.harrier.alarm.send.email.exception; 4 | 5 | public class AlertEmailException extends RuntimeException { 6 | 7 | /** 8 | * Create Runtime exception 9 | * 10 | * @param errMsg - Error message 11 | */ 12 | public AlertEmailException(String errMsg) { 13 | super(errMsg); 14 | } 15 | 16 | /** 17 | * Create Runtime exception 18 | * 19 | * @param errMsg - Error message 20 | * @param cause - cause 21 | */ 22 | public AlertEmailException(String errMsg, Throwable cause) { 23 | super(errMsg, cause); 24 | } 25 | } 26 | -------------------------------------------------------------------------------- /harrier-alarm/src/main/java/cn/spdb/harrier/alarm/send/http/HttpAlarmProcess.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.alarm.send.http; 2 | 3 | import java.util.Map; 4 | 5 | import cn.spdb.harrier.alarm.send.AlarmProcess; 6 | import cn.spdb.harrier.alarm.send.modle.AlarmData; 7 | import cn.spdb.harrier.alarm.send.modle.AlarmInfo; 8 | import cn.spdb.harrier.alarm.send.modle.AlarmResult; 9 | import cn.spdb.harrier.common.enmus.alarm.SendStatus; 10 | 11 | public class HttpAlarmProcess implements AlarmProcess { 12 | 13 | @Override 14 | public AlarmResult process(AlarmInfo info) { 15 | AlarmData alertData = info.getAlarmData(); 16 | Map paramsMap = info.getAlertParams(); 17 | if (null == paramsMap) { 18 | return new AlarmResult(SendStatus.FAIL.name(), "http params is null"); 19 | } 20 | 21 | return new HttpSender(paramsMap).send(alertData.getContent()); 22 | } 23 | 24 | } 25 | -------------------------------------------------------------------------------- /harrier-alarm/src/main/java/cn/spdb/harrier/alarm/send/modle/AlarmData.java: -------------------------------------------------------------------------------- 1 | 2 | package cn.spdb.harrier.alarm.send.modle; 3 | 4 | /** 5 | * AlertData 6 | */ 7 | public class AlarmData { 8 | 9 | 10 | /** 11 | * title 12 | */ 13 | private String title; 14 | /** 15 | * content 16 | */ 17 | private String content; 18 | 19 | 20 | public String getTitle() { 21 | return title; 22 | } 23 | 24 | public AlarmData setTitle(String title) { 25 | this.title = title; 26 | return this; 27 | } 28 | 29 | public String getContent() { 30 | return content; 31 | } 32 | 33 | public AlarmData setContent(String content) { 34 | this.content = content; 35 | return this; 36 | } 37 | 38 | } 39 | -------------------------------------------------------------------------------- /harrier-alarm/src/main/java/cn/spdb/harrier/alarm/send/modle/AlarmResult.java: -------------------------------------------------------------------------------- 1 | 2 | package cn.spdb.harrier.alarm.send.modle; 3 | 4 | public class AlarmResult { 5 | 6 | private String status; 7 | 8 | private String message; 9 | 10 | public String getStatus() { 11 | return status; 12 | } 13 | 14 | public void setStatus(String status) { 15 | this.status = status; 16 | } 17 | 18 | public String getMessage() { 19 | return message == null ? "" : message; 20 | } 21 | 22 | public void setMessage(String message) { 23 | this.message = message; 24 | } 25 | 26 | public AlarmResult(String status, String message) { 27 | this.status = status; 28 | this.message = message; 29 | } 30 | 31 | public AlarmResult() { 32 | } 33 | } 34 | -------------------------------------------------------------------------------- /harrier-alarm/src/main/java/cn/spdb/harrier/alarm/send/wechat/WeChatAlertConstants.java: -------------------------------------------------------------------------------- 1 | 2 | package cn.spdb.harrier.alarm.send.wechat; 3 | 4 | /** 5 | * WeChatAlertConstants 6 | */ 7 | public class WeChatAlertConstants { 8 | 9 | private WeChatAlertConstants() { 10 | throw new IllegalStateException(WeChatAlertConstants.class.getName()); 11 | } 12 | 13 | static final String MARKDOWN_QUOTE = ">"; 14 | 15 | static final String MARKDOWN_ENTER = "\n"; 16 | 17 | static final String CHARSET = "UTF-8"; 18 | 19 | static final String WE_CHAT_PUSH_URL = "https://qyapi.weixin.qq.com/cgi-bin/message/send?access_token={token}"; 20 | 21 | static final String WE_CHAT_TOKEN_URL = "https://qyapi.weixin.qq.com/cgi-bin/gettoken?corpid={corpId}&corpsecret={secret}"; 22 | } 23 | -------------------------------------------------------------------------------- /harrier-alarm/src/main/java/cn/spdb/harrier/alarm/send/wechat/WechatAlarmProcess.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.alarm.send.wechat; 2 | 3 | import java.util.Map; 4 | 5 | import cn.spdb.harrier.alarm.send.AlarmProcess; 6 | import cn.spdb.harrier.alarm.send.modle.AlarmData; 7 | import cn.spdb.harrier.alarm.send.modle.AlarmInfo; 8 | import cn.spdb.harrier.alarm.send.modle.AlarmResult; 9 | import cn.spdb.harrier.common.enmus.alarm.SendStatus; 10 | 11 | public class WechatAlarmProcess implements AlarmProcess { 12 | 13 | @Override 14 | public AlarmResult process(AlarmInfo info) { 15 | AlarmData alertData = info.getAlarmData(); 16 | Map paramsMap = info.getAlertParams(); 17 | if (null == paramsMap) { 18 | return new AlarmResult(SendStatus.FAIL.name(), "we chat params is null"); 19 | } 20 | return new WeChatSender(paramsMap).sendEnterpriseWeChat(alertData.getTitle(), alertData.getContent()); 21 | 22 | } 23 | 24 | } 25 | -------------------------------------------------------------------------------- /harrier-alarm/src/main/java/cn/spdb/harrier/alarm/send/wechat/exception/WeChatAlertException.java: -------------------------------------------------------------------------------- 1 | 2 | package cn.spdb.harrier.alarm.send.wechat.exception; 3 | 4 | public class WeChatAlertException extends RuntimeException { 5 | 6 | /** 7 | * 8 | */ 9 | private static final long serialVersionUID = 1L; 10 | 11 | /** 12 | * Create Runtime Exception 13 | * 14 | * @param errMsg - Error message 15 | */ 16 | public WeChatAlertException(String errMsg) { 17 | super(errMsg); 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /harrier-api/.gitignore: -------------------------------------------------------------------------------- 1 | /target/ 2 | -------------------------------------------------------------------------------- /harrier-api/.project: -------------------------------------------------------------------------------- 1 | 2 | 3 | harrier-api 4 | 5 | 6 | 7 | 8 | 9 | org.eclipse.jdt.core.javabuilder 10 | 11 | 12 | 13 | 14 | org.eclipse.m2e.core.maven2Builder 15 | 16 | 17 | 18 | 19 | 20 | org.eclipse.jdt.core.javanature 21 | org.eclipse.m2e.core.maven2Nature 22 | 23 | 24 | -------------------------------------------------------------------------------- /harrier-api/.settings/org.eclipse.core.resources.prefs: -------------------------------------------------------------------------------- 1 | eclipse.preferences.version=1 2 | encoding//src/main/java=UTF-8 3 | encoding//src/main/resources=UTF-8 4 | encoding//src/test/java=UTF-8 5 | encoding//src/test/resources=UTF-8 6 | encoding/=UTF-8 7 | -------------------------------------------------------------------------------- /harrier-api/.settings/org.eclipse.jdt.core.prefs: -------------------------------------------------------------------------------- 1 | eclipse.preferences.version=1 2 | org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.8 3 | org.eclipse.jdt.core.compiler.compliance=1.8 4 | org.eclipse.jdt.core.compiler.problem.enablePreviewFeatures=disabled 5 | org.eclipse.jdt.core.compiler.problem.forbiddenReference=warning 6 | org.eclipse.jdt.core.compiler.problem.reportPreviewFeatures=ignore 7 | org.eclipse.jdt.core.compiler.release=disabled 8 | org.eclipse.jdt.core.compiler.source=1.8 9 | -------------------------------------------------------------------------------- /harrier-api/.settings/org.eclipse.m2e.core.prefs: -------------------------------------------------------------------------------- 1 | activeProfiles= 2 | eclipse.preferences.version=1 3 | resolveWorkspaceProjects=true 4 | version=1 5 | -------------------------------------------------------------------------------- /harrier-api/src/main/java/cn/spdb/harrier/api/ApiServer.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.api; 2 | 3 | import org.springframework.boot.autoconfigure.SpringBootApplication; 4 | import org.springframework.boot.builder.SpringApplicationBuilder; 5 | import org.springframework.boot.web.servlet.ServletComponentScan; 6 | import org.springframework.context.annotation.Bean; 7 | import org.springframework.context.annotation.Primary; 8 | 9 | import cn.spdb.harrier.common.cache.HarrierCache; 10 | import cn.spdb.harrier.common.cache.HarrierCacheImpl; 11 | 12 | @SpringBootApplication(scanBasePackages = { "cn.spdb.harrier.api", "cn.spdb.harrier.service", "cn.spdb.harrier.dao" }) 13 | @ServletComponentScan 14 | public class ApiServer { 15 | 16 | @Primary 17 | @Bean("api-cache") 18 | public HarrierCache addHarrierCache() { 19 | return new HarrierCacheImpl(); 20 | } 21 | 22 | public static void main(String[] args) { 23 | new SpringApplicationBuilder(ApiServer.class).run(args); 24 | } 25 | } 26 | -------------------------------------------------------------------------------- /harrier-api/src/main/java/cn/spdb/harrier/api/MonitorApplication.java: -------------------------------------------------------------------------------- 1 | 2 | package cn.spdb.harrier.api; 3 | 4 | import org.springframework.boot.autoconfigure.SpringBootApplication; 5 | import org.springframework.boot.builder.SpringApplicationBuilder; 6 | 7 | import cn.spdb.harrier.alarm.AlarmServer; 8 | 9 | @SpringBootApplication 10 | public class MonitorApplication { 11 | 12 | public static void main(String[] args) { 13 | new SpringApplicationBuilder(ApiServer.class,AlarmServer.class).run(args); 14 | } 15 | 16 | } 17 | -------------------------------------------------------------------------------- /harrier-api/src/main/java/cn/spdb/harrier/api/aspect/AccessLogAnnotation.java: -------------------------------------------------------------------------------- 1 | 2 | package cn.spdb.harrier.api.aspect; 3 | 4 | import java.lang.annotation.Documented; 5 | import java.lang.annotation.ElementType; 6 | import java.lang.annotation.Retention; 7 | import java.lang.annotation.RetentionPolicy; 8 | import java.lang.annotation.Target; 9 | 10 | @Target(ElementType.METHOD) 11 | @Retention(RetentionPolicy.RUNTIME) 12 | @Documented 13 | public @interface AccessLogAnnotation { 14 | // ignore request args 15 | String[] ignoreRequestArgs() default {}; 16 | 17 | boolean ignoreRequest() default false; 18 | 19 | boolean ignoreResponse() default true; 20 | 21 | boolean isDbInstall() default false; 22 | 23 | String job() default ""; 24 | 25 | } 26 | -------------------------------------------------------------------------------- /harrier-api/src/main/java/cn/spdb/harrier/api/aspect/DataScope.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.api.aspect; 2 | 3 | import java.lang.annotation.Documented; 4 | import java.lang.annotation.ElementType; 5 | import java.lang.annotation.Retention; 6 | import java.lang.annotation.RetentionPolicy; 7 | import java.lang.annotation.Target; 8 | 9 | /** 10 | * 数据权限过滤注解 11 | * 12 | * @author ruoyi 13 | */ 14 | @Target(ElementType.METHOD) 15 | @Retention(RetentionPolicy.RUNTIME) 16 | @Documented 17 | public @interface DataScope { 18 | 19 | public String tableAlias() default ""; 20 | 21 | 22 | public String plaftormAlias() default "platform"; 23 | 24 | 25 | public String systemsAlias() default "systems"; 26 | 27 | } 28 | -------------------------------------------------------------------------------- /harrier-api/src/main/java/cn/spdb/harrier/api/controller/develop/package-info.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.api.controller.develop; -------------------------------------------------------------------------------- /harrier-api/src/main/java/cn/spdb/harrier/api/enums/ExecuteType.java: -------------------------------------------------------------------------------- 1 | 2 | package cn.spdb.harrier.api.enums; 3 | 4 | /** 5 | * execute type 6 | */ 7 | public enum ExecuteType { 8 | 9 | 10 | /** 11 | * operation type 12 | * 1 repeat running 13 | * 2 resume pause 14 | * 3 resume failure 15 | * 4 stop 16 | * 5 pause 17 | */ 18 | NONE, REPEAT_RUNNING, RECOVER_SUSPENDED_PROCESS, START_FAILURE_TASK_PROCESS, STOP, PAUSE; 19 | 20 | 21 | public static ExecuteType getEnum(int value){ 22 | for (ExecuteType e: ExecuteType.values()) { 23 | if(e.ordinal() == value) { 24 | return e; 25 | } 26 | } 27 | return null; 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /harrier-api/src/main/java/cn/spdb/harrier/api/enums/PermissionStatus.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.api.enums; 2 | 3 | public enum PermissionStatus { 4 | R("R"), W("W"), RW("RW"); 5 | 6 | private String status; 7 | 8 | private PermissionStatus(String status) { 9 | this.status = status; 10 | } 11 | 12 | public String getStatus() { 13 | return status; 14 | } 15 | 16 | public void setStatus(String status) { 17 | this.status = status; 18 | } 19 | 20 | } 21 | -------------------------------------------------------------------------------- /harrier-api/src/main/java/cn/spdb/harrier/api/exceptions/ApiException.java: -------------------------------------------------------------------------------- 1 | 2 | package cn.spdb.harrier.api.exceptions; 3 | 4 | import static java.lang.annotation.ElementType.METHOD; 5 | import static java.lang.annotation.RetentionPolicy.RUNTIME; 6 | 7 | import java.lang.annotation.Retention; 8 | import java.lang.annotation.Target; 9 | 10 | import cn.spdb.harrier.api.enums.Status; 11 | 12 | /** 13 | * controller exception annotation 14 | */ 15 | @Retention(RUNTIME) 16 | @Target(METHOD) 17 | public @interface ApiException { 18 | Status value(); 19 | } 20 | -------------------------------------------------------------------------------- /harrier-api/src/main/java/cn/spdb/harrier/api/exceptions/ServiceException.java: -------------------------------------------------------------------------------- 1 | 2 | package cn.spdb.harrier.api.exceptions; 3 | 4 | import cn.spdb.harrier.api.enums.Status; 5 | 6 | 7 | /** 8 | * service exception 9 | */ 10 | public class ServiceException extends RuntimeException { 11 | 12 | /** 13 | * code 14 | */ 15 | private Integer code; 16 | 17 | public ServiceException() { 18 | } 19 | 20 | public ServiceException(Status status) { 21 | super(status.getMsg()); 22 | this.code = status.getCode(); 23 | } 24 | 25 | public ServiceException(Integer code,String message) { 26 | super(message); 27 | this.code = code; 28 | } 29 | 30 | public ServiceException(String message) { 31 | super(message); 32 | } 33 | 34 | public Integer getCode() { 35 | return this.code; 36 | } 37 | 38 | public void setCode(Integer code) { 39 | this.code = code; 40 | } 41 | } -------------------------------------------------------------------------------- /harrier-api/src/main/java/cn/spdb/harrier/api/interceptor/RepeatSubmit.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.api.interceptor; 2 | 3 | import java.lang.annotation.Documented; 4 | import java.lang.annotation.ElementType; 5 | import java.lang.annotation.Inherited; 6 | import java.lang.annotation.Retention; 7 | import java.lang.annotation.RetentionPolicy; 8 | import java.lang.annotation.Target; 9 | 10 | import cn.spdb.harrier.api.enums.Status; 11 | 12 | /** 13 | * 自定义注解防止表单重复提交 14 | * 15 | * @author ruoyi 16 | * 17 | */ 18 | @Inherited 19 | @Target(ElementType.METHOD) 20 | @Retention(RetentionPolicy.RUNTIME) 21 | @Documented 22 | public @interface RepeatSubmit 23 | { 24 | /** 25 | * 间隔时间(ms),小于此时间视为重复提交 26 | */ 27 | public int interval() default 5000; 28 | 29 | /** 30 | * 提示消息 31 | */ 32 | public Status message() default Status.SUBMIT_AGAIN; 33 | } 34 | -------------------------------------------------------------------------------- /harrier-api/src/main/java/cn/spdb/harrier/api/model/RegisterBody.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.api.model; 2 | 3 | /** 4 | * 用户注册对象 5 | * 6 | * @author ruoyi 7 | */ 8 | public class RegisterBody extends LoginBody 9 | { 10 | 11 | /** 12 | * 用户邮箱 13 | */ 14 | private String userEmail; 15 | 16 | public String getUserEmail() { 17 | return userEmail; 18 | } 19 | 20 | public void setUserEmail(String userEmail) { 21 | this.userEmail = userEmail; 22 | } 23 | 24 | 25 | } 26 | -------------------------------------------------------------------------------- /harrier-api/src/main/java/cn/spdb/harrier/api/rpc/transport/MasterTransportServerInterfasce.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.api.rpc.transport; 2 | 3 | import java.util.List; 4 | 5 | import cn.spdb.harrier.common.model.JobSignal; 6 | import cn.spdb.harrier.dao.entity.UdsComplement; 7 | import cn.spdb.harrier.rpc.common.RpcHandler; 8 | import cn.spdb.harrier.rpc.common.RpcMethod; 9 | 10 | @RpcHandler("MasterTransportServerInterfasce") 11 | public interface MasterTransportServerInterfasce { 12 | @RpcMethod 13 | Boolean streamJobSignal(JobSignal jobSignal); 14 | 15 | @RpcMethod 16 | Boolean complementJob(List jobList, UdsComplement complement); 17 | 18 | @RpcMethod 19 | String command(String cmd, String... args); 20 | 21 | } -------------------------------------------------------------------------------- /harrier-api/src/main/java/cn/spdb/harrier/api/rpc/transport/WorkTransportServerInterface.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.api.rpc.transport; 2 | 3 | import cn.spdb.harrier.rpc.common.RpcHandler; 4 | import cn.spdb.harrier.rpc.common.RpcMethod; 5 | 6 | @RpcHandler("WorkTransportServerInterface") 7 | public interface WorkTransportServerInterface { 8 | 9 | @RpcMethod 10 | Boolean killJob(Long taskInstanceId); 11 | } -------------------------------------------------------------------------------- /harrier-api/src/main/java/cn/spdb/harrier/api/service/alarm/MAlarmConfigService.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.api.service.alarm; 2 | 3 | import cn.spdb.harrier.dao.entity.MAlarmConfig; 4 | import java.util.List; 5 | 6 | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; 7 | 8 | public interface MAlarmConfigService { 9 | /** 10 | *新增 11 | */ 12 | int add(MAlarmConfig record); 13 | 14 | /** 15 | *id删除 16 | */ 17 | int delete(Integer id,String platfrom); 18 | 19 | /** 20 | *修改 21 | */ 22 | int update(MAlarmConfig record); 23 | 24 | /** 25 | *查看详情 26 | */ 27 | MAlarmConfig getDetail(Integer id); 28 | 29 | /** 30 | *未完成的列表查询,待完善 31 | */ 32 | List listQuery(); 33 | 34 | Page search(Page page, String platfrom, String system, String job, String code); 35 | 36 | Page searchJobConfig(Page page, String platfrom, String system, String job, String code); 37 | } -------------------------------------------------------------------------------- /harrier-api/src/main/java/cn/spdb/harrier/api/service/alarm/MAlarmMsgService.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.api.service.alarm; 2 | 3 | import cn.spdb.harrier.dao.entity.MAlarmMsg; 4 | import java.util.List; 5 | 6 | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; 7 | 8 | public interface MAlarmMsgService { 9 | /** 10 | *新增 11 | */ 12 | int add(MAlarmMsg record); 13 | 14 | /** 15 | *id删除 16 | */ 17 | int delete(Integer id); 18 | 19 | /** 20 | *修改 21 | */ 22 | int update(MAlarmMsg record); 23 | 24 | /** 25 | *查看详情 26 | */ 27 | MAlarmMsg getDetail(Integer id); 28 | 29 | /** 30 | *未完成的列表查询,待完善 31 | */ 32 | List listQuery(); 33 | 34 | Page search(Page page, String platfrom, String system, String code); 35 | } -------------------------------------------------------------------------------- /harrier-api/src/main/java/cn/spdb/harrier/api/service/alarm/MAlarmSendQueueService.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.api.service.alarm; 2 | 3 | import cn.spdb.harrier.dao.entity.MAlarmSendQueue; 4 | import java.util.List; 5 | 6 | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; 7 | 8 | public interface MAlarmSendQueueService { 9 | /** 10 | *新增 11 | */ 12 | int add(MAlarmSendQueue record); 13 | 14 | /** 15 | *id删除 16 | */ 17 | int delete(Long id); 18 | 19 | /** 20 | *修改 21 | */ 22 | int update(MAlarmSendQueue record); 23 | 24 | /** 25 | *查看详情 26 | */ 27 | MAlarmSendQueue getDetail(Long id); 28 | 29 | /** 30 | *未完成的列表查询,待完善 31 | */ 32 | List listQuery(); 33 | 34 | Page search(Page page); 35 | 36 | } -------------------------------------------------------------------------------- /harrier-api/src/main/java/cn/spdb/harrier/api/service/alarm/MAlarmUserGroupService.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.api.service.alarm; 2 | 3 | import cn.spdb.harrier.dao.entity.MAlarmUserGroup; 4 | import java.util.List; 5 | 6 | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; 7 | 8 | public interface MAlarmUserGroupService { 9 | /** 10 | *新增 11 | */ 12 | int add(MAlarmUserGroup record); 13 | 14 | /** 15 | *id删除 16 | */ 17 | int delete(Integer id); 18 | 19 | /** 20 | *修改 21 | */ 22 | int update(MAlarmUserGroup record); 23 | 24 | /** 25 | *查看详情 26 | */ 27 | MAlarmUserGroup getDetail(Integer id); 28 | 29 | /** 30 | *未完成的列表查询,待完善 31 | */ 32 | List listQuery(); 33 | 34 | Page search(Page page, String groupName); 35 | 36 | List getDetailByGroupName(String groupName); 37 | } -------------------------------------------------------------------------------- /harrier-api/src/main/java/cn/spdb/harrier/api/service/complement/UdsComplementService.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.api.service.complement; 2 | 3 | import cn.spdb.harrier.dao.entity.UdsComplement; 4 | import cn.spdb.harrier.dao.entity.UdsJobComplement; 5 | 6 | import java.util.List; 7 | 8 | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; 9 | 10 | public interface UdsComplementService { 11 | /** 12 | *新增 13 | */ 14 | int add(UdsComplement record); 15 | 16 | /** 17 | *id删除 18 | */ 19 | int delete(Long id); 20 | 21 | /** 22 | *修改 23 | */ 24 | int update(UdsComplement record); 25 | 26 | /** 27 | *查看详情 28 | */ 29 | UdsComplement getDetail(Long id); 30 | 31 | /** 32 | *未完成的列表查询,待完善 33 | */ 34 | List listQuery(); 35 | 36 | /** 37 | * 补数记录—查询所有记录(分页) 38 | */ 39 | Page selectAll(Page page, String comName); 40 | 41 | } -------------------------------------------------------------------------------- /harrier-api/src/main/java/cn/spdb/harrier/api/service/complement/UdsJobComplementService.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.api.service.complement; 2 | 3 | import cn.spdb.harrier.dao.entity.UdsJobComplement; 4 | 5 | import java.util.List; 6 | 7 | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; 8 | 9 | public interface UdsJobComplementService { 10 | /** 11 | *新增 12 | */ 13 | int add(UdsJobComplement record); 14 | 15 | /** 16 | *id删除 17 | */ 18 | int delete(Long id); 19 | 20 | /** 21 | *修改 22 | */ 23 | int update(UdsJobComplement record); 24 | 25 | /** 26 | *查看详情 27 | */ 28 | UdsJobComplement getDetail(Long id); 29 | 30 | /** 31 | *未完成的列表查询,待完善 32 | */ 33 | List listQuery(); 34 | 35 | /** 36 | * 补数记录—查询所有记录(分页) 37 | */ 38 | Page selectAll(Page page, String platform, String systems, String job, String last_status,Long complementId); 39 | 40 | } -------------------------------------------------------------------------------- /harrier-api/src/main/java/cn/spdb/harrier/api/service/develop/IDeployScriptService.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.api.service.develop; 2 | 3 | import cn.spdb.harrier.dao.entity.DyJobArrange; 4 | 5 | public interface IDeployScriptService { 6 | boolean deployScript(DyJobArrange dyJobArrange); 7 | } 8 | -------------------------------------------------------------------------------- /harrier-api/src/main/java/cn/spdb/harrier/api/service/develop/IDeploySqlCreate.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.api.service.develop; 2 | 3 | import java.util.List; 4 | 5 | import cn.spdb.harrier.api.model.JobYamlObject; 6 | 7 | public interface IDeploySqlCreate { 8 | 9 | /** 10 | * 新增作业SQL 11 | * @param jobConfig 12 | * @return 13 | */ 14 | List newJobSql(JobYamlObject jobConfig); 15 | 16 | /** 17 | * 变更作业SQL 18 | * @param jobConfig 19 | * @return 20 | */ 21 | List updateJobSql(JobYamlObject jobConfig); 22 | 23 | /** 24 | * 下线作业SQL 25 | * @param jobConfig 26 | * @return 27 | */ 28 | List deleteJobSql(JobYamlObject jobConfig); 29 | 30 | } -------------------------------------------------------------------------------- /harrier-api/src/main/java/cn/spdb/harrier/api/service/develop/IDeploySqlService.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.api.service.develop; 2 | 3 | import java.util.List; 4 | 5 | import cn.spdb.harrier.dao.entity.DyJobArrange; 6 | 7 | public interface IDeploySqlService { 8 | /** 9 | * 根据作业编排信息生成知识库部署SQL 10 | * @param dyJobArrange 11 | * @return 12 | */ 13 | boolean deploySqlGenerate(DyJobArrange dyJobArrange); 14 | 15 | /** 16 | * 执行sql 17 | * @param contextList 18 | * @return 19 | */ 20 | int[] sqlExecute(List contextList); 21 | 22 | /** 23 | * 部署回退 24 | * @param dyJobArrange 25 | * @return 26 | */ 27 | boolean rollBack(DyJobArrange dyJobArrange); 28 | } 29 | -------------------------------------------------------------------------------- /harrier-api/src/main/java/cn/spdb/harrier/api/service/firstpage/Stats.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.api.service.firstpage; 2 | 3 | import java.util.Date; 4 | import java.util.List; 5 | import java.util.Map; 6 | 7 | public interface Stats { 8 | //平台总数 9 | long SumPlatforms(); 10 | //应用总数 11 | long SumSystems(); 12 | //未完成平台总数 13 | long SumUndonePlatforms(); 14 | //未完成应用总数 15 | long SumUndoneSystems(); 16 | //作业总数 17 | long SumJobs(); 18 | //未完成作业总数 19 | long SumUndoneJobs(); 20 | //集群资源利用率统计 21 | List> ServerResourceInfo(); 22 | //各平台应用作业总量 23 | List> sumAllPatformJob(); 24 | //平台作业时刻运行情况统计 25 | Map> platformJobStatus(String platform,Date Start,Date end); 26 | //节点作业时刻运行情况统计 27 | Map> ServerJobStatus (String servername,Date start,Date end); 28 | //查询平台 29 | List ListAllPlatform(); 30 | //查询子节点 31 | List ListAllWorker(); 32 | 33 | } 34 | -------------------------------------------------------------------------------- /harrier-api/src/main/java/cn/spdb/harrier/api/service/job/CustomSqlService.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.api.service.job; 2 | 3 | import java.util.List; 4 | import java.util.Map; 5 | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; 6 | 7 | 8 | public interface CustomSqlService { 9 | int updateExec(String updateSql); 10 | int deleteExec(String deleteSql); 11 | int insertExec(String insertSql); 12 | List> execSelect(int pageCurrent, int pageSize, String selectSql); 13 | int execSelectCount(String selectSql); 14 | } 15 | -------------------------------------------------------------------------------- /harrier-api/src/main/java/cn/spdb/harrier/api/service/job/UdsJobConfigService.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.api.service.job; 2 | 3 | import cn.spdb.harrier.dao.entity.UdsJobConfig; 4 | import java.util.List; 5 | 6 | public interface UdsJobConfigService { 7 | /** 8 | *新增 9 | */ 10 | int add(UdsJobConfig record); 11 | 12 | /** 13 | *id删除 14 | */ 15 | int delete(Long id); 16 | 17 | /** 18 | *修改 19 | */ 20 | int update(UdsJobConfig record); 21 | 22 | /** 23 | *查看详情 24 | */ 25 | UdsJobConfig getDetail(Long id); 26 | 27 | /** 28 | *未完成的列表查询,待完善 29 | */ 30 | List listQuery(); 31 | 32 | /** 33 | * 启用禁用 34 | */ 35 | int setEnable(String platform_,String systems_,String job_,Boolean enable_); 36 | 37 | /** 38 | * 置实置虚 39 | */ 40 | int setVirtual(String platform_,String systems_,String job_,Boolean virtual_); 41 | } -------------------------------------------------------------------------------- /harrier-api/src/main/java/cn/spdb/harrier/api/service/job/UdsJobDateFrequencyService.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.api.service.job; 2 | 3 | import cn.spdb.harrier.dao.entity.UdsJobDateFrequency; 4 | import java.util.List; 5 | 6 | public interface UdsJobDateFrequencyService { 7 | /** 8 | *新增 9 | */ 10 | int add(UdsJobDateFrequency record); 11 | 12 | /** 13 | *id删除 14 | */ 15 | int delete(Long id); 16 | 17 | /** 18 | *修改 19 | */ 20 | int update(UdsJobDateFrequency record); 21 | 22 | /** 23 | *查看详情 24 | */ 25 | UdsJobDateFrequency getDetail(Long id); 26 | 27 | /** 28 | *未完成的列表查询,待完善 29 | */ 30 | List listQuery(); 31 | 32 | /** 33 | * 作业列表-查询作业频度 34 | */ 35 | UdsJobDateFrequency selectJobFrequency(String platform_, String system_, String job_); 36 | 37 | } -------------------------------------------------------------------------------- /harrier-api/src/main/java/cn/spdb/harrier/api/service/job/UdsJobDependencyService.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.api.service.job; 2 | 3 | import cn.spdb.harrier.dao.entity.UdsJobDependency; 4 | import java.util.List; 5 | 6 | public interface UdsJobDependencyService { 7 | /** 8 | *新增 9 | */ 10 | int add(UdsJobDependency record); 11 | 12 | /** 13 | *id删除 14 | */ 15 | int delete(Long id); 16 | 17 | /** 18 | *修改 19 | */ 20 | int update(UdsJobDependency record); 21 | 22 | /** 23 | *查看详情 24 | */ 25 | UdsJobDependency getDetail(Long id); 26 | 27 | /** 28 | *未完成的列表查询,待完善 29 | */ 30 | List listQuery(); 31 | 32 | /** 33 | * 启用禁用依赖 34 | */ 35 | int setDepEnable(String pjob, String job_, Boolean enable_); 36 | } -------------------------------------------------------------------------------- /harrier-api/src/main/java/cn/spdb/harrier/api/service/job/UdsJobRecordService.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.api.service.job; 2 | 3 | import cn.spdb.harrier.dao.entity.UdsJobDateFrequency; 4 | import cn.spdb.harrier.dao.entity.UdsJobRecord; 5 | import java.util.List; 6 | 7 | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; 8 | 9 | public interface UdsJobRecordService { 10 | /** 11 | *新增 12 | */ 13 | int add(UdsJobRecord record); 14 | 15 | /** 16 | *id删除 17 | */ 18 | int delete(Long id); 19 | 20 | /** 21 | *修改 22 | */ 23 | int update(UdsJobRecord record); 24 | 25 | /** 26 | *查看详情 27 | */ 28 | UdsJobRecord getDetail(Long id); 29 | 30 | /** 31 | *未完成的列表查询,待完善 32 | */ 33 | List listQuery(); 34 | 35 | /** 36 | * 作业列表-查询作业运行记录 37 | */ 38 | Page selectJobRecord(Page page, String platform_, String system_, String job_); 39 | 40 | } -------------------------------------------------------------------------------- /harrier-api/src/main/java/cn/spdb/harrier/api/service/job/UdsJobSourceService.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.api.service.job; 2 | 3 | import cn.spdb.harrier.dao.entity.UdsJobSource; 4 | import java.util.List; 5 | 6 | public interface UdsJobSourceService { 7 | /** 8 | *新增 9 | */ 10 | int add(UdsJobSource record); 11 | 12 | /** 13 | *id删除 14 | */ 15 | int delete(Long id); 16 | 17 | /** 18 | *修改 19 | */ 20 | int update(UdsJobSource record); 21 | 22 | /** 23 | *查看详情 24 | */ 25 | UdsJobSource getDetail(Long id); 26 | 27 | /** 28 | *未完成的列表查询,待完善 29 | */ 30 | List listQuery(); 31 | } -------------------------------------------------------------------------------- /harrier-api/src/main/java/cn/spdb/harrier/api/service/job/UdsJobStepRecordService.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.api.service.job; 2 | 3 | import cn.spdb.harrier.dao.entity.UdsJobStepRecord; 4 | import java.util.List; 5 | 6 | public interface UdsJobStepRecordService { 7 | /** 8 | *新增 9 | */ 10 | int add(UdsJobStepRecord record); 11 | 12 | /** 13 | *id删除 14 | */ 15 | int delete(Long id); 16 | 17 | /** 18 | *修改 19 | */ 20 | int update(UdsJobStepRecord record); 21 | 22 | /** 23 | *查看详情 24 | */ 25 | UdsJobStepRecord getDetail(Long id); 26 | 27 | /** 28 | *未完成的列表查询,待完善 29 | */ 30 | List listQuery(); 31 | 32 | /** 33 | * 作业列表-查询作业脚本运行记录 34 | */ 35 | List selectJobStepRecord(Long job_record_id); 36 | } -------------------------------------------------------------------------------- /harrier-api/src/main/java/cn/spdb/harrier/api/service/job/UdsJobStepService.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.api.service.job; 2 | 3 | import cn.spdb.harrier.common.utils.URI; 4 | import cn.spdb.harrier.dao.entity.UdsJobStep; 5 | import cn.spdb.harrier.rpc.transport.File.FileMessage; 6 | 7 | import java.util.List; 8 | 9 | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; 10 | 11 | public interface UdsJobStepService { 12 | /** 13 | * 新增 14 | */ 15 | int add(UdsJobStep record); 16 | 17 | /** 18 | * id删除 19 | */ 20 | int delete(Long id); 21 | 22 | /** 23 | * 修改 24 | */ 25 | int update(UdsJobStep record); 26 | 27 | /** 28 | * 查看详情 29 | */ 30 | UdsJobStep getDetail(Long id); 31 | 32 | /** 33 | * 未完成的列表查询,待完善 34 | */ 35 | List listQuery(); 36 | 37 | Page selectJobStepList(Page page, String platform, String system, String job); 38 | 39 | FileMessage downloadResource(URI stepURI, Long streamId, Long pos, Long size); 40 | 41 | UdsJobStep downloadJobStep(String platform, String system, String job, Byte index); 42 | } -------------------------------------------------------------------------------- /harrier-api/src/main/java/cn/spdb/harrier/api/service/job/UdsJobTimeTriggerService.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.api.service.job; 2 | 3 | import cn.spdb.harrier.dao.entity.UdsJobTimeTrigger; 4 | import java.util.List; 5 | 6 | public interface UdsJobTimeTriggerService { 7 | /** 8 | *新增 9 | */ 10 | int add(UdsJobTimeTrigger record); 11 | 12 | /** 13 | *id删除 14 | */ 15 | int delete(Long id); 16 | 17 | /** 18 | *修改 19 | */ 20 | int update(UdsJobTimeTrigger record); 21 | 22 | /** 23 | *查看详情 24 | */ 25 | UdsJobTimeTrigger getDetail(Long id); 26 | 27 | /** 28 | *未完成的列表查询,待完善 29 | */ 30 | List listQuery(); 31 | 32 | UdsJobTimeTrigger selectJobTrigger(String platform, String system, String job); 33 | } -------------------------------------------------------------------------------- /harrier-api/src/main/java/cn/spdb/harrier/api/service/job/UdsJobWeightLimitService.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.api.service.job; 2 | 3 | import cn.spdb.harrier.dao.entity.UdsJobWeightLimit; 4 | import java.util.List; 5 | 6 | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; 7 | 8 | public interface UdsJobWeightLimitService { 9 | /** 10 | *新增 11 | */ 12 | int add(UdsJobWeightLimit record); 13 | 14 | /** 15 | *id删除 16 | */ 17 | int delete(Long id); 18 | 19 | /** 20 | *修改 21 | */ 22 | int update(UdsJobWeightLimit record); 23 | 24 | /** 25 | *查看详情 26 | */ 27 | UdsJobWeightLimit getDetail(Long id); 28 | 29 | /** 30 | *未完成的列表查询,待完善 31 | */ 32 | List listQuery(); 33 | 34 | Page selectAll(Page page, Integer limit_type); 35 | 36 | int updateWeightLimit(Integer limit_type, Integer limit_value, String serverIds_, String timeWindows); 37 | 38 | int delete(Long[] ids); 39 | } -------------------------------------------------------------------------------- /harrier-api/src/main/java/cn/spdb/harrier/api/service/job/UdsJobWeightService.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.api.service.job; 2 | 3 | import cn.spdb.harrier.dao.entity.UdsJobWeight; 4 | import java.util.List; 5 | 6 | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; 7 | 8 | public interface UdsJobWeightService { 9 | /** 10 | *新增 11 | */ 12 | int add(UdsJobWeight record); 13 | 14 | /** 15 | *id删除 16 | */ 17 | int delete(Long id); 18 | 19 | /** 20 | *修改 21 | */ 22 | int update(UdsJobWeight record); 23 | 24 | /** 25 | *查看详情 26 | */ 27 | UdsJobWeight getDetail(Long id); 28 | 29 | /** 30 | *未完成的列表查询,待完善 31 | */ 32 | List listQuery(); 33 | 34 | Page selectAll(Page page,String platform,String systems,String job, Integer limitType); 35 | 36 | int updateConfValue(String platform_, String systems_, String job_, Integer limit_type, Integer conf_value); 37 | 38 | int delete(Long[] ids); 39 | } -------------------------------------------------------------------------------- /harrier-api/src/main/java/cn/spdb/harrier/api/service/system/FileDisposeService.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.api.service.system; 2 | 3 | import java.util.List; 4 | 5 | import cn.spdb.harrier.common.utils.URI; 6 | import cn.spdb.harrier.rpc.transport.File.FileAtt; 7 | import cn.spdb.harrier.rpc.transport.File.FileMessage; 8 | 9 | public interface FileDisposeService { 10 | 11 | Boolean deleteFile(URI uri); 12 | 13 | boolean createDir(URI uri); 14 | 15 | List selectFile(URI uri,String fileName,String order); 16 | 17 | FileMessage loadFile(URI uri, Long streamId, Long pos, Long size); 18 | 19 | FileMessage uploadFile(URI uri, Long streamId, Long pos, byte[] data); 20 | 21 | } -------------------------------------------------------------------------------- /harrier-api/src/main/java/cn/spdb/harrier/api/service/system/ISysConfigService.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.api.service.system; 2 | 3 | public interface ISysConfigService { 4 | 5 | boolean selectCaptchaOnOff(String key); 6 | 7 | Object selectConfigByKey(String string); 8 | 9 | } 10 | -------------------------------------------------------------------------------- /harrier-api/src/main/java/cn/spdb/harrier/api/service/system/ISysRoleService.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.api.service.system; 2 | 3 | import java.util.List; 4 | 5 | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; 6 | 7 | import cn.spdb.harrier.dao.entity.MRole; 8 | 9 | public interface ISysRoleService { 10 | 11 | List rolesByUserid(Long userId); 12 | 13 | List rolesByUserCode(String userCode); 14 | 15 | Page search(Page page,String roleName); 16 | 17 | MRole load(Integer roleId); 18 | 19 | int add(MRole role); 20 | 21 | boolean update(MRole role); 22 | 23 | int delete(Integer roleId); 24 | 25 | int allotMenus(Integer roleId, Integer[] menuIds); 26 | 27 | int delete(Integer[] ids); 28 | } 29 | -------------------------------------------------------------------------------- /harrier-api/src/main/java/cn/spdb/harrier/api/service/system/MDictionaryService.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.api.service.system; 2 | 3 | import cn.spdb.harrier.dao.entity.MDictionary; 4 | import java.util.List; 5 | 6 | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; 7 | 8 | public interface MDictionaryService { 9 | /** 10 | *新增 11 | */ 12 | int add(MDictionary record); 13 | 14 | /** 15 | *id删除 16 | */ 17 | int delete(Long id); 18 | 19 | /** 20 | *修改 21 | */ 22 | int update(MDictionary record); 23 | 24 | /** 25 | *查看详情 26 | */ 27 | MDictionary getDetail(Long id); 28 | 29 | /** 30 | *未完成的列表查询,待完善 31 | */ 32 | List listQuery(); 33 | 34 | List selectDicCode(String dicCode, String dicKey); 35 | 36 | Page search(Page page, String dicCode, String dicKey); 37 | 38 | /** 39 | * 删除字典 40 | */ 41 | int delete(Long[] ids); 42 | } -------------------------------------------------------------------------------- /harrier-api/src/main/java/cn/spdb/harrier/api/service/system/MOperatLogService.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.api.service.system; 2 | 3 | import java.util.List; 4 | 5 | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; 6 | 7 | import cn.spdb.harrier.dao.entity.MOperatLog; 8 | 9 | public interface MOperatLogService { 10 | 11 | /** 12 | *未完成的列表查询,待完善 13 | */ 14 | List listQuery(); 15 | 16 | Page search(Page page, String userCode, String operatType, String job); 17 | 18 | } 19 | -------------------------------------------------------------------------------- /harrier-api/src/main/java/cn/spdb/harrier/api/service/system/impl/MOperatLogServiceImpl.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.api.service.system.impl; 2 | 3 | import java.util.List; 4 | 5 | import org.springframework.beans.factory.annotation.Autowired; 6 | import org.springframework.stereotype.Service; 7 | 8 | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; 9 | 10 | import cn.spdb.harrier.api.service.system.MOperatLogService; 11 | import cn.spdb.harrier.dao.entity.MOperatLog; 12 | import cn.spdb.harrier.dao.mapper.MOperatLogMapper; 13 | 14 | @Service 15 | public class MOperatLogServiceImpl implements MOperatLogService { 16 | @Autowired 17 | private MOperatLogMapper mapper; 18 | 19 | @Override 20 | public List listQuery() { 21 | return mapper.select( c -> c ); 22 | } 23 | 24 | @Override 25 | public Page search(Page page, String userCode, String operatType, String job){ 26 | return mapper.selectAll(page, userCode, operatType, job); 27 | } 28 | 29 | } 30 | -------------------------------------------------------------------------------- /harrier-api/src/main/java/cn/spdb/harrier/api/utils/JobDeployPath.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.api.utils; 2 | 3 | public enum JobDeployPath { 4 | // 路径相关 5 | UPLOAD_SCRIPT_PATH("脚本上传路径", "./job/project/dev"), 6 | COMPRESS_TEMP_PATH("压缩临时路径", "./job/project/compress"), 7 | UPLOAD_DEPLOY_TEMP_PATH("导入工程临时路径", "./job/project/deploy"); 8 | 9 | // 路径名称 10 | private String key; 11 | // 路径值 12 | private String value; 13 | 14 | // 构造 15 | private JobDeployPath(String key, String value) { 16 | this.key = key; 17 | this.value = value; 18 | } 19 | 20 | public String getKey() { 21 | return key; 22 | } 23 | 24 | public void setKey(String key) { 25 | this.key = key; 26 | } 27 | 28 | public String getValue() { 29 | return value; 30 | } 31 | 32 | public void setValue(String value) { 33 | this.value = value; 34 | } 35 | } 36 | -------------------------------------------------------------------------------- /harrier-api/src/main/java/cn/spdb/harrier/api/utils/JobDeployStatus.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.api.utils; 2 | 3 | public enum JobDeployStatus { 4 | // 变更状态相关 5 | UPDATE_ADD("新增", 1), 6 | UPDATE_CHANGE("变更", 2), 7 | UPDATE_DEL("下线", 3), 8 | 9 | // 任务状态相关 10 | PROCESS_REDAY("待投产", 1), 11 | PROCESS_FAILED("投产失败", 2), 12 | PROCESS_SUCCESS("投产成功", 3), 13 | 14 | // 同步状态相关 15 | SYN_COMMON("正常线上开发无需同步", 0), 16 | SYN_SUCCESS("同步成功", 1), 17 | SYN_FAILED("同步失败", 2), 18 | 19 | // 作业触发类型 20 | STREAM_JOB("作业触发", 0), 21 | STREAM_CRON("定时触发", 1), 22 | STREAM_SIGNAL("信号文件触发", 2), 23 | STREAM_HTTP("http请求触发", 3); 24 | 25 | 26 | private JobDeployStatus(String key, Integer value) { 27 | this.key = key; 28 | this.value = value; 29 | } 30 | // 标识 31 | private String key; 32 | // 值 33 | private Integer value; 34 | 35 | public String getKey() { 36 | return key; 37 | } 38 | public void setKey(String key) { 39 | this.key = key; 40 | } 41 | public Integer getValue() { 42 | return value; 43 | } 44 | public void setValue(Integer value) { 45 | this.value = value; 46 | } 47 | 48 | 49 | } 50 | -------------------------------------------------------------------------------- /harrier-api/src/main/resources/application.properties: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/spdb-opensource/harrier/eba49fc7869498e5ffd7981fc84c17ca2e932633/harrier-api/src/main/resources/application.properties -------------------------------------------------------------------------------- /harrier-api/src/main/resources/i18n/messages.properties: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/spdb-opensource/harrier/eba49fc7869498e5ffd7981fc84c17ca2e932633/harrier-api/src/main/resources/i18n/messages.properties -------------------------------------------------------------------------------- /harrier-api/src/main/resources/i18n/messages_en_US.properties: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/spdb-opensource/harrier/eba49fc7869498e5ffd7981fc84c17ca2e932633/harrier-api/src/main/resources/i18n/messages_en_US.properties -------------------------------------------------------------------------------- /harrier-api/src/main/resources/i18n/messages_zh_CN.properties: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/spdb-opensource/harrier/eba49fc7869498e5ffd7981fc84c17ca2e932633/harrier-api/src/main/resources/i18n/messages_zh_CN.properties -------------------------------------------------------------------------------- /harrier-api/src/test/java/cn/spdb/harrier/api/http/HttpClientTest.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.api.http; 2 | 3 | import java.util.HashMap; 4 | 5 | import org.junit.Test; 6 | 7 | import cn.spdb.harrier.api.AbstractHttpClientTest; 8 | import cn.spdb.harrier.common.utils.HttpUtils; 9 | 10 | public class HttpClientTest extends AbstractHttpClientTest { 11 | 12 | @Test 13 | public void getMrole() { 14 | 15 | HashMap param = new HashMap(); 16 | // param.put("platfrom", "BDP"); 17 | // param.put("systems", "*"); 18 | String str = HttpUtils.sendGetHttp("http://127.0.0.1:12345/harrier/menu", headerMap, param); 19 | System.out.println(str); 20 | str = HttpUtils.sendGetHttp("http://127.0.0.1:12345/harrier/menu", headerMap, param); 21 | System.out.println(str); 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /harrier-api/src/test/java/cn/spdb/harrier/api/mock/SysMenuControllerTest.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.api.mock; 2 | 3 | import org.junit.Test; 4 | 5 | import cn.spdb.harrier.api.AbstractControllerTest; 6 | 7 | public class SysMenuControllerTest extends AbstractControllerTest { 8 | 9 | @Test 10 | public void test() { 11 | 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /harrier-common/.gitignore: -------------------------------------------------------------------------------- 1 | /target/ 2 | -------------------------------------------------------------------------------- /harrier-common/.project: -------------------------------------------------------------------------------- 1 | 2 | 3 | harrier-common 4 | 5 | 6 | 7 | 8 | 9 | org.eclipse.jdt.core.javabuilder 10 | 11 | 12 | 13 | 14 | org.eclipse.m2e.core.maven2Builder 15 | 16 | 17 | 18 | 19 | 20 | org.eclipse.jdt.core.javanature 21 | org.eclipse.m2e.core.maven2Nature 22 | 23 | 24 | -------------------------------------------------------------------------------- /harrier-common/.settings/org.eclipse.core.resources.prefs: -------------------------------------------------------------------------------- 1 | eclipse.preferences.version=1 2 | encoding//src/main/java=UTF-8 3 | encoding//src/main/resources=UTF-8 4 | encoding//src/test/java=UTF-8 5 | encoding//src/test/resources=UTF-8 6 | encoding/=UTF-8 7 | -------------------------------------------------------------------------------- /harrier-common/.settings/org.eclipse.jdt.core.prefs: -------------------------------------------------------------------------------- 1 | eclipse.preferences.version=1 2 | org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.8 3 | org.eclipse.jdt.core.compiler.compliance=1.8 4 | org.eclipse.jdt.core.compiler.problem.enablePreviewFeatures=disabled 5 | org.eclipse.jdt.core.compiler.problem.forbiddenReference=warning 6 | org.eclipse.jdt.core.compiler.problem.reportPreviewFeatures=ignore 7 | org.eclipse.jdt.core.compiler.release=disabled 8 | org.eclipse.jdt.core.compiler.source=1.8 9 | -------------------------------------------------------------------------------- /harrier-common/.settings/org.eclipse.m2e.core.prefs: -------------------------------------------------------------------------------- 1 | activeProfiles= 2 | eclipse.preferences.version=1 3 | resolveWorkspaceProjects=true 4 | version=1 5 | -------------------------------------------------------------------------------- /harrier-common/src/main/java/cn/spdb/harrier/common/Application.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.common; 2 | 3 | public class Application { 4 | 5 | public static void main(String[] args) { 6 | throw new IllegalStateException("is not execute jar"); 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /harrier-common/src/main/java/cn/spdb/harrier/common/CommandConstant.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.common; 2 | 3 | public class CommandConstant { 4 | 5 | public static final String MASTER="master"; 6 | public static final String WORKER="worker"; 7 | public static final String ALL = "all"; 8 | public static final String SUCCESS = "success"; 9 | public static final String FAIL = "fail"; 10 | 11 | 12 | 13 | public static final String LOAD_SYSTEM = "LoadSystem"; 14 | 15 | } 16 | -------------------------------------------------------------------------------- /harrier-common/src/main/java/cn/spdb/harrier/common/cache/HarrierCache.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.common.cache; 2 | 3 | import java.util.concurrent.Callable; 4 | 5 | public interface HarrierCache { 6 | 7 | T get(String key); 8 | 9 | void put(String key, Object object); 10 | 11 | void delete(String verifyKey); 12 | 13 | T get(String key, Callable call); 14 | } 15 | -------------------------------------------------------------------------------- /harrier-common/src/main/java/cn/spdb/harrier/common/constants/alarm/HttpAlertConstants.java: -------------------------------------------------------------------------------- 1 | 2 | package cn.spdb.harrier.common.constants.alarm; 3 | 4 | public class HttpAlertConstants { 5 | 6 | private HttpAlertConstants() { 7 | } 8 | 9 | public static final String URL = "url"; 10 | 11 | public static final String HEADER_PARAMS = "headerParams"; 12 | 13 | public static final String BODY_PARAMS = "bodyParams"; 14 | 15 | public static final String CONTENT_FIELD = "contentField"; 16 | 17 | public static final String REQUEST_TYPE = "requestType"; 18 | 19 | } 20 | -------------------------------------------------------------------------------- /harrier-common/src/main/java/cn/spdb/harrier/common/dynamicjava/CharSequenceJavaFileObject.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.common.dynamicjava; 2 | 3 | import java.io.IOException; 4 | import java.net.URI; 5 | 6 | import javax.tools.SimpleJavaFileObject; 7 | 8 | public class CharSequenceJavaFileObject extends SimpleJavaFileObject { 9 | 10 | private CharSequence content; 11 | 12 | public static CharSequenceJavaFileObject build(URI uri ,CharSequence content){ 13 | CharSequenceJavaFileObject object=new CharSequenceJavaFileObject(uri, Kind.SOURCE); 14 | object.setContent(content); 15 | return object; 16 | } 17 | 18 | 19 | @Override 20 | public CharSequence getCharContent(boolean ignoreEncodingErrors) 21 | throws IOException { 22 | return content; 23 | } 24 | 25 | protected CharSequenceJavaFileObject(URI uri, Kind kind) { 26 | super(uri, kind); 27 | } 28 | 29 | public CharSequence getContent() { 30 | return content; 31 | } 32 | 33 | public void setContent(CharSequence content) { 34 | this.content = content; 35 | } 36 | 37 | } 38 | -------------------------------------------------------------------------------- /harrier-common/src/main/java/cn/spdb/harrier/common/dynamicjava/JavaClassObject.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.common.dynamicjava; 2 | 3 | import java.io.ByteArrayOutputStream; 4 | import java.io.IOException; 5 | import java.io.OutputStream; 6 | import java.net.URI; 7 | 8 | import javax.tools.SimpleJavaFileObject; 9 | 10 | public class JavaClassObject extends SimpleJavaFileObject { 11 | 12 | protected final ByteArrayOutputStream bosArrayOutputStream = new ByteArrayOutputStream(); 13 | 14 | public static JavaClassObject buildJavaClassObject(String name, Kind kind) { 15 | URI uri = URI.create("file:///" + name.replace(".", "/") + kind.extension); 16 | return new JavaClassObject(uri, kind); 17 | } 18 | 19 | protected JavaClassObject(URI uri, Kind kind) { 20 | super(uri, kind); 21 | } 22 | 23 | public byte[] getBytes() { 24 | return bosArrayOutputStream.toByteArray(); 25 | } 26 | 27 | @Override 28 | public OutputStream openOutputStream() throws IOException { 29 | return bosArrayOutputStream; 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /harrier-common/src/main/java/cn/spdb/harrier/common/enmus/DownLoadResourceProtocol.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.common.enmus; 2 | 3 | public enum DownLoadResourceProtocol { 4 | HTTP("http"), HTTPS("https"), SCP("scp"), AWS("aws"), SPDB("spdb"),LOCAL("local"); 5 | 6 | private String name; 7 | 8 | private DownLoadResourceProtocol(String name) { 9 | this.name = name; 10 | } 11 | 12 | public String getName() { 13 | return name; 14 | } 15 | 16 | public void setName(String name) { 17 | this.name = name; 18 | } 19 | 20 | public static DownLoadResourceProtocol valueNaeOf(String name) { 21 | for (DownLoadResourceProtocol protocol : DownLoadResourceProtocol.values()) { 22 | if (protocol.getName().equals(name)) { 23 | return protocol; 24 | } 25 | } 26 | return null; 27 | } 28 | 29 | } 30 | -------------------------------------------------------------------------------- /harrier-common/src/main/java/cn/spdb/harrier/common/enmus/RegistryState.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.common.enmus; 2 | 3 | public enum RegistryState { 4 | CONNECTED, RECONNECTED, SUSPENDED, DISCONNECTED, UPDATE_PARA; 5 | } 6 | -------------------------------------------------------------------------------- /harrier-common/src/main/java/cn/spdb/harrier/common/enmus/StreamType.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.common.enmus; 2 | 3 | public enum StreamType { 4 | TIMING_STREAM((byte) 1, "定时任务"), SINGN_FILE((byte) 2, "信号文件"), HTTP((byte) 3, "HTTP请求"), JOB_STREAM((byte) 4, "作业触发"), INVOKE_STREAM((byte) 5, "置Pending"), 5 | FORCE_START((byte) 6, "补数"),SELF_JOB_STREAM((byte) 7,"自检测触发"),DEP_CHANGE_STREAM((byte) 8,"修改依赖触发"); 6 | 7 | private Byte id; 8 | private String name; 9 | 10 | private StreamType(Byte id, String name) { 11 | this.id = id; 12 | this.name = name; 13 | } 14 | 15 | public Byte getId() { 16 | return id; 17 | } 18 | 19 | public void setId(Byte id) { 20 | this.id = id; 21 | } 22 | 23 | public String getName() { 24 | return name; 25 | } 26 | 27 | public void setName(String name) { 28 | this.name = name; 29 | } 30 | 31 | } 32 | -------------------------------------------------------------------------------- /harrier-common/src/main/java/cn/spdb/harrier/common/enmus/UdsJobType.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.common.enmus; 2 | 3 | public enum UdsJobType { 4 | 5 | D,W,M,Y,C,; 6 | } 7 | -------------------------------------------------------------------------------- /harrier-common/src/main/java/cn/spdb/harrier/common/enmus/alarm/AlarmCode.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.common.enmus.alarm; 2 | 3 | public enum AlarmCode { 4 | INFO,WARN,SYSTEM, DB_ERROR, JOB_ERROR, JOB_WARN; 5 | 6 | } 7 | -------------------------------------------------------------------------------- /harrier-common/src/main/java/cn/spdb/harrier/common/enmus/alarm/AlarmLevel.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.common.enmus.alarm; 2 | 3 | public enum AlarmLevel { 4 | L, M, H; 5 | } 6 | -------------------------------------------------------------------------------- /harrier-common/src/main/java/cn/spdb/harrier/common/enmus/alarm/AlarmStatus.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.common.enmus.alarm; 2 | 3 | public enum AlarmStatus { 4 | HIDE("HIDE"), INFO("INFO"), WARN("WARN"), DEAL("DEAL"), END("END"); 5 | 6 | private AlarmStatus(String msg) { 7 | this.name = msg; 8 | } 9 | 10 | private String name; 11 | 12 | public String getName() { 13 | return name; 14 | } 15 | 16 | public void setName(String msg) { 17 | this.name = msg; 18 | } 19 | 20 | public static AlarmStatus indexOf(String name) { 21 | for (AlarmStatus state : values()) { 22 | if (state.getName().equals(name)) { 23 | return state; 24 | } 25 | } 26 | return null; 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /harrier-common/src/main/java/cn/spdb/harrier/common/enmus/alarm/SendStatus.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.common.enmus.alarm; 2 | 3 | public enum SendStatus { 4 | NEW("NEW"),SENDING("SENDING"),STOP("STOP"),SUCC("SUCC"),FAIL("FAIL"); 5 | 6 | private String name; 7 | 8 | private SendStatus(String name) { 9 | this.name = name; 10 | } 11 | 12 | public String getName() { 13 | return name; 14 | } 15 | 16 | public void setName(String name) { 17 | this.name = name; 18 | } 19 | 20 | 21 | 22 | } 23 | -------------------------------------------------------------------------------- /harrier-common/src/main/java/cn/spdb/harrier/common/enmus/alarm/ShowType.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.common.enmus.alarm; 2 | 3 | 4 | public enum ShowType { 5 | /** 6 | * 0 TABLE; 7 | * 1 TEXT; 8 | * 2 attachment; 9 | * 3 TABLE+attachment; 10 | */ 11 | TABLE(0, "table"), 12 | TEXT(1, "text"), 13 | ATTACHMENT(2, "attachment"), 14 | TABLEAT_TACHMENT(3, "table attachment"); 15 | 16 | ShowType(int code, String descp) { 17 | this.code = code; 18 | this.descp = descp; 19 | } 20 | 21 | private final int code; 22 | private final String descp; 23 | 24 | public int getCode() { 25 | return code; 26 | } 27 | 28 | public String getDescp() { 29 | return descp; 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /harrier-common/src/main/java/cn/spdb/harrier/common/log/AlarmLogFilter.java: -------------------------------------------------------------------------------- 1 | 2 | package cn.spdb.harrier.common.log; 3 | 4 | import ch.qos.logback.classic.Level; 5 | import ch.qos.logback.classic.spi.ILoggingEvent; 6 | import ch.qos.logback.core.filter.Filter; 7 | import ch.qos.logback.core.spi.FilterReply; 8 | 9 | public class AlarmLogFilter extends Filter { 10 | 11 | private Level level = Level.INFO; 12 | 13 | public void setLevel(String level) { 14 | this.level = Level.toLevel(level); 15 | } 16 | 17 | @Override 18 | public FilterReply decide(ILoggingEvent event) { 19 | if ((event.getThreadName().startsWith("Alarm") 20 | ||event.getLoggerName().startsWith("Alarm")) 21 | && event.getLevel().isGreaterOrEqual(level)) { 22 | return FilterReply.ACCEPT; 23 | } 24 | return FilterReply.DENY; 25 | } 26 | 27 | } -------------------------------------------------------------------------------- /harrier-common/src/main/java/cn/spdb/harrier/common/log/MasterLogFilter.java: -------------------------------------------------------------------------------- 1 | 2 | package cn.spdb.harrier.common.log; 3 | 4 | import ch.qos.logback.classic.Level; 5 | import ch.qos.logback.classic.spi.ILoggingEvent; 6 | import ch.qos.logback.core.filter.Filter; 7 | import ch.qos.logback.core.spi.FilterReply; 8 | 9 | public class MasterLogFilter extends Filter { 10 | 11 | private Level level = Level.INFO; 12 | 13 | public void setLevel(String level) { 14 | this.level = Level.toLevel(level); 15 | } 16 | 17 | @Override 18 | public FilterReply decide(ILoggingEvent event) { 19 | if ((event.getThreadName().startsWith("Master") || event.getLoggerName().startsWith("Master")) 20 | && event.getLevel().isGreaterOrEqual(level)) { 21 | return FilterReply.ACCEPT; 22 | } 23 | return FilterReply.DENY; 24 | } 25 | 26 | } -------------------------------------------------------------------------------- /harrier-common/src/main/java/cn/spdb/harrier/common/log/MonitorLogFilter.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.common.log; 2 | 3 | import ch.qos.logback.classic.Level; 4 | import ch.qos.logback.classic.spi.ILoggingEvent; 5 | import ch.qos.logback.core.filter.Filter; 6 | import ch.qos.logback.core.spi.FilterReply; 7 | 8 | public class MonitorLogFilter extends Filter { 9 | private Level level = Level.INFO; 10 | public void setLevel(String level) { 11 | this.level = Level.toLevel(level); 12 | } 13 | @Override 14 | public FilterReply decide(ILoggingEvent event) { 15 | if((event.getThreadName().startsWith("Monitor") 16 | || event.getLoggerName().startsWith("Monitor")) 17 | && event.getLevel().isGreaterOrEqual(level)) { 18 | return FilterReply.ACCEPT; 19 | } 20 | return FilterReply.DENY; 21 | } 22 | 23 | } 24 | -------------------------------------------------------------------------------- /harrier-common/src/main/java/cn/spdb/harrier/common/log/OtherLogFilter.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.common.log; 2 | 3 | import ch.qos.logback.classic.Level; 4 | import ch.qos.logback.classic.spi.ILoggingEvent; 5 | import ch.qos.logback.core.filter.Filter; 6 | import ch.qos.logback.core.spi.FilterReply; 7 | import cn.spdb.harrier.common.utils.LoggerUtils; 8 | 9 | public class OtherLogFilter extends Filter { 10 | private Level level = Level.INFO; 11 | public void setLevel(String level) { 12 | this.level = Level.toLevel(level); 13 | } 14 | @Override 15 | public FilterReply decide(ILoggingEvent event) { 16 | if(event.getThreadName().startsWith("Master") 17 | ||event.getThreadName().startsWith("Worker") 18 | ||event.getLoggerName().startsWith(LoggerUtils.TASK_STEP_LOGGER_PREFIX) 19 | ||!event.getLevel().isGreaterOrEqual(level)) { 20 | return FilterReply.DENY; 21 | } 22 | return FilterReply.ACCEPT; 23 | } 24 | 25 | } 26 | -------------------------------------------------------------------------------- /harrier-common/src/main/java/cn/spdb/harrier/common/log/TaskLogDiscriminator.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.common.log; 2 | 3 | import ch.qos.logback.classic.spi.ILoggingEvent; 4 | import ch.qos.logback.core.sift.AbstractDiscriminator; 5 | import cn.spdb.harrier.common.utils.LoggerUtils; 6 | 7 | public class TaskLogDiscriminator extends AbstractDiscriminator { 8 | 9 | private String key; 10 | 11 | @Override 12 | public String getDiscriminatingValue(ILoggingEvent event) { 13 | String loggerName = event.getLoggerName(); 14 | String prefix = LoggerUtils.TASK_STEP_LOGGER_PREFIX; 15 | if (loggerName.startsWith(prefix)) { 16 | return loggerName.substring(prefix.length(), loggerName.length() - 1); 17 | } else { 18 | return "unknown_task"; 19 | } 20 | } 21 | 22 | @Override 23 | public void start() { 24 | started = true; 25 | } 26 | 27 | @Override 28 | public String getKey() { 29 | return key; 30 | } 31 | 32 | public void setKey(String key) { 33 | this.key = key; 34 | } 35 | 36 | } 37 | -------------------------------------------------------------------------------- /harrier-common/src/main/java/cn/spdb/harrier/common/log/TaskLogFilter.java: -------------------------------------------------------------------------------- 1 | 2 | package cn.spdb.harrier.common.log; 3 | 4 | import ch.qos.logback.classic.Level; 5 | import ch.qos.logback.classic.spi.ILoggingEvent; 6 | import ch.qos.logback.core.filter.Filter; 7 | import ch.qos.logback.core.spi.FilterReply; 8 | import cn.spdb.harrier.common.utils.LoggerUtils; 9 | 10 | /** 11 | * task log filter 12 | */ 13 | public class TaskLogFilter extends Filter { 14 | 15 | 16 | private Level level=Level.INFO; 17 | 18 | public void setLevel(String level) { 19 | this.level = Level.toLevel(level); 20 | } 21 | 22 | @Override 23 | public FilterReply decide(ILoggingEvent event) { 24 | if (event.getLoggerName().startsWith(LoggerUtils.TASK_STEP_LOGGER_PREFIX) 25 | &&event.getLevel().isGreaterOrEqual(level) 26 | ) { 27 | return FilterReply.ACCEPT; 28 | } 29 | return FilterReply.DENY; 30 | } 31 | 32 | } -------------------------------------------------------------------------------- /harrier-common/src/main/java/cn/spdb/harrier/common/log/WorkerLogFilter.java: -------------------------------------------------------------------------------- 1 | 2 | package cn.spdb.harrier.common.log; 3 | 4 | import ch.qos.logback.classic.Level; 5 | import ch.qos.logback.classic.spi.ILoggingEvent; 6 | import ch.qos.logback.core.filter.Filter; 7 | import ch.qos.logback.core.spi.FilterReply; 8 | 9 | public class WorkerLogFilter extends Filter { 10 | 11 | private Level level = Level.INFO; 12 | 13 | public void setLevel(String level) { 14 | this.level = Level.toLevel(level); 15 | } 16 | 17 | @Override 18 | public FilterReply decide(ILoggingEvent event) { 19 | if ((event.getThreadName().startsWith("Worker") 20 | ||event.getLoggerName().startsWith("Worker")) 21 | && event.getLevel().isGreaterOrEqual(level)) { 22 | return FilterReply.ACCEPT; 23 | } 24 | return FilterReply.DENY; 25 | } 26 | 27 | } -------------------------------------------------------------------------------- /harrier-common/src/main/java/cn/spdb/harrier/common/utils/FileUtils.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.common.utils; 2 | 3 | import java.io.File; 4 | import java.util.ArrayList; 5 | import java.util.List; 6 | 7 | public class FileUtils extends org.apache.commons.io.FileUtils { 8 | 9 | public static Boolean isExists(String path) { 10 | File file = new File(path); 11 | return file.exists(); 12 | } 13 | 14 | public static Boolean isFile(String path) { 15 | File file = new File(path); 16 | return file.isFile(); 17 | } 18 | 19 | public static Boolean isFileAndExists(String path) { 20 | File file = new File(path); 21 | return file.exists() && file.isFile(); 22 | } 23 | 24 | public static Boolean createDirectory(String path) { 25 | File directory = new File(path); 26 | if (!directory.exists()) { 27 | if (!directory.mkdirs()) { 28 | if (directory.isDirectory()) { 29 | return true; 30 | } 31 | } 32 | } 33 | return false; 34 | } 35 | 36 | } 37 | -------------------------------------------------------------------------------- /harrier-common/src/main/java/cn/spdb/harrier/common/utils/Stopper.java: -------------------------------------------------------------------------------- 1 | 2 | package cn.spdb.harrier.common.utils; 3 | 4 | import java.util.concurrent.atomic.AtomicBoolean; 5 | 6 | /** 7 | * if the process closes, a signal is placed as true, and all threads get this flag to stop working 8 | */ 9 | public class Stopper { 10 | 11 | private static AtomicBoolean signal = new AtomicBoolean(false); 12 | 13 | public static final boolean isStopped(){ 14 | return signal.get(); 15 | } 16 | 17 | public static final boolean isRunning(){ 18 | return !signal.get(); 19 | } 20 | 21 | public static final void stop(){ 22 | signal.set(true); 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /harrier-common/src/main/java/cn/spdb/harrier/common/utils/StringUtils.java: -------------------------------------------------------------------------------- 1 | 2 | package cn.spdb.harrier.common.utils; 3 | 4 | public class StringUtils extends org.apache.commons.lang3.StringUtils { 5 | public static final String EMPTY = ""; 6 | 7 | public static boolean isEmpty(final String cs) { 8 | return cs == null || cs.length() == 0; 9 | } 10 | 11 | public static boolean isNotEmpty(final String cs) { 12 | return !isEmpty(cs); 13 | } 14 | 15 | public static boolean isBlank(String s) { 16 | if (isEmpty(s)) { 17 | return true; 18 | } 19 | return s.trim().length() == 0; 20 | } 21 | 22 | public static boolean isNotBlank(String s) { 23 | return !isBlank(s); 24 | } 25 | 26 | public static boolean inStringIgnoreCase(String str, String... strs) { 27 | if (str != null && strs != null) { 28 | for (String s : strs) { 29 | if (str.equalsIgnoreCase(s.trim())) { 30 | return true; 31 | } 32 | } 33 | } 34 | return false; 35 | } 36 | } 37 | -------------------------------------------------------------------------------- /harrier-common/src/test/java/cn/spdb/harrier/common/test/DagTest.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.common.test; 2 | 3 | import org.junit.Test; 4 | 5 | import cn.spdb.harrier.common.model.DAG; 6 | 7 | public class DagTest { 8 | 9 | private static DAG dag=new DAG(); 10 | 11 | @Test 12 | public void load() { 13 | dag.addNode("A", "A1"); 14 | dag.addNode("B", "B2"); 15 | dag.addNode("C", "C3"); 16 | dag.addNode("D", "D4"); 17 | dag.addNode("E", "E5"); 18 | dag.addNode("F", "F5"); 19 | 20 | dag.addEdge("A", "B", 1, false); 21 | dag.addEdge("A", "C", 2, false); 22 | dag.addEdge("B", "D", 3, false); 23 | dag.addEdge("C", "D", 4, false); 24 | dag.addEdge("D", "E", 5, false); 25 | 26 | System.out.println(dag.getBeginNode()); 27 | System.out.println(dag.getEndNode()); 28 | System.out.println(dag.getInDegree("D")); 29 | System.out.println(dag.getPreviousNodes("D")); 30 | System.out.println(dag.getSubsequentNodes("D")); 31 | 32 | } 33 | 34 | } 35 | -------------------------------------------------------------------------------- /harrier-dao/.gitignore: -------------------------------------------------------------------------------- 1 | /target/ 2 | -------------------------------------------------------------------------------- /harrier-dao/.project: -------------------------------------------------------------------------------- 1 | 2 | 3 | harrier-dao 4 | 5 | 6 | 7 | 8 | 9 | org.eclipse.jdt.core.javabuilder 10 | 11 | 12 | 13 | 14 | org.eclipse.m2e.core.maven2Builder 15 | 16 | 17 | 18 | 19 | 20 | org.eclipse.jdt.core.javanature 21 | org.eclipse.m2e.core.maven2Nature 22 | 23 | 24 | -------------------------------------------------------------------------------- /harrier-dao/.settings/org.eclipse.core.resources.prefs: -------------------------------------------------------------------------------- 1 | eclipse.preferences.version=1 2 | encoding//src/main/java=UTF-8 3 | encoding//src/main/resources=UTF-8 4 | encoding//src/test/java=UTF-8 5 | encoding//src/test/resources=UTF-8 6 | encoding/=UTF-8 7 | -------------------------------------------------------------------------------- /harrier-dao/.settings/org.eclipse.jdt.core.prefs: -------------------------------------------------------------------------------- 1 | eclipse.preferences.version=1 2 | org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.8 3 | org.eclipse.jdt.core.compiler.compliance=1.8 4 | org.eclipse.jdt.core.compiler.problem.enablePreviewFeatures=disabled 5 | org.eclipse.jdt.core.compiler.problem.forbiddenReference=warning 6 | org.eclipse.jdt.core.compiler.problem.reportPreviewFeatures=ignore 7 | org.eclipse.jdt.core.compiler.release=disabled 8 | org.eclipse.jdt.core.compiler.source=1.8 9 | -------------------------------------------------------------------------------- /harrier-dao/.settings/org.eclipse.m2e.core.prefs: -------------------------------------------------------------------------------- 1 | activeProfiles= 2 | eclipse.preferences.version=1 3 | resolveWorkspaceProjects=true 4 | version=1 5 | -------------------------------------------------------------------------------- /harrier-dao/src/main/java/cn/spdb/harrier/dao/Application.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.dao; 2 | 3 | public class Application { 4 | 5 | public static void main(String[] args) { 6 | throw new IllegalStateException("is not execute jar"); 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /harrier-dao/src/main/java/cn/spdb/harrier/dao/entity/UserSystemPermiss.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.dao.entity; 2 | 3 | public class UserSystemPermiss { 4 | 5 | private Long userId; 6 | private String platform; 7 | private String systems; 8 | private String permissions; 9 | 10 | public Long getUserId() { 11 | return userId; 12 | } 13 | public void setUserId(Long userId) { 14 | this.userId = userId; 15 | } 16 | public String getPlatform() { 17 | return platform; 18 | } 19 | public void setPlatform(String platform) { 20 | this.platform = platform; 21 | } 22 | public String getSystems() { 23 | return systems; 24 | } 25 | public void setSystems(String systems) { 26 | this.systems = systems; 27 | } 28 | public String getPermissions() { 29 | return permissions; 30 | } 31 | public void setPermissions(String permissions) { 32 | this.permissions = permissions; 33 | } 34 | 35 | } 36 | -------------------------------------------------------------------------------- /harrier-dao/src/main/resources/redis.properties: -------------------------------------------------------------------------------- 1 | spring.redis.host= 2 | spring.redis.port= 3 | #spring.redis.password= 4 | #spring.redis.timeout= 5 | #spring.redis.database= 6 | #spring.redis.pool.max-active= 7 | #spring.redis.pool.max-idle= 8 | #spring.redis.pool.max-wait= 9 | #spring.redis.pool.min-idle= -------------------------------------------------------------------------------- /harrier-rpc/.gitignore: -------------------------------------------------------------------------------- 1 | /target/ 2 | -------------------------------------------------------------------------------- /harrier-rpc/.project: -------------------------------------------------------------------------------- 1 | 2 | 3 | harrier-rpc 4 | 5 | 6 | 7 | 8 | 9 | org.eclipse.jdt.core.javabuilder 10 | 11 | 12 | 13 | 14 | org.eclipse.m2e.core.maven2Builder 15 | 16 | 17 | 18 | 19 | 20 | org.eclipse.jdt.core.javanature 21 | org.eclipse.m2e.core.maven2Nature 22 | 23 | 24 | -------------------------------------------------------------------------------- /harrier-rpc/.settings/org.eclipse.core.resources.prefs: -------------------------------------------------------------------------------- 1 | eclipse.preferences.version=1 2 | encoding//src/main/java=UTF-8 3 | encoding//src/main/resources=UTF-8 4 | encoding//src/test/java=UTF-8 5 | encoding//src/test/resources=UTF-8 6 | encoding/=UTF-8 7 | -------------------------------------------------------------------------------- /harrier-rpc/.settings/org.eclipse.jdt.core.prefs: -------------------------------------------------------------------------------- 1 | eclipse.preferences.version=1 2 | org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.8 3 | org.eclipse.jdt.core.compiler.compliance=1.8 4 | org.eclipse.jdt.core.compiler.problem.enablePreviewFeatures=disabled 5 | org.eclipse.jdt.core.compiler.problem.forbiddenReference=warning 6 | org.eclipse.jdt.core.compiler.problem.reportPreviewFeatures=ignore 7 | org.eclipse.jdt.core.compiler.release=disabled 8 | org.eclipse.jdt.core.compiler.source=1.8 9 | -------------------------------------------------------------------------------- /harrier-rpc/.settings/org.eclipse.m2e.core.prefs: -------------------------------------------------------------------------------- 1 | activeProfiles= 2 | eclipse.preferences.version=1 3 | resolveWorkspaceProjects=true 4 | version=1 5 | -------------------------------------------------------------------------------- /harrier-rpc/src/main/java/cn/spdb/harrier/rpc/Application.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.rpc; 2 | 3 | public class Application { 4 | 5 | public static void main(String[] args) { 6 | throw new IllegalStateException("is not execute jar"); 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /harrier-rpc/src/main/java/cn/spdb/harrier/rpc/client/ConsumerConfigCache.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.rpc.client; 2 | 3 | import java.util.concurrent.ConcurrentHashMap; 4 | 5 | public class ConsumerConfigCache { 6 | 7 | private static ConcurrentHashMap concurrentHashMap = new ConcurrentHashMap(); 8 | 9 | public static ConsumerConfig getConfigByServersName(String handlerMethName) { 10 | return concurrentHashMap.get(handlerMethName); 11 | } 12 | 13 | public static void putConfig(String handlerMethName,ConsumerConfig consumerConfig) { 14 | concurrentHashMap.putIfAbsent(handlerMethName, consumerConfig); 15 | } 16 | 17 | } 18 | -------------------------------------------------------------------------------- /harrier-rpc/src/main/java/cn/spdb/harrier/rpc/client/InterfaceRpcClient.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.rpc.client; 2 | 3 | import java.lang.reflect.InvocationTargetException; 4 | 5 | import cn.spdb.harrier.common.utils.URI; 6 | 7 | public interface InterfaceRpcClient { 8 | 9 | T create(Class calzz, URI uri) throws InstantiationException, IllegalAccessException, IllegalArgumentException, InvocationTargetException, NoSuchMethodException, SecurityException; 10 | } 11 | -------------------------------------------------------------------------------- /harrier-rpc/src/main/java/cn/spdb/harrier/rpc/client/RpcRequestCache.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.rpc.client; 2 | 3 | public class RpcRequestCache { 4 | 5 | private RpcFuture future; 6 | 7 | private String handlerMethName; 8 | 9 | public RpcFuture getFuture() { 10 | return future; 11 | } 12 | 13 | public void setFuture(RpcFuture future) { 14 | this.future = future; 15 | } 16 | 17 | public String getHandlerMethName() { 18 | return handlerMethName; 19 | } 20 | 21 | public void setHandlerMethName(String serviceName) { 22 | this.handlerMethName = serviceName; 23 | } 24 | 25 | } 26 | -------------------------------------------------------------------------------- /harrier-rpc/src/main/java/cn/spdb/harrier/rpc/client/RpcRequestTable.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.rpc.client; 2 | 3 | import java.util.concurrent.ConcurrentHashMap; 4 | import java.util.concurrent.atomic.AtomicLong; 5 | 6 | public class RpcRequestTable { 7 | 8 | private static AtomicLong requestIdGen = new AtomicLong(0); 9 | 10 | private static ConcurrentHashMap requestMap = new ConcurrentHashMap(); 11 | 12 | public static void put(Long key, RpcRequestCache requestCache) { 13 | requestMap.put(key, requestCache); 14 | } 15 | 16 | public static RpcRequestCache get(Long key) { 17 | return requestMap.get(key); 18 | } 19 | 20 | public static void remove(long key) { 21 | requestMap.remove(key); 22 | } 23 | 24 | public static long getRequestId() { 25 | return requestIdGen.incrementAndGet(); 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /harrier-rpc/src/main/java/cn/spdb/harrier/rpc/common/ConsumerConfigConstant.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.rpc.common; 2 | 3 | public class ConsumerConfigConstant { 4 | 5 | public static final boolean DEFAULT_SYNC = false; 6 | public static final int DEFAULT_RETRIES = 3; 7 | public static final boolean DEFAULT_CALL_BACK = false; 8 | public static final int TIME_OUT = 5000; 9 | 10 | } 11 | -------------------------------------------------------------------------------- /harrier-rpc/src/main/java/cn/spdb/harrier/rpc/common/DefaultRpcCallBack.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.rpc.common; 2 | 3 | public class DefaultRpcCallBack implements InterfaceRpcCallBack { 4 | 5 | @Override 6 | public void run(Object object) { 7 | 8 | } 9 | 10 | } 11 | -------------------------------------------------------------------------------- /harrier-rpc/src/main/java/cn/spdb/harrier/rpc/common/HttpMapProtocol.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.rpc.common; 2 | 3 | import java.lang.annotation.Documented; 4 | import java.lang.annotation.ElementType; 5 | import java.lang.annotation.Retention; 6 | import java.lang.annotation.RetentionPolicy; 7 | import java.lang.annotation.Target; 8 | 9 | /** 10 | * 11 | * @author T-luzl http path map 12 | * 13 | */ 14 | @Documented 15 | @Target(ElementType.TYPE) 16 | @Retention(RetentionPolicy.RUNTIME) 17 | public @interface HttpMapProtocol { 18 | String value() default "/"; 19 | } 20 | -------------------------------------------------------------------------------- /harrier-rpc/src/main/java/cn/spdb/harrier/rpc/common/InterfaceRpcCallBack.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.rpc.common; 2 | 3 | public interface InterfaceRpcCallBack { 4 | 5 | public void run(Object object); 6 | } 7 | -------------------------------------------------------------------------------- /harrier-rpc/src/main/java/cn/spdb/harrier/rpc/common/RequestEventType.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.rpc.common; 2 | 3 | public enum RequestEventType { 4 | HEARTBET((byte) 1, "heartbeat"), BUSINESS((byte) 2, "business request"); 5 | 6 | private Byte type; 7 | private String description; 8 | 9 | private RequestEventType(Byte type, String description) { 10 | this.type = type; 11 | this.description = description; 12 | } 13 | 14 | public Byte getType() { 15 | return type; 16 | } 17 | 18 | public void setType(Byte type) { 19 | this.type = type; 20 | } 21 | 22 | public String getDescription() { 23 | return description; 24 | } 25 | 26 | public void setDescription(String description) { 27 | this.description = description; 28 | } 29 | 30 | } 31 | -------------------------------------------------------------------------------- /harrier-rpc/src/main/java/cn/spdb/harrier/rpc/common/ResponseEventType.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.rpc.common; 2 | 3 | public enum ResponseEventType { 4 | ACK((byte) 1, "ack"), BUSINESS_RSP((byte) 2, "business response"); 5 | 6 | private Byte type; 7 | private String description; 8 | 9 | private ResponseEventType(Byte type, String description) { 10 | this.type = type; 11 | this.description = description; 12 | } 13 | 14 | public Byte getType() { 15 | return type; 16 | } 17 | 18 | public void setType(Byte type) { 19 | this.type = type; 20 | } 21 | 22 | public String getDescription() { 23 | return description; 24 | } 25 | 26 | public void setDescription(String description) { 27 | this.description = description; 28 | } 29 | 30 | } 31 | -------------------------------------------------------------------------------- /harrier-rpc/src/main/java/cn/spdb/harrier/rpc/common/RpcHandler.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.rpc.common; 2 | 3 | import java.lang.annotation.ElementType; 4 | import java.lang.annotation.Retention; 5 | import java.lang.annotation.RetentionPolicy; 6 | import java.lang.annotation.Target; 7 | 8 | @Target(ElementType.TYPE) 9 | @Retention(RetentionPolicy.RUNTIME) 10 | public @interface RpcHandler { 11 | String value() default ""; 12 | } 13 | -------------------------------------------------------------------------------- /harrier-rpc/src/main/java/cn/spdb/harrier/rpc/common/RpcMethod.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.rpc.common; 2 | 3 | import java.lang.annotation.ElementType; 4 | import java.lang.annotation.Retention; 5 | import java.lang.annotation.RetentionPolicy; 6 | import java.lang.annotation.Target; 7 | 8 | import cn.spdb.harrier.rpc.compress.CompressEnum; 9 | 10 | @Target(ElementType.METHOD) 11 | @Retention(RetentionPolicy.RUNTIME) 12 | public @interface RpcMethod { 13 | 14 | int retries() default ConsumerConfigConstant.DEFAULT_RETRIES; 15 | 16 | boolean async() default ConsumerConfigConstant.DEFAULT_SYNC; 17 | 18 | int timeOut() default ConsumerConfigConstant.TIME_OUT; 19 | 20 | CompressEnum compressType() default CompressEnum.NO; 21 | 22 | Class serviceCallBack() default DefaultRpcCallBack.class; 23 | 24 | } 25 | -------------------------------------------------------------------------------- /harrier-rpc/src/main/java/cn/spdb/harrier/rpc/common/RpcResponse.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.rpc.common; 2 | 3 | public class RpcResponse { 4 | 5 | private Byte status; 6 | private String msg; 7 | private Object result; 8 | 9 | 10 | public String getMsg() { 11 | return msg; 12 | } 13 | 14 | public void setMsg(String msg) { 15 | this.msg = msg; 16 | } 17 | 18 | public Object getResult() { 19 | return result; 20 | } 21 | 22 | public void setResult(Object result) { 23 | this.result = result; 24 | } 25 | 26 | public Byte getStatus() { 27 | return status; 28 | } 29 | 30 | public void setStatus(Byte status) { 31 | this.status = status; 32 | } 33 | 34 | } 35 | -------------------------------------------------------------------------------- /harrier-rpc/src/main/java/cn/spdb/harrier/rpc/common/RpcServiceHandler.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.rpc.common; 2 | 3 | import java.lang.annotation.ElementType; 4 | import java.lang.annotation.Retention; 5 | import java.lang.annotation.RetentionPolicy; 6 | import java.lang.annotation.Target; 7 | 8 | @Target(ElementType.TYPE) 9 | @Retention(RetentionPolicy.RUNTIME) 10 | public @interface RpcServiceHandler { 11 | String value(); 12 | } 13 | -------------------------------------------------------------------------------- /harrier-rpc/src/main/java/cn/spdb/harrier/rpc/compress/Compress.java: -------------------------------------------------------------------------------- 1 | 2 | package cn.spdb.harrier.rpc.compress; 3 | 4 | import java.io.IOException; 5 | 6 | /** 7 | * Compress interface. 8 | * 9 | * @author xiemalin 10 | * @since 1.4 11 | */ 12 | public interface Compress { 13 | 14 | /** 15 | * Compress. 16 | * 17 | * @param array the array 18 | * @return the byte[] 19 | * @throws IOException Signals that an I/O exception has occurred. 20 | */ 21 | byte[] compress(byte[] array) throws IOException; 22 | 23 | 24 | /** 25 | * Un compress. 26 | * 27 | * @param array the array 28 | * @return the byte[] 29 | * @throws IOException Signals that an I/O exception has occurred. 30 | */ 31 | byte[] unCompress(byte[] array) throws IOException; 32 | } 33 | -------------------------------------------------------------------------------- /harrier-rpc/src/main/java/cn/spdb/harrier/rpc/compress/CompressEnum.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.rpc.compress; 2 | 3 | public enum CompressEnum { 4 | NO(0, null), SNAPPY(1, new SnappyCompress()), GIZP(2, new GZipCompress()); 5 | 6 | private Compress compress; 7 | private byte type; 8 | 9 | private CompressEnum(int type, Compress compress) { 10 | this.compress = compress; 11 | this.type = (byte) type; 12 | } 13 | 14 | public Compress getCompress() { 15 | return compress; 16 | } 17 | 18 | public void setCompress(Compress compress) { 19 | this.compress = compress; 20 | } 21 | 22 | public byte getType() { 23 | return type; 24 | } 25 | 26 | public void setType(byte type) { 27 | this.type = type; 28 | } 29 | 30 | public static Compress getCompressByType(byte type) { 31 | for (CompressEnum compressEnum : CompressEnum.values()) { 32 | if (compressEnum.getType() == type) { 33 | return compressEnum.getCompress(); 34 | } 35 | } 36 | return null; 37 | } 38 | } 39 | -------------------------------------------------------------------------------- /harrier-rpc/src/main/java/cn/spdb/harrier/rpc/compress/SnappyCompress.java: -------------------------------------------------------------------------------- 1 | 2 | package cn.spdb.harrier.rpc.compress; 3 | 4 | import java.io.IOException; 5 | 6 | import org.xerial.snappy.Snappy; 7 | 8 | 9 | public class SnappyCompress implements Compress { 10 | 11 | 12 | public byte[] compress(byte[] array) throws IOException { 13 | if (array == null) { 14 | return null; 15 | } 16 | return Snappy.compress(array); 17 | } 18 | 19 | 20 | public byte[] unCompress(byte[] array) throws IOException { 21 | if (array == null) { 22 | return null; 23 | } 24 | return Snappy.uncompress(array); 25 | } 26 | 27 | 28 | } 29 | -------------------------------------------------------------------------------- /harrier-rpc/src/main/java/cn/spdb/harrier/rpc/protocol/ProtocolEventType.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.rpc.protocol; 2 | 3 | public enum ProtocolEventType { 4 | 5 | HEARTBEAT(1, "heartbeat"), 6 | REQUEST(2, "business request"), 7 | RESPONSE( 3, "business response"), 8 | COMPERESS_ERROR(4, "comperess error"); 9 | 10 | private Byte type; 11 | private String description; 12 | 13 | private ProtocolEventType(int type, String description) { 14 | this.type = (byte) type; 15 | this.description = description; 16 | } 17 | 18 | public Byte getType() { 19 | return type; 20 | } 21 | 22 | public void setType(Byte type) { 23 | this.type = type; 24 | } 25 | 26 | public String getDescription() { 27 | return description; 28 | } 29 | 30 | public void setDescription(String description) { 31 | this.description = description; 32 | } 33 | 34 | } 35 | -------------------------------------------------------------------------------- /harrier-rpc/src/main/java/cn/spdb/harrier/rpc/protocol/RpcProtocol.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.rpc.protocol; 2 | 3 | public class RpcProtocol { 4 | 5 | private ProtocolHeader protocolHeader; 6 | 7 | private T body; 8 | 9 | public ProtocolHeader getProtocolHeader() { 10 | return protocolHeader; 11 | } 12 | 13 | public void setProtocolHeader(ProtocolHeader protocolHeader) { 14 | this.protocolHeader = protocolHeader; 15 | } 16 | 17 | public T getBody() { 18 | return body; 19 | } 20 | 21 | public void setBody(T body) { 22 | this.body = body; 23 | } 24 | 25 | } 26 | -------------------------------------------------------------------------------- /harrier-rpc/src/main/java/cn/spdb/harrier/rpc/protocol/RpcProtocolConstants.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.rpc.protocol; 2 | 3 | public class RpcProtocolConstants { 4 | 5 | public static final int HEADER_LENGTH = 20; 6 | public static final int MAGIC = 0x73706462; 7 | public static final byte VERSION = 1; 8 | 9 | } 10 | -------------------------------------------------------------------------------- /harrier-rpc/src/main/java/cn/spdb/harrier/rpc/serializer/FastJsonSerializer.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.rpc.serializer; 2 | 3 | import com.alibaba.fastjson.JSON; 4 | 5 | public class FastJsonSerializer implements Serializer { 6 | 7 | 8 | 9 | @Override 10 | public byte[] serialize(T object) { 11 | return JSON.toJSONBytes(object); 12 | } 13 | 14 | @Override 15 | public T deserialize(byte[] body, Class clazz) { 16 | return JSON.parseObject(body, clazz); 17 | } 18 | 19 | } -------------------------------------------------------------------------------- /harrier-rpc/src/main/java/cn/spdb/harrier/rpc/serializer/SerializeEnum.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.rpc.serializer; 2 | 3 | public enum SerializeEnum { 4 | FastJson((byte) 1, new FastJsonSerializer()), PROTOSTUFF((byte) 2, new ProtoStuffSerializer()); 5 | 6 | private byte type; 7 | private Serializer serializer; 8 | 9 | private SerializeEnum(byte type, Serializer serializer) { 10 | this.type = type; 11 | this.serializer = serializer; 12 | } 13 | 14 | public static Serializer getSerializerByType(byte type) { 15 | for (SerializeEnum serializeEnum : SerializeEnum.values()) { 16 | if (serializeEnum.getType() == type) { 17 | return serializeEnum.getSerializer(); 18 | } 19 | } 20 | return null; 21 | } 22 | 23 | public byte getType() { 24 | return type; 25 | } 26 | 27 | public void setType(byte type) { 28 | this.type = type; 29 | } 30 | 31 | public Serializer getSerializer() { 32 | return serializer; 33 | } 34 | 35 | public void setSerializer(Serializer serializer) { 36 | this.serializer = serializer; 37 | } 38 | 39 | } 40 | -------------------------------------------------------------------------------- /harrier-rpc/src/main/java/cn/spdb/harrier/rpc/serializer/Serializer.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.rpc.serializer; 2 | 3 | public interface Serializer { 4 | 5 | byte[] serialize(T object); 6 | 7 | T deserialize(byte[] body, Class clazz); 8 | } 9 | -------------------------------------------------------------------------------- /harrier-rpc/src/main/java/cn/spdb/harrier/rpc/transport/File/FileMessage.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.rpc.transport.File; 2 | 3 | public class FileMessage { 4 | 5 | private Long streamId; 6 | 7 | private Long pos = 0L; 8 | 9 | private byte[] data; 10 | 11 | private Byte status = -1; 12 | 13 | public Long getStreamId() { 14 | return streamId; 15 | } 16 | 17 | public void setStreamId(Long streamId) { 18 | this.streamId = streamId; 19 | } 20 | 21 | public Long getPos() { 22 | return pos; 23 | } 24 | 25 | public void setPos(Long pos) { 26 | this.pos = pos; 27 | } 28 | 29 | public byte[] getData() { 30 | return data; 31 | } 32 | 33 | public void setData(byte[] data) { 34 | this.data = data; 35 | } 36 | 37 | public Byte getStatus() { 38 | return status; 39 | } 40 | 41 | public void setStatus(Byte status) { 42 | this.status = status; 43 | } 44 | 45 | } 46 | -------------------------------------------------------------------------------- /harrier-rpc/src/main/java/cn/spdb/harrier/rpc/transport/File/FileStatus.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.rpc.transport.File; 2 | 3 | public enum FileStatus { 4 | LOAD_FILE((byte) 2), UPLOAD_FILE((byte) 1), SUCC_FILE((byte) 0), FAIL_FILE((byte) -1); 5 | ; 6 | 7 | private Byte type; 8 | 9 | private FileStatus(Byte type) { 10 | this.type = type; 11 | } 12 | 13 | public byte status() { 14 | return type; 15 | } 16 | 17 | public Byte getType() { 18 | return type; 19 | } 20 | 21 | public void setType(Byte type) { 22 | this.type = type; 23 | } 24 | 25 | public static FileStatus getFileStatus(Byte status) { 26 | for (FileStatus fileStatus : FileStatus.values()) { 27 | if (fileStatus.status() == status) { 28 | return fileStatus; 29 | } 30 | } 31 | return null; 32 | } 33 | 34 | } 35 | -------------------------------------------------------------------------------- /harrier-rpc/src/main/java/cn/spdb/harrier/rpc/transport/File/IRpcFileService.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.rpc.transport.File; 2 | 3 | import java.util.List; 4 | 5 | import cn.spdb.harrier.rpc.common.RpcHandler; 6 | import cn.spdb.harrier.rpc.common.RpcMethod; 7 | import cn.spdb.harrier.rpc.compress.CompressEnum; 8 | 9 | @RpcHandler("IRpcFileService") 10 | public interface IRpcFileService { 11 | 12 | @RpcMethod(compressType = CompressEnum.GIZP, async = true, serviceCallBack = RpcFileLoadCallBack.class) 13 | public FileMessage loadFile(String loadPath, Long streamId, Long pos, Long bufferSize); 14 | 15 | @RpcMethod(compressType = CompressEnum.GIZP, async = true, serviceCallBack = RpcFileUploadCallBack.class) 16 | public FileMessage uploadFile(String remotePath, Long streamId, Long pos, byte[] data); 17 | 18 | @RpcMethod(timeOut = 1000 * 5) 19 | public Boolean deleteFile(String string); 20 | 21 | @RpcMethod(timeOut = 1000 * 5) 22 | public Boolean createDirFile(String string); 23 | 24 | @RpcMethod(timeOut = 1000 * 5) 25 | public List selectFiles(String path); 26 | 27 | } -------------------------------------------------------------------------------- /harrier-rpc/src/main/java/cn/spdb/harrier/rpc/transport/http/AbstractHttpGetWorkerHandler.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.rpc.transport.http; 2 | 3 | import java.util.Map; 4 | 5 | public abstract class AbstractHttpGetWorkerHandler extends AbstractHttpWorkerHandler { 6 | @Override 7 | public Object handlerPost(Map parMap, Map objectMap) { 8 | return null; 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /harrier-rpc/src/main/java/cn/spdb/harrier/rpc/transport/http/AbstractHttpPostWorkerHandler.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.rpc.transport.http; 2 | 3 | import java.util.Map; 4 | 5 | public abstract class AbstractHttpPostWorkerHandler extends AbstractHttpWorkerHandler { 6 | 7 | @Override 8 | public Object handlerGet(Map parMap) { 9 | return null; 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /harrier-rpc/src/main/java/cn/spdb/harrier/rpc/transport/http/InterfaceHttpHandler.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.rpc.transport.http; 2 | 3 | import io.netty.handler.codec.http.FullHttpRequest; 4 | import io.netty.handler.codec.http.FullHttpResponse; 5 | 6 | public interface InterfaceHttpHandler { 7 | 8 | FullHttpResponse handler(FullHttpRequest fullHttpRequest); 9 | 10 | 11 | } 12 | -------------------------------------------------------------------------------- /harrier-rpc/src/main/java/cn/spdb/harrier/rpc/transport/http/handler/TestHandler.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.rpc.transport.http.handler; 2 | 3 | import java.util.Map; 4 | 5 | import cn.spdb.harrier.rpc.common.HttpMapProtocol; 6 | import cn.spdb.harrier.rpc.transport.http.AbstractHttpGetWorkerHandler; 7 | 8 | @HttpMapProtocol("/") 9 | public class TestHandler extends AbstractHttpGetWorkerHandler { 10 | 11 | @Override 12 | public String handlerGet(Map parMap) { 13 | return "hello world!!!"; 14 | } 15 | 16 | } 17 | -------------------------------------------------------------------------------- /harrier-rpc/src/main/java/cn/spdb/harrier/rpc/transport/script/IRpcScriptService.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.rpc.transport.script; 2 | 3 | import cn.spdb.harrier.rpc.common.RpcHandler; 4 | import cn.spdb.harrier.rpc.common.RpcMethod; 5 | 6 | @RpcHandler("IRpcScriptService") 7 | public interface IRpcScriptService { 8 | 9 | @RpcMethod 10 | public String script(String clazz,String ... parms); 11 | } 12 | -------------------------------------------------------------------------------- /harrier-rpc/src/main/java/cn/spdb/harrier/rpc/transport/script/InterfaceCommand.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.rpc.transport.script; 2 | 3 | 4 | public interface InterfaceCommand { 5 | 6 | String handle(String... args); 7 | 8 | } 9 | -------------------------------------------------------------------------------- /harrier-server/.gitignore: -------------------------------------------------------------------------------- 1 | /target/ 2 | -------------------------------------------------------------------------------- /harrier-server/.project: -------------------------------------------------------------------------------- 1 | 2 | 3 | harrier-server 4 | 5 | 6 | 7 | 8 | 9 | org.eclipse.jdt.core.javabuilder 10 | 11 | 12 | 13 | 14 | org.eclipse.m2e.core.maven2Builder 15 | 16 | 17 | 18 | 19 | 20 | org.eclipse.jdt.core.javanature 21 | org.eclipse.m2e.core.maven2Nature 22 | 23 | 24 | -------------------------------------------------------------------------------- /harrier-server/.settings/org.eclipse.core.resources.prefs: -------------------------------------------------------------------------------- 1 | eclipse.preferences.version=1 2 | encoding//src/main/java=UTF-8 3 | encoding//src/main/resources=UTF-8 4 | encoding//src/test/java=UTF-8 5 | encoding//src/test/resources=UTF-8 6 | encoding/=UTF-8 7 | -------------------------------------------------------------------------------- /harrier-server/.settings/org.eclipse.jdt.core.prefs: -------------------------------------------------------------------------------- 1 | eclipse.preferences.version=1 2 | org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.8 3 | org.eclipse.jdt.core.compiler.compliance=1.8 4 | org.eclipse.jdt.core.compiler.problem.enablePreviewFeatures=disabled 5 | org.eclipse.jdt.core.compiler.problem.forbiddenReference=warning 6 | org.eclipse.jdt.core.compiler.problem.reportPreviewFeatures=ignore 7 | org.eclipse.jdt.core.compiler.release=disabled 8 | org.eclipse.jdt.core.compiler.source=1.8 9 | -------------------------------------------------------------------------------- /harrier-server/.settings/org.eclipse.m2e.core.prefs: -------------------------------------------------------------------------------- 1 | activeProfiles= 2 | eclipse.preferences.version=1 3 | resolveWorkspaceProjects=true 4 | version=1 5 | -------------------------------------------------------------------------------- /harrier-server/src/main/java/cn/spdb/harrier/server/Application.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.server; 2 | 3 | import org.springframework.boot.WebApplicationType; 4 | import org.springframework.boot.autoconfigure.SpringBootApplication; 5 | import org.springframework.boot.builder.SpringApplicationBuilder; 6 | 7 | import cn.spdb.harrier.server.master.UdsMasterServer; 8 | import cn.spdb.harrier.server.worker.UdsWorkerServer; 9 | 10 | @SpringBootApplication 11 | public class Application { 12 | 13 | public static void main(String[] args) { 14 | new SpringApplicationBuilder(UdsWorkerServer.class, UdsMasterServer.class).web(WebApplicationType.NONE).run(args); 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /harrier-server/src/main/java/cn/spdb/harrier/server/master/UdsMasterServer.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.server.master; 2 | 3 | import org.springframework.boot.WebApplicationType; 4 | import org.springframework.boot.autoconfigure.SpringBootApplication; 5 | import org.springframework.boot.builder.SpringApplicationBuilder; 6 | import org.springframework.transaction.annotation.EnableTransactionManagement; 7 | 8 | @SpringBootApplication(scanBasePackages = { "cn.spdb.harrier.server.master", "cn.spdb.harrier.dao", 9 | "cn.spdb.harrier.service" }) 10 | @EnableTransactionManagement 11 | public class UdsMasterServer { 12 | 13 | public static void main(String[] args) { 14 | new SpringApplicationBuilder(UdsMasterServer.class).web(WebApplicationType.NONE).run(args); 15 | } 16 | 17 | } 18 | -------------------------------------------------------------------------------- /harrier-server/src/main/java/cn/spdb/harrier/server/master/deal/Deal.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.server.master.deal; 2 | 3 | public interface Deal { 4 | 5 | public void stop(); 6 | 7 | public void start(); 8 | } 9 | -------------------------------------------------------------------------------- /harrier-server/src/main/java/cn/spdb/harrier/server/master/dispath/select/AbstractSelector.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.server.master.dispath.select; 2 | 3 | import java.util.Collection; 4 | 5 | import org.springframework.util.CollectionUtils; 6 | 7 | public abstract class AbstractSelector implements Selector { 8 | 9 | @Override 10 | public T select(Collection sources) { 11 | 12 | if (CollectionUtils.isEmpty(sources)) { 13 | return null; 14 | } 15 | if (sources.size() == 1) { 16 | return (T) sources.toArray()[0]; 17 | } 18 | try { 19 | 20 | return doSelect(sources); 21 | } catch (Exception e) { 22 | e.printStackTrace(); 23 | } 24 | return null; 25 | } 26 | 27 | protected abstract T doSelect(Collection sources); 28 | 29 | } 30 | -------------------------------------------------------------------------------- /harrier-server/src/main/java/cn/spdb/harrier/server/master/dispath/select/Selector.java: -------------------------------------------------------------------------------- 1 | 2 | package cn.spdb.harrier.server.master.dispath.select; 3 | 4 | import java.util.Collection; 5 | 6 | 7 | 8 | public interface Selector { 9 | 10 | T select(Collection source); 11 | } 12 | -------------------------------------------------------------------------------- /harrier-server/src/main/java/cn/spdb/harrier/server/master/rpc/transport/AlarmTransportServerInterfasce.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.server.master.rpc.transport; 2 | 3 | import cn.spdb.harrier.dao.entity.MAlarm; 4 | import cn.spdb.harrier.dao.entity.MAlarmSendQueue; 5 | import cn.spdb.harrier.rpc.common.RpcHandler; 6 | import cn.spdb.harrier.rpc.common.RpcMethod; 7 | 8 | @RpcHandler("AlarmTransportServerInterfasce") 9 | public interface AlarmTransportServerInterfasce { 10 | 11 | @RpcMethod 12 | Boolean createAlarm(MAlarm alarm); 13 | 14 | @RpcMethod 15 | Boolean create(MAlarmSendQueue alarmSendQueue); 16 | 17 | } -------------------------------------------------------------------------------- /harrier-server/src/main/java/cn/spdb/harrier/server/script/command/InterfaceCommand.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.server.script.command; 2 | 3 | import cn.spdb.harrier.common.CommandConstant; 4 | 5 | public interface InterfaceCommand { 6 | 7 | String handle(String... args); 8 | 9 | default String getType() { 10 | return CommandConstant.ALL; 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /harrier-server/src/main/java/cn/spdb/harrier/server/script/command/handle/LoadSystem.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.server.script.command.handle; 2 | 3 | import org.apache.commons.lang3.ObjectUtils; 4 | 5 | import cn.spdb.harrier.common.CommandConstant; 6 | import cn.spdb.harrier.common.utils.Symbol; 7 | import cn.spdb.harrier.dao.cache.SystemCache; 8 | import cn.spdb.harrier.dao.utils.BeanContext; 9 | import cn.spdb.harrier.server.script.command.InterfaceCommand; 10 | 11 | public class LoadSystem implements InterfaceCommand { 12 | 13 | @Override 14 | public String handle(String... args) { 15 | SystemCache systemCache = BeanContext.getBean(SystemCache.class); 16 | if (ObjectUtils.isNotEmpty(systemCache)) { 17 | if (args.length > 1) { 18 | systemCache.delete(args[0], Symbol.XING_HAO); 19 | systemCache.delete(args[0], args[1]); 20 | } else { 21 | systemCache.load(); 22 | } 23 | } 24 | return CommandConstant.SUCCESS; 25 | } 26 | 27 | @Override 28 | public String getType() { 29 | return CommandConstant.MASTER; 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /harrier-server/src/main/java/cn/spdb/harrier/server/worker/UdsWorkerServer.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.server.worker; 2 | 3 | import java.net.URISyntaxException; 4 | 5 | import org.springframework.boot.WebApplicationType; 6 | import org.springframework.boot.autoconfigure.SpringBootApplication; 7 | import org.springframework.boot.builder.SpringApplicationBuilder; 8 | 9 | @SpringBootApplication(scanBasePackages = { "cn.spdb.harrier.server.worker", "cn.spdb.harrier.dao", 10 | "cn.spdb.harrier.service" }) 11 | public class UdsWorkerServer { 12 | 13 | public static void main(String[] args) throws URISyntaxException { 14 | new SpringApplicationBuilder(UdsWorkerServer.class).web(WebApplicationType.NONE).run(args); 15 | } 16 | 17 | 18 | 19 | } 20 | -------------------------------------------------------------------------------- /harrier-server/src/main/java/cn/spdb/harrier/server/worker/cache/ComplementContextCacheManager.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.server.worker.cache; 2 | 3 | import cn.spdb.harrier.server.worker.exec.ComplementRunable; 4 | 5 | public interface ComplementContextCacheManager { 6 | 7 | 8 | ComplementRunable getByComplementId(Long complementId); 9 | 10 | void cacheComplementContext(ComplementRunable comRunable); 11 | 12 | void removeByComplementId(Long complementId); 13 | 14 | boolean updateComplementContext(ComplementRunable comRunable); 15 | 16 | } -------------------------------------------------------------------------------- /harrier-server/src/main/java/cn/spdb/harrier/server/worker/cache/TaskExecutionContextCacheManager.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.server.worker.cache; 2 | 3 | import cn.spdb.harrier.server.entity.JobExecutionContext; 4 | import cn.spdb.harrier.server.worker.exec.ExecuteRunable; 5 | 6 | public interface TaskExecutionContextCacheManager { 7 | 8 | ExecuteRunable getByTaskInstanceId(Long taskInstanceId); 9 | 10 | void cacheTaskExecutionContext(ExecuteRunable jobExecutionContext); 11 | 12 | void removeByTaskInstanceId(Long taskInstanceId); 13 | 14 | boolean updateTaskExecutionContext(JobExecutionContext jobExecutionContext); 15 | 16 | } -------------------------------------------------------------------------------- /harrier-server/src/main/java/cn/spdb/harrier/server/worker/rpc/transport/WorkTransportServerInterface.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.server.worker.rpc.transport; 2 | 3 | import cn.spdb.harrier.rpc.common.RpcHandler; 4 | import cn.spdb.harrier.rpc.common.RpcMethod; 5 | import cn.spdb.harrier.server.entity.ComplementIns; 6 | import cn.spdb.harrier.server.entity.JobExecutionContext; 7 | 8 | @RpcHandler("WorkTransportServerInterface") 9 | public interface WorkTransportServerInterface { 10 | 11 | @RpcMethod 12 | Boolean dispathcer(JobExecutionContext job); 13 | 14 | @RpcMethod 15 | Boolean killJob(Long taskInstanceId); 16 | 17 | @RpcMethod 18 | Boolean dispathcerComplement(ComplementIns ins); 19 | } -------------------------------------------------------------------------------- /harrier-server/src/main/resources/application.properties: -------------------------------------------------------------------------------- 1 | master.server.name= 2 | master.role.name= 3 | master.role.group= 4 | master.listen.port= 5 | 6 | worker.server.name= 7 | worker.role.name= 8 | worker.role.group= 9 | worker.listen.port= 10 | 11 | aws.s3.accessKey= 12 | aws.s3.secretKey= 13 | aws.s3.bucket= 14 | aws.s3.enndpoint= 15 | 16 | 17 | harrier.logs.step.prex=/logs/step/ -------------------------------------------------------------------------------- /harrier-service/.gitignore: -------------------------------------------------------------------------------- 1 | /target/ 2 | -------------------------------------------------------------------------------- /harrier-service/.project: -------------------------------------------------------------------------------- 1 | 2 | 3 | harrier-service 4 | 5 | 6 | 7 | 8 | 9 | org.eclipse.jdt.core.javabuilder 10 | 11 | 12 | 13 | 14 | org.eclipse.m2e.core.maven2Builder 15 | 16 | 17 | 18 | 19 | 20 | org.eclipse.jdt.core.javanature 21 | org.eclipse.m2e.core.maven2Nature 22 | 23 | 24 | -------------------------------------------------------------------------------- /harrier-service/.settings/org.eclipse.core.resources.prefs: -------------------------------------------------------------------------------- 1 | eclipse.preferences.version=1 2 | encoding//src/main/java=UTF-8 3 | encoding//src/main/java/cn/spdb/harrier/service/etcd/AbstractEtcdConfig.java=UTF-8 4 | encoding//src/main/resources=UTF-8 5 | encoding//src/test/java=UTF-8 6 | encoding//src/test/resources=UTF-8 7 | encoding/=UTF-8 8 | -------------------------------------------------------------------------------- /harrier-service/.settings/org.eclipse.jdt.core.prefs: -------------------------------------------------------------------------------- 1 | eclipse.preferences.version=1 2 | org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.8 3 | org.eclipse.jdt.core.compiler.compliance=1.8 4 | org.eclipse.jdt.core.compiler.problem.enablePreviewFeatures=disabled 5 | org.eclipse.jdt.core.compiler.problem.forbiddenReference=warning 6 | org.eclipse.jdt.core.compiler.problem.reportPreviewFeatures=ignore 7 | org.eclipse.jdt.core.compiler.release=disabled 8 | org.eclipse.jdt.core.compiler.source=1.8 9 | -------------------------------------------------------------------------------- /harrier-service/.settings/org.eclipse.m2e.core.prefs: -------------------------------------------------------------------------------- 1 | activeProfiles= 2 | eclipse.preferences.version=1 3 | resolveWorkspaceProjects=true 4 | version=1 5 | -------------------------------------------------------------------------------- /harrier-service/src/main/java/cn/spdb/harrier/service/Application.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.service; 2 | 3 | public class Application { 4 | 5 | public static void main(String[] args) { 6 | throw new IllegalStateException("is not execute jar"); 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /harrier-service/src/main/java/cn/spdb/harrier/service/db/SubscribeListener.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.service.db; 2 | 3 | public interface SubscribeListener { 4 | 5 | void notity(WatchEvent event); 6 | } 7 | -------------------------------------------------------------------------------- /harrier-service/src/main/java/cn/spdb/harrier/service/etcd/config/DefaultEtcdConfig.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.service.etcd.config; 2 | 3 | import cn.spdb.harrier.service.etcd.AbstractEtcdConfig; 4 | 5 | public class DefaultEtcdConfig extends AbstractEtcdConfig { 6 | 7 | 8 | 9 | } 10 | -------------------------------------------------------------------------------- /harrier-service/src/main/java/cn/spdb/harrier/service/registry/HarrierRegistry.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.service.registry; 2 | 3 | import java.util.Collection; 4 | 5 | import cn.spdb.harrier.dao.entity.UdsServer; 6 | 7 | public interface HarrierRegistry { 8 | 9 | 10 | 11 | UdsServer registrydb(UdsServer udsServer, SubscribeListener listener); 12 | 13 | void unregistrydb(String ip, int port); 14 | 15 | void addListener(SubscribeListener listener); 16 | 17 | UdsServer getLeader(String nodeClusterType); 18 | 19 | Collection getUdsServerList(); 20 | } 21 | -------------------------------------------------------------------------------- /harrier-service/src/main/java/cn/spdb/harrier/service/registry/SubscribeListener.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.service.registry; 2 | 3 | public interface SubscribeListener { 4 | 5 | void notity(WatchEvent event); 6 | } 7 | -------------------------------------------------------------------------------- /harrier-standalone-server/.gitignore: -------------------------------------------------------------------------------- 1 | /target/ 2 | /bin/ 3 | -------------------------------------------------------------------------------- /harrier-standalone-server/.project: -------------------------------------------------------------------------------- 1 | 2 | 3 | harrier-standalone-server 4 | 5 | 6 | 7 | 8 | 9 | org.eclipse.jdt.core.javabuilder 10 | 11 | 12 | 13 | 14 | org.eclipse.m2e.core.maven2Builder 15 | 16 | 17 | 18 | 19 | 20 | org.eclipse.jdt.core.javanature 21 | org.eclipse.m2e.core.maven2Nature 22 | 23 | 24 | -------------------------------------------------------------------------------- /harrier-standalone-server/.settings/org.eclipse.core.resources.prefs: -------------------------------------------------------------------------------- 1 | eclipse.preferences.version=1 2 | encoding//src/main/java=UTF-8 3 | encoding//src/main/resources=UTF-8 4 | encoding//src/test/java=UTF-8 5 | encoding//src/test/resources=UTF-8 6 | encoding/=UTF-8 7 | -------------------------------------------------------------------------------- /harrier-standalone-server/.settings/org.eclipse.jdt.core.prefs: -------------------------------------------------------------------------------- 1 | eclipse.preferences.version=1 2 | org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.8 3 | org.eclipse.jdt.core.compiler.compliance=1.8 4 | org.eclipse.jdt.core.compiler.problem.enablePreviewFeatures=disabled 5 | org.eclipse.jdt.core.compiler.problem.forbiddenReference=warning 6 | org.eclipse.jdt.core.compiler.problem.reportPreviewFeatures=ignore 7 | org.eclipse.jdt.core.compiler.release=disabled 8 | org.eclipse.jdt.core.compiler.source=1.8 9 | -------------------------------------------------------------------------------- /harrier-standalone-server/.settings/org.eclipse.m2e.core.prefs: -------------------------------------------------------------------------------- 1 | activeProfiles= 2 | eclipse.preferences.version=1 3 | resolveWorkspaceProjects=true 4 | version=1 5 | -------------------------------------------------------------------------------- /harrier-standalone-server/src/main/java/cn/spdb/harrier/standalone/StandaloneServer.java: -------------------------------------------------------------------------------- 1 | package cn.spdb.harrier.standalone; 2 | 3 | import org.springframework.boot.autoconfigure.SpringBootApplication; 4 | import org.springframework.boot.builder.SpringApplicationBuilder; 5 | 6 | import cn.spdb.harrier.alarm.AlarmServer; 7 | import cn.spdb.harrier.api.MonitorApplication; 8 | import cn.spdb.harrier.server.master.UdsMasterServer; 9 | import cn.spdb.harrier.server.worker.UdsWorkerServer; 10 | 11 | @SpringBootApplication 12 | public class StandaloneServer { 13 | 14 | public static void main(String[] args) { 15 | new SpringApplicationBuilder(AlarmServer.class, MonitorApplication.class, UdsWorkerServer.class, 16 | UdsMasterServer.class).run(args); 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /harrier-ui/.babelrc: -------------------------------------------------------------------------------- 1 | { 2 | "presets": [ 3 | "@vue/app" 4 | ] 5 | } 6 | -------------------------------------------------------------------------------- /harrier-ui/.editorconfig: -------------------------------------------------------------------------------- 1 | root = true 2 | 3 | [*] 4 | charset = utf-8 5 | indent_style = space 6 | indent_size = 2 7 | end_of_line = lf 8 | insert_final_newline = true 9 | trim_trailing_whitespace = true 10 | -------------------------------------------------------------------------------- /harrier-ui/.eslintignore: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/spdb-opensource/harrier/eba49fc7869498e5ffd7981fc84c17ca2e932633/harrier-ui/.eslintignore -------------------------------------------------------------------------------- /harrier-ui/.eslintrc.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | root: true, 3 | 'extends': [ 4 | 'plugin:vue/essential', 5 | '@vue/standard' 6 | ], 7 | rules: { 8 | // allow async-await 9 | 'generator-star-spacing': 'off', 10 | // allow debugger during development 11 | 'no-debugger': process.env.NODE_ENV === 'production' ? 'error' : 'off', 12 | 'vue/no-parsing-error': [2, { 13 | 'x-invalid-end-tag': false 14 | }], 15 | 'no-undef': 'off', 16 | 'camelcase': 'off' 17 | }, 18 | parserOptions: { 19 | parser: 'babel-eslint' 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /harrier-ui/.gitignore: -------------------------------------------------------------------------------- 1 | /target/ 2 | -------------------------------------------------------------------------------- /harrier-ui/.postcssrc.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | plugins: { 3 | autoprefixer: {} 4 | } 5 | } 6 | -------------------------------------------------------------------------------- /harrier-ui/.project: -------------------------------------------------------------------------------- 1 | 2 | 3 | harrier-ui 4 | 5 | 6 | 7 | 8 | 9 | org.eclipse.jdt.core.javabuilder 10 | 11 | 12 | 13 | 14 | org.eclipse.m2e.core.maven2Builder 15 | 16 | 17 | 18 | 19 | 20 | org.eclipse.jdt.core.javanature 21 | org.eclipse.m2e.core.maven2Nature 22 | 23 | 24 | -------------------------------------------------------------------------------- /harrier-ui/.settings/org.eclipse.core.resources.prefs: -------------------------------------------------------------------------------- 1 | eclipse.preferences.version=1 2 | encoding//src/main/java=UTF-8 3 | encoding//src/main/resources=UTF-8 4 | encoding//src/test/java=UTF-8 5 | encoding//src/test/resources=UTF-8 6 | encoding/=UTF-8 7 | -------------------------------------------------------------------------------- /harrier-ui/.settings/org.eclipse.jdt.core.prefs: -------------------------------------------------------------------------------- 1 | eclipse.preferences.version=1 2 | org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.8 3 | org.eclipse.jdt.core.compiler.compliance=1.8 4 | org.eclipse.jdt.core.compiler.problem.enablePreviewFeatures=disabled 5 | org.eclipse.jdt.core.compiler.problem.forbiddenReference=warning 6 | org.eclipse.jdt.core.compiler.problem.reportPreviewFeatures=ignore 7 | org.eclipse.jdt.core.compiler.release=disabled 8 | org.eclipse.jdt.core.compiler.source=1.8 9 | -------------------------------------------------------------------------------- /harrier-ui/.settings/org.eclipse.m2e.core.prefs: -------------------------------------------------------------------------------- 1 | activeProfiles= 2 | eclipse.preferences.version=1 3 | resolveWorkspaceProjects=true 4 | version=1 5 | -------------------------------------------------------------------------------- /harrier-ui/.travis.yml: -------------------------------------------------------------------------------- 1 | language: node_js 2 | node_js: stable 3 | script: npm run lint 4 | notifications: 5 | email: false 6 | -------------------------------------------------------------------------------- /harrier-ui/.vscode/settings.json: -------------------------------------------------------------------------------- 1 | { 2 | "maven.view": "flat" 3 | } -------------------------------------------------------------------------------- /harrier-ui/cypress.json: -------------------------------------------------------------------------------- 1 | { 2 | "pluginsFile": "tests/e2e/plugins/index.js" 3 | } 4 | -------------------------------------------------------------------------------- /harrier-ui/pom.xml: -------------------------------------------------------------------------------- 1 | 2 | 4.0.0 3 | 4 | cn.spdb.harrier 5 | harrier 6 | 3.0-SNAPSHOT 7 | 8 | harrier-ui 9 | -------------------------------------------------------------------------------- /harrier-ui/public/harrier.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/spdb-opensource/harrier/eba49fc7869498e5ffd7981fc84c17ca2e932633/harrier-ui/public/harrier.ico -------------------------------------------------------------------------------- /harrier-ui/public/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 14 |
15 | 16 | 17 | 18 | -------------------------------------------------------------------------------- /harrier-ui/src/App.vue: -------------------------------------------------------------------------------- 1 | 6 | 7 | 12 | 13 | 28 | -------------------------------------------------------------------------------- /harrier-ui/src/api/routers.js: -------------------------------------------------------------------------------- 1 | import axios from '@/libs/api.request' 2 | 3 | export const getRouterReq = (access) => { 4 | return axios.request({ 5 | url: 'get_router', 6 | params: { 7 | access 8 | }, 9 | method: 'get' 10 | }) 11 | } 12 | -------------------------------------------------------------------------------- /harrier-ui/src/assets/icons/iconfont.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/spdb-opensource/harrier/eba49fc7869498e5ffd7981fc84c17ca2e932633/harrier-ui/src/assets/icons/iconfont.ttf -------------------------------------------------------------------------------- /harrier-ui/src/assets/icons/iconfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/spdb-opensource/harrier/eba49fc7869498e5ffd7981fc84c17ca2e932633/harrier-ui/src/assets/icons/iconfont.woff -------------------------------------------------------------------------------- /harrier-ui/src/assets/icons/iconfont.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/spdb-opensource/harrier/eba49fc7869498e5ffd7981fc84c17ca2e932633/harrier-ui/src/assets/icons/iconfont.woff2 -------------------------------------------------------------------------------- /harrier-ui/src/assets/icons/jobC.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/spdb-opensource/harrier/eba49fc7869498e5ffd7981fc84c17ca2e932633/harrier-ui/src/assets/icons/jobC.png -------------------------------------------------------------------------------- /harrier-ui/src/assets/icons/platformC.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/spdb-opensource/harrier/eba49fc7869498e5ffd7981fc84c17ca2e932633/harrier-ui/src/assets/icons/platformC.png -------------------------------------------------------------------------------- /harrier-ui/src/assets/icons/systemC.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/spdb-opensource/harrier/eba49fc7869498e5ffd7981fc84c17ca2e932633/harrier-ui/src/assets/icons/systemC.png -------------------------------------------------------------------------------- /harrier-ui/src/assets/icons/unJobC.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/spdb-opensource/harrier/eba49fc7869498e5ffd7981fc84c17ca2e932633/harrier-ui/src/assets/icons/unJobC.png -------------------------------------------------------------------------------- /harrier-ui/src/assets/icons/unPlatformC.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/spdb-opensource/harrier/eba49fc7869498e5ffd7981fc84c17ca2e932633/harrier-ui/src/assets/icons/unPlatformC.png -------------------------------------------------------------------------------- /harrier-ui/src/assets/icons/unSystemC.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/spdb-opensource/harrier/eba49fc7869498e5ffd7981fc84c17ca2e932633/harrier-ui/src/assets/icons/unSystemC.png -------------------------------------------------------------------------------- /harrier-ui/src/assets/images/corn.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/spdb-opensource/harrier/eba49fc7869498e5ffd7981fc84c17ca2e932633/harrier-ui/src/assets/images/corn.png -------------------------------------------------------------------------------- /harrier-ui/src/assets/images/icon-qr-qq-wechat.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/spdb-opensource/harrier/eba49fc7869498e5ffd7981fc84c17ca2e932633/harrier-ui/src/assets/images/icon-qr-qq-wechat.png -------------------------------------------------------------------------------- /harrier-ui/src/assets/images/icon-social-juejin.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /harrier-ui/src/assets/images/login-bg.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/spdb-opensource/harrier/eba49fc7869498e5ffd7981fc84c17ca2e932633/harrier-ui/src/assets/images/login-bg.jpg -------------------------------------------------------------------------------- /harrier-ui/src/assets/images/login_background.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/spdb-opensource/harrier/eba49fc7869498e5ffd7981fc84c17ca2e932633/harrier-ui/src/assets/images/login_background.png -------------------------------------------------------------------------------- /harrier-ui/src/assets/images/login_bg01.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/spdb-opensource/harrier/eba49fc7869498e5ffd7981fc84c17ca2e932633/harrier-ui/src/assets/images/login_bg01.jpg -------------------------------------------------------------------------------- /harrier-ui/src/assets/images/logo-min.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/spdb-opensource/harrier/eba49fc7869498e5ffd7981fc84c17ca2e932633/harrier-ui/src/assets/images/logo-min.jpg -------------------------------------------------------------------------------- /harrier-ui/src/assets/images/logo.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/spdb-opensource/harrier/eba49fc7869498e5ffd7981fc84c17ca2e932633/harrier-ui/src/assets/images/logo.jpg -------------------------------------------------------------------------------- /harrier-ui/src/assets/images/logoBig.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/spdb-opensource/harrier/eba49fc7869498e5ffd7981fc84c17ca2e932633/harrier-ui/src/assets/images/logoBig.png -------------------------------------------------------------------------------- /harrier-ui/src/assets/images/logoSmall.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/spdb-opensource/harrier/eba49fc7869498e5ffd7981fc84c17ca2e932633/harrier-ui/src/assets/images/logoSmall.png -------------------------------------------------------------------------------- /harrier-ui/src/assets/images/talkingdata.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/spdb-opensource/harrier/eba49fc7869498e5ffd7981fc84c17ca2e932633/harrier-ui/src/assets/images/talkingdata.png -------------------------------------------------------------------------------- /harrier-ui/src/assets/images/workflow/CMD.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/spdb-opensource/harrier/eba49fc7869498e5ffd7981fc84c17ca2e932633/harrier-ui/src/assets/images/workflow/CMD.png -------------------------------------------------------------------------------- /harrier-ui/src/assets/images/workflow/DELETE.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/spdb-opensource/harrier/eba49fc7869498e5ffd7981fc84c17ca2e932633/harrier-ui/src/assets/images/workflow/DELETE.png -------------------------------------------------------------------------------- /harrier-ui/src/assets/images/workflow/GET.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/spdb-opensource/harrier/eba49fc7869498e5ffd7981fc84c17ca2e932633/harrier-ui/src/assets/images/workflow/GET.png -------------------------------------------------------------------------------- /harrier-ui/src/assets/images/workflow/HEAD.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/spdb-opensource/harrier/eba49fc7869498e5ffd7981fc84c17ca2e932633/harrier-ui/src/assets/images/workflow/HEAD.png -------------------------------------------------------------------------------- /harrier-ui/src/assets/images/workflow/JAVA.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/spdb-opensource/harrier/eba49fc7869498e5ffd7981fc84c17ca2e932633/harrier-ui/src/assets/images/workflow/JAVA.png -------------------------------------------------------------------------------- /harrier-ui/src/assets/images/workflow/PERL.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/spdb-opensource/harrier/eba49fc7869498e5ffd7981fc84c17ca2e932633/harrier-ui/src/assets/images/workflow/PERL.png -------------------------------------------------------------------------------- /harrier-ui/src/assets/images/workflow/POST.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/spdb-opensource/harrier/eba49fc7869498e5ffd7981fc84c17ca2e932633/harrier-ui/src/assets/images/workflow/POST.png -------------------------------------------------------------------------------- /harrier-ui/src/assets/images/workflow/PUT.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/spdb-opensource/harrier/eba49fc7869498e5ffd7981fc84c17ca2e932633/harrier-ui/src/assets/images/workflow/PUT.png -------------------------------------------------------------------------------- /harrier-ui/src/assets/images/workflow/PYTHON2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/spdb-opensource/harrier/eba49fc7869498e5ffd7981fc84c17ca2e932633/harrier-ui/src/assets/images/workflow/PYTHON2.png -------------------------------------------------------------------------------- /harrier-ui/src/assets/images/workflow/PYTHON3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/spdb-opensource/harrier/eba49fc7869498e5ffd7981fc84c17ca2e932633/harrier-ui/src/assets/images/workflow/PYTHON3.png -------------------------------------------------------------------------------- /harrier-ui/src/assets/images/workflow/SHELL.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/spdb-opensource/harrier/eba49fc7869498e5ffd7981fc84c17ca2e932633/harrier-ui/src/assets/images/workflow/SHELL.png -------------------------------------------------------------------------------- /harrier-ui/src/assets/images/workflow/SQL.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/spdb-opensource/harrier/eba49fc7869498e5ffd7981fc84c17ca2e932633/harrier-ui/src/assets/images/workflow/SQL.png -------------------------------------------------------------------------------- /harrier-ui/src/assets/jobimg/basic.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/spdb-opensource/harrier/eba49fc7869498e5ffd7981fc84c17ca2e932633/harrier-ui/src/assets/jobimg/basic.png -------------------------------------------------------------------------------- /harrier-ui/src/assets/jobimg/bg1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/spdb-opensource/harrier/eba49fc7869498e5ffd7981fc84c17ca2e932633/harrier-ui/src/assets/jobimg/bg1.png -------------------------------------------------------------------------------- /harrier-ui/src/assets/jobimg/bj.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/spdb-opensource/harrier/eba49fc7869498e5ffd7981fc84c17ca2e932633/harrier-ui/src/assets/jobimg/bj.png -------------------------------------------------------------------------------- /harrier-ui/src/assets/jobimg/brain1.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/spdb-opensource/harrier/eba49fc7869498e5ffd7981fc84c17ca2e932633/harrier-ui/src/assets/jobimg/brain1.gif -------------------------------------------------------------------------------- /harrier-ui/src/assets/jobimg/emergy.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/spdb-opensource/harrier/eba49fc7869498e5ffd7981fc84c17ca2e932633/harrier-ui/src/assets/jobimg/emergy.png -------------------------------------------------------------------------------- /harrier-ui/src/assets/jobimg/influ.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/spdb-opensource/harrier/eba49fc7869498e5ffd7981fc84c17ca2e932633/harrier-ui/src/assets/jobimg/influ.png -------------------------------------------------------------------------------- /harrier-ui/src/assets/jobimg/life.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/spdb-opensource/harrier/eba49fc7869498e5ffd7981fc84c17ca2e932633/harrier-ui/src/assets/jobimg/life.png -------------------------------------------------------------------------------- /harrier-ui/src/assets/jobimg/radar.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/spdb-opensource/harrier/eba49fc7869498e5ffd7981fc84c17ca2e932633/harrier-ui/src/assets/jobimg/radar.png -------------------------------------------------------------------------------- /harrier-ui/src/assets/jobimg/time.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/spdb-opensource/harrier/eba49fc7869498e5ffd7981fc84c17ca2e932633/harrier-ui/src/assets/jobimg/time.png -------------------------------------------------------------------------------- /harrier-ui/src/assets/jobimg/xueyuan.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/spdb-opensource/harrier/eba49fc7869498e5ffd7981fc84c17ca2e932633/harrier-ui/src/assets/jobimg/xueyuan.png -------------------------------------------------------------------------------- /harrier-ui/src/components/charts/index.js: -------------------------------------------------------------------------------- 1 | import ChartPie from './pie.vue' 2 | import ChartBar from './bar.vue' 3 | export { ChartPie, ChartBar } 4 | -------------------------------------------------------------------------------- /harrier-ui/src/components/common-icon/common-icon.vue: -------------------------------------------------------------------------------- 1 | 4 | 5 | 39 | 40 | 43 | -------------------------------------------------------------------------------- /harrier-ui/src/components/common-icon/index.js: -------------------------------------------------------------------------------- 1 | import CommonIcon from './common-icon.vue' 2 | export default CommonIcon 3 | -------------------------------------------------------------------------------- /harrier-ui/src/components/common/common.less: -------------------------------------------------------------------------------- 1 | .no-select{ 2 | -webkit-touch-callout: none; 3 | -webkit-user-select: none; 4 | -khtml-user-select: none; 5 | -moz-user-select: none; 6 | -ms-user-select: none; 7 | user-select: none; 8 | } 9 | -------------------------------------------------------------------------------- /harrier-ui/src/components/common/util.js: -------------------------------------------------------------------------------- 1 | export const showTitle = (item, vm) => { 2 | return vm.$config.useI18n ? vm.$t(item.name) : ((item.meta && item.meta.title) || item.name) 3 | } 4 | -------------------------------------------------------------------------------- /harrier-ui/src/components/count-to/index.js: -------------------------------------------------------------------------------- 1 | import countTo from './count-to.vue' 2 | export default countTo 3 | -------------------------------------------------------------------------------- /harrier-ui/src/components/count-to/index.less: -------------------------------------------------------------------------------- 1 | @prefix: ~"count-to"; 2 | 3 | .@{prefix}-wrapper{ 4 | .content-outer{ 5 | display: inline-block; 6 | .@{prefix}-unit-text{ 7 | font-style: normal; 8 | } 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /harrier-ui/src/components/cropper/index.js: -------------------------------------------------------------------------------- 1 | import Cropper from './index.vue' 2 | export default Cropper 3 | -------------------------------------------------------------------------------- /harrier-ui/src/components/cropper/index.less: -------------------------------------------------------------------------------- 1 | .bg{ 2 | background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQAQMAAAAlPW0iAAAAA3NCSVQICAjb4U/gAAAABlBMVEXMzMz////TjRV2AAAACXBIWXMAAArrAAAK6wGCiw1aAAAAHHRFWHRTb2Z0d2FyZQBBZG9iZSBGaXJld29ya3MgQ1M26LyyjAAAABFJREFUCJlj+M/AgBVhF/0PAH6/D/HkDxOGAAAAAElFTkSuQmCC") 3 | } 4 | .cropper-wrapper{ 5 | width: 600px; 6 | height: 340px; 7 | .img-box{ 8 | height: 340px; 9 | width: 430px; 10 | border: 1px solid #ebebeb; 11 | display: inline-block; 12 | .bg; 13 | img{ 14 | max-width: 100%; 15 | display: block; 16 | } 17 | } 18 | .right-con{ 19 | display: inline-block; 20 | width: 170px; 21 | vertical-align: top; 22 | box-sizing: border-box; 23 | padding: 0 10px; 24 | .preview-box{ 25 | height: 150px !important; 26 | width: 100% !important; 27 | overflow: hidden; 28 | border: 1px solid #ebebeb; 29 | .bg; 30 | } 31 | .button-box{ 32 | padding: 10px 0 0; 33 | } 34 | } 35 | } 36 | -------------------------------------------------------------------------------- /harrier-ui/src/components/drag-drawer/drag-drawer-trigger.vue: -------------------------------------------------------------------------------- 1 | 8 | 9 | 16 | 17 | 19 | -------------------------------------------------------------------------------- /harrier-ui/src/components/drag-drawer/index.js: -------------------------------------------------------------------------------- 1 | import DragDrawer from './drag-drawer.vue' 2 | export default DragDrawer 3 | -------------------------------------------------------------------------------- /harrier-ui/src/components/drag-drawer/mixin.js: -------------------------------------------------------------------------------- 1 | export default { 2 | data () { 3 | return { 4 | prefix: 'drag-drawer' 5 | } 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /harrier-ui/src/components/drag-list/index.js: -------------------------------------------------------------------------------- 1 | import DragList from './drag-list.vue' 2 | export default DragList 3 | -------------------------------------------------------------------------------- /harrier-ui/src/components/editor/index.js: -------------------------------------------------------------------------------- 1 | import Editor from './editor.vue' 2 | export default Editor 3 | -------------------------------------------------------------------------------- /harrier-ui/src/components/icons/icons.vue: -------------------------------------------------------------------------------- 1 | 4 | 5 | 32 | 33 | 36 | -------------------------------------------------------------------------------- /harrier-ui/src/components/icons/index.js: -------------------------------------------------------------------------------- 1 | import Icons from './icons.vue' 2 | export default Icons 3 | -------------------------------------------------------------------------------- /harrier-ui/src/components/info-card-new/index.js: -------------------------------------------------------------------------------- 1 | import InforCard from './infor-card-new.vue' 2 | export default InforCard 3 | -------------------------------------------------------------------------------- /harrier-ui/src/components/info-card/index.js: -------------------------------------------------------------------------------- 1 | import InforCard from './infor-card.vue' 2 | export default InforCard 3 | -------------------------------------------------------------------------------- /harrier-ui/src/components/info-circle/index.js: -------------------------------------------------------------------------------- 1 | import InfoCircle from './info-circle.vue' 2 | export default InfoCircle 3 | -------------------------------------------------------------------------------- /harrier-ui/src/components/login-form/index.js: -------------------------------------------------------------------------------- 1 | import LoginForm from './login-form.vue' 2 | export default LoginForm 3 | -------------------------------------------------------------------------------- /harrier-ui/src/components/main/components/a-back-top/index.js: -------------------------------------------------------------------------------- 1 | import ABackTop from './index.vue' 2 | export default ABackTop 3 | -------------------------------------------------------------------------------- /harrier-ui/src/components/main/components/error-store/error-store.vue: -------------------------------------------------------------------------------- 1 | 10 | 11 | 38 | 39 | 50 | -------------------------------------------------------------------------------- /harrier-ui/src/components/main/components/error-store/index.js: -------------------------------------------------------------------------------- 1 | import ErrorStore from './error-store.vue' 2 | export default ErrorStore 3 | -------------------------------------------------------------------------------- /harrier-ui/src/components/main/components/fullscreen/index.js: -------------------------------------------------------------------------------- 1 | import Fullscreen from './fullscreen.vue' 2 | export default Fullscreen 3 | -------------------------------------------------------------------------------- /harrier-ui/src/components/main/components/header-bar/custom-bread-crumb/custom-bread-crumb.less: -------------------------------------------------------------------------------- 1 | .custom-bread-crumb{ 2 | display: inline-block; 3 | vertical-align: top; 4 | } 5 | -------------------------------------------------------------------------------- /harrier-ui/src/components/main/components/header-bar/custom-bread-crumb/index.js: -------------------------------------------------------------------------------- 1 | import customBreadCrumb from './custom-bread-crumb.vue' 2 | export default customBreadCrumb 3 | -------------------------------------------------------------------------------- /harrier-ui/src/components/main/components/header-bar/header-bar.less: -------------------------------------------------------------------------------- 1 | .header-bar{ 2 | width: 100%; 3 | height: 100%; 4 | position: relative; 5 | // .custom-content-con{ 6 | // float: right; 7 | // height: auto; 8 | // padding-right: 20px; 9 | // line-height: 64px; 10 | // & > *{ 11 | // float: right; 12 | // } 13 | // } 14 | .custom-content-con{ 15 | color:#afb5bc; 16 | width: 300px; 17 | float: right; 18 | height: auto; 19 | padding-right: 20px; 20 | line-height: 64px; 21 | & > *{ 22 | float: right; 23 | } 24 | } 25 | } 26 | -------------------------------------------------------------------------------- /harrier-ui/src/components/main/components/header-bar/header-bar.vue: -------------------------------------------------------------------------------- 1 | 10 | 35 | -------------------------------------------------------------------------------- /harrier-ui/src/components/main/components/header-bar/index.js: -------------------------------------------------------------------------------- 1 | import HeaderBar from './header-bar' 2 | export default HeaderBar 3 | -------------------------------------------------------------------------------- /harrier-ui/src/components/main/components/header-bar/sider-trigger/index.js: -------------------------------------------------------------------------------- 1 | import siderTrigger from './sider-trigger.vue' 2 | export default siderTrigger 3 | -------------------------------------------------------------------------------- /harrier-ui/src/components/main/components/header-bar/sider-trigger/sider-trigger.less: -------------------------------------------------------------------------------- 1 | .trans{ 2 | transition: transform .2s ease; 3 | } 4 | @size: 40px; 5 | .sider-trigger-a{ 6 | padding: 6px; 7 | width: @size; 8 | height: @size; 9 | display: inline-block; 10 | text-align: center; 11 | color: #5c6b77; 12 | margin-top: 12px; 13 | i{ 14 | .trans; 15 | vertical-align: top; 16 | } 17 | &.collapsed i{ 18 | transform: rotateZ(90deg); 19 | .trans; 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /harrier-ui/src/components/main/components/header-bar/sider-trigger/sider-trigger.vue: -------------------------------------------------------------------------------- 1 | 4 | 25 | 28 | -------------------------------------------------------------------------------- /harrier-ui/src/components/main/components/help/help.less: -------------------------------------------------------------------------------- 1 | .sys-bar-user-a { 2 | // color: #515a6e 3 | color:#afb5bc 4 | // color: #fff 5 | } 6 | -------------------------------------------------------------------------------- /harrier-ui/src/components/main/components/help/index.js: -------------------------------------------------------------------------------- 1 | import Help from './help.vue' 2 | export default Help 3 | -------------------------------------------------------------------------------- /harrier-ui/src/components/main/components/language/index.js: -------------------------------------------------------------------------------- 1 | import Language from './language.vue' 2 | export default Language 3 | -------------------------------------------------------------------------------- /harrier-ui/src/components/main/components/side-menu/index.js: -------------------------------------------------------------------------------- 1 | import SideMenu from './side-menu.vue' 2 | export default SideMenu 3 | -------------------------------------------------------------------------------- /harrier-ui/src/components/main/components/side-menu/item-mixin.js: -------------------------------------------------------------------------------- 1 | export default { 2 | props: { 3 | parentItem: { 4 | type: Object, 5 | default: () => {} 6 | }, 7 | theme: String, 8 | iconSize: Number 9 | }, 10 | computed: { 11 | parentName () { 12 | return this.parentItem.name 13 | }, 14 | children () { 15 | return this.parentItem.children 16 | }, 17 | textColor () { 18 | return this.theme === 'dark' ? '#fff' : '#495060' 19 | } 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /harrier-ui/src/components/main/components/side-menu/mixin.js: -------------------------------------------------------------------------------- 1 | import CommonIcon from '_c/common-icon' 2 | import { showTitle } from '@/libs/util' 3 | export default { 4 | components: { 5 | CommonIcon 6 | }, 7 | methods: { 8 | showTitle (item) { 9 | return showTitle(item, this) 10 | }, 11 | showChildren (item) { 12 | return item.children && (item.children.length > 1 || (item.meta && item.meta.showAlways)) 13 | }, 14 | getNameOrHref (item, children0) { 15 | return item.href ? `isTurnByHref_${item.href}` : (children0 ? item.children[0].name : item.name) 16 | } 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /harrier-ui/src/components/main/components/side-menu/side-menu.less: -------------------------------------------------------------------------------- 1 | .side-menu-wrapper{ 2 | user-select: none; 3 | .menu-collapsed{ 4 | padding-top: 10px; 5 | 6 | .ivu-dropdown{ 7 | width: 100%; 8 | .ivu-dropdown-rel a{ 9 | width: 100%; 10 | } 11 | } 12 | .ivu-tooltip{ 13 | width: 100%; 14 | .ivu-tooltip-rel{ 15 | width: 100%; 16 | } 17 | .ivu-tooltip-popper .ivu-tooltip-content{ 18 | .ivu-tooltip-arrow{ 19 | border-right-color: #fff; 20 | } 21 | .ivu-tooltip-inner{ 22 | background: #fff; 23 | color: #495060; 24 | } 25 | } 26 | } 27 | 28 | 29 | } 30 | a.drop-menu-a{ 31 | display: inline-block; 32 | padding: 6px 15px; 33 | width: 100%; 34 | text-align: center; 35 | color: #495060; 36 | } 37 | } 38 | .menu-title{ 39 | padding-left: 6px; 40 | } 41 | -------------------------------------------------------------------------------- /harrier-ui/src/components/main/components/tags-nav/index.js: -------------------------------------------------------------------------------- 1 | import TagsNav from './tags-nav.vue' 2 | export default TagsNav 3 | -------------------------------------------------------------------------------- /harrier-ui/src/components/main/components/user/index.js: -------------------------------------------------------------------------------- 1 | import User from './user.vue' 2 | export default User 3 | -------------------------------------------------------------------------------- /harrier-ui/src/components/main/components/user/old_user.less: -------------------------------------------------------------------------------- 1 | .user{ 2 | &-avatar-dropdown{ 3 | cursor: pointer; 4 | display: inline-block; 5 | // height: 64px; 6 | vertical-align: middle; 7 | // line-height: 64px; 8 | .ivu-badge-dot{ 9 | top: 16px; 10 | } 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /harrier-ui/src/components/main/components/user/user.less: -------------------------------------------------------------------------------- 1 | .user{ 2 | &-avatar-dropdown{ 3 | cursor: pointer; 4 | display: inline-block; 5 | // height: 64px; 6 | vertical-align: middle; 7 | // line-height: 64px; 8 | .ivu-badge-dot{ 9 | top: 16px; 10 | } 11 | } 12 | } 13 | .sys-bar-user { 14 | // width: 600px; 15 | // position: fixed; 16 | // top: 3px; 17 | // z-index: 999; 18 | // right: 0px; 19 | // height: 60px; 20 | color: #515a6e; 21 | text-align: right; 22 | } 23 | .sys-bar-user-a { 24 | color: #515a6e 25 | } 26 | .select-menu { 27 | position: absolute; 28 | left: -40px; 29 | top: -20px; 30 | transform-origin: center top 0px; 31 | margin: 5px 0; 32 | padding: 5px 0; 33 | background-color: #fff; 34 | box-sizing: border-box; 35 | border-radius: 4px; 36 | box-shadow: 0 1px 6px rgba(0, 0, 0, 0.2); 37 | z-index: 999; 38 | } 39 | -------------------------------------------------------------------------------- /harrier-ui/src/components/main/index.js: -------------------------------------------------------------------------------- 1 | import Main from './main.vue' 2 | export default Main 3 | -------------------------------------------------------------------------------- /harrier-ui/src/components/markdown/index.js: -------------------------------------------------------------------------------- 1 | import MarkdownEditor from './markdown.vue' 2 | export default MarkdownEditor 3 | -------------------------------------------------------------------------------- /harrier-ui/src/components/parent-view/index.js: -------------------------------------------------------------------------------- 1 | import ParentView from './parent-view.vue' 2 | export default ParentView 3 | -------------------------------------------------------------------------------- /harrier-ui/src/components/parent-view/parent-view.vue: -------------------------------------------------------------------------------- 1 | 6 | 22 | -------------------------------------------------------------------------------- /harrier-ui/src/components/paste-editor/index.js: -------------------------------------------------------------------------------- 1 | import PasteEditor from './paste-editor.vue' 2 | export default PasteEditor 3 | -------------------------------------------------------------------------------- /harrier-ui/src/components/paste-editor/paste-editor.less: -------------------------------------------------------------------------------- 1 | .paste-editor-wrapper{ 2 | width: 100%; 3 | height: 100%; 4 | border: 1px dashed gainsboro; 5 | textarea.textarea-el{ 6 | width: 100%; 7 | height: 100%; 8 | } 9 | .CodeMirror{ 10 | height: 100%; 11 | padding: 0; 12 | .CodeMirror-code div .CodeMirror-line > span > span.cm-tab{ 13 | &::after{ 14 | content: '→'; 15 | color: #BFBFBF; 16 | } 17 | } 18 | } 19 | .first-row{ 20 | font-weight: 700; 21 | font-size: 14px; 22 | } 23 | .incorrect-row{ 24 | background: #F5CBD1; 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /harrier-ui/src/components/s-auth-button/index.js: -------------------------------------------------------------------------------- 1 | import SAuthButton from './s-auth-button.vue'; 2 | export default SAuthButton; -------------------------------------------------------------------------------- /harrier-ui/src/components/s-tree-table/expand.js: -------------------------------------------------------------------------------- 1 | export default { 2 | name: 'TableExpand', 3 | functional: true, 4 | props: { 5 | row: Object, 6 | render: Function, 7 | index: Number, 8 | column: { 9 | type: Object, 10 | default: null 11 | } 12 | }, 13 | render: (h, ctx) => { 14 | const params = { 15 | row: ctx.props.row, 16 | index: ctx.props.index 17 | }; 18 | if (ctx.props.column) params.column = ctx.props.column; 19 | return ctx.props.render(h, params); 20 | } 21 | }; -------------------------------------------------------------------------------- /harrier-ui/src/components/s-tree-table/header.js: -------------------------------------------------------------------------------- 1 | export default { 2 | name: 'TableRenderHeader', 3 | functional: true, 4 | props: { 5 | render: Function, 6 | column: Object, 7 | index: Number 8 | }, 9 | render: (h, ctx) => { 10 | const params = { 11 | column: ctx.props.column, 12 | index: ctx.props.index 13 | }; 14 | return ctx.props.render(h, params); 15 | } 16 | }; -------------------------------------------------------------------------------- /harrier-ui/src/components/s-tree-table/index.js: -------------------------------------------------------------------------------- 1 | import STreeTable from './s-tree-table.vue' 2 | export default STreeTable 3 | -------------------------------------------------------------------------------- /harrier-ui/src/components/s-tree-table/table-tr.vue: -------------------------------------------------------------------------------- 1 | 4 | -------------------------------------------------------------------------------- /harrier-ui/src/components/s-tree-table/total.vue: -------------------------------------------------------------------------------- 1 | 6 | -------------------------------------------------------------------------------- /harrier-ui/src/components/tables/handle-btns.js: -------------------------------------------------------------------------------- 1 | const btns = { 2 | delete: (h, params, vm) => { 3 | return h('Poptip', { 4 | props: { 5 | confirm: true, 6 | title: '你确定要删除吗?' 7 | }, 8 | on: { 9 | 'on-ok': () => { 10 | vm.$emit('on-delete', params) 11 | vm.$emit('input', params.tableData.filter((item, index) => index !== params.row.initRowIndex)) 12 | } 13 | } 14 | }, [ 15 | h('Button', { 16 | props: { 17 | type: 'text', 18 | ghost: true 19 | } 20 | }, [ 21 | h('Icon', { 22 | props: { 23 | type: 'md-trash', 24 | size: 18, 25 | color: '#000000' 26 | } 27 | }) 28 | ]) 29 | ]) 30 | } 31 | } 32 | 33 | export default btns 34 | -------------------------------------------------------------------------------- /harrier-ui/src/components/tables/index.js: -------------------------------------------------------------------------------- 1 | import Tables from './tables.vue' 2 | export default Tables 3 | -------------------------------------------------------------------------------- /harrier-ui/src/components/tables/index.less: -------------------------------------------------------------------------------- 1 | .search-con{ 2 | padding: 10px 0; 3 | .search{ 4 | &-col{ 5 | display: inline-block; 6 | width: 200px; 7 | } 8 | &-input{ 9 | display: inline-block; 10 | width: 200px; 11 | margin-left: 2px; 12 | } 13 | &-btn{ 14 | margin-left: 2px; 15 | } 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /harrier-ui/src/components/tree-select/index.js: -------------------------------------------------------------------------------- 1 | export { default } from './tree-select.vue' 2 | -------------------------------------------------------------------------------- /harrier-ui/src/config/index.js: -------------------------------------------------------------------------------- 1 | var config = require('../../package.json') 2 | export default { 3 | /** 4 | * @description 配置显示在浏览器标签的title 5 | */ 6 | title: 'Harrier', 7 | /** 8 | * @description token在Cookie中存储的天数,默认1天 9 | */ 10 | cookieExpires: 1, 11 | /** 12 | * @description 是否使用国际化,默认为false 13 | * 如果不使用,则需要在路由中给需要在菜单中展示的路由设置meta: {title: 'xxx'} 14 | * 用来在菜单中显示文字 15 | */ 16 | useI18n: false, 17 | /** 18 | * @description api请求基础路径 19 | */ 20 | baseUrl: { 21 | dev: 'http://localhost:12345/' + config.name, // 开发环境 22 | // dev: 'http://' + location.host + '/' + config.name, // 开发环境 23 | pro: 'https://' + location.host + '/' + config.name 24 | }, 25 | /** 26 | * @description 默认打开的首页的路由name值,默认为home 27 | */ 28 | homeName: 'home', 29 | /** 30 | * @description 需要加载的插件 31 | */ 32 | plugin: { 33 | 'error-store': { 34 | showInHeader: true, // 设为false后不会在顶部显示错误日志徽标 35 | developmentOff: true // 设为true后在开发环境不会收集错误信息,方便开发中排查错误 36 | } 37 | }, 38 | host: 'localhost:12345' 39 | // host: location.host 40 | } 41 | -------------------------------------------------------------------------------- /harrier-ui/src/directive/directives.js: -------------------------------------------------------------------------------- 1 | import draggable from './module/draggable' 2 | import clipboard from './module/clipboard' 3 | 4 | const directives = { 5 | draggable, 6 | clipboard 7 | } 8 | 9 | export default directives 10 | -------------------------------------------------------------------------------- /harrier-ui/src/directive/index.js: -------------------------------------------------------------------------------- 1 | import directive from './directives' 2 | 3 | const importDirective = Vue => { 4 | /** 5 | * 拖拽指令 v-draggable="options" 6 | * options = { 7 | * trigger: /这里传入作为拖拽触发器的CSS选择器/, 8 | * body: /这里传入需要移动容器的CSS选择器/, 9 | * recover: /拖动结束之后是否恢复到原来的位置/ 10 | * } 11 | */ 12 | Vue.directive('draggable', directive.draggable) 13 | /** 14 | * clipboard指令 v-draggable="options" 15 | * options = { 16 | * value: /在输入框中使用v-model绑定的值/, 17 | * success: /复制成功后的回调/, 18 | * error: /复制失败后的回调/ 19 | * } 20 | */ 21 | Vue.directive('clipboard', directive.clipboard) 22 | } 23 | 24 | export default importDirective 25 | -------------------------------------------------------------------------------- /harrier-ui/src/directive/module/clipboard.js: -------------------------------------------------------------------------------- 1 | import Clipboard from 'clipboard' 2 | export default { 3 | bind: (el, binding) => { 4 | const clipboard = new Clipboard(el, { 5 | text: () => binding.value.value 6 | }) 7 | el.__success_callback__ = binding.value.success 8 | el.__error_callback__ = binding.value.error 9 | clipboard.on('success', e => { 10 | const callback = el.__success_callback__ 11 | callback && callback(e) 12 | }) 13 | clipboard.on('error', e => { 14 | const callback = el.__error_callback__ 15 | callback && callback(e) 16 | }) 17 | el.__clipboard__ = clipboard 18 | }, 19 | update: (el, binding) => { 20 | el.__clipboard__.text = () => binding.value.value 21 | el.__success_callback__ = binding.value.success 22 | el.__error_callback__ = binding.value.error 23 | }, 24 | unbind: (el, binding) => { 25 | delete el.__success_callback__ 26 | delete el.__error_callback__ 27 | el.__clipboard__.destroy() 28 | delete el.__clipboard__ 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /harrier-ui/src/index.less: -------------------------------------------------------------------------------- 1 | @import '~iview/src/styles/index.less'; 2 | 3 | @menu-dark-title: #001529; 4 | @menu-dark-active-bg: #000c17; 5 | @layout-sider-background: #001529; 6 | -------------------------------------------------------------------------------- /harrier-ui/src/libs/api.request.js: -------------------------------------------------------------------------------- 1 | import HttpRequest from '@/libs/axios' 2 | import config from '@/config' 3 | const baseUrl = process.env.NODE_ENV === 'development' ? config.baseUrl.dev : config.baseUrl.pro 4 | 5 | const axios = new HttpRequest(baseUrl) 6 | export default axios 7 | -------------------------------------------------------------------------------- /harrier-ui/src/libs/render-dom.js: -------------------------------------------------------------------------------- 1 | export default { 2 | name: 'RenderDom', 3 | functional: true, 4 | props: { 5 | render: Function 6 | }, 7 | render: (h, ctx) => { 8 | return ctx.props.render(h) 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /harrier-ui/src/libs/router-util.js: -------------------------------------------------------------------------------- 1 | import { 2 | hasChild, 3 | localRead 4 | } from '@/libs/util' 5 | import Main from '@/components/main' 6 | import { 7 | forEach 8 | } from '@/libs/tools' 9 | // 加载菜单 10 | export const loadMenu = () => { 11 | let list = [] 12 | let data = localRead('route') 13 | if (!data) { 14 | return list 15 | } 16 | list = formatMenu(JSON.parse(data)) 17 | return list 18 | } 19 | 20 | // 格式化菜单 21 | export const formatMenu = (list) => { 22 | let res = [] 23 | forEach(list, item => { 24 | let obj = { 25 | path: item.path, 26 | name: item.name 27 | } 28 | obj.meta = item.meta 29 | 30 | if (item.parentId === 0) { 31 | obj.component = Main 32 | } else { 33 | let data = item.component 34 | // 这里的data应为 /notice/notice.vue 类似的数据,对应的是src/view/下的本地文件 35 | obj.component = () => import('@/view' + data) 36 | } 37 | if (hasChild(item)) { 38 | obj.children = formatMenu(item.children) 39 | } 40 | res.push(obj) 41 | }) 42 | return res 43 | } 44 | -------------------------------------------------------------------------------- /harrier-ui/src/mixins/common.js: -------------------------------------------------------------------------------- 1 | export default { 2 | data: function () { 3 | return { 4 | selection: [], 5 | page: { 6 | current: 1, 7 | total: 10, 8 | size: 10, 9 | opt: [10, 50, 100] 10 | }, 11 | ctrlDisable: true, 12 | loading: true 13 | } 14 | }, 15 | methods: { 16 | select: function (selection) { 17 | this.selection = selection 18 | }, 19 | changePage: function (currentPage) { 20 | this.page.current = currentPage 21 | this.search() 22 | }, 23 | changePageSize: function (pageSize) { 24 | this.page.size = pageSize 25 | this.search() 26 | } 27 | }, 28 | watch: { 29 | selection: function (val) { 30 | if (val.length !== 0) { 31 | this.ctrlDisable = false 32 | } else { 33 | this.ctrlDisable = true 34 | } 35 | } 36 | }, 37 | mounted: function () { 38 | this.init() 39 | } 40 | } 41 | -------------------------------------------------------------------------------- /harrier-ui/src/mock/data.js: -------------------------------------------------------------------------------- 1 | import Mock from 'mockjs' 2 | import { doCustomTimes } from '@/libs/util' 3 | import orgData from './data/org-data' 4 | import { treeData } from './data/tree-select' 5 | const Random = Mock.Random 6 | 7 | export const getTableData = req => { 8 | let tableData = [] 9 | doCustomTimes(5, () => { 10 | tableData.push(Mock.mock({ 11 | name: '@name', 12 | email: '@email', 13 | createTime: '@date' 14 | })) 15 | }) 16 | return tableData 17 | } 18 | 19 | export const getDragList = req => { 20 | let dragList = [] 21 | doCustomTimes(5, () => { 22 | dragList.push(Mock.mock({ 23 | name: Random.csentence(10, 13), 24 | id: Random.increment(10) 25 | })) 26 | }) 27 | return dragList 28 | } 29 | 30 | export const uploadImage = req => { 31 | return Promise.resolve() 32 | } 33 | 34 | export const getOrgData = req => { 35 | return orgData 36 | } 37 | 38 | export const getTreeSelectData = req => { 39 | return treeData 40 | } 41 | -------------------------------------------------------------------------------- /harrier-ui/src/mock/data/org-data.js: -------------------------------------------------------------------------------- 1 | export default { 2 | id: 0, 3 | label: 'XXX科技有限公司', 4 | children: [ 5 | { 6 | id: 2, 7 | label: '产品研发部', 8 | children: [ 9 | { 10 | id: 5, 11 | label: '研发-前端' 12 | }, { 13 | id: 6, 14 | label: '研发-后端' 15 | }, { 16 | id: 9, 17 | label: 'UI设计' 18 | }, { 19 | id: 10, 20 | label: '产品经理' 21 | } 22 | ] 23 | }, 24 | { 25 | id: 3, 26 | label: '销售部', 27 | children: [ 28 | { 29 | id: 7, 30 | label: '销售一部' 31 | }, { 32 | id: 8, 33 | label: '销售二部' 34 | } 35 | ] 36 | }, 37 | { 38 | id: 4, 39 | label: '财务部' 40 | }, { 41 | id: 11, 42 | label: 'HR人事' 43 | } 44 | ] 45 | } 46 | -------------------------------------------------------------------------------- /harrier-ui/src/mock/login.js: -------------------------------------------------------------------------------- 1 | import { getParams } from '@/libs/util' 2 | const USER_MAP = { 3 | super_admin: { 4 | name: 'super_admin', 5 | user_id: '1', 6 | access: ['super_admin', 'admin'], 7 | token: 'super_admin', 8 | avatar: 'https://file.iviewui.com/dist/a0e88e83800f138b94d2414621bd9704.png' 9 | }, 10 | admin: { 11 | name: 'admin', 12 | user_id: '2', 13 | access: ['admin'], 14 | token: 'admin', 15 | avatar: 'https://avatars0.githubusercontent.com/u/20942571?s=460&v=4' 16 | } 17 | } 18 | 19 | export const login = req => { 20 | req = JSON.parse(req.body) 21 | return { token: USER_MAP[req.userName].token } 22 | } 23 | 24 | export const getUserInfo = req => { 25 | const params = getParams(req.url) 26 | return USER_MAP[params.token] 27 | } 28 | 29 | export const logout = req => { 30 | return null 31 | } 32 | -------------------------------------------------------------------------------- /harrier-ui/src/plugin/error-store/index.js: -------------------------------------------------------------------------------- 1 | import store from '@/store' 2 | export default { 3 | install (Vue, options) { 4 | if (options.developmentOff && process.env.NODE_ENV === 'development') return 5 | Vue.config.errorHandler = (error, vm, mes) => { 6 | let info = { 7 | type: 'script', 8 | code: 0, 9 | mes: error.message, 10 | url: window.location.href 11 | } 12 | Vue.nextTick(() => { 13 | store.dispatch('addErrorLog', info) 14 | }) 15 | } 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /harrier-ui/src/plugin/index.js: -------------------------------------------------------------------------------- 1 | import config from '@/config' 2 | const { plugin } = config 3 | 4 | export default (Vue) => { 5 | for (let name in plugin) { 6 | const value = plugin[name] 7 | Vue.use(require(`./${name}`).default, typeof value === 'object' ? value : undefined) 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /harrier-ui/src/router/before-close.js: -------------------------------------------------------------------------------- 1 | import { Modal } from 'iview' 2 | 3 | const beforeClose = { 4 | before_close_normal: (resolve) => { 5 | Modal.confirm({ 6 | title: '确定要关闭这一页吗', 7 | onOk: () => { 8 | resolve(true) 9 | }, 10 | onCancel: () => { 11 | resolve(false) 12 | } 13 | }) 14 | } 15 | } 16 | 17 | export default beforeClose 18 | -------------------------------------------------------------------------------- /harrier-ui/src/store/index.js: -------------------------------------------------------------------------------- 1 | import Vue from 'vue' 2 | import Vuex from 'vuex' 3 | 4 | import user from './module/user' 5 | import app from './module/app' 6 | 7 | Vue.use(Vuex) 8 | 9 | export default new Vuex.Store({ 10 | state: { 11 | // 12 | }, 13 | mutations: { 14 | // 15 | }, 16 | actions: { 17 | // 18 | }, 19 | modules: { 20 | user, 21 | app 22 | } 23 | }) 24 | -------------------------------------------------------------------------------- /harrier-ui/src/view/app/alarm/alarmconfig/Index.vue: -------------------------------------------------------------------------------- 1 | 10 | 11 | 42 | -------------------------------------------------------------------------------- /harrier-ui/src/view/app/alarm/alarmjobconfig/Index.vue: -------------------------------------------------------------------------------- 1 | 10 | 11 | 42 | -------------------------------------------------------------------------------- /harrier-ui/src/view/app/alarm/alarmmsg/Index.vue: -------------------------------------------------------------------------------- 1 | 10 | 11 | 42 | -------------------------------------------------------------------------------- /harrier-ui/src/view/app/alarm/alarmsendqueue/Index.vue: -------------------------------------------------------------------------------- 1 | 10 | 11 | 42 | -------------------------------------------------------------------------------- /harrier-ui/src/view/app/alarm/alarmusergroup/Index.vue: -------------------------------------------------------------------------------- 1 | 10 | 11 | 42 | -------------------------------------------------------------------------------- /harrier-ui/src/view/app/workflow/newworkflow/Index.vue: -------------------------------------------------------------------------------- 1 | 7 | 8 | 38 | -------------------------------------------------------------------------------- /harrier-ui/src/view/app/workflow/updateworkflow/Index.vue: -------------------------------------------------------------------------------- 1 | 9 | 10 | 41 | -------------------------------------------------------------------------------- /harrier-ui/src/view/app/workflow/workflowmanage/Index.vue: -------------------------------------------------------------------------------- 1 | 9 | 10 | 41 | -------------------------------------------------------------------------------- /harrier-ui/src/view/argu-page/params.vue: -------------------------------------------------------------------------------- 1 | 9 | 10 | 33 | 34 | 37 | -------------------------------------------------------------------------------- /harrier-ui/src/view/argu-page/query.vue: -------------------------------------------------------------------------------- 1 | 9 | 10 | 33 | 34 | 37 | -------------------------------------------------------------------------------- /harrier-ui/src/view/components/editor/editor.vue: -------------------------------------------------------------------------------- 1 | 7 | 8 | 30 | 31 | 34 | -------------------------------------------------------------------------------- /harrier-ui/src/view/components/markdown/markdown.vue: -------------------------------------------------------------------------------- 1 | 6 | 7 | 21 | 22 | 25 | -------------------------------------------------------------------------------- /harrier-ui/src/view/error-page/401.vue: -------------------------------------------------------------------------------- 1 | 4 | 5 | 20 | -------------------------------------------------------------------------------- /harrier-ui/src/view/error-page/404.vue: -------------------------------------------------------------------------------- 1 | 4 | 5 | 20 | -------------------------------------------------------------------------------- /harrier-ui/src/view/error-page/500.vue: -------------------------------------------------------------------------------- 1 | 4 | 5 | 20 | -------------------------------------------------------------------------------- /harrier-ui/src/view/error-page/back-btn-group.vue: -------------------------------------------------------------------------------- 1 | 7 | 8 | 39 | -------------------------------------------------------------------------------- /harrier-ui/src/view/error-page/error-content.vue: -------------------------------------------------------------------------------- 1 | 13 | 14 | 29 | -------------------------------------------------------------------------------- /harrier-ui/src/view/error-page/error.less: -------------------------------------------------------------------------------- 1 | .error-page{ 2 | width: 100%; 3 | height: 100%; 4 | position: relative; 5 | background: #f8f8f9; 6 | .content-con{ 7 | width: 700px; 8 | height: 600px; 9 | position: absolute; 10 | left: 50%; 11 | top: 50%; 12 | transform: translate(-50%, -60%); 13 | img{ 14 | display: block; 15 | width: 100%; 16 | height: 100%; 17 | } 18 | .text-con{ 19 | position: absolute; 20 | left: 0px; 21 | top: 0px; 22 | h4{ 23 | position: absolute; 24 | left: 0px; 25 | top: 0px; 26 | font-size: 80px; 27 | font-weight: 700; 28 | color: #348EED; 29 | } 30 | h5{ 31 | position: absolute; 32 | width: 700px; 33 | left: 0px; 34 | top: 100px; 35 | font-size: 20px; 36 | font-weight: 700; 37 | color: #67647D; 38 | } 39 | } 40 | .back-btn-group{ 41 | position: absolute; 42 | right: 0px; 43 | bottom: 20px; 44 | } 45 | } 46 | } 47 | -------------------------------------------------------------------------------- /harrier-ui/src/view/login/old_login.less: -------------------------------------------------------------------------------- 1 | .login{ 2 | width: 100%; 3 | height: 100%; 4 | background-image: url('../../assets/images/login-bg.jpg'); 5 | background-size: cover; 6 | background-position: center; 7 | position: relative; 8 | &-con{ 9 | position: absolute; 10 | right: 160px; 11 | top: 50%; 12 | transform: translateY(-60%); 13 | width: 300px; 14 | &-header{ 15 | font-size: 16px; 16 | font-weight: 300; 17 | text-align: center; 18 | padding: 30px 0; 19 | } 20 | .form-con{ 21 | padding: 10px 0 0; 22 | } 23 | .login-tip{ 24 | font-size: 10px; 25 | text-align: center; 26 | color: #c3c3c3; 27 | } 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /harrier-ui/src/view/multilevel/level-2-1.vue: -------------------------------------------------------------------------------- 1 | 4 | 9 | -------------------------------------------------------------------------------- /harrier-ui/src/view/multilevel/level-2-2/level-2-2-1.vue: -------------------------------------------------------------------------------- 1 | 7 | 17 | -------------------------------------------------------------------------------- /harrier-ui/src/view/multilevel/level-2-2/level-2-2-2.vue: -------------------------------------------------------------------------------- 1 | 7 | 17 | -------------------------------------------------------------------------------- /harrier-ui/src/view/multilevel/level-2-3.vue: -------------------------------------------------------------------------------- 1 | 4 | 9 | -------------------------------------------------------------------------------- /harrier-ui/src/view/single-page/home/index.js: -------------------------------------------------------------------------------- 1 | import home from './home.vue' 2 | export default home 3 | -------------------------------------------------------------------------------- /harrier-ui/src/view/spdb/authority/menu/Index.vue: -------------------------------------------------------------------------------- 1 | 7 | 8 | 29 | -------------------------------------------------------------------------------- /harrier-ui/src/view/spdb/authority/role/Index.vue: -------------------------------------------------------------------------------- 1 | 7 | 8 | 34 | -------------------------------------------------------------------------------- /harrier-ui/src/view/spdb/authority/user/Index.vue: -------------------------------------------------------------------------------- 1 | 7 | 8 | 34 | -------------------------------------------------------------------------------- /harrier-ui/src/view/spdb/job/sqlQuery/Index.vue: -------------------------------------------------------------------------------- 1 | 10 | 11 | 42 | -------------------------------------------------------------------------------- /harrier-ui/src/view/spdb/systemsetting/dictionary/Index.vue: -------------------------------------------------------------------------------- 1 | 10 | 11 | 42 | -------------------------------------------------------------------------------- /harrier-ui/src/view/spdb/systemsetting/fileManage/Index.vue: -------------------------------------------------------------------------------- 1 | 10 | 11 | 42 | -------------------------------------------------------------------------------- /harrier-ui/src/view/spdb/systemsetting/jobWeight/Index.vue: -------------------------------------------------------------------------------- 1 | 10 | 11 | 42 | -------------------------------------------------------------------------------- /harrier-ui/src/view/spdb/systemsetting/operatLog/Index.vue: -------------------------------------------------------------------------------- 1 | 10 | 11 | 42 | -------------------------------------------------------------------------------- /harrier-ui/src/view/spdb/systemsetting/platformConfig/Index.vue: -------------------------------------------------------------------------------- 1 | 10 | 11 | 42 | -------------------------------------------------------------------------------- /harrier-ui/src/view/spdb/systemsetting/weightType/Index.vue: -------------------------------------------------------------------------------- 1 | 10 | 11 | 42 | -------------------------------------------------------------------------------- /harrier-ui/tests/e2e/.eslintrc: -------------------------------------------------------------------------------- 1 | { 2 | "plugins": [ 3 | "cypress" 4 | ], 5 | "env": { 6 | "mocha": true, 7 | "cypress/globals": true 8 | }, 9 | "rules": { 10 | "strict": "off" 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /harrier-ui/tests/e2e/plugins/index.js: -------------------------------------------------------------------------------- 1 | // https://docs.cypress.io/guides/guides/plugins-guide.html 2 | 3 | module.exports = (on, config) => Object.assign({}, config, { 4 | fixturesFolder: 'tests/e2e/fixtures', 5 | integrationFolder: 'tests/e2e/specs', 6 | screenshotsFolder: 'tests/e2e/screenshots', 7 | videosFolder: 'tests/e2e/videos', 8 | supportFile: 'tests/e2e/support/index.js' 9 | }) 10 | -------------------------------------------------------------------------------- /harrier-ui/tests/e2e/specs/test.js: -------------------------------------------------------------------------------- 1 | // https://docs.cypress.io/api/introduction/api.html 2 | 3 | describe('My First Test', () => { 4 | it('Visits the app root url', () => { 5 | cy.visit('/') 6 | cy.contains('h1', 'Welcome to Your Vue.js App') 7 | }) 8 | }) 9 | -------------------------------------------------------------------------------- /harrier-ui/tests/e2e/support/commands.js: -------------------------------------------------------------------------------- 1 | // *********************************************** 2 | // This example commands.js shows you how to 3 | // create various custom commands and overwrite 4 | // existing commands. 5 | // 6 | // For more comprehensive examples of custom 7 | // commands please read more here: 8 | // https://on.cypress.io/custom-commands 9 | // *********************************************** 10 | // 11 | // 12 | // -- This is a parent command -- 13 | // Cypress.Commands.add("login", (email, password) => { ... }) 14 | // 15 | // 16 | // -- This is a child command -- 17 | // Cypress.Commands.add("drag", { prevSubject: 'element'}, (subject, options) => { ... }) 18 | // 19 | // 20 | // -- This is a dual command -- 21 | // Cypress.Commands.add("dismiss", { prevSubject: 'optional'}, (subject, options) => { ... }) 22 | // 23 | // 24 | // -- This is will overwrite an existing command -- 25 | // Cypress.Commands.overwrite("visit", (originalFn, url, options) => { ... }) 26 | -------------------------------------------------------------------------------- /harrier-ui/tests/e2e/support/index.js: -------------------------------------------------------------------------------- 1 | // *********************************************************** 2 | // This example support/index.js is processed and 3 | // loaded automatically before your test files. 4 | // 5 | // This is a great place to put global configuration and 6 | // behavior that modifies Cypress. 7 | // 8 | // You can change the location of this file or turn off 9 | // automatically serving support files with the 10 | // 'supportFile' configuration option. 11 | // 12 | // You can read more here: 13 | // https://on.cypress.io/configuration 14 | // *********************************************************** 15 | 16 | // Import commands.js using ES2015 syntax: 17 | import './commands' 18 | 19 | // Alternatively you can use CommonJS syntax: 20 | // require('./commands') 21 | -------------------------------------------------------------------------------- /harrier-ui/tests/unit/.eslintrc.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | env: { 3 | mocha: true 4 | }, 5 | rules: { 6 | 'import/no-extraneous-dependencies': 'off' 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /harrier-ui/tests/unit/HelloWorld.spec.js: -------------------------------------------------------------------------------- 1 | import { expect } from 'chai' 2 | import { shallow } from '@vue/test-utils' 3 | import HelloWorld from '@/components/HelloWorld.vue' 4 | 5 | describe('HelloWorld.vue', () => { 6 | it('renders props.msg when passed', () => { 7 | const msg = 'new message' 8 | const wrapper = shallow(HelloWorld, { 9 | propsData: { msg } 10 | }) 11 | expect(wrapper.text()).to.include(msg) 12 | }) 13 | }) 14 | -------------------------------------------------------------------------------- /harrier部署包.zip: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/spdb-opensource/harrier/eba49fc7869498e5ffd7981fc84c17ca2e932633/harrier部署包.zip -------------------------------------------------------------------------------- /k8s/docker/Dockerfile: -------------------------------------------------------------------------------- 1 | #基础环境 2 | FROM xxx/openjdk:17.0.2 3 | 4 | #环境变量 5 | ENV DOCKER=true 6 | ENV HARRIER_APP=standalone-server 7 | 8 | #工作路径 9 | WORKDIR /harrier 10 | 11 | #暴露端口 12 | EXPOSE 12345/tcp 13 | 14 | #添加源文件 15 | ADD ./harrier /harrier 16 | 17 | #创建镜像处理命令-创建用户 18 | RUN groupadd -g 5001 harrier && \ 19 | useradd -u 5001 -d /home/harrier/ -g 5001 harrier && \ 20 | chown -R harrier:harrier /harrier && \ 21 | chmod -R 755 /harrier 22 | 23 | 24 | #指定入口 25 | ENTRYPOINT ["su", "harrier", "-c", "/harrier/bin/harrier-daemon.sh start $HARRIER_APP" ] 26 | 27 | --------------------------------------------------------------------------------