| 限定符和类型 | 方法和说明 |
|---|---|
ListInfoHelper |
ListLoaderCenter.getListInfo(Object account_id,
LsCacheInfoHelper lsHelper,
int strategy,
boolean needLock) |
ListInfoHelper |
ListLoader.getListInfo(Object account_id,
LsCacheInfoHelper lsInfo,
int strategy,
boolean needLock) |
List |
ListLoaderCenter.getSectionIdList(LsCacheInfoHelper lsHelper,
ListInfoHelper infoHelper,
Object account_id,
Long sectionNo,
int strategy,
boolean needLock) |
List |
ListLoader.getSectionIdList(LsCacheInfoHelper lsInfo,
ListInfoHelper infoHelper,
Object account_id,
Long sectionNo,
int strategy,
boolean needLock) |
SectionInfo |
ListLoaderCenter.getUpdatedSection(Object account_id,
Object obj,
LsCacheInfoHelper lsHelper) |
SectionInfo |
ListLoader.getUpdatedSection(Object account_id,
Object obj,
LsCacheInfoHelper lsHelper) |
| 限定符和类型 | 方法和说明 |
|---|---|
List<SectionInfo> |
ListHandler.getDeleteInfos(Object account_id,
Object obj,
List<LsCacheInfoHelper> infoList)
和对象删除相关的两个方法
|
List<SectionInfo> |
ListHandler.getSavedInfos(Object account_id,
Object obj,
List<LsCacheInfoHelper> infoList)
和对象保存相关的两个方法
|
UpdateInfo |
ListHandler.getUpdateInfos(Object account_id,
Object obj,
Object oldObj,
Map<String,LsCacheInfoHelper> newObjLsMap,
Map<String,LsCacheInfoHelper> oldObjLsMap)
和对象更新相关的两个方法
|
UpdateInfo |
ListHandler.getUpdateInfos(Object account_id,
Object obj,
Object oldObj,
Map<String,LsCacheInfoHelper> newObjLsMap,
Map<String,LsCacheInfoHelper> oldObjLsMap)
和对象更新相关的两个方法
|
void |
ListHandler.processBatchedSave(Map<String,List<LsCacheInfoHelper>> lsMap)
批量保存相关的方法
|
| 限定符和类型 | 方法和说明 |
|---|---|
List<SectionInfo> |
AbstractListHandler.getDeleteInfos(Object account_id,
Object obj,
List<LsCacheInfoHelper> infoList) |
List<SectionInfo> |
AbstractListHandler.getSavedInfos(Object account_id,
Object obj,
List<LsCacheInfoHelper> infoHelperList) |
UpdateInfo |
CommonListHandler.getUpdateInfos(Object account_id,
Object obj,
Object oldObj,
Map<String,LsCacheInfoHelper> newObjLsMap,
Map<String,LsCacheInfoHelper> oldObjLsMap)
核心 : 在DAL的这个模块中,依据的理念是---以人为本,系统中的某个List一定是某个人的
1 .同一个List,在同一时间只能由一个人修改, 此时如果缓存中没有这个List的ListInfo对象,则其他用户不能加载
2.
|
UpdateInfo |
CommonListHandler.getUpdateInfos(Object account_id,
Object obj,
Object oldObj,
Map<String,LsCacheInfoHelper> newObjLsMap,
Map<String,LsCacheInfoHelper> oldObjLsMap)
核心 : 在DAL的这个模块中,依据的理念是---以人为本,系统中的某个List一定是某个人的
1 .同一个List,在同一时间只能由一个人修改, 此时如果缓存中没有这个List的ListInfo对象,则其他用户不能加载
2.
|
UpdateInfo |
AbstractListHandler.getUpdateInfos(Object account_id,
Object obj,
Object oldObj,
Map<String,LsCacheInfoHelper> newObjLsMap,
Map<String,LsCacheInfoHelper> oldObjLsMap)
参考 CommonListHandler --->getUpdateInfos 的说明,仅适合于非 主/从数据库分离的情况
查找因对象更新,导致的数据将发生变化的与对象相关的List,此处仅考虑对象的KeyProperty 和 orderByProperty 两个属性
场景一.
|
UpdateInfo |
AbstractListHandler.getUpdateInfos(Object account_id,
Object obj,
Object oldObj,
Map<String,LsCacheInfoHelper> newObjLsMap,
Map<String,LsCacheInfoHelper> oldObjLsMap)
参考 CommonListHandler --->getUpdateInfos 的说明,仅适合于非 主/从数据库分离的情况
查找因对象更新,导致的数据将发生变化的与对象相关的List,此处仅考虑对象的KeyProperty 和 orderByProperty 两个属性
场景一.
|
void |
AbstractListHandler.processBatchedSave(Map<String,List<LsCacheInfoHelper>> lsMap)
批量保存时的处理逻辑:
设计理念: 判断对应的List是否在缓存中,发现即删除 ^_^ 简单粗暴,但略显复杂
|
| 限定符和类型 | 方法和说明 |
|---|---|
static void |
LogHelper.cachedListUnVisited(org.apache.commons.logging.Log log,
LsCacheInfoHelper info) |
Long |
VisitHelper.checkIdLsLoad(LsCacheInfoHelper lsHelper) |
Long |
VisitHelper.checkLsInLoading(LsCacheInfoHelper lsHelper) |
boolean |
VisitHelper.endIdLsLoading(LsCacheInfoHelper lsHelper,
Long value) |
boolean |
VisitHelper.endLsLoading(LsCacheInfoHelper lsHelper,
Long value) |
static void |
LogHelper.errorAddObjectToListSection(org.apache.commons.logging.Log log,
LsCacheInfoHelper info,
Number currentMaxSecNo) |
static void |
LogHelper.errorLoadLatestListSection(org.apache.commons.logging.Log log,
LsCacheInfoHelper lsInfo) |
static void |
LogHelper.failedFindIdFromList(org.apache.commons.logging.Log log,
LsCacheInfoHelper info,
Object id) |
static void |
LogHelper.failedLoadListSection(org.apache.commons.logging.Log log,
LsCacheInfoHelper lsHelper,
ListInfoHelper infoHelper,
Object sectionNo) |
static void |
LogHelper.failedLoadOneListSection(org.apache.commons.logging.Log log,
LsCacheInfoHelper lsInfo,
Long secNo) |
static void |
LogHelper.listInfoNotMatchSectionInCache(org.apache.commons.logging.Log log,
LsCacheInfoHelper lsHelper,
ListLoadInfo listLoadInfo,
List idCacheList) |
static void |
LogHelper.listParamsNull(org.apache.commons.logging.Log log,
LsCacheInfoHelper lsHelper) |
| 限定符和类型 | 方法和说明 |
|---|---|
ListInfoHelper |
CrossAggrListLoader.getListInfo(Object account_id,
LsCacheInfoHelper lsHelper,
int strategy,
boolean needLock) |
ListInfoHelper |
CommonListLoader.getListInfo(Object account_id,
LsCacheInfoHelper lsHelper,
int strategy,
boolean needLock) |
List |
CrossAggrListLoader.getSectionIdList(LsCacheInfoHelper lsHelper,
ListInfoHelper infoHelper,
Object account_id,
Long sectionNo,
int strategy,
boolean needLock) |
List |
CommonListLoader.getSectionIdList(LsCacheInfoHelper lsHelper,
ListInfoHelper infoHelper,
Object account_id,
Long sectionNo,
int strategy,
boolean needLock)
心得 :该方法目前在 4个地方 被调用,分别是
1,2 removeIdFromList,getUpdatedSection --->对应update/delete的操作
3.AbstractListHandler.getSavedInfos(.....)
|
SectionInfo |
CrossAggrListLoader.getUpdatedSection(Object account_id,
Object obj,
LsCacheInfoHelper lsHelper) |
SectionInfo |
CommonListLoader.getUpdatedSection(Object account_id,
Object obj,
LsCacheInfoHelper lsHelper) |
| 限定符和类型 | 方法和说明 |
|---|---|
LsCacheInfoHelper |
SectionInfo.getLsHelper() |
| 限定符和类型 | 方法和说明 |
|---|---|
Map<String,LsCacheInfoHelper> |
UpdateInfo.getNewLsMap() |
| 限定符和类型 | 方法和说明 |
|---|---|
void |
SectionInfo.setLsHelper(LsCacheInfoHelper lsHelper) |
| 限定符和类型 | 方法和说明 |
|---|---|
void |
UpdateInfo.setNewLsMap(Map<String,LsCacheInfoHelper> newLsMap) |
| 构造器和说明 |
|---|
SectionInfo(Long no,
ListInfoHelper helper,
List list,
LsCacheInfoHelper lshepler,
Number[] minMaxs) |
| 构造器和说明 |
|---|
UpdateInfo(Map<String,LsCacheInfoHelper[]> lsHelpers,
List<SectionInfo> oldObjListSections,
Map<String,LsCacheInfoHelper> lsMap) |
| 限定符和类型 | 方法和说明 |
|---|---|
static List<LsCacheInfoHelper> |
ObjectUtil.getLsInfoList(Object object) |
| 限定符和类型 | 方法和说明 |
|---|---|
static Object |
CacheHelper.get(LsCacheInfoHelper lsHelper) |
static SqlInfo |
SqlUtil.getListCountSql(LsCacheInfoHelper lsHelper) |
static ListInfo |
CacheHelper.getListInfo(LsCacheInfoHelper lsHelper)
得到缓存中的ListInfo
|
static SqlInfo |
SqlUtil.getListSql(LsCacheInfoHelper lsHelper,
boolean bReverse) |
static Object |
ObjectUtil.getObjectValueOfList(Object obj,
LsCacheInfoHelper lsHelper) |
static void |
CacheHelper.increaseListSize(LsCacheInfoHelper lsHelper) |
static void |
CacheHelper.increaseListSize(LsCacheInfoHelper lsHelper,
ListInfoHelper infoHelper) |
static void |
CacheHelper.putListInfo(LsCacheInfoHelper lsHelper,
ListInfo listInfo) |
static void |
CacheHelper.putListInfo(LsCacheInfoHelper lsHelper,
Long listCnt) |
static void |
CacheHelper.removeListInfo(LsCacheInfoHelper lsHelper)
从缓存中清除一个ListInfo对象时,把该对象所对应的各Id List也从缓存中清除
|
static void |
CacheHelper.removeListInfos(LsCacheInfoHelper[] lsHelpers) |
static void |
CacheHelper.removeListVisitedInfo(LsCacheInfoHelper lsHelper) |
Copyright © 2022. All rights reserved.