Skip to content

Commit 5361b41

Browse files
authored
Image Store: View Access status of the image store and view events (#8467)
1 parent 9f1b34a commit 5361b41

File tree

3 files changed

+5
-1
lines changed

3 files changed

+5
-1
lines changed

api/src/main/java/com/cloud/event/EventTypes.java

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -400,6 +400,7 @@ public class EventTypes {
400400
public static final String EVENT_IMAGE_STORE_DATA_MIGRATE = "IMAGE.STORE.MIGRATE.DATA";
401401
public static final String EVENT_IMAGE_STORE_RESOURCES_MIGRATE = "IMAGE.STORE.MIGRATE.RESOURCES";
402402
public static final String EVENT_IMAGE_STORE_OBJECT_DOWNLOAD = "IMAGE.STORE.OBJECT.DOWNLOAD";
403+
public static final String EVENT_UPDATE_IMAGE_STORE_ACCESS_STATE = "IMAGE.STORE.ACCESS.UPDATED";
403404

404405
// Configuration Table
405406
public static final String EVENT_CONFIGURATION_VALUE_EDIT = "CONFIGURATION.VALUE.EDIT";
@@ -1164,6 +1165,7 @@ public class EventTypes {
11641165

11651166
entityEventDetails.put(EVENT_IMAGE_STORE_DATA_MIGRATE, ImageStore.class);
11661167
entityEventDetails.put(EVENT_IMAGE_STORE_OBJECT_DOWNLOAD, ImageStore.class);
1168+
entityEventDetails.put(EVENT_UPDATE_IMAGE_STORE_ACCESS_STATE, ImageStore.class);
11671169
entityEventDetails.put(EVENT_LIVE_PATCH_SYSTEMVM, "SystemVMs");
11681170

11691171
//Object Store

server/src/main/java/com/cloud/storage/StorageManagerImpl.java

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3261,6 +3261,8 @@ public ImageStore migrateToObjectStore(String name, String url, String providerN
32613261
}
32623262

32633263
@Override
3264+
@ActionEvent(eventType = EventTypes.EVENT_UPDATE_IMAGE_STORE_ACCESS_STATE,
3265+
eventDescription = "image store access updated")
32643266
public ImageStore updateImageStoreStatus(Long id, Boolean readonly) {
32653267
// Input validation
32663268
ImageStoreVO imageStoreVO = _imageStoreDao.findById(id);

ui/src/components/view/ListView.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -340,7 +340,7 @@
340340
<template v-if="column.key === 'softwareversion'">
341341
<span> {{ record.softwareversion ? record.softwareversion : 'N/A' }} </span>
342342
</template>
343-
<template v-if="column.key === 'access'">
343+
<template v-if="column.key === 'readonly'">
344344
<status :text="record.readonly ? 'ReadOnly' : 'ReadWrite'" displayText />
345345
</template>
346346
<template v-if="column.key === 'requiresupgrade'">

0 commit comments

Comments
 (0)