11.CacheManager源码分析

Java安全框架Shiro:认证授权与会话管理详解 Java安全框架是构建企业级应用的重要基础设施,负责处理认证、授权等核心安全功能。Apache Shiro作为轻量级安全框架,通过分层架构设计实现了认证授权、会话管理和加密等模块的解耦。其核心价值在于提供简单一致的API,支持从Web应用到命令行工具的各种部署环境。在认证方面,Shiro采用Realm作为数据源适配层,支持多因素认证策略;授权机制则提供基于角色和权限的细粒度访问控制。典型应用场景包括Spring Boot集成、分布式会话管理以及微服务安全网关等。本文以Shiro框架为例,深入解析其认证流程源 阅读详情

先来张原理图:


从rdd的iterator方法开始  , 因为在读取rdd的数据时是从iterator方法开始迭代数据的:
  1. /**
  2. * Internal method to this RDD; will read from cache if applicable, or otherwise compute it.
  3. * This should ''not'' be called by users directly, but is available for implementors of custom
  4. * subclasses of RDD.
  5. *
  6. * RDD的迭代方法 , 获取RDD中的数据
  7. */
  8. final def iterator(split: Partition, context: TaskContext): Iterator[T] = {
  9. // 如果StorageLevel不为NONE , 表示之前持久化过RDD那么就不直接去从父RDD执行算子计算新的RDD的partition
  10. // 优先尝试使用CacheManager去获取持久化的数据
  11. if (storageLevel != StorageLevel.NONE) {
  12. // CacheManager
  13. SparkEnv.get.cacheManager.getOrCompute(this, split, context, storageLevel)
  14. } else {
  15. computeOrReadCheckpoint(split, context)
  16. }
  17. }

1. 首先深入Cachemanager的getOrCompute方法 , 源码如下:
  1. def getOrCompute[T](
  2. rdd: RDD[T],
  3. partition: Partition,
  4. context: TaskContext,
  5. storageLevel: StorageLevel): Iterator[T] = {
  6. val key = RDDBlockId(rdd.id, partition.index)
  7. logDebug(s"Looking for partition $key")
  8. // 直接用BlockManager来获取数据 , 如果获取到了那就直接返回就好了
  9. blockManager.get(key) match {
  10. case Some(blockResult) =>
  11. // Partition is already materialized, so just return its values
  12. val inputMetrics = blockResult.inputMetrics
  13. val existingMetrics = context.taskMetrics
  14. .getInputMetricsForReadMethod(inputMetrics.readMethod)
  15. existingMetrics.incBytesRead(inputMetrics.bytesRead)
  16. val iter = blockResult.data.asInstanceOf[Iterator[T]]
  17. new InterruptibleIterator[T](context, iter) {
  18. override def next(): T = {
  19. existingMetrics.incRecordsRead(1)
  20. delegate.next()
  21. }
  22. }
  23. // 如果BlockManager没有获取到数据 , 虽然rdd持久化过但是因为未知的原因数据既不在本地内存或磁盘也不再远程的BlockManager上
  24. // 那么需要做后续的处理
  25. case None =>
  26. // 再次尝试一次BlockManager的get方法去获取数据 , 如果获取到了就直接返回数据若是没有获取到继续往后走
  27. val storedValues = acquireLockForPartition[T](key)
  28. if (storedValues.isDefined) {
  29. return new InterruptibleIterator[T](context, storedValues.get)
  30. }
  31. // Otherwise, we have to load the partition ourselves
  32. try {
  33. logInfo(s"Partition $key not found, computing it")
  34. // 如果computeOrReadCheckpoint()方法 , 如果rdd之前checkPoint过 , 那么就尝试读取它的checkpoint
  35. // 但是如果rdd没有checkpoint过 , 那么此时就别无选择 , 只能重新使用父rdd的数据执行算子计算一份
  36. val computedValues = rdd.computeOrReadCheckpoint(partition, context)
  37. // If the task is running locally, do not persist the result
  38. if (context.isRunningLocally) {
  39. return computedValues
  40. }
  41. // Otherwise, cache the values and keep track of any updates in block statuses
  42. val updatedBlocks = new ArrayBuffer[(BlockId, BlockStatus)]
  43. // 由于走CacheManager肯定意味着rdd是设置过持久化级别的
  44. // 只是因为某些原因持久化的数据没有找到那么才会走到这里来
  45. // 所以读取了checkpoint数据或者是重新计算数据之后要用putInBlockManager方法将数据在BlockManager中持久化一份
  46. val cachedValues = putInBlockManager(key, computedValues, storageLevel, updatedBlocks)
  47. val metrics = context.taskMetrics
  48. val lastUpdatedBlocks = metrics.updatedBlocks.getOrElse(Seq[(BlockId, BlockStatus)]())
  49. metrics.updatedBlocks = Some(lastUpdatedBlocks ++ updatedBlocks.toSeq)
  50. new InterruptibleIterator(context, cachedValues)
  51. } finally {
  52. loading.synchronized {
  53. loading.remove(key)
  54. loading.notifyAll()
  55. }
  56. }
  57. }
  58. }
