Add Better XML parsing and Error Handling (#8)

* Added lazy loading of field hash, better XML handling and validation, additional validation for OData 4.0 and 4.01, and updated the RESOScript templates
* Added un-interpreted attempt to download and validate metadata if the Olingo client can't parse the response. Improved messaging.
* Changed XML metadata retrieval to fetch raw response so it could be validated using OASIS XSDs
* Added improved error message handling
This commit is contained in:
Joshua Darnell 2020-04-05 16:21:23 -07:00 committed by GitHub
parent 8f1179cf2f
commit 13adc2cc24
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
13 changed files with 308 additions and 230 deletions

View File

@ -91,8 +91,7 @@ task testWebApiServer_1_0_2_Gold() {
'org.reso.certification.stepdefs#WebAPIServer_1_0_2',
'src/main/java/org/reso/certification/features/web-api',
'--tags',
'not @platinum'
+ (systemProperties.get('cucumber.filter.tags') != null ? ' and ' + systemProperties.get('cucumber.filter.tags') : '')
(systemProperties.get('cucumber.filter.tags', '').toString().trim().length() > 0 ? 'not @platinum and ' + systemProperties.get('cucumber.filter.tags') : 'not @platinum')
]
}
}
@ -142,8 +141,7 @@ task testDataDictionary_1_5() {
'org.reso.certification.stepdefs#DataDictionary',
'src/main/java/org/reso/certification/features/data-dictionary',
'--tags',
'@DD1.5'
+ (systemProperties.get('cucumber.filter.tags') != null ? ' and ' + systemProperties.get('cucumber.filter.tags') : '')
(systemProperties.get('cucumber.filter.tags', '').toString().trim().length() > 0 ? '@DD1.5 and ' + systemProperties.get('cucumber.filter.tags') : '@DD1.5')
]
}
}
@ -169,8 +167,7 @@ task testDataDictionary_1_6() {
'org.reso.certification.stepdefs#DataDictionary',
'src/main/java/org/reso/certification/features/data-dictionary',
'--tags',
'@DD1.6'
+ (systemProperties.get('cucumber.filter.tags') != null ? ' and ' + systemProperties.get('cucumber.filter.tags') : '')
(systemProperties.get('cucumber.filter.tags', '').toString().trim().length() > 0 ? '@DD1.6 and ' + systemProperties.get('cucumber.filter.tags') : '@DD1.6')
]
}
}

Binary file not shown.

View File

