Skip to content
This repository was archived by the owner on Feb 23, 2024. It is now read-only.

Commit 3e3ea99

Browse files
karm435Karmjit Singh
andauthored
correct spelling of multipleAPIs (#395)
Co-authored-by: Karmjit Singh <karmjit.singh@readify.net>
1 parent 1000a68 commit 3e3ea99

File tree

5 files changed

+11
-11
lines changed

5 files changed

+11
-11
lines changed

src/APIM_ARMTemplate/README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -342,7 +342,7 @@ You have two choices when specifying your settings:
342342
| policyXMLBaseUrl | No | Policy XML files remote location. If provided, Extractor generates policies folder with xml files, and requires they be pushed to remote location. |
343343
| splitAPIs | No | If set to "true", then generate multiple api folders, each api will have a seperate folder, with a separate master template to deploy this api. If this single api has a version set, then a version set folder will generate instead, then all apis that belongs to this version set will be included in the version set folder, apis in this version set can be deployed separately using every api's master template, or they can be deployed together using the master template in "VersionSetMasterFolder" folder |
344344
| apiVersionSetName | No | Name of the APIVersionSet. If provided, extract all apis within this apiversionset. It will generate seperate folder for each api and also a master folder to link all apis in this apiversionset |
345-
| mutipleAPIs | No | Specify multiple APIs to extract. Generate templates for each API, also generate an aggregated templates folder to deploy these APIs together at a time |
345+
| multipleAPIs | No | Specify multiple APIs to extract. Generate templates for each API, also generate an aggregated templates folder to deploy these APIs together at a time |
346346
| includeAllRevisions | No | Set to "true" will extract all revisions for the single API. Will work only with "apiName" paramter, where you specify which API's revisions to extract. Generate templates for each revision, also generate an aggregated master folder to deploy these revisions together at one time. Note: there are many complicated issues with deploying revisions, make sure your deployment won't overwrite or break the existing ones |
347347
| baseFileName | No | Specify base file name of the template files |
348348
| policyXMLSasToken | No | Specify sasToken for fetching policy files |
@@ -356,7 +356,7 @@ You have two choices when specifying your settings:
356356

357357
#### Note
358358
* Can not use "splitAPIs" and "apiName" at the same time, since using "apiName" only extract one API
359-
* Can not use "apiName" and "mutipleAPIs" at the same time
359+
* Can not use "apiName" and "multipleAPIs" at the same time
360360
* Can only "includeAllRevisions" with "apiName"
361361

362362
<a name="extractorParameterFileExamples"></a>
@@ -431,7 +431,7 @@ Extract **multiple APIs**, use the following parameters:
431431
"fileFolder": "<destination-file-folder>",
432432
"linkedTemplatesBaseUrl": "<linked_templates_remote_location>",
433433
"policyXMLBaseUrl": "<policies_remote_location>",
434-
"mutipleAPIs": "api1, api2, api3"
434+
"multipleAPIs": "api1, api2, api3"
435435
}
436436
```
437437
Extract **single API with baseFileName**, use the following parameters:

src/APIM_ARMTemplate/apimtemplate.test/Extractor/ExtractorConfigTests.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ public void ExtractorConfigValidate_VerifyNotSupportedCases_ThrowsException(stri
5050
apiName = apiName,
5151
apiVersionSetName = apiVersionSetName,
5252
includeAllRevisions = includeAllRevisions,
53-
mutipleAPIs = multipleApis
53+
multipleAPIs = multipleApis
5454
};
5555

5656
Assert.Throws<NotSupportedException>(() => extractorConfig.Validate());

src/APIM_ARMTemplate/apimtemplate/Commands/Extract.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ public ExtractCommand()
3838
bool hasVersionSetName = extractorConfig.apiVersionSetName != null;
3939
bool hasSingleApi = singleApiName != null;
4040
bool includeRevisions = extractorConfig.includeAllRevisions != null && extractorConfig.includeAllRevisions.Equals("true");
41-
bool hasMultipleAPIs = extractorConfig.mutipleAPIs != null;
41+
bool hasMultipleAPIs = extractorConfig.multipleAPIs != null;
4242
EntityExtractor.baseUrl = (extractorConfig.serviceBaseUrl == null) ? EntityExtractor.baseUrl : extractorConfig.serviceBaseUrl;
4343

4444
// start running extractor

src/APIM_ARMTemplate/apimtemplate/Extractor/Models/ExtractorConfiguration.cs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ public class ExtractorConfig
1616
[Description("API name")]
1717
public string apiName { get; set; }
1818
[Description("Comma-separated list of API names")]
19-
public string mutipleAPIs { get; set; }
19+
public string multipleAPIs { get; set; }
2020
[Description("Creates a master template with links")]
2121
public string linkedTemplatesBaseUrl { get; set; }
2222
public string linkedTemplatesSasToken { get; set; }
@@ -57,7 +57,7 @@ public void Validate()
5757
bool hasVersionSetName = apiVersionSetName != null;
5858
bool hasSingleApi = apiName != null;
5959
bool includeRevisions = includeAllRevisions != null && includeAllRevisions.Equals("true");
60-
bool hasMultipleAPIs = mutipleAPIs != null;
60+
bool hasMultipleAPIs = multipleAPIs != null;
6161

6262
if (shouldSplitAPIs && hasSingleApi)
6363
{
@@ -71,7 +71,7 @@ public void Validate()
7171

7272
if ((hasVersionSetName || hasSingleApi) && hasMultipleAPIs)
7373
{
74-
throw new NotSupportedException("Can't use mutipleAPIs with apiName or apiVersionSetName at the same time");
74+
throw new NotSupportedException("Can't use multipleAPIs with apiName or apiVersionSetName at the same time");
7575
}
7676

7777
if (hasSingleApi && hasVersionSetName)

src/APIM_ARMTemplate/apimtemplate/Extractor/Utilities/ExtractorUtils.cs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -200,12 +200,12 @@ public static async Task GenerateAPIVersionSetTemplates(ExtractorConfig exc, Fil
200200
// this function will generate templates for multiple specified APIs
201201
public static async Task GenerateMultipleAPIsTemplates(ExtractorConfig exc, FileNameGenerator fileNameGenerator, FileWriter fileWriter, FileNames fileNames)
202202
{
203-
if (exc.mutipleAPIs == null && exc.mutipleAPIs.Equals(""))
203+
if (exc.multipleAPIs == null && exc.multipleAPIs.Equals(""))
204204
{
205-
throw new Exception("mutipleAPIs parameter doesn't have any data");
205+
throw new Exception("multipleAPIs parameter doesn't have any data");
206206
}
207207

208-
string[] apis = exc.mutipleAPIs.Split(',');
208+
string[] apis = exc.multipleAPIs.Split(',');
209209
for (int i = 0; i < apis.Length; i++)
210210
{
211211
apis[i] = apis[i].Trim();

0 commit comments

Comments
 (0)