As one of the core frameworks of the Hyperledger, Fabric provides users with private transaction space with its multi-channel design. In order to solve the problem of multi-channel resource load balancing based on distributed architecture, a Blockchain as a Service (BaaS) load balancing scheduling algorithm SC-channel based on NJW spectral clustering was proposed. The proposed algorithm took the number of platform sub-nodes as the basis for classifying the number of clusters. Firstly, based on channel the Jaccard coefficient between peer was used to construct the similarity matrix. Secondly, the Laplacian matrix was calculated to obtain the first k eigenvalues and eigenvectors, and the eigenvectors were unitized. Finally, the feature clustering was done using the classical weight-based k-means algorithm. The proposed algorithm was validated on the Kubernetes platform and its resource balance degree was compared with those of the NJW algorithm using the classic k-means and the default scheduling algorithm. Theoretical analysis and experimental results show that the BaaS resource load balancing scheduling algorithm based on spectral clustering can improve the balance of resource utilization and enhance the usability and reliability of the platform.
[1] Nakamoto S. Bitcoin: A peer-to-peer electronic cash system[DB/OL].(2006)[2019-5-26]. https://bitcoin.org/bitcoin.pdf.
[2] 邵奇峰, 金澈清, 张召, 等. 区块链技术: 架构及进展[J]. 计算机学报, 2018, 41(5): 969-988. Shao Q F, Jin C Q, Zhang Z, et al. Blockchain: architecture and research progress[J]. Chinese Journal of Computers, 2018, 41(5): 969-988. (in Chinese)
[3] Blockchain As A Service[EB/OL]. (2017)[2019-6-28].https://it.toolbox.com/blogs/trevoreddolls/blockchain-as-a-service-042317.
[5] 龚正. Kubernetes权威指南: 从Docker到Kubernetes实践全接触[M]. 北京: 电子工业出版社, 2017:12-14, 238-242. Gong Z. Kubernetes definitive guide: from Docker to Kubernets practice[M]. Beijing: Publishing House of Electronics industry, 2017: 12-14, 238-242. (in Chinese)
[6] 才丽. 面向BaaS平台的资源调度算法研究与实现[D]. 杭州: 浙江大学, 2018. Cai L. The BaaS platform orientated research and implementation for scheduling algorithm[D]. Hangzhou: Zhejiang University, 2018. (in Chinese)
[8] Nga Y, Jordanm I, Weiss Y. On spectral clustering: analysis and an algorithm[C]//Proceedings of the 14th Advances in Neural Information Processing System, 2002:849-856.
[9] 蔡晓妍, 戴冠中, 杨黎斌. 谱聚类算法综述[J]. 计算机科学, 2008, 35(7): 14-18. Cai X Y, Dai G Z, Yang L B. Survey on spectral clustering algorithms[J]. Computer Science, 2008, 35(7): 14-18. (in Chinese)
[10] 于佐军, 秦欢. 基于改进蜂群算法的K-means算法[J]. 控制与决策, 2018, 33(1): 181-185. Yu Z J, Qin H. K-means algorithm based on improved artificial bee colony algorithm[J]. Control and Decision, 2018, 33(1): 181-185. (in Chinese)
[11] Bouguettaya A, Yu Q, Liu X M, et al. Efficient agglomerative hierarchical clustering[J]. Expert Systems With Applications, 2015, 42(5): 2785-2797.
[12] Tran T N, Drab K, Daszykowski M. Revised DBSCAN algorithm to cluster data with dense adjacent clusters[J]. Chemometrics and Intelligent Laboratory Systems, 2013, 120: 92-96.
[13] Perona P, Freeman W. A factorization approach to grouping[C]//Computer Vision—ECCV'98. Berlin, Heidelberg: Springer Berlin Heidelberg, 1998: 655-670.
[14] Shi J B, Malik J. Normalized cuts and image segmentation[J]. IEEE Transactions on Pattern Analysis and Machine Intelligence, 2000, 22(8): 888-905.
[15] 陈俊芬, 张明, 何强. 基于启发式确定类数的NJW谱聚类算法[J]. 计算机科学, 2018, 45(S2): 474-479. Chen J F, Zhang M, He Q. Heuristically determining cluster numbers based NJW spectral clustering algorithm[J]. Computer Science, 2018, 45(S2): 474-479. (in Chinese)
[16] Zeng C P, Zhou A M, Zhang G X. Self-adaptive spectral cluster number detecting with particle swarm optimization algorithm[C]//2016 IEEE Congress on Evolutionary Computation (CEC). July 24-29, 2016, Vancouver, BC, Canada. IEEE, 2016: 4607-4611.
[17] Li Y Y, Wang Y, Wang Y Y, et al. Quantum clustering using kernel entropy component analysis[J]. Neurocomputing, 2016, 202: 36-48.
[18] Xie J Y, Zhou Y, Ding L J. Local standard deviation spectral clustering[C]//2018 IEEE International Conference on Big Data and Smart Computing (BigComp). January 15-17, 2018, Shanghai, China. IEEE, 2018: 242-250.
[19] Zelnik-Manor L, Perona P. Spectral kernel methods for clustering[C]//Advances in Neural Information Processing Systems 14. Cambridge MA: The MIT Press, 2002.
[20] Mohanavalli S, Jaisakthi S M, Aravindan C. Automatic scale parameters in affinity matrix construction for improved spectral clustering[J]. International Journal of Pattern Recognition and Artificial Intelligence, 2016, 30(10): 1650023.
[21] 谢娟英, 丁丽娟. 完全自适应的谱聚类算法[J]. 电子学报, 2019, 47(5): 1000-1008. Xie J Y, Ding L J. The true self-adaptive spectral clustering algorithms[J]. Acta Electronica Sinica, 2019, 47(5): 1000-1008. (in Chinese)