JAVA8 ArrayBloackingQueue源码分析


构造函数用于创建一个带有给定的(固定)容量和默认访问策略的 ArrayBlockingQueue。 public ArrayBlockingQueue(int capacity, boolean fair) { // 初始容量必须大于0 if (capacity <= 0) throw new Il

kubernetes系列:(二)、kubernetes部署mysql(单节点)


from https://www.cnblogs.com/haoprogrammer/p/10827287.html 一、环境说明 kubernetes 1.13.1 docker 18.06.1-ce mysql 5.7 一、创建mysql-pv.yaml,用来将mysql存储的数据放到宿主

Mysql解压版 Centos安装


1.install #!/bin/bash /mysql/bin/mysql_install_db –user=service –basedir=/mysql/ –datadir=/mysql_data/ 2.init #!/bin/bash nohup /mysql/bin/mysqld –dat

Scala try-with-resources


def using[A, B <: {def close() : Unit}](closeable: B)(f: B => A): A = try { f(closeable) } finally { closeable.close() } 用法

常用排序算法JAVA实现


import java.util.Arrays; public class Sort { public static int[] nums = {49, 38, 65, 97, 76, 13, 27, 49, 78, 34, 12, 64, 5, 4, 62, 99, 98, 54, 56

javax Filter实现重定向


public class ProxyFilter implements Filter { @Override public void init(FilterConfig filterConfig) { } @Override publ

Hive常用语法


动态分区导入 set hive.exec.dynamici.partition=true; set hive.exec.dynamic.partition.mode=nonstrict; 随机范围日期 select cast(rand()*(1561910400-1514736000)+151473

apache kylin streaming table


1. 无法找到 org.apache.kafka.clients.consumer.Consumer 确认kylin-server的服务器上安装了kafka,且kafka对应的版本为 kylin中依赖的版本 kafka-2.11_1.0.0 由于此版本无法找到,更高版本的是否支持未验证 You ne

Code for parquet writer


import com.sf.presto.jdbc.internal.airlift.slice.Slice; import com.sf.presto.jdbc.internal.airlift.slice.Slices; import org.apache.hadoop.conf.Configu

Code for Presto TestCase


/* * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may o