stepScope
@Scope(value = "step", proxyMode = ScopedProxyMode.TARGET_CLASS)
DEFAULT和NO一样
使用相关
优秀博文(案例)
No context holder available for step scope
StepContext stepContext = StepSynchronizationManager.register(stepExecution);
StepScope#getContext()
AbstractBeanFactory#doGetBean
mbd.isSingleton()
mbd.isPrototype()
mbd.getScope()
如何获取->StepScope#get(String, ObjectFactory)
如何写入->BatchScopeSupport#postProcessBeanFactory
BeanFactoryPostProcessor
BeanPostProcessor
如何注册->ScopeConfiguration#stepScope()
AbstractBatchConfiguration
@EnableBatchProcessing#BatchConfigurationSelector
AbstractBeanFactory是bean工厂最核心的实现所有bean相关都在此
SpEL
step支持的
#{jobParameters[xy]}
#{jobExecutionContext[xy]}
#{stepExecutionContext[xy]}
SpEL 字面量
#{8}
#{1e4}
#{true}
SpEL引用bean
#{car}
#{car.brand}
#{car.toString()}
#{T(java.lang.Math).PI}
系统属性
systemProperties
systemEnvironment
#{systemEnvironment['HOME']}
运算符号
算术运算符
比较运算符
逻辑运算符
if-else 运算符
正则表达式