上面的代码就是说一步一步往持久化级别更低的方式去获取数据 , 先内存在磁盘 , 最后若是走到了putInBlockManager方法那就表示这一份数据是经过父RDD重新计算得来,
那么本身这份数据是设置过持久化级别的但是就是在通过CacheManager获取数据时失败那么就需要再一次将这份数据持久化 , putInBlockManager方法源码如下:
  1. private def putInBlockManager[T](
  2. key: BlockId,
  3. values: Iterator[T],
  4. level: StorageLevel,
  5. updatedBlocks: ArrayBuffer[(BlockId, BlockStatus)],
  6. effectiveStorageLevel: Option[StorageLevel] = None): Iterator[T] = {
  7. val putLevel = effectiveStorageLevel.getOrElse(level)
  8. // 如果持久化级别没有指定内存级别仅仅是纯磁盘的级别
  9. if (!putLevel.useMemory) {
  10. /*
  11. * This RDD is not to be cached in memory, so we can just pass the computed values as an
  12. * iterator directly to the BlockManager rather than first fully unrolling it in memory.
  13. */
  14. updatedBlocks ++=
  15. // 那么直接调用BlockManager的putIterator()方法将数据写入磁盘即可
  16. blockManager.putIterator(key, values, level, tellMaster = true, effectiveStorageLevel)
  17. blockManager.get(key) match {
  18. case Some(v) => v.data.asInstanceOf[Iterator[T]]
  19. case None =>
  20. logInfo(s"Failure to store $key")
  21. throw new BlockException(key, s"Block manager failed to return cached value for $key!")
  22. }
  23. // 如果指定了内存存储级别
  24. } else {
  25. /*
  26. * This RDD is to be cached in memory. In this case we cannot pass the computed values
  27. * to the BlockManager as an iterator and expect to read it back later. This is because
  28. * we may end up dropping a partition from memory store before getting it back.
  29. *
  30. * In addition, we must be careful to not unroll the entire partition in memory at once.
  31. * Otherwise, we may cause an OOM exception if the JVM does not have enough space for this
  32. * single partition. Instead, we unroll the values cautiously, potentially aborting and
  33. * dropping the partition to disk if applicable.
  34. */
  35. // 这里会调用MemoryStore的unrollSafely()方法尝试将数据写入内存
  36. // 如果unrollSafely()方法判断数据可以写入内存那么写入 , 反之则只能写入文件
  37. blockManager.memoryStore.unrollSafely(key, values, updatedBlocks) match {
  38. case Left(arr) =>
  39. // We have successfully unrolled the entire partition, so cache it in memory
  40. updatedBlocks ++=
  41. blockManager.putArray(key, arr, level, tellMaster = true, effectiveStorageLevel)
  42. arr.iterator.asInstanceOf[Iterator[T]]
  43. case Right(it) =>
  44. // There is not enough space to cache this partition in memory
  45. val returnValues = it.asInstanceOf[Iterator[T]]
  46. // 如果有些数据是在无法写入内存那么就判断数据是否有磁盘级别 , 有的话就写入磁盘
  47. if (putLevel.useDisk) {
  48. logWarning(s"Persisting partition $key to disk instead.")
  49. val diskOnlyLevel = StorageLevel(useDisk = true, useMemory = false,
  50. useOffHeap = false, deserialized = false, putLevel.replication)
  51. putInBlockManager[T](key, returnValues, level, updatedBlocks, Some(diskOnlyLevel))
  52. } else {
  53. returnValues
  54. }
  55. }
  56. }
  57. }
