public class ResourceAccessComponent extends AbstractMyBatisDAO
Modifier and Type | Field and Description |
---|---|
protected ListMultimap<String,ResourceAccess> |
_pendingRecords
List of pending
ResourceAccess waiting to be exported to the database. |
static String |
ROLE
Avalon ROLE.
|
Constructor and Description |
---|
ResourceAccessComponent() |
Modifier and Type | Method and Description |
---|---|
private int |
_fillDatabase(ListMultimap<String,ResourceAccess> resourcesAccess) |
private int |
_fillDatabase(SqlSession sqlSession,
List<ResourceAccess> resourcesAccess) |
void |
addAccessRecord(ResourceAccess ra)
Add a new
ResourceAccess to the monitored resources. |
void |
exportPendings()
Call this method to transfer pendings resource access from memory to database
This is normally called by a scheduler
|
configure, contextualize, getSession, getSession, reload, service, setPluginInfo
getLogger, setLogger
protected ListMultimap<String,ResourceAccess> _pendingRecords
ResourceAccess
waiting to be exported to the database.public ResourceAccessComponent()
public void addAccessRecord(ResourceAccess ra)
ResourceAccess
to the monitored resources.ra
- The resource access object.public void exportPendings()
private int _fillDatabase(ListMultimap<String,ResourceAccess> resourcesAccess)
private int _fillDatabase(SqlSession sqlSession, List<ResourceAccess> resourcesAccess)