GitHub user kiszk opened a pull request:
https://github.com/apache/spark/pull/17436
[SPARK-20101][SQL] Use OffHeapColumnVector when
"spark.memory.offHeap.enabled" is set to "true"
## What changes were proposed in this pull request?
This PR enables to use ``OffHeapColumnVector`` when
``spark.memory.offHeap.enable`` is set to ``true``. While ``ColumnVector`` has
two implementations ``OnHeapColumnVector`` and ``OffHeapColumnVector``, only
``OnHeapColumnVector`` is always used.
This PR implements the followings
- Pass ``OFF_HEAP`` to ``ColumnarBatch.allocate()`` when
``spark.memory.offHeap.enable`` is set to ``true``
- Free all of off-heap memory regions by ``OffHeapColumnVector.close()``
- Ensure to call ``OffHeapColumnVector.close()``
## How was this patch tested?
Use existing tests
You can merge this pull request into a Git repository by running:
$ git pull https://github.com/kiszk/spark SPARK-20101
Alternatively you can review and apply these changes as the patch at:
https://github.com/apache/spark/pull/17436.patch
To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:
This closes #17436
----
commit 6cf5a8d98d65a5c354f80dd99f9990f1a8a3ad98
Author: Kazuaki Ishizaki <[email protected]>
Date: 2017-03-26T17:50:55Z
initial commit
commit 099a257675741aa281d15db4b3a0d1f4898632e8
Author: Kazuaki Ishizaki <[email protected]>
Date: 2017-03-26T17:51:51Z
tentatively set true into spark.memory.offHeap.enabled
----
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]