zno2

上一页 1 ··· 8 9 10 11 12 13 14 15 16 ··· 21 下一页

2016年8月6日 #

context:propertyPlaceholder

摘要: Activates replacement of ${...} placeholders by registering a PropertySourcesPlaceholderConfigurer within the application context. Properties will be 阅读全文

posted @ 2016-08-06 08:05 zno2 阅读(211) 评论(0) 推荐(0) 编辑

加载 bean.xml 的几种方式 (java or web project)

摘要: 1. java project 2. web project 3. Test org.springframework spring-test 阅读全文

posted @ 2016-08-06 08:05 zno2 阅读(253) 评论(0) 推荐(0) 编辑

加载 bean*.xml

摘要: 入口 最后发现 java.util.regex.Pattern 调用matches() 方法 从而得知 支持正则表达式。 总结: 冒号分析 /** * A {@link ResourcePatternResolver} implementation that is able to resolve a 阅读全文

posted @ 2016-08-06 08:05 zno2 阅读(500) 评论(0) 推荐(0) 编辑

Spring MyBatis Oracle 多数据源

摘要: 数据源1 数据源2 注:xx1Mapper.java 和 xx1Mapper.xml 、 xx2Mapper.java 和 xx2Mapper.xml 上下文中不能出现同名的 结果:操作db1 调用 mapper1 ,操作db2 调用 mapper2 配置多数据源时需注意的单元测试问题: 如果 @T 阅读全文

posted @ 2016-08-06 08:04 zno2 阅读(846) 评论(0) 推荐(0) 编辑

context:

摘要: Spring Bean Configuration File 命名空间 xmlns:context="http://www.springframework.org/schema/context" 语法 http://www.springframework.org/schema/context htt 阅读全文

posted @ 2016-08-06 08:04 zno2 阅读(83) 评论(0) 推荐(0) 编辑

context:annotation-config

摘要: Activates various annotations to be detected in bean classes: Spring's @Required and @Autowired, as well as JSR 250's @PostConstruct, @PreDestroy and 阅读全文

posted @ 2016-08-06 08:04 zno2 阅读(200) 评论(0) 推荐(0) 编辑

context:component-scan

摘要: 一、介绍 Scans the classpath for annotated components that will be auto-registered as Spring beans. By default, the Spring-provided @Component, @Repositor 阅读全文

posted @ 2016-08-06 08:04 zno2 阅读(395) 评论(0) 推荐(0) 编辑

主键冲突异常 DuplicateKeyException

摘要: org.springframework.dao.DuplicateKeyException Exception thrown when an attempt to insert or update data results in violation of an primary key or uniq 阅读全文

posted @ 2016-08-06 08:04 zno2 阅读(14924) 评论(0) 推荐(0) 编辑

SLF4J: Failed to load class "org.slf4j.impl.StaticLoggerBinder".

摘要: SLF4J: Failed to load class "org.slf4j.impl.StaticLoggerBinder".SLF4J: Defaulting to no-operation (NOP) logger implementationSLF4J: See http://www.slf 阅读全文

posted @ 2016-08-06 08:03 zno2 阅读(516) 评论(0) 推荐(0) 编辑

HAService 刨坑

摘要: High availability is a characteristic of a system, which describes the duration (length of time) for which the system is operational. HAService.java 即 阅读全文

posted @ 2016-08-06 08:02 zno2 阅读(362) 评论(0) 推荐(0) 编辑

RocketMQ服务器监控误区

摘要: 请不要监控10912端口 case: result: 监控10912端口会导致HAService异常,新起线程,吃掉内存,无限次监控虚拟机将宕机! 时间上是直接因果关系. 监控10911 和 9876 没有问题. MessageStoreConfig.java 阅读全文

posted @ 2016-08-06 08:02 zno2 阅读(535) 评论(0) 推荐(0) 编辑

Send [1] times, still failed

摘要: 关键代码片段 1. 循环几次发送几次 2. selectOneMessageQueue 返回与上一个broker不同名的broker 3. timesTotal 是brokersSent 数组 4. 某broker发送失败时,如果想要重试其他broker,需要把retryAnotherBrokerW 阅读全文

posted @ 2016-08-06 08:02 zno2 阅读(7073) 评论(0) 推荐(0) 编辑

RECONSUME_LATER

摘要: Failure consumption,later try to consume. MessageExt [queueId=0, storeSize=134, queueOffset=2, sysFlag=0, bornTimestamp=1442224189878, bornHost=/172.1 阅读全文

posted @ 2016-08-06 08:02 zno2 阅读(1328) 评论(0) 推荐(0) 编辑

RocketMQ 自定义文件路径

摘要: 一 、1. 修改store路径2. 修改logs路径3. 修改rmq_bk_gc.log路径4. 修改rmq_srv_gc.log路径二 、1. 获取正确的rocketmq 源码2. 地址:https://github.com/alibaba/RocketMQ三 、1. 修改store路径: ① 修 阅读全文

posted @ 2016-08-06 08:01 zno2 阅读(3652) 评论(0) 推荐(0) 编辑

RocketMQ 运维指令

摘要: 1.1. 控制台使用 RocketMQ 提供有控制台及一系列控制台命令,用于管理员对主题,集群,broker 等信息的管理 登录控制台 首先进入RocketMQ 工程,进入/RocketMQ/bin 在该目录下有个mqadmin 脚本 查看帮助 在mqadmin 下可以查看有哪些命令 sh mqad 阅读全文

posted @ 2016-08-06 08:01 zno2 阅读(5946) 评论(0) 推荐(0) 编辑

RocketMQ 服务器3模式

摘要: 22 a b-s sh mqbroker -c $ROCKETMQ_HOME/conf/2m-2s-async/broker-a.properties &sh mqbroker -c $ROCKETMQ_HOME/conf/2m-2s-async/broker-b-s.properties & 23 阅读全文

posted @ 2016-08-06 08:01 zno2 阅读(206) 评论(0) 推荐(0) 编辑

RocketMQ broker jvm 监控

摘要: 1. jps 获取要监控broker jvm 的进程ID jsp 2. nohup 输出监控日志 nohup jstat -gc -t [pid] [interval] -t 会在每一条记录前加时间戳,执行命令间隔interval(毫秒) 3. 想要结束监控时Ctrl+C 4. 查看日志 cat n 阅读全文

posted @ 2016-08-06 08:01 zno2 阅读(638) 评论(0) 推荐(0) 编辑

RocketMQ runbroker.sh 分析JVM启动参数

摘要: runbroker.sh -server By default, all client applications run in -client mode, while the directory server and certain server utilities run in -server m 阅读全文

posted @ 2016-08-06 08:01 zno2 阅读(1336) 评论(0) 推荐(0) 编辑

问题:虚拟机老生代垃圾回收频繁出现

摘要: case: runbroker.sh JAVA_OPT 使用的是默认参数,broker运行过程中新生代垃圾回收次数较少,频繁出现老生代垃圾回收 cms gc ,并且老生代内存回收不掉。造成卡顿、消息发送失败。最终导致java heap 被占用完,broker 宕机。求教! 内存分析: broker瘫 阅读全文

posted @ 2016-08-06 08:01 zno2 阅读(436) 评论(0) 推荐(0) 编辑

空白行 ,空白

摘要: \n\s*\r 应用: 搜索结果: 额外应用,消除xml文件的空白 阅读全文

posted @ 2016-08-06 08:00 zno2 阅读(147) 评论(0) 推荐(0) 编辑

eclipse find 两位数

摘要: 查找两位数 阅读全文

posted @ 2016-08-06 08:00 zno2 阅读(99) 评论(0) 推荐(0) 编辑

生成字母+数字6位字符串

摘要: package test; import java.util.Random; import java.util.regex.Pattern; public class CodeUtil { public static final char[] CHARS = { '0', '1', '2', '3', '4', '5', '6', '7', '8', '9', 'A', 'B'... 阅读全文

posted @ 2016-08-06 08:00 zno2 阅读(329) 评论(0) 推荐(0) 编辑

字母数字组合 正则

摘要: http://www.w3school.com.cn/jsref/jsref_obj_regexp.asp/^[0-9a-zA-Z]*$/g 阅读全文

posted @ 2016-08-06 08:00 zno2 阅读(349) 评论(0) 推荐(0) 编辑

RocketMQ 加载配置文件

摘要: BrokerStartup.java MixAll.java 由资源文件生成对象: 首先获取资源文件 获取对象的所有set开头的方法 截取方法,如:setMethod1 则为 method1 通过key获取properties文件value 获取该方法参数类型 调用该方法。 从而完成set 。 阅读全文

posted @ 2016-08-06 08:00 zno2 阅读(750) 评论(0) 推荐(0) 编辑

RocketMQ 使用及常见问题

摘要: 前言 本文档是针对RocketMQ使用及常见问题的说明。 一.获取项目、安装包及文档 1. alibaba/RocketMQ https://github.com/alibaba/RocketMQ 2. Download the latest release package https://gith 阅读全文

posted @ 2016-08-06 08:00 zno2 阅读(9079) 评论(0) 推荐(1) 编辑

http://www.rabbitmq.com/

摘要: 什么是RabbitMQ 官网http://www.rabbitmq.com/ 1.应用程序间健壮的消息发送 2.简单易用 3.可在所有主流操作系统运行 4.支持巨量的开发者平台 5.开源和商用双重支持 下载server http://www.rabbitmq.com/download.html ja 阅读全文

posted @ 2016-08-06 07:59 zno2 阅读(211) 评论(0) 推荐(0) 编辑

安装及运行 RabbitMQ 服务器 (linux) 失败! 安装erlang 失败,无法继续

摘要: 文档 http://www.rabbitmq.com/install-rpm.html 安装前置条件 Before installing RabbitMQ, you must install Erlang. 下载RabbitMQ 提供的 erlang-17.4-1.el6.x86_64.rpm 比其 阅读全文

posted @ 2016-08-06 07:59 zno2 阅读(993) 评论(0) 推荐(0) 编辑

安装及运行 RabbitMQ 服务器 (windows)

摘要: 1. 一些网址 http://www.rabbitmq.com/ http://www.rabbitmq.com/install-windows.html http://www.rabbitmq.com/releases/rabbitmq-server/v3.5.4/rabbitmq-server- 阅读全文

posted @ 2016-08-06 07:59 zno2 阅读(248) 评论(0) 推荐(0) 编辑

RabbitMQ client ( java )

摘要: Maven 依赖 GitHub https://github.com/rabbitmq/rabbitmq-java-client/archives/master 文档 http://www.rabbitmq.com/getstarted.html 基本概念理解 A producer a progra 阅读全文

posted @ 2016-08-06 07:59 zno2 阅读(322) 评论(0) 推荐(0) 编辑

task:scheduled cron 合法

摘要: http://www.quartz-scheduler.org/documentation/quartz-2.x/tutorials/crontrigger.html task:scheduled org.springframework.scheduling.support.CronSequence 阅读全文

posted @ 2016-08-06 07:58 zno2 阅读(821) 评论(0) 推荐(0) 编辑

一)get started with the Quartz project

摘要: 官网 http://www.quartz-scheduler.org/ 下载链接 http://www.terracotta.org/download/reflector.jsp?b=tcdistributions&i=quartz-2.2.2-distribution.tar.gz 提示 开源产品 阅读全文

posted @ 2016-08-06 07:58 zno2 阅读(237) 评论(0) 推荐(0) 编辑

二)quartz.properties

摘要: The Properties File Quartz uses a properties file called (kudos on the originality) quartz.properties. This isn't necessary at first, but to use anyth 阅读全文

posted @ 2016-08-06 07:58 zno2 阅读(133) 评论(0) 推荐(0) 编辑

三)Wiring up jobs using triggers and the SchedulerFactoryBean

摘要: 示例地址: https://github.com/witaste/quartz.git 两种触发器:简单的触发器和cron表达式触发器 阅读全文

posted @ 2016-08-06 07:58 zno2 阅读(211) 评论(0) 推荐(0) 编辑

四)Spring + Quartz

摘要: 使用Quartz默认配置 /* * Copyright 2002-2014 the original author or authors. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may no 阅读全文

posted @ 2016-08-06 07:58 zno2 阅读(468) 评论(0) 推荐(0) 编辑

五)Spring + Quartz 复杂业务的两个问题:获取Spring上下文 和 自动注入服务类

摘要: 配置如下: 为什么要配置这个 因为可以通过这个key取到Spring上下文。 配置1存在的问题:不能自动注入。 配置一改:解决自动注入问题 change to cn.zno.common.SpringBeanJobFactory 另一种实现方式为: 阅读全文

posted @ 2016-08-06 07:58 zno2 阅读(925) 评论(0) 推荐(0) 编辑

六)定时任务持久化

摘要: If you're using JDBC-Jobstore, you will need a DataSource for its use. It is recommended that your DataSource max connection size be configured to be 阅读全文

posted @ 2016-08-06 07:58 zno2 阅读(410) 评论(0) 推荐(0) 编辑

公钥私钥

摘要: (原版) 阅读全文

posted @ 2016-08-06 07:57 zno2 阅读(128) 评论(0) 推荐(0) 编辑

域名如何绑定IP

摘要: 以 http://www.xinnet.com/ 为例 1.登陆新网,进入域名管理,解析 2.进入mydns 添加新的A记录 填写主机名比如:www.xxx.com 填写对应的ip地址:xxx.xxx.xx.xxx 3.还可以设置 转发、别名 ps:什么是DNS https://en.wikiped 阅读全文

posted @ 2016-08-06 07:57 zno2 阅读(685) 评论(0) 推荐(0) 编辑

SSH 密钥登录 SecureCRT

摘要: https://www.qcloud.com/doc/product/213/2036 1.3. 使用SecureCRT登录 1.3.1. 复制公钥 登录腾讯云控制台,点击【云服务器】-【SSH密钥】进入密钥窗口。点击您绑定了Linux云服务器的SSH密钥ID,进入密钥详情页,复制公钥信息。 将公钥 阅读全文

posted @ 2016-08-06 07:57 zno2 阅读(442) 评论(0) 推荐(0) 编辑

文档中心 —— 自行查询关键字

摘要: https://www.qcloud.com/doc/product 阅读全文

posted @ 2016-08-06 07:57 zno2 阅读(126) 评论(0) 推荐(0) 编辑

上一页 1 ··· 8 9 10 11 12 13 14 15 16 ··· 21 下一页

导航