ITeye博客

白云天-旭日东升!亮剑!

白云天 · 共 121 篇文章

kubernetes基本框架和基本概念

作者:翼动晴空 链接:https://www.jianshu.com/p/0a656b3d94b2 來源:简书 简书著作权归作者所有,任何形式的转载都请联系作者获得授权并注明出处。 kubernetes基本框架和基本概念 Kubernetes是什么?我(们)为什么使用? Kubernetes主要概念 Kubernetes总体结构 Kubernetes核心原理 Kubernetes网络模型 Kubernetes是什么?我(们)为什么使用? Kubernetes是Google(基于borg)开源的容器集群管理系统,其提供应用部署、维护、 扩展机制等功能,利用Kubernetes能方便地管理跨机器…

2018-07-06 17:49 · 评论(0)

centos7.4上安装mysql5.7记录

准备 CentOS7默认安装了和MySQL有兼容性的MariaDB数据库,在我们安装MySQL5.7之前为了避免发生冲突首先删除MariaDB。 # rpm -qa | grep maria mariadb-libs-5.5.50-1.el7_2.x86_64 # yum remove mariadb-libs -y 添加MySQL的yum源 在CentOS7上yum安装MySQL需使用 MySQL的yum源 。执行以下命令首先添加MySQL的yum源。 # yum localinstall http://dev.mysql.com/get/mysql57-community-release…

2018-03-13 15:46 · 评论(1)

并发调用的一种实现方式

一种在线程池中执行目标代码,异步获取返回值的方式。 仅供参考,欢迎拍砖。 /** * 异步返回结果 * @author benyi * @date 2017-12-9 * */ public class AsyResult { private String tid; private Object result; private boolean finished=false; public AsyResult(String id){ tid=id; finished=false; } public String getId(){ return tid; } public void setRes…

2017-12-09 14:00 · Java性能优化 多核线程 优化 · Java技术 并行调用 线程池 · 评论(0)

ApplicationContextAware dubbo-Reference to RPC

import org.springframework.beans.BeansException; import org.springframework.beans.factory.DisposableBean; import org.springframework.context.ApplicationContext; import org.springframework.context.ApplicationContextAware; import org.springframework.context.annotation.Lazy; import org.springframework…

2017-11-17 09:55 · 评论(0)

docker初探

1、docker , 先从仓库中下载一个和自己的 linux 一致的 centos image 。 命令: docker pull centos 2、运行 centos 镜像,运行起来后成为一个 container image_id 用 docker images 命令查看 docker run -i -t -v /root/software/:/mnt/software/ image_id /bin/bash docker run <相关参数> <镜像 ID> <初始命令> 其中,相关参数包括: -i:表示以“交互模式”运行容器 -t:表示容器启动后会进入其命令行 -v:表示需要将本地哪个…

2017-08-17 16:49 · Java技术 · 科技随笔 · 漫谈云计算 · 评论(1)

java-nio的hello-word

重点注意:有说明的地方。 package nio.chat; import java.net.InetSocketAddress; import java.nio.ByteBuffer; import java.nio.channels.SelectionKey; import java.nio.channels.Selector; import java.nio.channels.ServerSocketChannel; import java.nio.channels.SocketChannel; import java.util.Iterator; public class Serve…

2017-04-27 17:55 · Java技术 · 评论(0)

mysql集群的初步整理

mySql数据库如果采用复制(Replication)方式的群集,在程序中进行读写分离的处理办法有如下几种: 自动主从管理方案有: MHA 官方介绍:https://code.google.com/p/mysql-master-ha/ 1、采用 MySql提供的 ReplicationDriver 驱动程序, 简单的过程如下: 缺点: 无法集成到 Spring 进行读写分离操作。 public static void main(String[] args) throws Exception { ReplicationDriver driver = new ReplicationDriver(…

2017-01-16 14:56 · mysql-数据库 · Java技术 MyCat · 评论(0)

nginx.conf

备份记录,随便笔记 ####################################################################### user nginx; worker_processes 4; worker_cpu_affinity 0001 0010 0100 1000; error_log /var/log/nginx/error.log; pid /var/run/nginx.pid; events { worker_connections 1024; } #-----------------------------------------------…

2016-11-26 14:12 · 评论(0)

mysql5.7安装

1、下载安装包 http://dev.mysql.com/downloads/mysql/#downloads 推荐下载通用安装方法的TAR包(http://cdn.mysql.com//Downloads/MySQL-5.7/mysql-5.7.12-linux-glibc2.5-x86_64.tar)。 2.检查库文件是否存在,如有删除。 [root@localhost Desktop]$ rpm -qa | grep mysql mysql-libs-5.1.52-1.el6_0.1.x86_64 [root@localhost ~]# rpm -e mysql-libs-5.1.52…

2016-11-16 11:37 · 记忆 · 评论(0)

在Karaf中部署Camel-AMP使用jms的记录

本文记录是在 Karaf 环境下使用 camel-amp 的过程,使用的 Apollo 作为 jms 服务器。 package example; import java.util.Date; public class Show { public Show(){ // } public String time(){ return (new Date()).toString(); } public void print(String msg){ System.out.println("-->pring("+msg+")"); } } 使用 camel-spring方式: 在 resources目…

2016-06-03 15:30 · amqp apollo camel karaf · 评论(0)

Easy installation of bundles in Apache Karaf

from: http://aniketos.eu/content/easy-installation-bundles-apache-karaf Apache Karaf provides many convenient ways for bundles installation: Use of the install command in Karaf's command prompt Copying of bundles to the deploy directory Use of Apache Karaf features From these three alternatives Kar…

2016-05-17 17:50 · karaf · 评论(0)

Camel 动态路由以及HttpServletRequest/Reponse的使用

本实验的配置文件 camel-context.xml 内容: <?xml version="1.0" encoding="UTF-8"?> <beans xmlns="http://www.springframework.org/schema/beans" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation=" http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-…

2016-05-17 16:39 · jetty camel dynamicRouter · 评论(0)

Camel的direct,Bean测试

//处理Bean import java.io.ByteArrayInputStream; import java.util.Date; import java.util.Map; import org.apache.camel.Exchange; import org.apache.camel.Message; public class TestBean { public TestBean(){ super(); } public String showBody(Exchange exchange) throws Exception { System.out.println("\r\n\r…

2016-05-14 19:00 · 评论(5)

Camel 2.17 手册

Apache Camel User Guide Version 2.17.0 Copyright 2007-2015, Apache Software Foundation Table of Contents Table of Contents Introduction Quickstart Getting Started Architecture Enterprise Integration Patterns Cook Book Tutorials Language Appendix DataFormat Appendix Pattern Appendix Component Append…

2016-05-11 17:32 · 评论(0)

Camel Bean的简单例子

web.xml <?xml version="1.0" encoding="ISO-8859-1"?> <web-app version="2.4" xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd"> <display-name>My Web Applica…

2016-05-10 15:15 · 评论(3)