Skip to content

Product End Of Support Matrix now available as JSON (incl. Script)

The database used at my VMware Product End Of Support Countdown is now available in JSON. The database is based on VMware Lifecycle Product Matrix and allows you to use the information in scripts or for automation purposes.

vmware-product-lifecycle-json

I’ve also written a small script to demonstrate what this information can be used for.

JSON Description
The JSON object is build in the following structure:

{
    "data": {
        "productLifecycle": [
            {
                "endOfAvailability": "[YYYY-MM-DD]",
                "endOfGeneralSupport": "[YYYY-MM-DD]",
                "endOfTechnicalGuidance": "[YYYY-MM-DD]",
                "generalAvailability": "[YYYY-MM-DD]",
                "productRelease": "[Release Name]"
            },
            [...]
        ]
    },
    "timestamp": [JSON file creation timestamp],
    "totalCount": [Number of entries]
}

JSON File

http://www.virten.net/repo/vmwareProductLifecycle.json

The JSON file is updated when I detect changes to VMware Lifecycle Product Matrix. The timestamp outlines the latest change. Feel free to use the link in your own scripts. I try to keep the link and format active. If you have questions or need any further information, please comment or contact me.

Please let me known if you are using this file in any automated process. You don’t have to, but when I known that someone is using it, its more unlikely that I change the format or link.

PowerCLI Script Example
To demonstrate what these information can be used for, I’ve created a little script that uses the JSON database to check when the installed ESXi Version runs out of general support.
scripted-esxi-endOfSupport-information

check_esxi_endOfSupport_from_json.ps1

$vmwareProductLifecycle = Invoke-WebRequest -Uri http://www.virten.net/repo/vmwareProductLifecycle.json | ConvertFrom-Json
$vmHosts = Get-VMHost

Foreach ($vmHost in $vmHosts) {
  $releaseFound = $false
  $product = "VMware ESXi $($vmHost.ApiVersion)"

  Write-Host "$($vmHost.Name) is running Version $($product)"
  
  Foreach ($prod in $vmwareProductLifecycle.data.productLifecycle) {
    If ($product -eq $prod.productRelease) {
      $TimeSpanEogs = New-TimeSpan –Start (get-date) –End (get-date $prod.endOfGeneralSupport)
      $TimeSpanEotg = New-TimeSpan –Start (get-date) –End (get-date $prod.endOfTechnicalGuidance)
      Write-Host " - End of Genereal Support: $($prod.endOfGeneralSupport) ($($TimeSpanEogs.days) Days)"
      Write-Host " - End of Technical Guidance: $($prod.endOfTechnicalGuidance) ($($TimeSpanEotg.days) Days)"
      $releaseFound = $true
    }
  }
  
  If (-Not $releaseFound){
    Write-Host " - $($product) not found in database!" -ForegroundColor Red
  }
}

The script is available on Github.

2 thoughts on “Product End Of Support Matrix now available as JSON (incl. Script)”

    1. CSV instead of JSON, or the PowerCLI Snippet?
      This was just an example, intended to demonstrate what you can do with this information. You can implement this on any existing report.

Leave a Reply

Your email address will not be published. Required fields are marked *