在深入到unrollSafely()方法尝试将数据写入内存 :
  1. def unrollSafely(
  2. blockId: BlockId,
  3. values: Iterator[Any],
  4. droppedBlocks: ArrayBuffer[(BlockId, BlockStatus)])
  5. : Either[Array[Any], Iterator[Any]] = {
  6. // Number of elements unrolled so far
  7. var elementsUnrolled = 0
  8. // Whether there is still enough memory for us to continue unrolling this block
  9. var keepUnrolling = true
  10. // Initial per-thread memory to request for unrolling blocks (bytes). Exposed for testing.
  11. val initialMemoryThreshold = unrollMemoryThreshold
  12. // How often to check whether we need to request more memory
  13. val memoryCheckPeriod = 16
  14. // Memory currently reserved by this thread for this particular unrolling operation
  15. var memoryThreshold = initialMemoryThreshold
  16. // Memory to request as a multiple of current vector size
  17. val memoryGrowthFactor = 1.5
  18. // Previous unroll memory held by this thread, for releasing later (only at the very end)
  19. val previousMemoryReserved = currentUnrollMemoryForThisThread
  20. // Underlying vector for unrolling the block
  21. var vector = new SizeTrackingVector[Any]
  22. // Request enough memory to begin unrolling
  23. keepUnrolling = reserveUnrollMemoryForThisThread(initialMemoryThreshold)
  24. if (!keepUnrolling) {
  25. logWarning(s"Failed to reserve initial memory threshold of " +
  26. s"${Utils.bytesToString(initialMemoryThreshold)} for computing block $blockId in memory.")
  27. }
  28. // Unroll this block safely, checking whether we have exceeded our threshold periodically
  29. try {
  30. while (values.hasNext && keepUnrolling) {
  31. vector += values.next()
  32. if (elementsUnrolled % memoryCheckPeriod == 0) {
  33. // If our vector's size has exceeded the threshold, request more memory
  34. val currentSize = vector.estimateSize()
  35. if (currentSize >= memoryThreshold) {
  36. val amountToRequest = (currentSize * memoryGrowthFactor - memoryThreshold).toLong
  37. // Hold the accounting lock, in case another thread concurrently puts a block that
  38. // takes up the unrolling space we just ensured here
  39. accountingLock.synchronized {
  40. if (!reserveUnrollMemoryForThisThread(amountToRequest)) {
  41. // If the first request is not granted, try again after ensuring free space
  42. // If there is still not enough space, give up and drop the partition
  43. val spaceToEnsure = maxUnrollMemory - currentUnrollMemory
  44. // 反复判断只要还有数据需要写入内存并且可以继续尝试写入内存那么就判断内存大小是否够用
  45. // 如果不够用的话调用ensureFreeSpace()反复尝试清空一些内存空间
  46. if (spaceToEnsure > 0) {
  47. val result = ensureFreeSpace(blockId, spaceToEnsure)
  48. droppedBlocks ++= result.droppedBlocks
  49. }
  50. keepUnrolling = reserveUnrollMemoryForThisThread(amountToRequest)
  51. }
  52. }
  53. // New threshold is currentSize * memoryGrowthFactor
  54. memoryThreshold += amountToRequest
  55. }
  56. }
  57. elementsUnrolled += 1
  58. }
  59. if (keepUnrolling) {
  60. // We successfully unrolled the entirety of this block
  61. Left(vector.toArray)
  62. } else {
  63. // We ran out of space while unrolling the values for this block
  64. logUnrollFailureMessage(blockId, vector.estimateSize())
  65. Right(vector.iterator ++ values)
  66. }
  67. } finally {
  68. // If we return an array, the values returned do not depend on the underlying vector and
  69. // we can immediately free up space for other threads. Otherwise, if we return an iterator,
  70. // we release the memory claimed by this thread later on when the task finishes.
  71. if (keepUnrolling) {
  72. val amountToRelease = currentUnrollMemoryForThisThread - previousMemoryReserved
  73. releaseUnrollMemoryForThisThread(amountToRelease)
  74. }
  75. }
  76. }

