上一页 1 ··· 16 17 18 19 20 21 22 23 24 ··· 167 下一页
摘要: import java.util.concurrent.ExecutorService; import java.util.concurrent.Executors; import java.util.concurrent.Semaphore; public class SemaphoreTest1 { private static final int SEM_MAX = 10... 阅读全文
posted @ 2018-07-19 11:43 无天666 阅读(2326) 评论(0) 推荐(0)
摘要: package com.test; import java.util.concurrent.CyclicBarrier; import java.util.concurrent.BrokenBarrierException; public class CyclicBarrierTest1 { private static int SIZE = 5; private stati... 阅读全文
posted @ 2018-07-19 11:29 无天666 阅读(297) 评论(0) 推荐(0)
摘要: package com.test; import java.util.concurrent.CountDownLatch; import java.util.concurrent.CyclicBarrier; public class CountDownLatchTest1 { private static int LATCH_SIZE = 5; private static... 阅读全文
posted @ 2018-07-19 11:02 无天666 阅读(223) 评论(0) 推荐(0)
摘要: package com.test; import java.util.concurrent.locks.ReadWriteLock; import java.util.concurrent.locks.ReentrantReadWriteLock; public class ReadWriteLockTest1 { public static void main(String[... 阅读全文
posted @ 2018-07-19 10:34 无天666 阅读(162) 评论(0) 推荐(0)
摘要: LockSupport是通过调用Unsafe函数中的接口实现阻塞和解除阻塞的。 park和wait的区别。wait让线程阻塞前,必须通过synchronized获取同步锁。 阅读全文
posted @ 2018-07-19 09:40 无天666 阅读(241) 评论(0) 推荐(0)
摘要: 安装所需环境 Nginx 是 C语言 开发,建议在 Linux 上运行,当然,也可以安装 Windows 版本,本篇则使用 CentOS 7 作为安装环境。 一. gcc 安装安装 nginx 需要先将官网下载的源码进行编译,编译依赖 gcc 环境,如果没有 gcc 环境,则需要安装: 二. PCR 阅读全文
posted @ 2018-07-16 20:47 无天666 阅读(231) 评论(0) 推荐(0)
摘要: © 版权声明:本文为博主原创文章,转载请注明出处 1. 目的 因为想要学习redis,因此在虚拟机中安装了redis,为了实现在物理机可以访问redis,弄了好久;因此记录下来,以免忘记。 2. 环境 虚拟机:CentOS Linux release 7.4.1708 (Core) redis:4. 阅读全文
posted @ 2018-07-16 20:10 无天666 阅读(418) 评论(0) 推荐(0)
摘要: 1、安装redis 第一步:下载redis安装包 wget http://download.redis.io/releases/redis-4.0.6.tar.gz 1 2 3 4 5 6 7 8 9 10 11 [root@iZwz991stxdwj560bfmadtZ local]# wget 阅读全文
posted @ 2018-07-16 19:46 无天666 阅读(160) 评论(0) 推荐(0)
摘要: 1、登陆mysql数据库 mysql -u root -p 查看user表 mysql> use mysql;Database changedmysql> select host,user,password from user;+ + + +| host | user | password |+ + 阅读全文
posted @ 2018-07-16 19:21 无天666 阅读(743) 评论(0) 推荐(0)
摘要: CentOS7默认数据库是mariadb,配置等用着不习惯,因此决定改成mysql,但是CentOS7的yum源中默认好像是没有mysql的。为了解决这个问题,我们要先下载mysql的repo源。 1.下载mysql的repo源 $ wget http://repo.mysql.com/mysql- 阅读全文
posted @ 2018-07-16 19:11 无天666 阅读(253) 评论(0) 推荐(0)
上一页 1 ··· 16 17 18 19 20 21 22 23 24 ··· 167 下一页