rspec-hive 0.4.2 → 0.6.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.gitignore +1 -0
- data/.rubocop.yml +39 -5
- data/.rubocop_todo.yml +40 -0
- data/.ruby-version +1 -1
- data/.travis.yml +4 -3
- data/Gemfile +18 -0
- data/Guardfile +10 -6
- data/README.md +15 -0
- data/Rakefile +4 -2
- data/docker/Dockerfile +38 -47
- data/docker/hive-site.xml +28 -0
- data/examples/lib/query.rb +2 -0
- data/examples/rspec-hive.yml.example +7 -1
- data/examples/spec/query_spec.rb +2 -0
- data/examples/spec/spec_helper.rb +2 -0
- data/lib/rspec/hive.rb +2 -0
- data/lib/rspec/hive/configuration.rb +14 -33
- data/lib/rspec/hive/connection_delegator.rb +19 -13
- data/lib/rspec/hive/connector.rb +3 -2
- data/lib/rspec/hive/db_name.rb +2 -0
- data/lib/rspec/hive/exponential_backoff.rb +2 -0
- data/lib/rspec/hive/matchers.rb +2 -0
- data/lib/rspec/hive/query_builder.rb +2 -0
- data/lib/rspec/hive/query_builder/null_strategy.rb +2 -0
- data/lib/rspec/hive/query_builder/row_transformer.rb +4 -2
- data/lib/rspec/hive/query_builder/type_faker.rb +2 -0
- data/lib/rspec/hive/query_builder/value_by_type_strategy.rb +2 -0
- data/lib/rspec/hive/query_builder_helper.rb +2 -0
- data/lib/rspec/hive/railtie.rb +2 -0
- data/lib/rspec/hive/rake_tasks/docker.rake +27 -14
- data/lib/rspec/hive/version.rb +3 -1
- data/lib/rspec/hive/with_hive_connection.rb +2 -0
- data/rspec-hive.gemspec +7 -16
- data/spec/lib/rspec/hive/configuration_spec.rb +29 -33
- data/spec/lib/rspec/hive/connection_delegator_spec.rb +58 -138
- data/spec/lib/rspec/hive/connector_spec.rb +33 -38
- data/spec/lib/rspec/hive/db_name_spec.rb +4 -2
- data/spec/lib/rspec/hive/matchers_spec.rb +2 -0
- data/spec/lib/rspec/hive/query_builder/row_transformer_spec.rb +6 -4
- data/spec/lib/rspec/hive/query_builder_helper_spec.rb +8 -6
- data/spec/lib/rspec/hive/query_builder_spec.rb +15 -17
- data/spec/lib/rspec/hive_spec.rb +15 -22
- metadata +13 -154
- data/.rubocop_u2i.yml +0 -63
- data/spec/.rubocop.yml +0 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 9242dae1f3ad9750670856055d1b4674e69225d8
|
4
|
+
data.tar.gz: a04e81680d2a346cded0bf3f827695037531b010
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: bcec72034eb383894133d8fb5dc147e57ea6a3e799982ac4cae9ad55f84dae0b31bcf16f0ed48c5e6194f31a9d72273e9147b0028a84155cb77758386389559e
|
7
|
+
data.tar.gz: 463964b574467f5e8e33c8eaf6c35318a89e411c8879868a61259e7e7bcbcf9e4efce2cdd0d53a5071d367450b59deed2105907b9d26d6d4297e3c54b35e0483
|
data/.gitignore
CHANGED
data/.rubocop.yml
CHANGED
@@ -1,10 +1,12 @@
|
|
1
|
-
|
1
|
+
require: rubocop-rspec
|
2
|
+
|
3
|
+
inherit_from: .rubocop_todo.yml
|
2
4
|
|
3
5
|
Rails:
|
4
6
|
Enabled: false
|
5
7
|
|
6
8
|
AllCops:
|
7
|
-
TargetRubyVersion: 2.
|
9
|
+
TargetRubyVersion: 2.3
|
8
10
|
Include:
|
9
11
|
- '**/Rakefile'
|
10
12
|
Exclude:
|
@@ -15,9 +17,41 @@ AllCops:
|
|
15
17
|
Metrics/LineLength:
|
16
18
|
Max: 120
|
17
19
|
Enabled: true
|
18
|
-
Exclude:
|
19
|
-
- spec/**/*
|
20
|
-
- examples/spec/**/*
|
21
20
|
|
22
21
|
Style/SignalException:
|
23
22
|
EnforcedStyle: only_raise
|
23
|
+
|
24
|
+
Naming/FileName:
|
25
|
+
Exclude:
|
26
|
+
- Gemfile
|
27
|
+
- Guardfile
|
28
|
+
- rspec-hive.gemspec
|
29
|
+
|
30
|
+
Metrics/BlockLength:
|
31
|
+
ExcludedMethods: ['describe', 'context']
|
32
|
+
|
33
|
+
Layout/MultilineOperationIndentation:
|
34
|
+
EnforcedStyle: indented
|
35
|
+
|
36
|
+
Style/Documentation:
|
37
|
+
Enabled: false
|
38
|
+
|
39
|
+
Layout/SpaceInsideHashLiteralBraces:
|
40
|
+
EnforcedStyle: no_space
|
41
|
+
EnforcedStyleForEmptyBraces: no_space
|
42
|
+
|
43
|
+
Layout/DotPosition:
|
44
|
+
EnforcedStyle: trailing
|
45
|
+
Enabled: true
|
46
|
+
|
47
|
+
Metrics/MethodLength:
|
48
|
+
CountComments: false # count full line comments?
|
49
|
+
Max: 30
|
50
|
+
|
51
|
+
RSpec/DescribeClass:
|
52
|
+
Exclude:
|
53
|
+
- spec/lib/rspec/hive/matchers_spec.rb
|
54
|
+
|
55
|
+
Style/Encoding:
|
56
|
+
Exclude:
|
57
|
+
- 'rspec-hive.gemspec'
|
data/.rubocop_todo.yml
ADDED
@@ -0,0 +1,40 @@
|
|
1
|
+
# This configuration was generated by
|
2
|
+
# `rubocop --auto-gen-config`
|
3
|
+
# on 2017-10-18 17:06:59 +0200 using RuboCop version 0.50.0.
|
4
|
+
# The point is for the user to remove these configuration records
|
5
|
+
# one by one as the offenses are removed from the code base.
|
6
|
+
# Note that changes in the inspected code, or installation of new
|
7
|
+
# versions of RuboCop, may require this file to be generated again.
|
8
|
+
|
9
|
+
# Offense count: 6
|
10
|
+
# Configuration parameters: CountComments, ExcludedMethods.
|
11
|
+
Metrics/BlockLength:
|
12
|
+
Max: 106
|
13
|
+
|
14
|
+
# Offense count: 44
|
15
|
+
RSpec/ExpectInHook:
|
16
|
+
Exclude:
|
17
|
+
- 'spec/lib/rspec/hive/connection_delegator_spec.rb'
|
18
|
+
- 'spec/lib/rspec/hive/connector_spec.rb'
|
19
|
+
- 'spec/lib/rspec/hive/query_builder_spec.rb'
|
20
|
+
|
21
|
+
# Offense count: 46
|
22
|
+
# Configuration parameters: SupportedStyles.
|
23
|
+
# SupportedStyles: have_received, receive
|
24
|
+
RSpec/MessageSpies:
|
25
|
+
EnforcedStyle: receive
|
26
|
+
|
27
|
+
# Offense count: 36
|
28
|
+
# Configuration parameters: Max.
|
29
|
+
RSpec/NestedGroups:
|
30
|
+
Exclude:
|
31
|
+
- 'spec/lib/rspec/hive/matchers_spec.rb'
|
32
|
+
- 'spec/lib/rspec/hive/query_builder_spec.rb'
|
33
|
+
|
34
|
+
# Offense count: 11
|
35
|
+
# Configuration parameters: IgnoreSymbolicNames.
|
36
|
+
RSpec/VerifiedDoubles:
|
37
|
+
Exclude:
|
38
|
+
- 'spec/lib/rspec/hive/connection_delegator_spec.rb'
|
39
|
+
- 'spec/lib/rspec/hive/connector_spec.rb'
|
40
|
+
- 'spec/lib/rspec/hive/query_builder_helper_spec.rb'
|
data/.ruby-version
CHANGED
@@ -1 +1 @@
|
|
1
|
-
ruby-2.
|
1
|
+
ruby-2.3.3
|
data/.travis.yml
CHANGED
@@ -4,9 +4,8 @@ services:
|
|
4
4
|
- docker
|
5
5
|
language: ruby
|
6
6
|
rvm:
|
7
|
-
- 2.
|
8
|
-
- 2.
|
9
|
-
- 2.3.0
|
7
|
+
- 2.3.3
|
8
|
+
- 2.4.1
|
10
9
|
env: CONFIG_FILE_NAME=rspec-hive.yml PORT=10000 CONFIG_FILE=rspec-hive.yml
|
11
10
|
|
12
11
|
before_script:
|
@@ -17,3 +16,5 @@ script:
|
|
17
16
|
- bundle exec rake spec
|
18
17
|
- bundle exec rake rubocop
|
19
18
|
- bundle exec rake hive_spec
|
19
|
+
|
20
|
+
bundler_args: --without development
|
data/Gemfile
CHANGED
@@ -1,3 +1,21 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
1
3
|
source 'https://rubygems.org'
|
2
4
|
|
3
5
|
gemspec
|
6
|
+
|
7
|
+
group :test do
|
8
|
+
gem 'bundler', '~> 1.15'
|
9
|
+
gem 'codeclimate-test-reporter', '~> 0.4'
|
10
|
+
gem 'rspec-its', '~> 1.2'
|
11
|
+
gem 'rubocop', '~> 0.50'
|
12
|
+
gem 'rubocop-rspec', '~> 1.18'
|
13
|
+
end
|
14
|
+
|
15
|
+
group :development do
|
16
|
+
gem 'guard'
|
17
|
+
gem 'guard-rspec'
|
18
|
+
gem 'guard-rubocop'
|
19
|
+
gem 'pry'
|
20
|
+
gem 'pry-byebug'
|
21
|
+
end
|
data/Guardfile
CHANGED
@@ -1,3 +1,5 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
1
3
|
# A sample Guardfile
|
2
4
|
# More info at https://github.com/guard/guard#readme
|
3
5
|
|
@@ -13,14 +15,16 @@ group :red_green_refactor, halt_on_fail: true do
|
|
13
15
|
watch('spec/spec_helper.rb') { 'spec' }
|
14
16
|
end
|
15
17
|
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
18
|
+
if system(detect_docker)
|
19
|
+
guard :rspec, cmd: 'bundle exec rspec', spec_paths: ['examples/spec'] do
|
20
|
+
watch(%r{^examples/spec/.+_spec\.rb$})
|
21
|
+
watch(%r{^examples/lib/(.+)\.rb$}) { |m| "examples/spec/#{m[1]}_spec.rb" }
|
22
|
+
watch('examples/spec/spec_helper.rb') { 'examples/spec' }
|
23
|
+
end
|
24
|
+
end
|
21
25
|
|
22
26
|
guard :rubocop, all_on_start: false do
|
23
|
-
watch(
|
27
|
+
watch(/.+\.rb$/)
|
24
28
|
watch(%r{(?:.+/)?\.rubocop\.yml$}) { |m| File.dirname(m[0]) }
|
25
29
|
end
|
26
30
|
end
|
data/README.md
CHANGED
@@ -47,6 +47,8 @@ You can specify following arguments:
|
|
47
47
|
* CONFIG_FILE_DIR - directory where to put generated config file
|
48
48
|
* CONFIG_FILE_NAME - name of the config file that will be generated
|
49
49
|
|
50
|
+
Watch out: in some cases Rspec hive may look for config files in e.g. you're current/root directory, not in config/ folder. Make sure you've got correct config in the directory used by the gem.
|
51
|
+
|
50
52
|
#### Installing Docker
|
51
53
|
Detailed instruction may be found on https://docs.docker.com/engine/installation.
|
52
54
|
|
@@ -112,10 +114,23 @@ Where we invoke:
|
|
112
114
|
|
113
115
|
RSpec::Hive.configure(File.join(__dir__, '/config.yml'))
|
114
116
|
|
117
|
+
### Loading udfs
|
118
|
+
|
119
|
+
`bundle exec rake "spec:hive:docker:load_udfs[path_to_udf_on_s3]"`
|
120
|
+
|
121
|
+
By default udfs will be loaded to `docker_shared_directory_path`.
|
122
|
+
|
123
|
+
|
115
124
|
## Note
|
116
125
|
|
117
126
|
Please remember docker does not remove containers automatically, use `docker ps -a` to list all unused containers.
|
118
127
|
|
128
|
+
## Changelog
|
129
|
+
|
130
|
+
0.5.0:
|
131
|
+
> Updated dockerfile to build container with hive 2.1.1 on Hadoop 2.7.3.
|
132
|
+
> Moved hive config to config file, default hive config is no longer provided, except for default config file generated using rake task.
|
133
|
+
|
119
134
|
## Contributing
|
120
135
|
|
121
136
|
1. Fork it ( https://github.com/[my-github-username]/rspec-hive/fork )
|
data/Rakefile
CHANGED
@@ -1,3 +1,5 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
1
3
|
require 'bundler/gem_tasks'
|
2
4
|
load 'lib/rspec/hive/rake_tasks/docker.rake'
|
3
5
|
|
@@ -26,7 +28,7 @@ detect_docker = <<-BASH
|
|
26
28
|
BASH
|
27
29
|
|
28
30
|
if system(detect_docker)
|
29
|
-
task default: [
|
31
|
+
task default: %i[spec hive_spec rubocop]
|
30
32
|
else
|
31
|
-
task default: [
|
33
|
+
task default: %i[spec rubocop]
|
32
34
|
end
|
data/docker/Dockerfile
CHANGED
@@ -1,47 +1,38 @@
|
|
1
|
-
FROM ubuntu:
|
2
|
-
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
RUN
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
RUN tar -xzf $HADOOP_BIN/hadoop.tar.gz --strip-components=1 -C $HADOOP_HOME
|
40
|
-
RUN tar -xzf $HIVE_BIN/hive.tar.gz --strip-components=1 -C $HIVE_HOME
|
41
|
-
|
42
|
-
CMD $HIVE_HOME/bin/hive \
|
43
|
-
--service hiveserver2 \
|
44
|
-
--hiveconf hive.server2.enable.doAs=false \
|
45
|
-
--hiveconf hive.server2.thrift.port=10000 \
|
46
|
-
--hiveconf hive.root.logger=INFO,console \
|
47
|
-
--hiveconf hive.metastore.warehouse.dir=$WAREHOUSE
|
1
|
+
FROM ubuntu:16.04
|
2
|
+
|
3
|
+
ENV DEBIAN_FRONTEND noninteractive
|
4
|
+
|
5
|
+
RUN apt-get -qq update && \
|
6
|
+
apt-get -qq install -y wget software-properties-common && \
|
7
|
+
add-apt-repository ppa:webupd8team/java && \
|
8
|
+
apt-get -qq update && \
|
9
|
+
(echo oracle-java8-installer shared/accepted-oracle-license-v1-1 select true | /usr/bin/debconf-set-selections) && \
|
10
|
+
apt-get -qq install -y oracle-java8-installer oracle-java8-set-default
|
11
|
+
|
12
|
+
ENV INSTALL_DIR=/opt
|
13
|
+
SHARED_FOLDER=/tmp/spec-tmp-files \
|
14
|
+
TMP_HOME=/tmp/home \
|
15
|
+
WAREHOUSE=/tmp/warehouse \
|
16
|
+
HADOOP_HOME=$INSTALL_DIR/hadoop \
|
17
|
+
HIVE_HOME=$INSTALL_DIR/hive \
|
18
|
+
JAVA_HOME=/usr
|
19
|
+
|
20
|
+
RUN mkdir -p $HADOOP_HOME $HIVE_HOME $SHARED_FOLDER $TMP_HOME $WAREHOUSE
|
21
|
+
|
22
|
+
RUN wget http://www-eu.apache.org/dist/hadoop/common/hadoop-2.7.3/hadoop-2.7.3.tar.gz --quiet -O /tmp/hadoop.tar.gz && \
|
23
|
+
wget http://www-eu.apache.org/dist/hive/hive-2.1.1/apache-hive-2.1.1-bin.tar.gz --quiet -O /tmp/hive.tar.gz && \
|
24
|
+
tar -xzf /tmp/hadoop.tar.gz --strip-components=1 -C $HADOOP_HOME && \
|
25
|
+
tar -xzf /tmp/hive.tar.gz --strip-components=1 -C $HIVE_HOME
|
26
|
+
|
27
|
+
RUN rm -rf $HIVE_HOME/metastore_db/
|
28
|
+
RUN $HIVE_HOME/bin/schematool -initSchema -dbType derby
|
29
|
+
|
30
|
+
ADD ./hive-site.xml $HIVE_HOME/conf/hive-site.xml
|
31
|
+
|
32
|
+
WORKDIR $TMP_HOME
|
33
|
+
ENTRYPOINT $HIVE_HOME/bin/hive \
|
34
|
+
--service hiveserver2 \
|
35
|
+
--hiveconf hive.server2.enable.doAs=false \
|
36
|
+
--hiveconf hive.server2.thrift.port=10000 \
|
37
|
+
--hiveconf hive.root.logger=INFO,console \
|
38
|
+
--hiveconf hive.metastore.warehouse.dir=$WAREHOUSE
|
@@ -0,0 +1,28 @@
|
|
1
|
+
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
2
|
+
<?xml-stylesheet type="text/xsl" href="configuration.xsl"?><!--
|
3
|
+
Licensed to the Apache Software Foundation (ASF) under one or more
|
4
|
+
contributor license agreements. See the NOTICE file distributed with
|
5
|
+
this work for additional information regarding copyright ownership.
|
6
|
+
The ASF licenses this file to You under the Apache License, Version 2.0
|
7
|
+
(the "License"); you may not use this file except in compliance with
|
8
|
+
the License. You may obtain a copy of the License at
|
9
|
+
|
10
|
+
http://www.apache.org/licenses/LICENSE-2.0
|
11
|
+
|
12
|
+
Unless required by applicable law or agreed to in writing, software
|
13
|
+
distributed under the License is distributed on an "AS IS" BASIS,
|
14
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
15
|
+
See the License for the specific language governing permissions and
|
16
|
+
limitations under the License.
|
17
|
+
-->
|
18
|
+
<configuration>
|
19
|
+
<property>
|
20
|
+
<name>hive.resultset.use.unique.column.names</name>
|
21
|
+
<value>false</value>
|
22
|
+
<description>
|
23
|
+
Make column names unique in the result set by qualifying column names with table alias if needed.
|
24
|
+
Table alias will be added to column names for queries of type "select *" or
|
25
|
+
if query explicitly uses table alias "select r1.x..".
|
26
|
+
</description>
|
27
|
+
</property>
|
28
|
+
</configuration>
|
data/examples/lib/query.rb
CHANGED
@@ -3,4 +3,10 @@ hive:
|
|
3
3
|
port: 10000
|
4
4
|
host_shared_directory_path: /Users/Shared/tmp/spec-tmp-files
|
5
5
|
docker_shared_directory_path: /tmp/spec-tmp-files
|
6
|
-
hive_version: 10
|
6
|
+
hive_version: 10
|
7
|
+
hive_options:
|
8
|
+
'hive.exec.dynamic.partition': 'true'
|
9
|
+
'hive.exec.dynamic.partition.mode': 'nonstrict'
|
10
|
+
'hive.exec.max.dynamic.partitions.pernode': '100000'
|
11
|
+
'hive.exec.max.dynamic.partitions': '100000'
|
12
|
+
'mapred.child.java.opts': '-Xmx2048m'
|
data/examples/spec/query_spec.rb
CHANGED
data/lib/rspec/hive.rb
CHANGED
@@ -1,8 +1,13 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
1
3
|
require 'tmpdir'
|
2
4
|
|
3
5
|
module RSpec
|
4
6
|
module Hive
|
5
7
|
class Configuration
|
8
|
+
DEFAULT_VERSION = 10
|
9
|
+
DEFAULT_TIMEOUT = 120
|
10
|
+
|
6
11
|
attr_accessor :host,
|
7
12
|
:port,
|
8
13
|
:host_shared_directory_path,
|
@@ -17,7 +22,7 @@ module RSpec
|
|
17
22
|
load_default_variables
|
18
23
|
else
|
19
24
|
interpolated = ERB.new(File.read(path_to_config_file)).result
|
20
|
-
config = YAML.
|
25
|
+
config = YAML.safe_load(interpolated)['hive']
|
21
26
|
load_variables_from_config(config)
|
22
27
|
end
|
23
28
|
@logger = Logger.new(STDOUT)
|
@@ -26,13 +31,13 @@ module RSpec
|
|
26
31
|
private
|
27
32
|
|
28
33
|
def load_default_variables
|
29
|
-
@host =
|
30
|
-
@port =
|
34
|
+
@host = '127.0.0.1'
|
35
|
+
@port = 10_000
|
31
36
|
@host_shared_directory_path = platform_specific_host_shared_dir_path
|
32
37
|
@docker_shared_directory_path = '/tmp/spec-tmp-files'
|
33
|
-
@hive_version =
|
34
|
-
@connection_timeout =
|
35
|
-
@hive_options =
|
38
|
+
@hive_version = DEFAULT_VERSION
|
39
|
+
@connection_timeout = DEFAULT_TIMEOUT
|
40
|
+
@hive_options = {}
|
36
41
|
end
|
37
42
|
|
38
43
|
def load_variables_from_config(config)
|
@@ -40,13 +45,9 @@ module RSpec
|
|
40
45
|
@port = config['port']
|
41
46
|
@host_shared_directory_path = config['host_shared_directory_path']
|
42
47
|
@docker_shared_directory_path = config['docker_shared_directory_path']
|
43
|
-
@hive_version = (config['hive_version'] ||
|
44
|
-
@connection_timeout = (config['timeout'] ||
|
45
|
-
@hive_options =
|
46
|
-
end
|
47
|
-
|
48
|
-
def merge_config_options(hash, config)
|
49
|
-
hash.merge(config['hive_options'].to_h)
|
48
|
+
@hive_version = (config['hive_version'] || DEFAULT_VERSION).to_i
|
49
|
+
@connection_timeout = (config['timeout'] || DEFAULT_TIMEOUT).to_i
|
50
|
+
@hive_options = config['hive_options'].to_h
|
50
51
|
end
|
51
52
|
|
52
53
|
def mac?
|
@@ -54,10 +55,6 @@ module RSpec
|
|
54
55
|
host_os =~ /darwin|mac os/
|
55
56
|
end
|
56
57
|
|
57
|
-
def platform_specific_host
|
58
|
-
mac? ? '192.168.99.100' : '127.0.0.1'
|
59
|
-
end
|
60
|
-
|
61
58
|
def platform_specific_host_shared_dir_path
|
62
59
|
if mac?
|
63
60
|
File.join(Dir.mktmpdir(nil, '/Users/Shared'), 'spec-tmp-files')
|
@@ -65,22 +62,6 @@ module RSpec
|
|
65
62
|
File.join(Dir.mktmpdir, 'spec-tmp-files')
|
66
63
|
end
|
67
64
|
end
|
68
|
-
|
69
|
-
def default_timeout
|
70
|
-
1800
|
71
|
-
end
|
72
|
-
|
73
|
-
def default_version
|
74
|
-
10
|
75
|
-
end
|
76
|
-
|
77
|
-
def default_hive_options
|
78
|
-
{'hive.exec.dynamic.partition' => 'true',
|
79
|
-
'hive.exec.dynamic.partition.mode' => 'nonstrict',
|
80
|
-
'hive.exec.max.dynamic.partitions.pernodexi' => '100000',
|
81
|
-
'hive.exec.max.dynamic.partitions' => '100000',
|
82
|
-
'mapred.child.java.opts' => '-Xmx2048m'}
|
83
|
-
end
|
84
65
|
end
|
85
66
|
end
|
86
67
|
end
|