tuxji commented on a change in pull request #460:
URL: https://github.com/apache/incubator-daffodil/pull/460#discussion_r528987021
##########
File path:
daffodil-propgen/src/main/resources/org/apache/daffodil/xsd/dafext.xsd
##########
@@ -200,20 +194,44 @@
</xs:documentation>
</xs:annotation>
</xs:element>
- <xs:element name="maxBinaryDecimalVirtualPoint" type="xs:int"
default="200" minOccurs="0">
+ <xs:element name="maxBinaryDecimalVirtualPoint" default="200"
minOccurs="0">
<xs:annotation>
<xs:documentation>
The largest allowed value of the dfdl:binaryDecimalVirtualPoint
property.
</xs:documentation>
</xs:annotation>
+ <xs:simpleType>
+ <xs:restriction base="xs:int">
+ <xs:minInclusive value="1" />
+ </xs:restriction>
+ </xs:simpleType>
+ </xs:element>
+ <xs:element name="maxByteArrayOutputStreamBufferSizeInBytes"
default="2097152000" minOccurs="0">
+ <xs:annotation>
+ <xs:documentation>
+ When unparsing, this is the maximum size of the buffer that the
+ ByteArrayOutputStream can grow to before switching to a file
based
+ output stream.
+ </xs:documentation>
+ </xs:annotation>
+ <xs:simpleType>
+ <xs:restriction base="xs:int">
+ <xs:minInclusive value="0" />
+ </xs:restriction>
+ </xs:simpleType>
Review comment:
Noticed this `maxByteArrayOutputStreamBufferSizeInBytes` tunable has
changed from xs:long to xs:int and it can go down to zero.
##########
File path:
daffodil-propgen/src/main/resources/org/apache/daffodil/xsd/dafext.xsd
##########
@@ -401,6 +471,11 @@
frequency of context switching, but increase the memory
footprint.
</xs:documentation>
</xs:annotation>
+ <xs:simpleType>
Review comment:
Yes, that's true. Most of the `xs:int` tunables are oneOrGreater types.
##########
File path:
daffodil-propgen/src/main/resources/org/apache/daffodil/xsd/dafext.xsd
##########
@@ -265,28 +302,48 @@
tunable tunable sets an upper limit for values to prevent
overflow.
</xs:documentation>
</xs:annotation>
+ <xs:simpleType>
+ <xs:restriction base="xs:int">
+ <xs:minInclusive value="1" />
+ </xs:restriction>
+ </xs:simpleType>
</xs:element>
- <xs:element name="maximumRegexMatchLengthInCharacters" type="xs:int"
default="1048576" minOccurs="0">
+ <xs:element name="maximumRegexMatchLengthInCharacters"
default="1048576" minOccurs="0">
<xs:annotation>
<xs:documentation>
Maximum number of characters to match when performing regular
expression
matches on input data.
</xs:documentation>
</xs:annotation>
+ <xs:simpleType>
+ <xs:restriction base="xs:int">
+ <xs:minInclusive value="1" />
+ </xs:restriction>
+ </xs:simpleType>
</xs:element>
- <xs:element name="maximumSimpleElementSizeInCharacters" type="xs:int"
default="1048576" minOccurs="0">
+ <xs:element name="maximumSimpleElementSizeInCharacters"
default="1048576" minOccurs="0">
<xs:annotation>
<xs:documentation>
Maximum number of characters to parse when parsing string data.
</xs:documentation>
</xs:annotation>
+ <xs:simpleType>
+ <xs:restriction base="xs:int">
+ <xs:minInclusive value="1" />
+ </xs:restriction>
+ </xs:simpleType>
</xs:element>
- <xs:element name="minBinaryDecimalVirtualPoint" type="xs:int"
default="-200" minOccurs="0">
+ <xs:element name="minBinaryDecimalVirtualPoint" default="-200"
minOccurs="0">
<xs:annotation>
<xs:documentation>
The smallest allowed value of the dfdl:binaryDecimalVirtualPoint
property.
</xs:documentation>
</xs:annotation>
+ <xs:simpleType>
+ <xs:restriction base="xs:int">
+ <xs:maxInclusive value="-1" />
+ </xs:restriction>
+ </xs:simpleType>
</xs:element>
Review comment:
The `minBinaryDecimalVirtualPoint` tunable has a default value of -200
and a maximum value of -1. Interesting.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]