发布一个k8s部署视频:https://edu.youkuaiyun.com/course/detail/26967
课程内容:各种k8s部署方式。包括minikube部署,kubeadm部署,kubeasz部署,rancher部署,k3s部署。包括开发测试环境部署k8s,和生产环境部署k8s。
腾讯课堂连接地址https://ke.qq.com/course/478827?taid=4373109931462251&tuin=ba64518
第二个视频发布 https://edu.youkuaiyun.com/course/detail/27109
腾讯课堂连接地址https://ke.qq.com/course/484107?tuin=ba64518
介绍主要的k8s资源的使用配置和命令。包括configmap,pod,service,replicaset,namespace,deployment,daemonset,ingress,pv,pvc,sc,role,rolebinding,clusterrole,clusterrolebinding,secret,serviceaccount,statefulset,job,cronjob,podDisruptionbudget,podSecurityPolicy,networkPolicy,resourceQuota,limitrange,endpoint,event,conponentstatus,node,apiservice,controllerRevision等。
第三个视频发布:https://edu.youkuaiyun.com/course/detail/27574
详细介绍helm命令,学习helm chart语法,编写helm chart。深入分析各项目源码,学习编写helm插件
————————————————------------------------------------------------------------------------------------------------------------------
package com.data.struct;
import java.util.concurrent.CountDownLatch;
public class MultiThreadMatrixMultipy {
static int[][]a=new int[][]{
{1,2,3,4},
{5,6,7,8},
{9,10,11,12},
{13,14,15,16}
};
static int[][]b=new int[][]{
{1,3,5,7},
{2,4,6,8},
{11,13,15,17},
{12,14,16,18}
};
static int[][]c=new int[a.length][a.length];
private static void matrixFirstLoop(int[][]a,int[][]b,int[][]c,int i,int i2,CountDownLatch cdl)throws Exception{
if(i==i2){
CountDownLatch cd=new CountDownLatch(2);
matrixSecondLoop(a,b,c,i,0,b.length-1,cd);
}else{
int mid=(i+i2)/2;
new maxtrixFirstThread(a,b,c,i,mid,cdl).start();
new maxtrixFirstThread(a,b,c,mid+1,i2,cdl).start();
cdl.await();
}
}
private static void matrixSecondLoop(int[][]a,int[][]b,int[][]c,int i,int j,int j2,CountDownLatch cdl)throws Exception{
int n=c.length;
if(j==j2){
c[i][j]=0;
for(int k=0;k<n;k++){
c[i][j]=c[i][j]+a[i][k]*b[k][j];
}
}else{
int mid2=(j+j2)/2;
new maxtrixSecondThread(a,b,c,i,j,mid2,cdl).start();
new maxtrixSecondThread(a,b,c,i,mid2+1,j2,cdl).start();
cdl.await();
}
}
private static class maxtrixFirstThread extends Thread{
private int[][]a;
private int[][]b;
private int[][]c;
private int i;
private int i2;;
private CountDownLatch cdl;
public maxtrixFirstThread(int[][]a,int[][]b,int[][]c,int i,int i2,CountDownLatch cdl){
this.a=a;
this.b=b;
this.c=c;
this.i=i;
this.i2=i2;
this.cdl=cdl;
}
@Override
public void run() {
try {
CountDownLatch cdlnext=new CountDownLatch(2);
matrixFirstLoop(a,b,c,i,i2, cdlnext);
cdl.countDown();
} catch (Exception e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
}
}
private static class maxtrixSecondThread extends Thread{
private int[][]a;
private int[][]b;
private int[][]c;
private int j;
private int j2;
private int i;
private CountDownLatch cdl;
public maxtrixSecondThread(int[][]a,int[][]b,int[][]c,int i,int j,int j2,CountDownLatch cdl){
this.a=a;
this.b=b;
this.c=c;
this.j=j;
this.j2=j2;
this.cdl=cdl;
this.i=i;
}
@Override
public void run() {
try {
CountDownLatch cdlnext=new CountDownLatch(2);
matrixSecondLoop(a,b,c,i,j,j2, cdlnext);
cdl.countDown();
} catch (Exception e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
}
}
private static int[][] ordernaryMultipy(int [][] a,int[][]b){
int n=a.length;
int [][] c=new int[n][n];
for(int i=0;i<n;i++){
for(int j=0;j<n;j++){
for(int k=0;k<n;k++){
c[i][k]+=a[i][j]*b[j][k];
}
}
}
return c;
}
public static void printC(){
for(int i=0;i<c.length;i++){
for(int j=0;j<c[i].length;j++){
System.out.print(c[i][j]+" ");
}
System.out.println();
}
}
public static void main(String[] args)throws Exception {
CountDownLatch cdlnext=new CountDownLatch(2);
matrixFirstLoop(a,b,c,0,a.length-1,cdlnext);
cdlnext.await();
printC();
}
}