@ -44,7 +44,7 @@
############################################################-->
<!-- The current version of this RESOScript -->
<RESOScriptVersion>2.0.0</RESOScriptVersion>
<RESOScriptVersion>2.0.1</RESOScriptVersion>
<!--
@ -250,235 +250,235 @@
<Request
RequestId="REQ-WA103-QR1"
OutputFile="REQ-WA103-QR1.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*(*Parameter_KeyOrKeyNumericValue*)?$select=*Parameter_KeyOrKeyNumericField*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*(*Parameter_KeyOrKeyNumericValue*)?$select=*Parameter_KeyOrKeyNumericField*,*Parameter_KeyOrKeyNumericField*"
/>
<Request
RequestId="REQ-WA103-QR3"
OutputFile="REQ-WA103-QR3.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* ne null and *Parameter_IntegerField* gt *Parameter_IntegerValueLow**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* gt *Parameter_IntegerValueLow**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QR4"
OutputFile="REQ-WA103-QR4.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* ne null and *Parameter_IntegerField* gt *Parameter_IntegerValueLow**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* gt *Parameter_IntegerValueLow**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QR5"
OutputFile="REQ-WA103-QR5.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* ne null and *Parameter_IntegerField* gt *Parameter_IntegerValueLow**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* gt *Parameter_IntegerValueLow**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO1.1"
OutputFile="REQ-WA103-QO1.1.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$SeLeCt=*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* ne null and *Parameter_IntegerField* eq *Parameter_IntegerValueLow**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$SeLeCt=*Parameter_KeyOrKeyNumericField*,*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* eq *Parameter_IntegerValueLow**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO1.2"
OutputFile="REQ-WA103-QO1.2.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_IntegerField*&amp;$FiLtEr=*Parameter_IntegerField* ne null and *Parameter_IntegerField* eq *Parameter_IntegerValueLow**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_IntegerField*&amp;$FiLtEr=*Parameter_IntegerField* eq *Parameter_IntegerValueLow**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO1.3"
OutputFile="REQ-WA103-QO1.3.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_SortCount*&amp;$select=*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* ne null and *Parameter_IntegerField* gt *Parameter_IntegerValueLow**Parameter_RequiredParameters*&amp;$OrDeRbY=*Parameter_IntegerField* asc"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_SortCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* gt *Parameter_IntegerValueLow**Parameter_RequiredParameters*&amp;$OrDeRbY=*Parameter_IntegerField* asc"
/>
<Request
RequestId="REQ-WA103-QO1.4"
OutputFile="REQ-WA103-QO1.4.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_SortCount*&amp;$select=*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* ne null and *Parameter_IntegerField* gt *Parameter_IntegerValueLow**Parameter_RequiredParameters*&amp;$oRdErBy=*Parameter_IntegerField* desc"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_SortCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* gt *Parameter_IntegerValueLow**Parameter_RequiredParameters*&amp;$oRdErBy=*Parameter_IntegerField* desc"
/>
<Request
RequestId="REQ-WA103-QO2"
OutputFile="REQ-WA103-QO2"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* ne null and *Parameter_IntegerField* eq *Parameter_IntegerValueLow**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* eq *Parameter_IntegerValueLow**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO3"
OutputFile="REQ-WA103-QO3"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* ne null and *Parameter_IntegerField* ne null and *Parameter_IntegerField* ne *Parameter_IntegerValueLow**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* ne *Parameter_IntegerValueLow**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO4"
OutputFile="REQ-WA103-QO4"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* ne null and *Parameter_IntegerField* gt *Parameter_IntegerValueLow**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* gt *Parameter_IntegerValueLow**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO5"
OutputFile="REQ-WA103-QO5.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* ne null and *Parameter_IntegerField* ge *Parameter_IntegerValueLow**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* ge *Parameter_IntegerValueLow**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO6"
OutputFile="REQ-WA103-QO6.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* ne null and *Parameter_IntegerField* lt *Parameter_IntegerValueLow**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* lt *Parameter_IntegerValueLow**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO7"
OutputFile="REQ-WA103-QO7.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* ne null and *Parameter_IntegerField* le *Parameter_IntegerValueLow**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* le *Parameter_IntegerValueLow**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO9"
OutputFile="REQ-WA103-QO9.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* ne null and *Parameter_IntegerField* gt *Parameter_IntegerValueLow* and *Parameter_IntegerField* lt *Parameter_IntegerValueHigh**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* gt *Parameter_IntegerValueLow* and *Parameter_IntegerField* lt *Parameter_IntegerValueHigh**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO10"
OutputFile="REQ-WA103-QO10.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* ne null and *Parameter_IntegerField* gt *Parameter_IntegerValueHigh* or *Parameter_IntegerField* lt *Parameter_IntegerValueLow**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* gt *Parameter_IntegerValueHigh* or *Parameter_IntegerField* lt *Parameter_IntegerValueLow**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO11"
OutputFile="REQ-WA103-QO11.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* ne null and not(*Parameter_FilterNotField* le *Parameter_FilterNotValue*)*Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_IntegerField*&amp;$filter=not(*Parameter_FilterNotField* le *Parameter_FilterNotValue*)*Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO25"
OutputFile="REQ-WA103-QO25.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_TimestampField*&amp;$filter=*Parameter_TimestampField* ne null and date(*Parameter_TimestampField*) gt *Parameter_DateValue**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_TimestampField*&amp;$filter=date(*Parameter_TimestampField*) gt *Parameter_DateValue**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO26"
OutputFile="REQ-WA103-QO26.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_TimestampField*&amp;$filter=*Parameter_TimestampField* ne null and time(*Parameter_TimestampField*) lt *Parameter_TimeValue**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_TimestampField*&amp;$filter=time(*Parameter_TimestampField*) lt *Parameter_TimeValue**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO26.2"
OutputFile="REQ-WA103-QO26.2.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_TimestampField*&amp;$filter=*Parameter_TimestampField* ne null and *Parameter_TimestampField* lt *Parameter_DateTimeValue**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_TimestampField*&amp;$filter=*Parameter_TimestampField* lt *Parameter_DateTimeValue**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO27"
OutputFile="REQ-WA103-QO27.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_TimestampField*&amp;$filter=*Parameter_TimestampField* ne null and *Parameter_TimestampField* le now()*Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_TimestampField*&amp;$filter=*Parameter_TimestampField* le now()*Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QM7"
OutputFile="REQ-WA103-QM7.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_SingleValueLookupField*&amp;$filter=*Parameter_SingleValueLookupField* ne null and *Parameter_SingleValueLookupField* has *Parameter_SingleValueLookupValue**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_KeyOrKeyNumericField*,*Parameter_SingleValueLookupField*&amp;$filter=*Parameter_SingleValueLookupField* has *Parameter_SingleValueLookupValue**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QM8"
OutputFile="REQ-WA103-QM8.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_MultipleValueLookupField*&amp;$filter=*Parameter_MultipleValueLookupField* ne null and *Parameter_MultipleValueLookupField* has *Parameter_MultipleValueLookupValue1**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_KeyOrKeyNumericField*,*Parameter_MultipleValueLookupField*&amp;$filter=*Parameter_MultipleValueLookupField* has *Parameter_MultipleValueLookupValue1**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QM8.2"
OutputFile="REQ-WA103-QM8.2.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_MultipleValueLookupField*&amp;$filter=*Parameter_MultipleValueLookupField* ne null and *Parameter_MultipleValueLookupField* has *Parameter_MultipleValueLookupValue1* and *Parameter_MultipleValueLookupField* has *Parameter_MultipleValueLookupValue2**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_KeyOrKeyNumericField*,*Parameter_MultipleValueLookupField*&amp;$filter=*Parameter_MultipleValueLookupField* has *Parameter_MultipleValueLookupValue1* and *Parameter_MultipleValueLookupField* has *Parameter_MultipleValueLookupValue2**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO8"
OutputFile="REQ-WA103-QO8.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_FilterHasField*&amp;$filter=*Parameter_FilterHasField* ne null and *Parameter_FilterHasField* has *Parameter_FilterHasValueLookupValue**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_FilterHasField*&amp;$filter=*Parameter_FilterHasField* has *Parameter_FilterHasValueLookupValue**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO28.1"
OutputFile="REQ-WA103-QO28.1.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_SortCount*&amp;$select=*Parameter_IntegerField*,*Parameter_TimestampField*&amp;$orderby=*Parameter_TimestampField* asc&amp;$filter=*Parameter_IntegerField* ne null and *Parameter_IntegerField* gt *Parameter_IntegerValueLow**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_SortCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_IntegerField*,*Parameter_TimestampField*&amp;$orderby=*Parameter_TimestampField* asc&amp;$filter=*Parameter_IntegerField* gt *Parameter_IntegerValueLow**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO28.2"
OutputFile="REQ-WA103-QO28.2.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_SortCount*&amp;$select=*Parameter_IntegerField*,*Parameter_TimestampField*&amp;$orderby=*Parameter_TimestampField* asc"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_SortCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_IntegerField*,*Parameter_TimestampField*&amp;$orderby=*Parameter_TimestampField* asc"
/>
<Request
RequestId="REQ-WA103-QO28.3"
OutputFile="REQ-WA103-QO28.3.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_SortCount*&amp;$select=*Parameter_IntegerField*,*Parameter_TimestampField*&amp;$orderby=*Parameter_TimestampField* desc&amp;$filter=*Parameter_IntegerField* ne null and *Parameter_IntegerField* gt *Parameter_IntegerValueLow**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_SortCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_IntegerField*,*Parameter_TimestampField*&amp;$orderby=*Parameter_TimestampField* desc&amp;$filter=*Parameter_IntegerField* gt *Parameter_IntegerValueLow**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO28.4"
OutputFile="REQ-WA103-QO28.4.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_SortCount*&amp;$select=*Parameter_IntegerField*,*Parameter_TimestampField*&amp;$orderby=*Parameter_TimestampField* desc"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_SortCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_IntegerField*,*Parameter_TimestampField*&amp;$orderby=*Parameter_TimestampField* desc"
/>
<Request
RequestId="REQ-WA103-QO18.1"
OutputFile="REQ-WA103-QO18.1.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_DateField*&amp;$filter=*Parameter_DateField* ne null and year(*Parameter_DateField*) eq *Parameter_YearValue**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_DateField*&amp;$filter=year(*Parameter_DateField*) eq *Parameter_YearValue**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO18.2"
OutputFile="REQ-WA103-QO18.2.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_TimestampField*&amp;$filter=*Parameter_TimestampField* ne null and year(*Parameter_TimestampField*) eq *Parameter_YearValue**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_TimestampField*&amp;$filter=year(*Parameter_TimestampField*) eq *Parameter_YearValue**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO19.1"
OutputFile="REQ-WA103-QO19.1.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_DateField*&amp;$filter=*Parameter_DateField* ne null and month(*Parameter_DateField*) eq *Parameter_MonthValue**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_DateField*&amp;$filter=month(*Parameter_DateField*) eq *Parameter_MonthValue**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO19.2"
OutputFile="REQ-WA103-QO19.2.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_TimestampField*&amp;$filter=*Parameter_TimestampField* ne null and month(*Parameter_TimestampField*) eq *Parameter_MonthValue**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_TimestampField*&amp;$filter=month(*Parameter_TimestampField*) eq *Parameter_MonthValue**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO20.1"
OutputFile="REQ-WA103-QO20.1.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_DateField*&amp;$filter=*Parameter_DateField* ne null and day(*Parameter_DateField*) eq *Parameter_DayValue**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_DateField*&amp;$filter=day(*Parameter_DateField*) eq *Parameter_DayValue**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO20.2"
OutputFile="REQ-WA103-QO20.2.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_TimestampField*&amp;$filter=*Parameter_TimestampField* ne null and day(*Parameter_TimestampField*) eq *Parameter_DayValue**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_TimestampField*&amp;$filter=day(*Parameter_TimestampField*) eq *Parameter_DayValue**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO21"
OutputFile="REQ-WA103-QO21.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_TimestampField*&amp;$filter=*Parameter_TimestampField* ne null and hour(*Parameter_TimestampField*) eq *Parameter_HourValue**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_TimestampField*&amp;$filter=hour(*Parameter_TimestampField*) eq *Parameter_HourValue**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO22"
OutputFile="REQ-WA103-QO22.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_TimestampField*&amp;$filter=*Parameter_TimestampField* ne null and minute(*Parameter_TimestampField*) gt *Parameter_MinuteValue**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_TimestampField*&amp;$filter=minute(*Parameter_TimestampField*) gt *Parameter_MinuteValue**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO23"
OutputFile="REQ-WA103-QO23.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_TimestampField*&amp;$filter=*Parameter_TimestampField* ne null and second(*Parameter_TimestampField*) lt *Parameter_SecondValue**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_TimestampField*&amp;$filter=second(*Parameter_TimestampField*) lt *Parameter_SecondValue**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO24"
OutputFile="REQ-WA103-QO24.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_TimestampField*&amp;$filter=*Parameter_TimestampField* ne null and fractionalseconds(*Parameter_TimestampField*) lt *Parameter_FractionalValue**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_TimestampField*&amp;$filter=fractionalseconds(*Parameter_TimestampField*) lt *Parameter_FractionalValue**Parameter_RequiredParameters*"
/>
<Request
@ -518,6 +518,5 @@
OutputFile="REQ-WA103-RC11_501NotImplemented.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_501NotImplemented*"
/>
</Requests>
</OutputScript>
</OutputScript>

View File