最后在看看putIterator方法将数据写入磁盘:
  1. def putIterator(
  2. blockId: BlockId,
  3. values: Iterator[Any],
  4. level: StorageLevel,
  5. tellMaster: Boolean = true,
  6. effectiveStorageLevel: Option[StorageLevel] = None): Seq[(BlockId, BlockStatus)] = {
  7. require(values != null, "Values is null")
  8. doPut(blockId, IteratorValues(values), level, tellMaster, effectiveStorageLevel)
  9. }
其实还是调用了BlockManager的doPut方法 , doPut方法调用就是上一章节讲到的BlockManager原理咯 , 这里不在分析
以上就是CacheManager的整个过程 , 其实从我们的代码中设置rdd的持久化persist开始 , CacheManager就开始工作 , 将数据持久化 , 当后面在需要用到这个rdd的时候 , 调用rdd的iterator方法开始找寻持久化的rdd对应的那份数据 , 若是没有找到则从父RDD重新计算并再一次进行持久化 ,这就是CacheManager的整个作用 !



Arduino程序设计(十四)舵机控制实验(SG90) 本文介绍SG90舵机控制原理及实验,主要内容有:1、介绍SG90舵机;2、舵机0°~180°来回转动;3、串口控制舵机转动固定角度。(1)舵机是一种位置(角度)伺服的驱动器。舵机只是一种通俗的叫法,其实质是一个伺服马达。在需要角度不断变化并可以保持的控制系统中应用广泛。如遥控机械人、飞机模型等。(2)舵机的转动角度为0~180°,其内部结构包括电机,控制电路和机械结构三部分。电机有三根线引出,分别接VCC、GNG和信号线。 阅读详情

相关推荐

极空间NAS零基础部署Wiki.js:Docker+PostgreSQL全流程避坑指南

本文提供了一份在极空间NAS上从零部署Wiki.js私有知识库的详细指南。通过Docker容器化技术,结合PostgreSQL数据库,手把手讲解环境准备、核心组件配置、性能优化及安全加固等全流程,并特别针对极空间平台特性提供了避坑要点,帮助用户打造安全、高效、自主可控的知识管理系统。

3a9bq4r8t2y的博客 490

cacheManager彻底解密

