原创 使用Spring Task實現輕量級調度
applicationContext.xml <task:annotation-driven executor="executor" scheduler="scheduler" /> <task:executor id="exec
原创 Mybatis中使用ehcache
maven <!-- 二級緩存 --> <dependency> <groupId>org.mybatis.caches</groupId> <artifactId>mybatis-ehcache</artifac
原创 將spark輸出到hdfs的文本數據壓縮成gzip格式
適合Spark SQL和Spark Structured Streaming 直接上代碼 SparkSession spark = SparkSession .builder()
原创 Mybatis--Mapper文件中使用靜態方法
從前,在if中判斷字符串是這樣的 <update id="update" parameterType="user"> UPDATE test_user <set> <if test="name!=
原创 Apache + Tomcat採用AJP實現負載均衡與session同步
說明:以下是基於Win7 + Apache2.2 + Tomcat7進行的配置 負載均衡 Apache的安裝目錄修改配置文件 Httpd.conf <!-- 打開註釋內容 --> LoadModule proxy_modul
原创 SpringMVC4.1中使用FastJson
pom.xml<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:sc
原创 將java項目部署到ROOT下
在項目名稱上點擊右鍵 --> 屬性 --> web --> 其他的看圖即可, 改完之後直接重新部署項目即可。 點贊 收藏 分享 文章舉報 ichinfun 發佈了29 篇原創
原创 將flink輸出到hdfs的數據壓縮成gzip格式
CompressionOutputStreamWrapper.class import org.apache.hadoop.io.compress.CompressionOutputStream; import java.io.
原创 \t \n(特殊字符)從外部傳入java main方法裏無法正常使用處理
pom導入 <!-- https://mvnrepository.com/artifact/org.apache.commons/commons-text --> <dependency> <groupId>org.apa
原创 Spark對多HDFS集羣Namenode HA的支持
具體的配置需要參考core-site.xml和hdfs-site.xml val sc = new SparkContext() // 多個HDFS的相同配置 sc.hadoopConfiguration.setStrings("fs
原创 Flume NG與MySQL整合開發
1 pom文件配置 <dependencies> <dependency> <groupId>org.apache.flume</groupId> <artifactId>flume-ng-conf
原创 Ambari告警郵件配置
登錄ambari管理頁面,找到Manage Notifications選項創建告警配置告警修改郵件標題 1)下載 alert-templates.xml https://raw.githubusercontent.com/apache
原创 Storm整合HDFS
1.pom文件 <dependencies> <dependency> <groupId>org.apache.storm</groupId> <artifactId>storm-core</art
原创 Linux下Rsync+Inotify-tools實現數據實時同步
rsync+inotify同步邏輯圖 節點說明 主機名 主機IP地址 inotify-master 10.1.1.1 inotify-slave 10.1.1.2 inotify-slave部署 1 安裝rsync
原创 nagios安裝和配置
1.安裝依賴 yum -y install httpd-devel automake autoconf libtool ncurses-devel libxslt groff pcre-devel pkgconfig 2.安裝nagios