@ -44,7 +44,7 @@
############################################################-->
<!-- The current version of this RESOScript -->
<RESOScriptVersion>2.0.0</RESOScriptVersion>
<RESOScriptVersion>2.0.1</RESOScriptVersion>
<!--
@ -287,253 +287,253 @@
<Request
RequestId="REQ-WA103-QR1"
OutputFile="REQ-WA103-QR1.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*(*Parameter_KeyOrKeyNumericValue*)?$select=*Parameter_KeyOrKeyNumericField*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*(*Parameter_KeyOrKeyNumericValue*)?$select=*Parameter_KeyOrKeyNumericField*,*Parameter_KeyOrKeyNumericField*"
/>
<Request
RequestId="REQ-WA103-QR3"
OutputFile="REQ-WA103-QR3.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* ne null and *Parameter_IntegerField* gt *Parameter_IntegerValueLow**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* gt *Parameter_IntegerValueLow**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QR4"
OutputFile="REQ-WA103-QR4.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* ne null and *Parameter_IntegerField* gt *Parameter_IntegerValueLow**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* gt *Parameter_IntegerValueLow**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QR5"
OutputFile="REQ-WA103-QR5.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* ne null and *Parameter_IntegerField* gt *Parameter_IntegerValueLow**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* gt *Parameter_IntegerValueLow**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO1.1"
OutputFile="REQ-WA103-QO1.1.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$SeLeCt=*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* ne null and *Parameter_IntegerField* eq *Parameter_IntegerValueLow**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$SeLeCt=*Parameter_KeyOrKeyNumericField*,*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* eq *Parameter_IntegerValueLow**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO1.2"
OutputFile="REQ-WA103-QO1.2.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_IntegerField*&amp;$FiLtEr=*Parameter_IntegerField* ne null and *Parameter_IntegerField* eq *Parameter_IntegerValueLow**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_IntegerField*&amp;$FiLtEr=*Parameter_IntegerField* eq *Parameter_IntegerValueLow**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO1.3"
OutputFile="REQ-WA103-QO1.3.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_SortCount*&amp;$select=*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* ne null and *Parameter_IntegerField* gt *Parameter_IntegerValueLow**Parameter_RequiredParameters*&amp;$OrDeRbY=*Parameter_IntegerField* asc"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_SortCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* gt *Parameter_IntegerValueLow**Parameter_RequiredParameters*&amp;$OrDeRbY=*Parameter_IntegerField* asc"
/>
<Request
RequestId="REQ-WA103-QO1.4"
OutputFile="REQ-WA103-QO1.4.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_SortCount*&amp;$select=*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* ne null and *Parameter_IntegerField* gt *Parameter_IntegerValueLow**Parameter_RequiredParameters*&amp;$oRdErBy=*Parameter_IntegerField* desc"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_SortCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* gt *Parameter_IntegerValueLow**Parameter_RequiredParameters*&amp;$oRdErBy=*Parameter_IntegerField* desc"
/>
<Request
RequestId="REQ-WA103-QO2"
OutputFile="REQ-WA103-QO2"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* ne null and *Parameter_IntegerField* eq *Parameter_IntegerValueLow**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* eq *Parameter_IntegerValueLow**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO3"
OutputFile="REQ-WA103-QO3"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* ne null and *Parameter_IntegerField* ne null and *Parameter_IntegerField* ne *Parameter_IntegerValueLow**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* ne *Parameter_IntegerValueLow**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO4"
OutputFile="REQ-WA103-QO4"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* ne null and *Parameter_IntegerField* gt *Parameter_IntegerValueLow**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* gt *Parameter_IntegerValueLow**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO5"
OutputFile="REQ-WA103-QO5.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* ne null and *Parameter_IntegerField* ge *Parameter_IntegerValueLow**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* ge *Parameter_IntegerValueLow**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO6"
OutputFile="REQ-WA103-QO6.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* ne null and *Parameter_IntegerField* lt *Parameter_IntegerValueLow**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* lt *Parameter_IntegerValueLow**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO7"
OutputFile="REQ-WA103-QO7.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* ne null and *Parameter_IntegerField* le *Parameter_IntegerValueLow**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* le *Parameter_IntegerValueLow**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO9"
OutputFile="REQ-WA103-QO9.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* ne null and *Parameter_IntegerField* gt *Parameter_IntegerValueLow* and *Parameter_IntegerField* lt *Parameter_IntegerValueHigh**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* gt *Parameter_IntegerValueLow* and *Parameter_IntegerField* lt *Parameter_IntegerValueHigh**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO10"
OutputFile="REQ-WA103-QO10.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* ne null and *Parameter_IntegerField* gt *Parameter_IntegerValueHigh* or *Parameter_IntegerField* lt *Parameter_IntegerValueLow**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* gt *Parameter_IntegerValueHigh* or *Parameter_IntegerField* lt *Parameter_IntegerValueLow**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO11"
OutputFile="REQ-WA103-QO11.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* ne null and not(*Parameter_FilterNotField* le *Parameter_FilterNotValue*)*Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_IntegerField*&amp;$filter=not(*Parameter_FilterNotField* le *Parameter_FilterNotValue*)*Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO25"
OutputFile="REQ-WA103-QO25.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_TimestampField*&amp;$filter=*Parameter_TimestampField* ne null and date(*Parameter_TimestampField*) gt *Parameter_DateValue**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_TimestampField*&amp;$filter=date(*Parameter_TimestampField*) gt *Parameter_DateValue**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO26"
OutputFile="REQ-WA103-QO26.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_TimestampField*&amp;$filter=*Parameter_TimestampField* ne null and time(*Parameter_TimestampField*) lt *Parameter_TimeValue**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_TimestampField*&amp;$filter=time(*Parameter_TimestampField*) lt *Parameter_TimeValue**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO26.2"
OutputFile="REQ-WA103-QO26.2.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_TimestampField*&amp;$filter=*Parameter_TimestampField* ne null and *Parameter_TimestampField* lt *Parameter_DateTimeValue**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_TimestampField*&amp;$filter=*Parameter_TimestampField* lt *Parameter_DateTimeValue**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO27"
OutputFile="REQ-WA103-QO27.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_TimestampField*&amp;$filter=*Parameter_TimestampField* ne null and *Parameter_TimestampField* le now()*Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_TimestampField*&amp;$filter=*Parameter_TimestampField* le now()*Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QM7"
OutputFile="REQ-WA103-QM7.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_SingleValueLookupField*&amp;$filter=*Parameter_SingleValueLookupField* ne null and *Parameter_SingleValueLookupField* has *Parameter_SingleValueLookupValue**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_KeyOrKeyNumericField*,*Parameter_SingleValueLookupField*&amp;$filter=*Parameter_SingleValueLookupField* has *Parameter_SingleValueLookupValue**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QM8"
OutputFile="REQ-WA103-QM8.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_MultipleValueLookupField*&amp;$filter=*Parameter_MultipleValueLookupField* ne null and *Parameter_MultipleValueLookupField* has *Parameter_MultipleValueLookupValue1**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_KeyOrKeyNumericField*,*Parameter_MultipleValueLookupField*&amp;$filter=*Parameter_MultipleValueLookupField* has *Parameter_MultipleValueLookupValue1**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QM8.2"
OutputFile="REQ-WA103-QM8.2.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_MultipleValueLookupField*&amp;$filter=*Parameter_MultipleValueLookupField* ne null and *Parameter_MultipleValueLookupField* has *Parameter_MultipleValueLookupValue1* and *Parameter_MultipleValueLookupField* has *Parameter_MultipleValueLookupValue2**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_KeyOrKeyNumericField*,*Parameter_MultipleValueLookupField*&amp;$filter=*Parameter_MultipleValueLookupField* has *Parameter_MultipleValueLookupValue1* and *Parameter_MultipleValueLookupField* has *Parameter_MultipleValueLookupValue2**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO8"
OutputFile="REQ-WA103-QO8.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_FilterHasField*&amp;$filter=*Parameter_FilterHasField* ne null and *Parameter_FilterHasField* has *Parameter_FilterHasValueLookupValue**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_FilterHasField*&amp;$filter=*Parameter_FilterHasField* has *Parameter_FilterHasValueLookupValue**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO28.1"
OutputFile="REQ-WA103-QO28.1.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_SortCount*&amp;$select=*Parameter_IntegerField*,*Parameter_TimestampField*&amp;$orderby=*Parameter_TimestampField* asc&amp;$filter=*Parameter_IntegerField* ne null and *Parameter_IntegerField* gt *Parameter_IntegerValueLow**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_SortCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_IntegerField*,*Parameter_TimestampField*&amp;$orderby=*Parameter_TimestampField* asc&amp;$filter=*Parameter_IntegerField* gt *Parameter_IntegerValueLow**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO28.2"
OutputFile="REQ-WA103-QO28.2.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_SortCount*&amp;$select=*Parameter_IntegerField*,*Parameter_TimestampField*&amp;$orderby=*Parameter_TimestampField* asc"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_SortCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_IntegerField*,*Parameter_TimestampField*&amp;$orderby=*Parameter_TimestampField* asc"
/>
<Request
RequestId="REQ-WA103-QO28.3"
OutputFile="REQ-WA103-QO28.3.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_SortCount*&amp;$select=*Parameter_IntegerField*,*Parameter_TimestampField*&amp;$orderby=*Parameter_TimestampField* desc&amp;$filter=*Parameter_IntegerField* ne null and *Parameter_IntegerField* gt *Parameter_IntegerValueLow**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_SortCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_IntegerField*,*Parameter_TimestampField*&amp;$orderby=*Parameter_TimestampField* desc&amp;$filter=*Parameter_IntegerField* gt *Parameter_IntegerValueLow**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO28.4"
OutputFile="REQ-WA103-QO28.4.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_SortCount*&amp;$select=*Parameter_IntegerField*,*Parameter_TimestampField*&amp;$orderby=*Parameter_TimestampField* desc"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_SortCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_IntegerField*,*Parameter_TimestampField*&amp;$orderby=*Parameter_TimestampField* desc"
/>
<Request
RequestId="REQ-WA103-QO18.1"
OutputFile="REQ-WA103-QO18.1.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_DateField*&amp;$filter=*Parameter_DateField* ne null and year(*Parameter_DateField*) eq *Parameter_YearValue**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_DateField*&amp;$filter=year(*Parameter_DateField*) eq *Parameter_YearValue**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO18.2"
OutputFile="REQ-WA103-QO18.2.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_TimestampField*&amp;$filter=*Parameter_TimestampField* ne null and year(*Parameter_TimestampField*) eq *Parameter_YearValue**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_TimestampField*&amp;$filter=year(*Parameter_TimestampField*) eq *Parameter_YearValue**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO19.1"
OutputFile="REQ-WA103-QO19.1.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_DateField*&amp;$filter=*Parameter_DateField* ne null and month(*Parameter_DateField*) eq *Parameter_MonthValue**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_DateField*&amp;$filter=month(*Parameter_DateField*) eq *Parameter_MonthValue**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO19.2"
OutputFile="REQ-WA103-QO19.2.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_TimestampField*&amp;$filter=*Parameter_TimestampField* ne null and month(*Parameter_TimestampField*) eq *Parameter_MonthValue**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_TimestampField*&amp;$filter=month(*Parameter_TimestampField*) eq *Parameter_MonthValue**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO20.1"
OutputFile="REQ-WA103-QO20.1.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_DateField*&amp;$filter=*Parameter_DateField* ne null and day(*Parameter_DateField*) eq *Parameter_DayValue**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_DateField*&amp;$filter=day(*Parameter_DateField*) eq *Parameter_DayValue**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO20.2"
OutputFile="REQ-WA103-QO20.2.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_TimestampField*&amp;$filter=*Parameter_TimestampField* ne null and day(*Parameter_TimestampField*) eq *Parameter_DayValue**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_TimestampField*&amp;$filter=day(*Parameter_TimestampField*) eq *Parameter_DayValue**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO21"
OutputFile="REQ-WA103-QO21.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_TimestampField*&amp;$filter=*Parameter_TimestampField* ne null and hour(*Parameter_TimestampField*) eq *Parameter_HourValue**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_TimestampField*&amp;$filter=hour(*Parameter_TimestampField*) eq *Parameter_HourValue**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO22"
OutputFile="REQ-WA103-QO22.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_TimestampField*&amp;$filter=*Parameter_TimestampField* ne null and minute(*Parameter_TimestampField*) gt *Parameter_MinuteValue**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_TimestampField*&amp;$filter=minute(*Parameter_TimestampField*) gt *Parameter_MinuteValue**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO23"
OutputFile="REQ-WA103-QO23.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_TimestampField*&amp;$filter=*Parameter_TimestampField* ne null and second(*Parameter_TimestampField*) lt *Parameter_SecondValue**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_TimestampField*&amp;$filter=second(*Parameter_TimestampField*) lt *Parameter_SecondValue**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO24"
OutputFile="REQ-WA103-QO24.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_TimestampField*&amp;$filter=*Parameter_TimestampField* ne null and fractionalseconds(*Parameter_TimestampField*) lt *Parameter_FractionalValue**Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_TimestampField*&amp;$filter=fractionalseconds(*Parameter_TimestampField*) lt *Parameter_FractionalValue**Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO29.1"
OutputFile="REQ-WA103-QO29.1.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_ExpandField*&amp;$expand=*Parameter_ExpandField*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_KeyOrKeyNumericField*,*Parameter_ExpandField*&amp;$expand=*Parameter_ExpandField*"
/>
<Request
RequestId="REQ-WA103-QO29.2"
OutputFile="REQ-WA103-QO29.2.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_ExpandField*&amp;$expand=*Parameter_ExpandField*&amp;$filter=PhotosCount gt 0"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_KeyOrKeyNumericField*,*Parameter_ExpandField*&amp;$expand=*Parameter_ExpandField*&amp;$filter=PhotosCount gt 0"
/>
<Request
RequestId="REQ-WA103-QO29.3"
OutputFile="REQ-WA103-QO29.3.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_ExpandField*&amp;$expand=*Parameter_ExpandField**Parameter_RequiredParametersFilter*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_KeyOrKeyNumericField*,*Parameter_ExpandField*&amp;$expand=*Parameter_ExpandField**Parameter_RequiredParametersFilter*"
/>
<Request
@ -551,49 +551,49 @@
<Request
RequestId="REQ-WA103-QM5.1"
OutputFile="REQ-WA103-QM5_GeoSpatialLongLat_PointGeo.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_GeoSpatialField*&amp;$filter=geo.distance(*Parameter_GeoSpatialField*, geography'SRID=*Parameter_SRID*;POINT(*Parameter_GeoSpatialValue*)' le *Parameter_GeoSpatialDistanceValue*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_GeoSpatialField*&amp;$filter=geo.distance(*Parameter_GeoSpatialField*, geography'SRID=*Parameter_SRID*;POINT(*Parameter_GeoSpatialValue*)' le *Parameter_GeoSpatialDistanceValue*"
/>
<Request
RequestId="REQ-WA103-QM5.2"
OutputFile="REQ-WA103-QM5_GeoSpatialLongLat_LatGT1_PointGeo.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_GeoSpatialField*&amp;$filter=geo.distance(*Parameter_GeoSpatialField*, geography'SRID=*Parameter_SRID*;POINT(*Parameter_GeoSpatialValue*)' le *Parameter_GeoSpatialDistanceValue* and *Parameter_GeoSpatialLatitudeField* gt 1"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_GeoSpatialField*&amp;$filter=geo.distance(*Parameter_GeoSpatialField*, geography'SRID=*Parameter_SRID*;POINT(*Parameter_GeoSpatialValue*)' le *Parameter_GeoSpatialDistanceValue* and *Parameter_GeoSpatialLatitudeField* gt 1"
/>
<Request
RequestId="REQ-WA103-QO12"
OutputFile="REQ-WA103-QO12_Grouping.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_IntegerField*&amp;$filter=*Parameter_IntegerField* ne null and (*Parameter_IntegerField* ge *Parameter_IntegerValueLow* and *Parameter_IntegerField* le *Parameter_IntegerValueHigh*) and (*Parameter_IntegerField* lt *Parameter_IntegerValueHigh* and *Parameter_IntegerField* gt *Parameter_IntegerValueLow*)*Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_IntegerField*&amp;$filter=(*Parameter_IntegerField* ge *Parameter_IntegerValueLow* and *Parameter_IntegerField* le *Parameter_IntegerValueHigh*) and (*Parameter_IntegerField* lt *Parameter_IntegerValueHigh* and *Parameter_IntegerField* gt *Parameter_IntegerValueLow*)*Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO13"
OutputFile="REQ-WA103-QO13.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_StringField*&amp;$filter=*Parameter_StringField* ne null and contains(*Parameter_StringField*,'*Parameter_ContainsValue*')*Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_StringField*&amp;$filter=contains(*Parameter_StringField*,'*Parameter_ContainsValue*')*Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO14"
OutputFile="REQ-WA103-QO14_EndsWith.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_StringField*&amp;$filter=*Parameter_StringField* ne null and endswith(*Parameter_StringField*,'*Parameter_EndsWithValue*')*Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_StringField*&amp;$filter=endswith(*Parameter_StringField*,'*Parameter_EndsWithValue*')*Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO15"
OutputFile="REQ-WA103-QO15_StartsWith.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_StringField*&amp;$filter=*Parameter_StringField* ne null and startswith(*Parameter_StringField*,'*Parameter_StartsWithValue*')*Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_StringField*&amp;$filter=startswith(*Parameter_StringField*,'*Parameter_StartsWithValue*')*Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO16"
OutputFile="REQ-WA103-QO16_ToLowerEQ.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_StringField*&amp;$filter=*Parameter_StringField* ne null and tolower(*Parameter_StringField*) eq '*Parameter_ToLowerValue*'*Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_StringField*&amp;$filter=tolower(*Parameter_StringField*) eq '*Parameter_ToLowerValue*'*Parameter_RequiredParameters*"
/>
<Request
RequestId="REQ-WA103-QO17"
OutputFile="REQ-WA103-QO17_ToUpperEQ.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_StringField*&amp;$filter=*Parameter_StringField* ne null and toupper(*Parameter_StringField*) eq '*Parameter_ToUpperValue*'*Parameter_RequiredParameters*"
Url="*ClientSettings_WebAPIURI*/*Parameter_EndpointResource*?$top=*Parameter_TopCount*&amp;$select=*Parameter_KeyOrKeyNumericField*,*Parameter_StringField*&amp;$filter=toupper(*Parameter_StringField*) eq '*Parameter_ToUpperValue*'*Parameter_RequiredParameters*"
/>
<Request
@ -633,6 +633,5 @@
OutputFile="REQ-WA103-RC11_501NotImplemented.json"
Url="*ClientSettings_WebAPIURI*/*Parameter_501NotImplemented*"
/>
</Requests>
</OutputScript>

View File

@ -19,14 +19,15 @@ Feature: Web API Server 1.0.2 Certification
When XML Metadata are requested from the service root in "ClientSettings_WebAPIURI"
Then the server responds with a status code of 200
And the server has an OData-Version header value of "4.0" or "4.01"
And the XML Metadata response is valid XML
And the XML metadata returned by the server are valid
And Edm metadata are requested from the service root in "ClientSettings_WebAPIURI"
Then the server responds with a status code of 200
And the server has an OData-Version header value of "4.0" or "4.01"
And the Edm metadata returned by the server are valid
And the metadata contains a valid service document
And the metadata contains the "Parameter_EndpointResource" resource
And the given "Parameter_EndpointResource" resource exists within "Parameter_DD17_WellKnownResourceList"
And the metadata contains the "Parameter_EndpointResource" resource
And the metadata contains at least one resource from "Parameter_WebAPI102_RequiredResourceList"
@REQ-WA103-END2 @core @2.4.1 @core-endorsement @datasystem

View File

@ -43,6 +43,8 @@ import static org.reso.commander.Commander.*;
import static org.reso.commander.TestUtils.*;
import static org.reso.commander.TestUtils.Operators.*;
import static org.reso.commander.certfication.containers.WebApiTestContainer.*;
import static org.reso.common.ErrorMsg.getAssertResponseCodeErrorMessage;
import static org.reso.common.ErrorMsg.getDefaultErrorMessage;
/**
* Contains the glue code for the Web API Server 1.0.2 Platinum Certification
@ -50,6 +52,9 @@ import static org.reso.commander.certfication.containers.WebApiTestContainer.*;
public class WebAPIServer_1_0_2 implements En {
private static final Logger LOG = LogManager.getLogger(WebAPIServer_1_0_2.class);
private static final String SHOW_RESPONSES = "showResponses";
//extract any params here
private static final boolean showResponses = Boolean.parseBoolean(System.getProperty(SHOW_RESPONSES));
/*
@ -123,7 +128,7 @@ public class WebAPIServer_1_0_2 implements En {
LOG.info("DataSystem response matches reference schema!");
}
} catch (Exception ex) {
fail(ex.toString());
fail(getDefaultErrorMessage(ex));
}
}
});
@ -158,27 +163,6 @@ public class WebAPIServer_1_0_2 implements En {
}
});
// /*
// * XMLMetadata Validator
// */
// And("^the XML metadata returned by the server are valid$", () -> {
// assertNotNull("ERROR: No Response Data exists to convert to XML Metadata!", getTestContainer().responseData.get());
//
// try {
// ByteArrayInputStream byteArrayInputStream = new ByteArrayInputStream(getTestContainer().responseData.get().getBytes());
// xmlMetadata.set(getTestContainer().commander.get().getClient().getDeserializer(ContentType.APPLICATION_XML).toMetadata(byteArrayInputStream));
//
// if (showResponses) LOG.info("XML Metadata is: \n" + getTestContainer().responseData.get());
//
// boolean isValid = getTestContainer().commander.get().validateMetadata(getTestContainer().getXmlMetadata());
// LOG.info("XML Metadata is " + (isValid ? "valid" : "invalid") + "!");
// assertTrue("ERROR: XML Metadata at the given service root is not valid! " + serviceRoot, isValid);
// } catch (Exception ex) {
// fail("ERROR: could not validate XML Metadata!\n" + ex.toString());
// }
// });
/*
* REQ-WA103-QR1
*/
@ -204,7 +188,7 @@ public class WebAPIServer_1_0_2 implements En {
assertEquals("ERROR: the given String value is not equal to the value found on the server!", expectedValueAsString, resolvedValue.toString());
}
} catch (Exception ex) {
fail(ex.toString());
fail(getDefaultErrorMessage(ex));
}
});
@ -247,7 +231,7 @@ public class WebAPIServer_1_0_2 implements En {
}
assertTrue("ERROR: no fields with data could be found from the given $select list!", numFieldsWithData.get() > 0);
} catch (Exception ex) {
fail(ex.toString());
fail(getDefaultErrorMessage(ex));
}
});
@ -267,7 +251,7 @@ public class WebAPIServer_1_0_2 implements En {
assertTrue("ERROR: results count must be greater than zero and less than " + parameterTopCount + "!",
numResults.get() > 0 && numResults.get() <= topCount);
} catch (Exception ex) {
fail(ex.toString());
fail(getDefaultErrorMessage(ex));
}
});
@ -292,7 +276,7 @@ public class WebAPIServer_1_0_2 implements En {
+ AMPERSAND + ODATA_QUERY_PARAMS.SKIP + EQUALS + skipCount));
getTestContainer().executePreparedGetRequest();
} catch (Exception ex) {
fail(ex.toString());
fail(getDefaultErrorMessage(ex));
}
});
@ -313,7 +297,7 @@ public class WebAPIServer_1_0_2 implements En {
assertEquals("ERROR: repeated data found, expected unique data on each page!", combinedCount, combined.size());
} catch (Exception ex) {
fail(ex.toString());
fail(getDefaultErrorMessage(ex));
}
});
@ -339,27 +323,27 @@ public class WebAPIServer_1_0_2 implements En {
if (getTestContainer().getODataClientErrorException().getODataError().getMessage() != null) {
LOG.error("Request failed with the following message: "
+ getTestContainer().getODataClientErrorException().getODataError().getMessage());
} else if (getTestContainer().getODataClientErrorException() != null) {
} else if (getTestContainer().getODataClientErrorException().getMessage() != null) {
LOG.error("Request failed with the following message: "
+ getTestContainer().getODataClientErrorException().getMessage());
}
}
fail("ERROR: asserted response code does not match the one returned from the server!");
fail(getAssertResponseCodeErrorMessage(assertedResponseCode, getTestContainer().getResponseCode()));
}
} catch (Exception ex) {
fail(ex.toString());
fail(getDefaultErrorMessage(ex));
}
});
/*
* validate XML wrapper
*/
And("^the response is valid XML$", () -> {
And("^the XML Metadata response is valid XML$", () -> {
try {
assertTrue("ERROR: invalid XML response!", Commander.validateXML(getTestContainer().getXMLMetadata()));
assertTrue("ERROR: invalid XML response!", Commander.validateXML(getTestContainer().getXMLResponseData()));
LOG.info("Response is valid XML!");
} catch (Exception ex) {
fail(ex.toString());
fail(getDefaultErrorMessage(ex));
}
});
@ -374,7 +358,7 @@ public class WebAPIServer_1_0_2 implements En {
if (showResponses)
LOG.info("Response: " + new ObjectMapper().readTree(getTestContainer().getResponseData()).toPrettyString());
} catch (Exception ex) {
fail(ex.toString());
fail(getDefaultErrorMessage(ex));
}
});
@ -392,7 +376,7 @@ public class WebAPIServer_1_0_2 implements En {
if (versionsMatch) {
LOG.info("Asserted Response Code: " + assertedHttpResponseCode + ", Response code: " + getTestContainer().getResponseCode());
assertTrue("ERROR: asserted response code does not match the one returned from the server!", responseCodesMatch);
assertTrue("ERROR: asserted response code (" + assertedHttpResponseCode + ") does not match the one returned from the server (" + getTestContainer().getResponseCode() + ") !", responseCodesMatch);
} else {
LOG.info("Test skipped! Only applies when the asserted version matches the reported server version.");
}
@ -420,13 +404,14 @@ public class WebAPIServer_1_0_2 implements En {
//iterate through response data and ensure that with data, the statement fieldName "op" assertValue is true
from(getTestContainer().getResponseData()).getList(JSON_VALUE_PATH, HashMap.class).forEach(item -> {
assertNotNull("ERROR: '" + fieldName + "' cannot be null!", item.get(fieldName));
fieldValue.set(Integer.parseInt(item.get(fieldName).toString()));
result.set(result.get() && TestUtils.compare(fieldValue.get(), op, assertedValue));
});
assertTrue(result.get());
} catch (Exception ex) {
fail(ex.toString());
fail(getDefaultErrorMessage(ex));
}
});
@ -435,11 +420,11 @@ public class WebAPIServer_1_0_2 implements En {
*/
And("^the response has results$", () -> {
try {
int count = from(getTestContainer().getResponseData()).getList(JSON_VALUE_PATH, HashMap.class).size();
assertTrue("ERROR: no results were found in the '" + JSON_VALUE_PATH + "' path of the JSON response!", count > 0);
LOG.info("Results count is: " + count);
assertTrue("ERROR: no results were found in the '" + JSON_VALUE_PATH + "' path of the JSON response!",
from(getTestContainer().getResponseData()).getList(JSON_VALUE_PATH, Map.class).size() > 0);
LOG.info("Results count is: " + from(getTestContainer().getResponseData()).getList(JSON_VALUE_PATH, Map.class).get(0).size());
} catch (Exception ex) {
fail(ex.toString());
fail(getDefaultErrorMessage(ex));
}
});
@ -454,7 +439,7 @@ public class WebAPIServer_1_0_2 implements En {
LOG.info("Response value is: " + value);
LOG.info("Is Present: " + isPresent);
} catch (Exception ex) {
fail(ex.toString());
fail(getDefaultErrorMessage(ex));
}
});
@ -468,7 +453,7 @@ public class WebAPIServer_1_0_2 implements En {
LOG.info("Results count is: " + count + ", Limit is: " + limit);
assertTrue("ERROR: number of results exceeds that specified in '" + limitField + "'!", count <= limit);
} catch (Exception ex) {
fail(ex.toString());
fail(getDefaultErrorMessage(ex));
}
});
@ -512,7 +497,7 @@ public class WebAPIServer_1_0_2 implements En {
}
});
} catch (Exception ex) {
fail(ex.toString());
fail(getDefaultErrorMessage(ex));
}
});
@ -533,11 +518,11 @@ public class WebAPIServer_1_0_2 implements En {
fieldValue.set(TestUtils.parseDateFromEdmDateTimeOffsetString(item.get(fieldName).toString()));
assertTrue(TestUtils.compare(fieldValue.get(), op, assertedValue.get()));
} catch (Exception ex) {
fail(ex.toString());
fail(getDefaultErrorMessage(ex));
}
});
} catch (Exception ex) {
fail(ex.toString());
fail(getDefaultErrorMessage(ex));
}
});
@ -562,7 +547,7 @@ public class WebAPIServer_1_0_2 implements En {
}
});
} catch (Exception ex) {
fail(ex.toString());
fail(getDefaultErrorMessage(ex));
}
});
@ -573,7 +558,7 @@ public class WebAPIServer_1_0_2 implements En {
try {
TestUtils.assertDateTimeOffset(parameterFieldName, op, parameterAssertedValue, getTestContainer().getResponseData(), getTestContainer().getSettings());
} catch (Exception ex) {
fail(ex.toString());
fail(getDefaultErrorMessage(ex));
}
});
@ -584,7 +569,7 @@ public class WebAPIServer_1_0_2 implements En {
try {
TestUtils.assertDateTimeOffset(parameterFieldName, op, Timestamp.from(Instant.now()), getTestContainer().getResponseData(), getTestContainer().getSettings());
} catch (Exception ex) {
fail(ex.toString());
fail(getDefaultErrorMessage(ex));
}
});
@ -609,7 +594,7 @@ public class WebAPIServer_1_0_2 implements En {
assertTrue(result.get());
});
} catch (Exception ex) {
fail(ex.toString());
fail(getDefaultErrorMessage(ex));
}
});
@ -635,7 +620,7 @@ public class WebAPIServer_1_0_2 implements En {
assertTrue(result.get());
});
} catch (Exception ex) {
fail(ex.toString());
fail(getDefaultErrorMessage(ex));
}
});
@ -674,7 +659,7 @@ public class WebAPIServer_1_0_2 implements En {
}
});
} catch (Exception ex) {
fail(ex.toString());
fail(getDefaultErrorMessage(ex));
}
});
@ -697,11 +682,11 @@ public class WebAPIServer_1_0_2 implements En {
fieldValue.set(TestUtils.getDatePart(datePart.get(), item.get(fieldName)));
assertTrue(TestUtils.compare(fieldValue.get(), operator.get(), assertedValue.get()));
} catch (Exception ex) {
fail(ex.toString());
fail(getDefaultErrorMessage(ex));
}
});
} catch (Exception ex) {
fail(ex.toString());
fail(getDefaultErrorMessage(ex));
}
});
@ -726,14 +711,14 @@ public class WebAPIServer_1_0_2 implements En {
fieldValue.set(TestUtils.getTimestampPart(datePart.get(), item.get(fieldName).toString()));
assertTrue(TestUtils.compare(fieldValue.get(), operator.get(), assertedValue.get()));
} catch (Exception ex) {
fail(ex.toString());
fail(getDefaultErrorMessage(ex));
}
});
} catch (Exception ex) {
fail(ex.toString());
fail(getDefaultErrorMessage(ex));
}
} catch (Exception ex) {
fail(ex.toString());
fail(getDefaultErrorMessage(ex));
}
});
@ -750,7 +735,7 @@ public class WebAPIServer_1_0_2 implements En {
assertTrue(TestUtils.compare(item.get(fieldName).toString(), operator.get(), assertedValue.get()));
});
} catch (Exception ex) {
fail(ex.toString());
fail(getDefaultErrorMessage(ex));
}
});
@ -775,7 +760,7 @@ public class WebAPIServer_1_0_2 implements En {
LOG.info("Found EntityContainer for the given resource: '" + resourceName + "'");
} catch (Exception ex) {
fail(ex.toString());
fail(getDefaultErrorMessage(ex));
}
});
@ -796,7 +781,7 @@ public class WebAPIServer_1_0_2 implements En {
}
});
} catch (Exception ex) {
fail(ex.toString());
fail(getDefaultErrorMessage(ex));
}
});
@ -813,7 +798,7 @@ public class WebAPIServer_1_0_2 implements En {
getTestContainer().setResponseCode(cex.getStatusLine().getStatusCode());
fail(cex.toString());
} catch (Exception ex) {
fail(ex.toString());
fail(getDefaultErrorMessage(ex));
}
});
@ -830,8 +815,10 @@ public class WebAPIServer_1_0_2 implements En {
} catch (ODataClientErrorException cex) {
getTestContainer().setResponseCode(cex.getStatusLine().getStatusCode());
fail(cex.toString());
} catch (IllegalArgumentException aex) {
fail(getDefaultErrorMessage(aex.toString()));
} catch (Exception ex) {
fail(ex.toString());
fail("ERROR: "+ ex.toString());
}
});
@ -850,7 +837,7 @@ public class WebAPIServer_1_0_2 implements En {
getTestContainer().setResponseCode(cex.getStatusLine().getStatusCode());
fail(cex.toString());
} catch (Exception ex) {
fail(ex.toString());
fail(getDefaultErrorMessage(ex));
}
});
@ -928,7 +915,7 @@ public class WebAPIServer_1_0_2 implements En {
* resource of the expanded type
*/
And("^the expanded data were found in the related resource$", () -> {
//TODO: this depends on either finding the appropriate navigation property for a given relationship, or having the Expanded resource type name
LOG.info("TODO: this depends on either finding the appropriate navigation property for a given relationship, or having the Expanded resource type name.");
});
@ -993,7 +980,7 @@ public class WebAPIServer_1_0_2 implements En {
getTestContainer().setODataClientErrorException(cex);
getTestContainer().setResponseCode(cex.getStatusLine().getStatusCode());
} catch (Exception ex) {
fail(ex.toString());
fail(getDefaultErrorMessage(ex));
}
});

