github.com/vmware/govmomi@v0.51.0/simulator/esx/event_manager.go (about)

     1  // © Broadcom. All Rights Reserved.
     2  // The term “Broadcom” refers to Broadcom Inc. and/or its subsidiaries.
     3  // SPDX-License-Identifier: Apache-2.0
     4  
     5  package esx
     6  
     7  import "github.com/vmware/govmomi/vim25/types"
     8  
     9  // EventInfo is the default template for the EventManager description.eventInfo property.
    10  // Capture method:
    11  // govc object.collect -s -dump EventManager:ha-eventmgr description.eventInfo
    12  // The captured list has been manually pruned and FullFormat fields changed to use Go's template variable syntax.
    13  var EventInfo = []types.EventDescriptionEventDetail{
    14  	{
    15  		Key:         "UserLoginSessionEvent",
    16  		Description: "User login",
    17  		Category:    "info",
    18  		FullFormat:  "User {{.UserName}}@{{.IpAddress}} logged in as {{.UserAgent}}",
    19  	},
    20  	{
    21  		Key:         "UserLogoutSessionEvent",
    22  		Description: "User logout",
    23  		Category:    "info",
    24  		FullFormat:  "User {{.UserName}}@{{.IpAddress}} logged out (login time: {{.LoginTime}}, number of API invocations: {{.CallCount}}, user agent: {{.UserAgent}})",
    25  	},
    26  	{
    27  		Key:         "DatacenterCreatedEvent",
    28  		Description: "Datacenter created",
    29  		Category:    "info",
    30  		FullFormat:  "Created datacenter {{.Datacenter.Name}} in folder {{.Parent.Name}}",
    31  	},
    32  	{
    33  		Key:         "DatastoreFileMovedEvent",
    34  		Description: "File or directory moved to datastore",
    35  		Category:    "info",
    36  		FullFormat:  "Move of file or directory {{.SourceFile}} from {{.SourceDatastore.Name}} to {{.Datastore.Name}} as {{.TargetFile}}",
    37  	},
    38  	{
    39  		Key:         "DatastoreFileCopiedEvent",
    40  		Description: "File or directory copied to datastore",
    41  		Category:    "info",
    42  		FullFormat:  "Copy of file or directory {{.SourceFile}} from {{.SourceDatastore.Name}} to {{.Datastore.Name}} as {{.TargetFile}}",
    43  	},
    44  	{
    45  		Key:         "DatastoreFileDeletedEvent",
    46  		Description: "File or directory deleted",
    47  		Category:    "info",
    48  		FullFormat:  "Deletion of file or directory {{.TargetFile}} from {{.Datastore.Name}} was initiated",
    49  	},
    50  	{
    51  		Key:         "EnteringMaintenanceModeEvent",
    52  		Description: "Entering maintenance mode",
    53  		Category:    "info",
    54  		FullFormat:  "Host {{.Host.Name}} in {{.Datacenter.Name}} has started to enter maintenance mode",
    55  	},
    56  	{
    57  		Key:         "EnteredMaintenanceModeEvent",
    58  		Description: "Entered maintenance mode",
    59  		Category:    "info",
    60  		FullFormat:  "Host {{.Host.Name}} in {{.Datacenter.Name}} has entered maintenance mode",
    61  	},
    62  	{
    63  		Key:         "ExitMaintenanceModeEvent",
    64  		Description: "Exit maintenance mode",
    65  		Category:    "info",
    66  		FullFormat:  "Host {{.Host.Name}} in {{.Datacenter.Name}} has exited maintenance mode",
    67  	},
    68  	{
    69  		Key:         "HostRemovedEvent",
    70  		Description: "Host removed",
    71  		FullFormat:  "Removed host {{.Host.Name}} in {{.Datacenter.Name}}",
    72  		Category:    "info",
    73  	},
    74  	{
    75  		Key:         "VmSuspendedEvent",
    76  		Description: "VM suspended",
    77  		Category:    "info",
    78  		FullFormat:  "{{.Vm.Name}} on {{.Host.Name}} in {{.Datacenter.Name}} is suspended",
    79  	},
    80  	{
    81  		Key:         "VmMigratedEvent",
    82  		Description: "VM migrated",
    83  		Category:    "info",
    84  		FullFormat:  "Migration of virtual machine {{.Vm.Name}} from {{.SourceHost.Name}}, {{.SourceDatastore.Name}} to {{.Host.Name}}, {{.Ds.Name}} completed",
    85  	},
    86  	{
    87  		Key:         "VmBeingMigratedEvent",
    88  		Description: "VM migrating",
    89  		Category:    "info",
    90  		FullFormat:  "Relocating {{.Vm.Name}} from {{.Host.Name}, {{.Ds.Name}} in {{.Datacenter.Name}} to {{.DestHost.Name}, {{.DestDatastore.Name}} in {{.DestDatacenter.Name}}",
    91  	},
    92  	{
    93  		Key:         "VmMacAssignedEvent",
    94  		Description: "VM MAC assigned",
    95  		Category:    "info",
    96  		FullFormat:  "New MAC address ({{.Mac}}) assigned to adapter {{.Adapter}} for {{.Vm.Name}}",
    97  	},
    98  	{
    99  		Key:         "VmRegisteredEvent",
   100  		Description: "VM registered",
   101  		Category:    "info",
   102  		FullFormat:  "Registered {{.Vm.Name}} on {{.Host.Name}} in {{.Datacenter.Name}}",
   103  	},
   104  	{
   105  		Key:         "VmReconfiguredEvent",
   106  		Description: "VM reconfigured",
   107  		Category:    "info",
   108  		FullFormat:  "Reconfigured {{.Vm.Name}} on {{.Host.Name}} in {{.Datacenter.Name}}",
   109  	},
   110  	{
   111  		Key:         "VmGuestRebootEvent",
   112  		Description: "Guest reboot",
   113  		Category:    "info",
   114  		FullFormat:  "Guest OS reboot for {{.Vm.Name}} on {{.Host.Name}} in {{.Datacenter.Name}}",
   115  	},
   116  	{
   117  		Key:         "VmBeingClonedEvent",
   118  		Description: "VM being cloned",
   119  		Category:    "info",
   120  		FullFormat:  "Cloning {{.Vm.Name}} on host {{.Host.Name}} in {{.Datacenter.Name}} to {{.DestName}} on host {{.DestHost.Name}}",
   121  	},
   122  	{
   123  		Key:         "VmClonedEvent",
   124  		Description: "VM cloned",
   125  		Category:    "info",
   126  		FullFormat:  "Clone of {{.SourceVm.Name}} completed",
   127  	},
   128  	{
   129  		Key:         "VmBeingDeployedEvent",
   130  		Description: "Deploying VM",
   131  		Category:    "info",
   132  		FullFormat:  "Deploying {{.Vm.Name}} on host {{.Host.Name}} in {{.Datacenter.Name}} from template {{.SrcTemplate.Name}}",
   133  	},
   134  	{
   135  		Key:         "VmDeployedEvent",
   136  		Description: "VM deployed",
   137  		Category:    "info",
   138  		FullFormat:  "Template {{.SrcTemplate.Name}} deployed on host {{.Host.Name}}",
   139  	},
   140  	{
   141  		Key:         "VmInstanceUuidAssignedEvent",
   142  		Description: "Assign a new instance UUID",
   143  		Category:    "info",
   144  		FullFormat:  "Assign a new instance UUID ({{.InstanceUuid}}) to {{.Vm.Name}}",
   145  	},
   146  	{
   147  		Key:         "VmPoweredOnEvent",
   148  		Description: "VM powered on",
   149  		Category:    "info",
   150  		FullFormat:  "{{.Vm.Name}} on {{.Host.Name}} in {{.Datacenter.Name}} is powered on",
   151  	},
   152  	{
   153  		Key:         "VmStartingEvent",
   154  		Description: "VM starting",
   155  		Category:    "info",
   156  		FullFormat:  "{{.Vm.Name}} on host {{.Host.Name}} in {{.Datacenter.Name}} is starting",
   157  	},
   158  	{
   159  		Key:         "VmStoppingEvent",
   160  		Description: "VM stopping",
   161  		Category:    "info",
   162  		FullFormat:  "{{.Vm.Name}} on host {{.Host.Name}} in {{.Datacenter.Name}} is stopping",
   163  	},
   164  	{
   165  		Key:         "VmSuspendingEvent",
   166  		Description: "VM being suspended",
   167  		Category:    "info",
   168  		FullFormat:  "{{.Vm.Name}} on {{.Host.Name}} in {{.Datacenter.Name}} is being suspended",
   169  	},
   170  	{
   171  		Key:         "VmResumingEvent",
   172  		Description: "VM resuming",
   173  		Category:    "info",
   174  		FullFormat:  "{{.Vm.Name}} on {{.Host.Name}} in {{.Datacenter.Name}} is resumed",
   175  	},
   176  	{
   177  		Key:         "VmBeingCreatedEvent",
   178  		Description: "Creating VM",
   179  		Category:    "info",
   180  		FullFormat:  "Creating {{.Vm.Name}} on host {{.Host.Name}} in {{.Datacenter.Name}}",
   181  	},
   182  	{
   183  		Key:         "VmCreatedEvent",
   184  		Description: "VM created",
   185  		Category:    "info",
   186  		FullFormat:  "Created virtual machine {{.Vm.Name}} on {{.Host.Name}} in {{.Datacenter.Name}}",
   187  	},
   188  	{
   189  		Key:         "VmRemovedEvent",
   190  		Description: "VM removed",
   191  		Category:    "info",
   192  		FullFormat:  "Removed {{.Vm.Name}} on {{.Host.Name}} from {{.Datacenter.Name}}",
   193  	},
   194  	{
   195  		Key:         "VmResettingEvent",
   196  		Description: "VM resetting",
   197  		Category:    "info",
   198  		FullFormat:  "{{.Vm.Name}} on {{.Host.Name}} in {{.Datacenter.Name}} is reset",
   199  	},
   200  	{
   201  		Key:         "VmGuestShutdownEvent",
   202  		Description: "Guest OS shut down",
   203  		Category:    "info",
   204  		FullFormat:  "Guest OS shut down for {{.Vm.Name}} on {{.Host.Name}} in {{.Datacenter.Name}}",
   205  	},
   206  	{
   207  		Key:         "VmUuidAssignedEvent",
   208  		Description: "VM UUID assigned",
   209  		Category:    "info",
   210  		FullFormat:  "Assigned new BIOS UUID ({{.Uuid}}) to {{.Vm.Name}} on {{.Host.Name}} in {{.Datacenter.Name}}",
   211  	},
   212  	{
   213  		Key:         "VmPoweredOffEvent",
   214  		Description: "VM powered off",
   215  		Category:    "info",
   216  		FullFormat:  "{{.Vm.Name}} on {{.Host.Name}} in {{.Datacenter.Name}} is powered off",
   217  	},
   218  	{
   219  		Key:         "VmRelocatedEvent",
   220  		Description: "VM relocated",
   221  		Category:    "info",
   222  		FullFormat:  "Completed the relocation of the virtual machine",
   223  	},
   224  	{
   225  		Key:         "CustomizationFailed",
   226  		Description: "An error occurred during customization",
   227  		Category:    "info",
   228  		FullFormat:  "An error occurred during customization on VM {{.Vm.Name}}",
   229  	},
   230  	{
   231  		Key:         "CustomizationStartedEvent",
   232  		Description: "Started customization",
   233  		Category:    "info",
   234  		FullFormat:  "Started customization of VM {{.Vm.Name}}",
   235  	},
   236  	{
   237  		Key:         "CustomizationSucceeded",
   238  		Description: "Customization succeeded",
   239  		Category:    "info",
   240  		FullFormat:  "Customization of VM {{.Vm.Name}} succeeded",
   241  	},
   242  	{
   243  		Key:         "DrsVmMigratedEvent",
   244  		Description: "DRS VM migrated",
   245  		Category:    "info",
   246  		FullFormat:  "DRS migrated {{.Vm.Name}} from {{.SourceHost.Name}} to {{.Host.Name}} in cluster {{.ComputeResource.Name}} in {{.Datacenter.Name}}",
   247  	},
   248  	{
   249  		Key:         "DrsVmPoweredOnEvent",
   250  		Description: "DRS VM powered on",
   251  		Category:    "info",
   252  		FullFormat:  "DRS powered On {{.Vm.Name}} on {{.Host.Name}} in {{.Datacenter.Name}}",
   253  	},
   254  	{
   255  		Key:         "DvsCreatedEvent",
   256  		Description: "vSphere Distributed Switch created",
   257  		Category:    "info",
   258  		FullFormat:  "A vSphere Distributed Switch {{.Dvs.Name}} was created in {{.Datacenter.Name}}.",
   259  	},
   260  	{
   261  		Key:         "DvsDestroyedEvent",
   262  		Description: "vSphere Distributed Switch deleted",
   263  		Category:    "info",
   264  		FullFormat:  "vSphere Distributed Switch {{.Dvs.Name}} in {{.Datacenter.Name}} was deleted.",
   265  	},
   266  	{
   267  		Key:         "DvsReconfiguredEvent",
   268  		Description: "vSphere Distributed Switch reconfigured",
   269  		Category:    "info",
   270  		FullFormat:  "The vSphere Distributed Switch {{.Dvs.Name}} in {{.Datacenter.Name}} was reconfigured.",
   271  	},
   272  	{
   273  		Key:         "DvsHostJoinedEvent",
   274  		Description: "Host joined the vSphere Distributed Switch",
   275  		Category:    "info",
   276  		FullFormat:  "The host {{.HostJoined.Name}} joined the vSphere Distributed Switch {{.Dvs.Name}} in {{.Datacenter.Name}}.",
   277  	},
   278  	{
   279  		Key:         "DvsHostLeftEvent",
   280  		Description: "Host left vSphere Distributed Switch",
   281  		Category:    "info",
   282  		FullFormat:  "The host {{.HostLeft.Name}} left the vSphere Distributed Switch {{.Dvs.Name}} in {{.Datacenter.Name}}.",
   283  	},
   284  	{
   285  		Key:         "DVPortgroupCreatedEvent",
   286  		Description: "dvPort group created",
   287  		Category:    "info",
   288  		FullFormat:  "dvPort group {{.Net.Name}} in {{.Datacenter.Name}} was added to switch {{.Dvs.Name}}.",
   289  	},
   290  	{
   291  		Key:         "DVPortgroupDestroyedEvent",
   292  		Description: "dvPort group deleted",
   293  		Category:    "info",
   294  		FullFormat:  "dvPort group {{.Net.Name}} in {{.Datacenter.Name}} was deleted.",
   295  	},
   296  }