一:CacheManager分析: 1, CacheManager管理的缓存,而缓存可以是基于内存的缓存,也可以是基于磁盘的缓存; 2, CacheManager需要通过BlockManager来操作数据; 3, 当Task运行的时候会调用RDD的compute方法进行计算,而compute方法会调用iterator方法: /**  * Internal method to this R

a11a2233445566的专栏 2443

C# 8. 在新窗口中使用chart控件波形移动显示

1. 添加新窗口 在Form1中新建button控件,名称为buttonStartWaveDisp,这样单击就能调出Form2窗口 在Form1中增加如下: private void buttonStartWaveDisp_Click(object sender, EventArgs e) { if((form2 == null) || (form2.IsDisposed == true)) { form2 = new Form2();

TrueLink的博客 1435

cachemanager

cachemanager多个都存在它取那个呢?

risc123456的博客 800

SolidWorks 2022 学习(一)软件安装

接下来是安装SolidWorks,右键SolidWorks.2022.SP0.Premium.DVD.iso,选择装载。然后以管理员身份运行SolidWorks_Flexnet_Server目录下的server_install.bat。更改需要安装的产品,以及安装路径,并勾选接受条款,点击现在安装,会弹出如下窗口。然后以管理员身份运行setup.exe,开始安装solidworks。下载链接会在文章末尾给出,下载完成的文件如下图所示。双击注册表文件,然后点击确定。保持不动,点击确定,开始安装。

qq_38383364的博客 3145

高温环境下(100℃以上)相机的几种保障方案

高温环境下相机保障措施摘要:针对120℃以上高温环境,相机需采取多重防护:1.散热设计采用金属机身、散热鳍片或风扇;2.关键部件选用耐高温材料(铝合金、特种玻璃);3.电子元件需军规级芯片并做三防处理;4.建议外接电源或耐高温电池。工业相机(如FLIR A655sc、Basler ace)及特种机型(Ximea xiQ)具备高温适应性,普通相机可加装隔热套件配合冷却系统。选择时需关注传感器信噪比和全局快门性能,并设置温度监控保护机制。注意高温会加速设备老化,需定期检测维护。(149字)

start_up_go的博客 1599

CacheManager

##spark 缓存 调用rdd的cache方法 一,把rdd放入sparkcontext的persistrdd的map中(怎么使用还没搞清楚) 二,设置rdd的storagelevel 在work执行的时候根据rdd的storagelevel觉得是否使用缓存 ...

github_28583061的博客 106

TC3XX - MCAL知识点(三):MCU EB-tresos配置说明及代码浅析

AURIX 2G Tc3xx的配置相较AURIX 1G Tc2xx来讲简化了许多,但是依赖于数据手册的理解来讲整个MCU功能做了较大增强,此处先简单的介绍一下,本文前期先补充介绍一下英飞凌手册的阅读规则,因为后面的文章会基于此文的一些缩写进行截图寄存器之类的。MCU在AUTOSAR架构里面的图示如下MCU驱动程序负责配置SCU、GTM、CCU6、GPT12和STM外设。驱动程序提供由AUTOSAR指定的运行时服务。

梦想技术家 2881

Cache Manager

package com.system.utils; import java.io.ByteArrayInputStream; import java.io.ByteArrayOutputStream; import java.io.ObjectInputStream; import java.io.ObjectOutputStream; import java.util.Map; import

YH的博客 447

生成mm grounding dino的onnx模型并在x-anylabeling中使用

X-AnyLabeling 是一款cvhub开发的交互式自动标注工具,其基于AnyLabeling进行构建和二次开发,在此基础上扩展并支持了许多的模型和功能,并借助Segment Anything和YOLO等主流模型提供强大的 AI 支持。其最新版基于grounding dino可以实现开放词汇检测及生成掩码。2024年,MMDet 3.3.0提出了 MM-Grounding-DINO。

blanokvaffy的博客 1734

一个服务如何被找到、被调用、被看见:注册中心、发布注册、发现调用与服务监控的治理闭环

服务数量一多,“对方在哪儿”就成了时刻变化的变量。本文沿发布、注册、发现、调用、监控的治理闭环展开:注册中心的数据模型、健康检查与AP/CP取舍,自我保护、推空保护与本地快照三道自保机制;服务发布的启动器、动态代理、发布管理器、协议服务器与登记顺序;消费端的服务目录、请求ID配对、六种集群容错与三种发现模式;日志、指标、链路三支柱与熔断舱壁。配套五个Java演示程序实测:默认参数下宕机实例平均240秒才被摘除,优雅下线可降至45秒,统计窗口长于租约会让自我保护失效,尾部采样可捕获全部慢请求。

曾经“等你生日那天”都遥远得像未来,如今却可欢愉的挥手说“下个十年见” 169万+

CacheManager原理剖析

前景:Task ——》 RDD(iterator方法) ——》计算当前Task要计算出来的那个partition 情景1: 该RDD是持久化过的:那么StorageLevel肯定不是NONE,则会使用CacheManager去帮助我们直接读取持久化过的数据 情景1.1:BlockManager,先尝试从本地读取(getLocal),或从远程获取(getRemote) 情景1.2:...

威少(微笑) 692

基于Simulink的PR(比例谐振)控制器在单相整流中的应用

本文详细介绍了基于Simulink的单相整流系统中PR(比例谐振)控制器的设计与实现方法。首先阐述了PR控制器相较于传统PI控制器的优势,能够有效消除交流信号跟踪中的稳态误差。接着系统讲解了PR控制器的传递函数原理、实用型设计(带带宽)及参数整定方法。通过Simulink建模步骤,包括主功率电路搭建、电压外环PI设计、电流指令生成、PR控制器实现(推荐MATLAB Function方法)和SPWM调制等关键环节。仿真对比显示PR控制在电流跟踪精度(THD仅1.9%)、功率因数(0.998)和动态响应(突变恢

amy_mhd的博客 698

Spring源码分析-Cache

文章目录缓存简介缓存命中率缓存策略Eviction policyTTL(Time To Live )TTI(Time To Idle)Cache@EnableCaching@CachePut@CacheEvict@Cacheable@CachingCacheManagerRedisCacheManager 缓存简介 缓存,我的理解是:让数据更接近于使用者;工作机制是:先从缓存中读取数据,如果没有再...

会走的桃子的博客 619

pscad IEEE标准系统搭建说明

pscad IEEE标准系统搭建说明,包含典型的IEEE 9节点、14节点、30节点、39节点和118节点系统。内含标准测试系统的原始数据和潮流结果。

lwip-2.0.3

lwip是瑞典计算机科学院(SICS)的Adam Dunkels 开发的一个小型开源的TCP/IP协议栈。实现的重点是在保持TCP协议主要功能的基础上减少对RAM 的占用。

开源中国 OsChina Android 客户端源码分析(11)缓存对象

为什么80%的码农都做不了架构师?>>> ...

weixin_34177064的博客 203

温度PID控制PLC程序

温度PID稳定控制程序,适用于欧姆龙PLC,对其他PLC也具有很大参考价值

《深入理解Spark:核心思想与源码分析》——SparkContext的初始化(伯篇)——执行环境与元数据清理器...

《深入理解Spark:核心思想与源码分析》一书前言的内容请看链接《深入理解SPARK:核心思想与源码分析》一书正式出版上市 《深入理解Spark:核心思想与源码分析》一书第一章的内容请看链接《第1章 环境准备》 《深入理解Spark:核心思想与源码分析》一书第二章的内容请看链接《第2章SPARK设计理念与基本架构》 由于本书的第3章内容较多,所以打算分别开辟四篇随笔分别展现。本文...

weixin_30825199的博客 205

Spark 子模块 SparkSQL 的缓存管理分析

一、前言 1.相关版本:Spark Master branch(2018.11, compiled-version spark-2.4.1) 2. SparkSQL 的CacheManager 独立于SparkCore 的 CacheManager(SparkCore的缓存管理机制详见:https://blog.csdn.net/don_chiang709/article/details/84...

Yannick Jiang 的专栏 1062

Spark源码分析之Spark执行环境SparkEnv

SparkEnv是创建SparkContext中的第一步,也是很重要的一环,它Spark 的执行环境对象,其中包括众多与Executor 执行相关的对象。由于在local 模式下Driver 会创建Executor,cluster 部署模式或者Standalone 部署模式下Worker 另起的CoarseGrainedExecutorBackend 进程中也会创建Executor,所以SparkE

chenguangchun1993的博客 596

大数据平台学习(三)----spark核心编程

spark架构原理 原理图: 创建RDD 一是使用程序中的集合创建RDD,主要用于进行测试,可以实际部署到集群运行之前, 自己使用集合构造测试数据,来测试后面的spark应用的流程; 二是使用本地文件创建RDD,主要用于的场景为在本地临时性地处理一些存储了大量数据的文件; 三是使用HDFS文件创建RDD,主要用于针对HDFS上存储的大数据,进行离线批处理操作 ...

bangche3676的博客 304

spark core源码分析6 Spark job的提交

首先看一个spark自带的最简单的例子: object SparkPi { def main(args: Array[String]) { val conf = new SparkConf().setAppName("Spark Pi") val spark = new SparkContext(conf) val slices = if (args.length >

zhu's 专栏 1529

《深入理解Spark:核心思想与源码分析》——3.2节创建执行环境SparkEnv

本节书摘来自华章社区《深入理解Spark:核心思想与源码分析》一书中的第3章,第3.2节创建执行环境SparkEnv,作者耿嘉安,更多章节内容可以访问云栖社区“华章社区”公众号查看 3.2 创建执行环境SparkEnvSparkEnv是Spark的执行环境对象,其中包括众多与Executor执行相关的对象。由于在local模式下Driver会创建Exec...

weixin_33832340的博客 147

ApachShiro 一个系统 两套验证方法-(后台管理员登录、前台App用户登录)同一接口实现、源码分析...

需求: 在公司新的系统里面博主我使用的是ApachShiro 作为安全框架、作为后端的鉴权以及登录、分配权限等操作 管理员的信息都是存储在管理员表 前台App 用户也需要校验用户名和密码进行登录、但是用户的信息却是存在另一张表里面、如何给这两个不同的数据表进行登录?鉴权呢? 当然 按照Shiro的强大,我们完全可以用一个接口作为登录的验证、不同的Realm 来执行不同的逻辑即...

adu521525的博客 1433

深入理解Spark:核心思想与源码分析. 3.2 创建执行环境SparkEnv

3.2 创建执行环境SparkEnv SparkEnv是Spark的执行环境对象,其中包括众多与Executor执行相关的对象。由于在local模式下Driver会创建Executor,local-cluster部署模式或者Standalone部署模式下Worker另起的CoarseGrainedExecutorBackend进程中也会创建Executo...

weixin_34228617的博客 123

SparkContext的初始化(伯篇)——执行环境与元数据清理器

第3章 SparkContext的初始化 “道生一,一生二,二生三,三生万物。”——《道德经》 本章导读: SparkContext的初始化是Driver应用程序提交执行的前提,本章内容以local模式为主,并按照代码执行顺序讲解,这将有助于首次接触Spark的读者理解源码。读者朋友如果能边跟踪代码,边学习本章内容,也许是快速理解SparkContext初始化过程的便捷途径。已经熟练使用Sp

beliefer的博客 1万+

ClawX Computer Use CLI 验证全记录:CUA 0.25.0 升级、遥测抑制与原生驱动边界

ClawX 通过内置原生 CUA 驱动(SDK + 原生二进制 + 官方 Skill 三者对齐 0.25.0)为用户提供图形化桌面控制能力,本文以 [computer-use-cli-validation.md](https://link.gitcode.com/i/726e48fc5b5e2c86c44deedf35902562) 为骨架,系统梳理 0.25.0 版本契约下的源码级结论、安装所有

gitblog_00686的博客 545

shiro缓存管理

文章目录shiro缓存现象如果我设置了缓存:缓存源码分析shiro提供的基于内存的CacheManager基于Ehcache的缓存基于Redis的缓存 shiro缓存现象 shiro缓存主要就是换成用户的授权信息,就是将我们的自定义realm的doGetAuthorizationInfo方法就是给用户授权的方法进行缓存. 如果不使用缓存,那么每次进行用户权限判断的时候就会调用一下授权方法: 我请求...

你就像甜甜的益达 1244

SpringBoot+Vue在线文档管理系统开发实战

现代Web开发中,前后端分离架构已成为主流技术范式。SpringBoot作为Java生态的微服务框架,通过自动配置和起步依赖简化了后端开发;Vue.js则以其响应式特性和组件化模式革新了前端工程实践。两者结合能高效构建RESTful API驱动的单页应用,特别适合文档管理系统这类需要实时交互的场景。系统采用MySQL关系型数据库确保数据一致性,同时支持多人协作编辑和版本控制等企业级功能。通过Spring Security实现细粒度权限管理,结合WebSocket技术可扩展为实时协作平台。这类项目不仅适合作为

weixin_34214500的博客 311
上一篇: 10.BlockManager源码分析
下一篇: 将博客搬至CSDN
AlanHand
博客等级 码龄14年 12粉丝 46原创
评论
成就一亿技术人!
拼手气红包6.0元
还能输入1000个字符
 
 条评论被折叠 查看
添加红包

请填写红包祝福语或标题

个

红包个数最小为10个

元

红包金额最低5元

当前余额3.43元 前往充值 >
需支付:10.00元
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付元
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值