View File

@ -273,13 +273,16 @@ public class App {
* See Commander#validateMetadata for more info.
*/
LOG.info("Checking Metadata for validity...");
if (commander.validateMetadata(inputFilename)) {
LOG.info("Valid Metadata!");
return true;
} else {
LOG.error("Invalid Metadata!");
return false;
try {
if (commander.validateMetadata(inputFilename)) {
LOG.info("Valid Metadata!");
return true;
}
} catch (Exception ex) {
LOG.error(ex);
}
LOG.error("Invalid Metadata!");
return false;
}
/**

View File

@ -9,6 +9,7 @@ import org.apache.logging.log4j.Logger;
import org.apache.olingo.client.api.ODataClient;
import org.apache.olingo.client.api.communication.ODataClientErrorException;
import org.apache.olingo.client.api.communication.request.retrieve.EdmMetadataRequest;
import org.apache.olingo.client.api.communication.request.retrieve.ODataRawRequest;
import org.apache.olingo.client.api.communication.request.retrieve.XMLMetadataRequest;
import org.apache.olingo.client.api.communication.response.ODataRawResponse;
import org.apache.olingo.client.api.communication.response.ODataRetrieveResponse;
@ -35,6 +36,7 @@ import javax.xml.validation.SchemaFactory;
import java.io.*;
import java.net.URI;
import java.net.URL;
import java.nio.charset.StandardCharsets;
import java.util.concurrent.atomic.AtomicReference;
import java.util.function.Function;
@ -43,7 +45,8 @@ import java.util.function.Function;
* the ones the Client programmer is expected to use.
*/
public class Commander {
//TODO move to utils class
private static final Logger LOG = LogManager.getLogger(Commander.class);
public static final int OK = 0;
public static final int NOT_OK = 1;
public static final String AMPERSAND = "&"; //TODO: find the corresponding query params constant for this
@ -55,8 +58,8 @@ public class Commander {
public static final String REPORT_DIVIDER_SMALL = "===========================";
public static final String RESOSCRIPT_EXTENSION = ".resoscript";
public static final String EDMX_EXTENSION = ".xml";
private static final Logger LOG = LogManager.getLogger(Commander.class);
private static final String EDM_4_0_3_XSD = "edm.4.0.3.xsd", EDMX_4_0_3_XSD = "edmx.4.0.3.xsd";
private static final String EDM_4_0_3_XSD = "edm.4.0.errata03.xsd", EDMX_4_0_3_XSD = "edmx.4.0.errata03.xsd";
private static String bearerToken;
private static String clientId;
@ -76,16 +79,6 @@ public class Commander {
//private constructor, should not be used. Use Builder instead.
}
/**
* Uses an XML validator to validate that the given string contains valid XML.
*
* @param xmlString the string containing the XML to validate.
* @return true if the given xmlString is valid and false otherwise.
*/
public static boolean validateXML(String xmlString) {
return validateXML(new ByteArrayInputStream(xmlString.getBytes()));
}
/**
* Validates XML for the given xmlMetadata item
*
@ -98,33 +91,32 @@ public class Commander {
}
/**
* Uses an XML validator to validate that the given inputStream contains valid XML.
* Uses an XML validator to validate that the given string contains valid XML.
*
* @param inputStream the input stream to check.
* @return true if the given inputStream has valid XML, false otherwise.
* @param xmlString the string containing the XML to validate.
* @return true if the given xmlString is valid and false otherwise.
*/
public static boolean validateXML(InputStream inputStream) {
public static boolean validateXML(final String xmlString) {
try {
SAXParserFactory factory = SAXParserFactory.newInstance();
factory.setValidating(false); //turn off expectation of having DTD in DOCTYPE tag
factory.setNamespaceAware(true);
factory.setSchema(SchemaFactory.newInstance(XMLConstants.W3C_XML_SCHEMA_NS_URI).newSchema(new StreamSource[]{
new StreamSource(Thread.currentThread().getContextClassLoader().getResourceAsStream(EDM_4_0_3_XSD)),
new StreamSource(Thread.currentThread().getContextClassLoader().getResourceAsStream(EDMX_4_0_3_XSD))
new StreamSource(Thread.currentThread().getContextClassLoader().getResourceAsStream(EDM_4_0_3_XSD)),
new StreamSource(Thread.currentThread().getContextClassLoader().getResourceAsStream(EDMX_4_0_3_XSD))
}));
SAXParser parser = factory.newSAXParser();
XMLReader reader = parser.getXMLReader();
reader.setErrorHandler(new SimpleErrorHandler());
InputSource inputSource = new InputSource();
inputSource.setByteStream(inputStream);
try {
reader.parse(inputSource);
return true;
} catch (SAXException saxEx) {
InputSource inputSource = new InputSource(new ByteArrayInputStream(xmlString.getBytes(StandardCharsets.UTF_8)));
reader.parse(inputSource);
return true;
} catch (SAXException saxEx) {
if (saxEx.getMessage() != null) {
LOG.error(saxEx);
return false;
}
} catch (Exception ex) {
LOG.error(ex);
@ -267,18 +259,7 @@ public class Commander {
.append(edmEnumType.getUnderlyingType().getFullQualifiedName().getFullQualifiedNameAsString())
.append(")");
edmEnumType.getMemberNames().forEach(n -> {
reportBuilder
.append("\n\tName: ").append(n);
if (edmEnumType.getMember(n).getAnnotations().size() > 0) {
reportBuilder
.append("\n\tAnnotations: ")
.append(edmEnumType.getMember(n).getAnnotations().toString())
.append("\n\n");
}
});
edmEnumType.getMemberNames().forEach(n -> reportBuilder.append("\n\tName: ").append(n));
});
schema.getComplexTypes().forEach(a ->
@ -450,9 +431,21 @@ public class Commander {
*/
public boolean validateMetadata(InputStream inputStream) {
try {
// deserialize metadata from given file
XMLMetadata metadata = client.getDeserializer(ContentType.APPLICATION_XML).toMetadata(inputStream);
return validateMetadata(metadata);
String xmlString = TestUtils.convertInputStreamToString(inputStream);
if (xmlString == null) return false;
//require the XML Document to be valid XML before trying to validate it with the OData validator
if (validateXML(xmlString)) {
// deserialize metadata from given file
XMLMetadata metadata = client.getDeserializer(ContentType.APPLICATION_XML).toMetadata(new ByteArrayInputStream(xmlString.getBytes()));
if (metadata != null) {
return validateMetadata(metadata);
} else {
LOG.error("ERROR: no valid metadata was found!");
return false;
}
}
} catch (Exception ex) {
LOG.error("ERROR in validateMetadata! " + ex.toString());
}
@ -467,10 +460,9 @@ public class Commander {
*/
public boolean validateMetadata(String pathToEdmx) {
try {
// deserialize metadata from given file
return validateMetadata(new FileInputStream(pathToEdmx));
} catch (Exception ex) {
LOG.error("Error occurred while validating metadata.\nPath was:" + pathToEdmx);
LOG.error("ERROR: could not validate metadata.\nPath was:" + pathToEdmx);
LOG.error(ex.getMessage());
}
return false;
@ -537,6 +529,25 @@ public class Commander {
return responseCode;
}
/**
* Executes a raw OData request in the current commander instance without trying to intepret the results
* @param requestUri the URI to make the request to
* @return a string containing the serialized response, or null
*/
public String executeRawRequest(String requestUri) {
String data = null;
if (requestUri != null) {
try {
ODataRawRequest request = getClient().getRetrieveRequestFactory().getRawRequest(URI.create(requestUri));
ODataRawResponse response = request.execute();
data = TestUtils.convertInputStreamToString(response.getRawResponse());
} catch (Exception ex) {
LOG.error(ex);
}
}
return data;
}
/**
* Gets a ClientEntitySet for the given uri string.
*

View File

@ -22,15 +22,17 @@ import org.reso.models.Parameters;
import org.reso.models.Request;
import org.reso.models.Settings;
import java.io.ByteArrayInputStream;
import java.net.URI;
import java.nio.charset.StandardCharsets;
import java.util.*;
import java.util.concurrent.atomic.AtomicReference;
import static org.junit.Assert.assertNotNull;
import static org.junit.Assert.fail;
import static org.junit.Assert.*;
import static org.reso.commander.Commander.AMPERSAND;
import static org.reso.commander.Commander.EQUALS;
import static org.reso.commander.TestUtils.HEADER_ODATA_VERSION;
import static org.reso.common.ErrorMsg.getDefaultErrorMessage;
/**
* Encapsulates Commander Requests and Responses during runtime
@ -44,6 +46,25 @@ public final class WebApiTestContainer implements TestContainer {
public static final String DOLLAR_SIGN = "$";
public static final String PRETTY_FIELD_SEPARATOR = FIELD_SEPARATOR + SINGLE_SPACE;
public Map<String, CsdlProperty> getFieldMap() {
if (fieldMap.get() == null) {
fieldMap.set(new HashMap<>());
LOG.info("Building Field Map...this may take a moment depending on size of metadata and connection speed.");
//build a map of all of the discovered fields on the server for the given resource by field name
//this can also be used to look up type information
TestUtils.findEntityTypesForEntityTypeName(getEdm(), getXMLMetadata(), getSettings().getParameters().getValue(Parameters.WELL_KNOWN.RESOURCE_NAME))
.forEach(csdlProperty -> fieldMap.get().put(csdlProperty.getName(), csdlProperty));
assertTrue("ERROR: No field were found in the server's metadata!", fieldMap.get().size() > 0);
LOG.info("Metadata Field Map created!");
}
return fieldMap.get();
}
public String getXMLResponseData() {
return xmlResponseData.get();
}
public static final class ODATA_QUERY_PARAMS {
private static String format = DOLLAR_SIGN + "%s";
@ -72,7 +93,8 @@ public final class WebApiTestContainer implements TestContainer {
private AtomicReference<String> redirectUri = new AtomicReference<>();
private AtomicReference<String> scope = new AtomicReference<>();
private AtomicReference<String> pathToRESOScript = new AtomicReference<>();
private AtomicReference<Map<String, CsdlProperty>> fieldMap = new AtomicReference<>(new HashMap<>());
private AtomicReference<Map<String, CsdlProperty>> fieldMap = new AtomicReference<>();
private AtomicReference<String> xmlResponseData = new AtomicReference<>();
// request instance variables - these get reset with every request
@ -143,11 +165,6 @@ public final class WebApiTestContainer implements TestContainer {
.useEdmEnabledClient(shouldUseEdmClient())
.build());
}
//build a map of all of the discovered fields on the server for the given resource by field name
//this can also be used to look up type information
TestUtils.findEntityTypesForEntityTypeName(getEdm(), getXMLMetadata(), getSettings().getParameters().getValue(Parameters.WELL_KNOWN.RESOURCE_NAME))
.forEach(csdlProperty -> fieldMap.get().put(csdlProperty.getName(), csdlProperty));
}
/**
@ -205,7 +222,7 @@ public final class WebApiTestContainer implements TestContainer {
* @return the metadata for the given field
*/
public CsdlProperty getCsdlForFieldName(String fieldName) {
return fieldMap.get().get(fieldName);
return getFieldMap().get(fieldName);
}
/**
@ -214,7 +231,7 @@ public final class WebApiTestContainer implements TestContainer {
* @return gets the local collection of Csdl Properties
*/
public Collection<CsdlProperty> getCsdlProperties() {
return fieldMap.get().values();
return getFieldMap().values();
}
public Collection<String> getSelectList() {
@ -255,7 +272,7 @@ public final class WebApiTestContainer implements TestContainer {
* Gets server metadata in Edm format.
*
* @return
* @implNote the data in this item are cached in the commander once fetched
* @implNote the data in this item are cached in the test container once fetched
*/
public Edm getEdm() {
if (edm.get() == null) {
@ -270,15 +287,38 @@ public final class WebApiTestContainer implements TestContainer {
/**
* Gets server metadata in XMLMetadata format.
*
* Note: this method takes a slightly different approach than getting XML Metadata did previously in that
* rather than fetching the metadata directly from the server using the Olingo getXmlMetadata method,
* we make a raw request instead so that we can capture the response string for XML validation, and
* we deserialize the XML Metadata object from the response string.
*
* @return XMLMetadata representation of the server metadata.
* @implNote the data in this item are cached in the commander once fetched
* @implNote the data in this item are cached in the test container once fetched
*/
public XMLMetadata getXMLMetadata() {
if (xmlMetadata.get() == null) {
ODataRetrieveResponse<XMLMetadata> response = getCommander().prepareXMLMetadataRequest().execute();
responseCode.set(response.getStatusCode());
setServerODataHeaderVersion(TestUtils.getHeaderData(HEADER_ODATA_VERSION, response));
xmlMetadata.set(response.getBody());
try {
String requestUri = Settings.resolveParameters(getSettings().getRequest(Request.WELL_KNOWN.METADATA_ENDPOINT), getSettings()).getUrl();
assertNotNull(getDefaultErrorMessage("Metadata request URI was null! Please check your RESOScript."), requestUri);
ODataRawRequest request = getCommander().getClient().getRetrieveRequestFactory().getRawRequest(URI.create(requestUri));
request.setFormat(ContentType.JSON.toContentTypeString());
ODataRawResponse response = request.execute();
xmlResponseData.set(TestUtils.convertInputStreamToString(response.getRawResponse()));
//deserialize response into XML Metadata - will throw an exception if metadata are in valid
XMLMetadata metadata = getCommander().getClient().getDeserializer(ContentType.APPLICATION_XML)
.toMetadata(new ByteArrayInputStream(xmlResponseData.get().getBytes(StandardCharsets.UTF_8)));
responseCode.set(response.getStatusCode());
setServerODataHeaderVersion(TestUtils.getHeaderData(HEADER_ODATA_VERSION, response));
xmlMetadata.set(metadata);
} catch (Exception ex) {
getDefaultErrorMessage(ex);
}
}
return xmlMetadata.get();
}

View File

@ -0,0 +1,36 @@
package org.reso.common;
import static org.reso.commander.certfication.containers.WebApiTestContainer.EMPTY_STRING;
public final class ErrorMsg {
private static final String ERROR_MESSAGE_TEMPLATE = "ERROR: %s";
private static final String ASSERTED_RESPONSE_CODE_TEMPLATE = "Asserted response code (%d) does not match the one returned from the server (%d)!";
/**
* Formats the given items with the default error message
* @param msgs the list of messages to display
* @return a string containing the default error message for display
*/
public static String getDefaultErrorMessage(final String... msgs) {
return String.format(ERROR_MESSAGE_TEMPLATE, String.join(EMPTY_STRING, msgs));
}
/**
* Formats error message using the default template
* @param ex the exception whose toString() method should be called
* @return formatted error message using the default format
*/
public static String getDefaultErrorMessage(final Exception ex) {
return String.format(ex.toString());
}
/**
* Specialized Assert code formatter
* @param assertedResponseCode the response code that was asserted
* @param serverResponseCode the server response code that was returned
* @return the formatted error message for this case
*/
public static String getAssertResponseCodeErrorMessage(final Integer assertedResponseCode, final Integer serverResponseCode) {
return String.format(ASSERTED_RESPONSE_CODE_TEMPLATE, assertedResponseCode, serverResponseCode);
}
}

View File

@ -237,4 +237,9 @@ public class Request {
static final String URL = "Url";
static final String REQUEST_ID = "RequestId";
}
public static final class WELL_KNOWN {
public static final String
METADATA_ENDPOINT = "REQ-WA103-END3";
}
}