The minimum agent version of target task is defined in the table of [AzureDevOps_Configuration].[Task].[tbl_TaskDefinitionVersion]
We can get it from the Column of MetadataDocument. This column is in Raw JSON Binary format. We can decode it from Binary JSON Formatter.
SELECT
t.Name
,t.TaskId
,v.InternalTaskId
,v.MajorVersion
,v.MinorVersion
,v.PatchVersion
,v.MetadataDocument
From [AzureDevOps_Configuration].[Task].[tbl_TaskDefinitionVersion] v,[AzureDevOps_Configuration].[Task].[tbl_TaskDefinition] t
where t.InternalTaskId = v.InternalTaskId and t.Name = 'CMAKE'
Output is as below:
Name TaskId InternalTaskId MajorVersion MinorVersion PatchVersion MetadataDocument
CMake 7D831C3C-3C68-459A-A5C9-BDE6E659596C 27 1 151 1 0x1F8B08000000000004006553516FDA3010FE2B96B5874E0232C4A005699A5AD8A44EA39AB4AE7BA87830F62571496CCB77296388FF3EDB90B42B2F897DF9EEBBEFBEBBECF9B346BDD695A61D9F3DF29B46578AAF7A5C2B3EE397EA6A349423D91FC9C955FFE3782AFA622CA7FDB582094CC6D3F17422798F1B514340CF976203E1FA0C1EB5357CB6E7B578B29ECF863D5E6B934EE37076826499A21AEF0189CF7251211C124AD74D7D5D80A18796860F07D3E1E04360CEBD06A3AADDDDFF0515A0F4DAD1119D5A605B4D25A312580231E92D62DF558272EB6BB64E18DC21411D08A42028ACDFB5D9215442E596C26F16761B491F97D603BB35315BC442AB8B92C8E12CCB0A3BA875E4B7390DA4ADB37C5B69B3C93E7F0FCFDBC5A7C97074399CBE3F71FEF255A06B739595F8265BFC6D3C640A9EADC3CC6907810C3023811BCC92EE4CD66DDF79F02BAAB9DFB968480485B868A88C66F365CBCCE6D63BEB93F294580BA3300EFCC815065E78DBB8188AC337AEA178DE7351698190A05BEB37DA140BED4152746BD58D5E6EA367955843ECEEF711C85E9049AB682A7A10551313D6279BE9283CD715FC10549E1B3F6FBC0FCBC04EC5996A39D9B604C3927CA691F9C60CF8A1B7EF14C50FD7BEC057BAC2B5A903199EEB799182E4439D73215D3273021114237BACCE0FC1070CD662AEE16420DAC64B5874F339859520F1337DBAD14685329DDF48C248887BFD356D58BBDDECDD45D7495C21E7E19B5D7FF903B239AEFB3EFC35F0EACAEFAC82F826E10BA0D689B81983A7D8B838F5D1D5E18740E12CD25BE2C33FA5BEC5711D040000
CMake 7D831C3C-3C68-459A-A5C9-BDE6E659596C 27 1 170 2 0x1F8B08000000000004006553616FDA3010FD2B96B50F9D04A48C414BA4696ACB266D2AD5A475DD87AA1F2ECE85B824B6E5BB9431C47F9F1D48DAB55F2076DEBD77F7EE65279F34E94C579AB732BD97978DAE72F930903A97A93CCBCF27633551C3899A9D0F3F4EE73084A99A0FB31C67389BCEA7F399920369A0C680BE5AC21AC3F1093D696B64BA93353C5A2FD3F140D6DAB44F67A703E9805529D30F41856E9158A6055484FB16A5EBA6BE58A1E1BB8E468E47F3F1E83430175EA3C9ABEDCDFF823992F2DAF101DD8E20369A4BC1258A162494B74443570117D6D7226B31B425C63A1028605C59BFEDAAC35589955B825F2FEC2692DE5F2378236AEB5140661B0EDC9A0403AD1F4E4A66476992ACECA8D651C9163C52B64E8A4DA5CD3AF97C1D7EBF2D3ECDC693B3F1FCFD91FD97AF0271579B5B45AFAAE16FE331C9F1C93A4A9C7618C89092A849493B41A2EACE812238170DB8DDBA684D04857B68B88CB6CB65C72CAEAC77D6436B562CACC1E414577FE00AAB5F79DBB8781563605CC3F17927A1D240D84237D6AFB5592DB447C5D1B7873E046A13DDAB20C338DDEF03503C23DB5EA1A9F80EAA26166447C3F9D078A12BFC015CBE5DC155E37D8885388A8BBCE3149B128D68DB176127BE3123B91FECFA8EE28B0BBFA2177D85635307327ADBCF732BC43EE8BC6DA42F160E8830176C0FEA721F7CA0602D151A8F06926DBCC245BF9FE3750E0C3FDB5797DAE441A6F79B188CC298F0AF21A9C05DCEC5BB937E921821E7F1BBCDBEFC41D51C82BF0BDF0FBE38CA1B9B63FC67F02BE4CE89988CD1631C1C8E73F43A721F289C257E4DBCFF07C69311A827040000
CMake 7D831C3C-3C68-459A-A5C9-BDE6E659596C 27 1 178 0 0x1F8B08000000000004006D544D6F1B390CFD2B82B08716B03D31D238B1814591262D9045935D346DF750E4C091381ED51A69204A76BD41FEFB52F3E17893BD0C4622F91EF948EA516E0D99D25813F772F5437E48C66AF9309146CB953CD717A77375AAA6A76A71317D77B684299CA9E5B4D4B8C0C5D9F26CB95072221D34C8DE57B7B0413E6E3190F14EAE1E65033F7D90ABF94436C6757FE71713D94254B55C9D300B7D458A725581257CEABC4C939ACB35BAF87D8491F3D9723E3B61E42A1874DAEEEFFE4BA89154306DECBDBB12C4CEC45AC41A45E72454F044D3D642AC7C6844D9F9D09E22360CA020E2DA87FD18CD5735DAF616C2E6DAEF32E88FCF08C189C6071450FA1419DB9088409B8737758C2DAD8A62ED678DC94CBE8A33E59BA2DA59E336C5FBCFFCBDB9FE7D313F3D9F2FDF0EE8DF8265E031567B452FA2E19F14B0D0B8F52D15AD6991C1908ACC49455741A19A51818A95CB027CDDB7599AECC4F790629D6597B723B2B8F2A1F5013AB17260034E536E7D8FC5AD5F079FDA7CF5387616F4169CC2AC8B36C42A8E1DB87C3618FAF8AB652C3E0CEDCC53E4DA147B28B006083BA69D0F1BE3D6D726A08A59F687C30CA95DC6B2506216E7EFDE513C7B76A542B2F13BD89403CAA15FB1AFBB3216FF8258BFEEE0550A81A74A0CE4428F986257A3135DF5825B1A929BC9A7C9A1F6CE7019D67494171F53C360F43A9FE7542806E6799DC82158B440845A44DFB31FB37216378E8CC67B8EB647D45FD2982B8F48EE9D309D9FA0C1F1453E5D2B9E932ABDB708EE7FE4E9D6040EB9ED8CB5A244513385E524AD6133EF13CBE513EF0E9B06625F0970E2CF7B412D2A5319D5A73213375128B6B0671ACAECC104BAAD09DE6522B18560A0B448C7704316A29790667218CABB17E398478C7894A932DD64E5A34F41E1F5611F866B0D11EE3BD307E37406EDEF993466AC8CFC895F0688072D7E7B73687D5ED936E01FBEFCF80B55EA1F9A477EAFF0E828EFBCC6F949FE8B5C01C67178F22ECE7EE659190B3B30C92706693DC597D04FFF0212727E7C99050000
Use Binary JSON Formatter format the output of MetadataDocument. We can see the minimumAgentVersion for CMake 1.170.2 is 1.91.0 in Azure Devops 2020 Update 1.
{
"visibility": [
"Build"
],
"id": "7d831c3c-3c68-459a-a5c9-bde6e659596c",
"name": "CMake",
"version": {
"major": 1,
"minor": 170,
"patch": 2,
"isTest": false
},
"minimumAgentVersion": "1.91.0",
"friendlyName": "CMake",
"description": "Build with the CMake cross-platform build system",
"category": "Build",
"helpMarkDown": "[Learn more about this task](https://go.microsoft.com/fwlink/?LinkID=613719)",
"helpUrl": "https://docs.microsoft.com/azure/devops/pipelines/tasks/build/cmake",
"definitionType": "task",
"author": "Microsoft Corporation",
"demands": [
"cmake"
],
"groups": [],
"inputs": [
{
"aliases": [
"workingDirectory"
],
"name": "cwd",
"label": "Working Directory",
"defaultValue": "build",
"type": "filePath",
"helpMarkDown": "Current working directory when cmake is run."
},
{
"name": "cmakeArgs",
"label": "Arguments",
"defaultValue": "",
"type": "string",
"helpMarkDown": "Arguments passed to cmake"
}
],
"satisfies": [],
"sourceDefinitions": [],
"dataSourceBindings": [],
"instanceNameFormat": "CMake $(cmakeArgs)",
"preJobExecution": {},
"execution": {
"Node": {
"target": "cmaketask.js",
"argumentFormat": ""
}
},
"postJobExecution": {}
}
文档信息
- 本文作者:Robin Chen
- 本文链接:https://crushonme.github.io/2021/07/01/Minimum-Agent-Version-For-Target-Task/
- 版权声明:自由转载-非商用-非衍生-保持署名(创意共享4.0许可证)
Document Information
- Author :Robin Chen
- Link : https://crushonme.github.io/2021/07/01/Minimum-Agent-Version-For-Target-Task/
- Copyright:Attribution-NonCommercial-NoDerivatives-No additional restrictions(CC BY-NC-ND 4.0)