Skip to content

Commit 02be22b

Browse files
committed
Merge branch 'master' into SPARK-29783
2 parents 88418e0 + 29dc59a commit 02be22b

43 files changed

Lines changed: 849 additions & 768 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/workflows/master.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ jobs:
3131
run: |
3232
export MAVEN_OPTS="-Xmx2g -XX:ReservedCodeCacheSize=1g -Dorg.slf4j.simpleLogger.defaultLogLevel=WARN"
3333
export MAVEN_CLI_OPTS="--no-transfer-progress"
34-
./build/mvn $MAVEN_CLI_OPTS -DskipTests -Pyarn -Pmesos -Pkubernetes -Phive -Phive-thriftserver -P${{ matrix.hadoop }} -Phadoop-cloud -Djava.version=${{ matrix.java }} package
34+
./build/mvn $MAVEN_CLI_OPTS -DskipTests -Pyarn -Pmesos -Pkubernetes -Phive -Phive-thriftserver -P${{ matrix.hadoop }} -Phadoop-cloud -Djava.version=${{ matrix.java }} install
3535
3636
3737
lint:

common/unsafe/src/main/java/org/apache/spark/unsafe/types/UTF8String.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -370,7 +370,7 @@ private byte getByte(int i) {
370370
return Platform.getByte(base, offset + i);
371371
}
372372

373-
private boolean matchAt(final UTF8String s, int pos) {
373+
public boolean matchAt(final UTF8String s, int pos) {
374374
if (s.numBytes + pos > numBytes || pos < 0) {
375375
return false;
376376
}

core/src/main/scala/org/apache/spark/TestUtils.scala

Lines changed: 12 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ import java.nio.file.{Files => JavaFiles}
2424
import java.nio.file.attribute.PosixFilePermission.{OWNER_EXECUTE, OWNER_READ, OWNER_WRITE}
2525
import java.security.SecureRandom
2626
import java.security.cert.X509Certificate
27-
import java.util.{Arrays, EnumSet, Properties}
27+
import java.util.{Arrays, EnumSet, Locale, Properties}
2828
import java.util.concurrent.{TimeoutException, TimeUnit}
2929
import java.util.jar.{JarEntry, JarOutputStream, Manifest}
3030
import javax.net.ssl._
@@ -214,12 +214,20 @@ private[spark] object TestUtils {
214214
* Asserts that exception message contains the message. Please note this checks all
215215
* exceptions in the tree.
216216
*/
217-
def assertExceptionMsg(exception: Throwable, msg: String): Unit = {
217+
def assertExceptionMsg(exception: Throwable, msg: String, ignoreCase: Boolean = false): Unit = {
218+
def contain(msg1: String, msg2: String): Boolean = {
219+
if (ignoreCase) {
220+
msg1.toLowerCase(Locale.ROOT).contains(msg2.toLowerCase(Locale.ROOT))
221+
} else {
222+
msg1.contains(msg2)
223+
}
224+
}
225+
218226
var e = exception
219-
var contains = e.getMessage.contains(msg)
227+
var contains = contain(e.getMessage, msg)
220228
while (e.getCause != null && !contains) {
221229
e = e.getCause
222-
contains = e.getMessage.contains(msg)
230+
contains = contain(e.getMessage, msg)
223231
}
224232
assert(contains, s"Exception tree doesn't contain the expected message: $msg")
225233
}

docs/running-on-yarn.md

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -419,6 +419,15 @@ To use a custom metrics.properties for the application master and executors, upd
419419
in YARN ApplicationReports, which can be used for filtering when querying YARN apps.
420420
</td>
421421
</tr>
422+
<tr>
423+
<td><code>spark.yarn.priority</code></td>
424+
<td>(none)</td>
425+
<td>
426+
Application priority for YARN to define pending applications ordering policy, those with higher
427+
integer value have a better opportunity to be activated. Currently, YARN only supports application
428+
priority when using FIFO ordering policy.
429+
</td>
430+
</tr>
422431
<tr>
423432
<td><code>spark.yarn.config.gatewayPath</code></td>
424433
<td>(none)</td>

docs/sql-migration-guide.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -217,6 +217,8 @@ license: |
217217
For example `SELECT timestamp 'tomorrow';`.
218218

219219
- Since Spark 3.0, the `size` function returns `NULL` for the `NULL` input. In Spark version 2.4 and earlier, this function gives `-1` for the same input. To restore the behavior before Spark 3.0, you can set `spark.sql.legacy.sizeOfNull` to `true`.
220+
221+
- Since Spark 3.0, when `array` function is called without parameters, it returns an empty array with `NullType` data type. In Spark version 2.4 and earlier, the data type of the result is `StringType`.
220222

221223
- Since Spark 3.0, the interval literal syntax does not allow multiple from-to units anymore. For example, `SELECT INTERVAL '1-1' YEAR TO MONTH '2-2' YEAR TO MONTH'` throws parser exception.
222224

0 commit comments

Comments
 (0)