GitHub user tinkoff-dwh reopened a pull request:
https://github.com/apache/zeppelin/pull/2221
[ZEPPELIN-2216] general solution to precode. refactoring jdbc precode
### What is this PR for?
General solution to execute precode. Refactoring jdbc precode using general
solution. Task contains to subtasks: executeAfterOpen, executeBeforeClose.
executeBeforeClose not done because we need the context so there is a solution
only for executeAfterOpen.
### What type of PR is it?
Feature | Refactoring
### What is the Jira issue?
https://issues.apache.org/jira/browse/ZEPPELIN-2216
### How should this be tested?
1. Add parameter zeppelin.PySparkInterpreter.precode `someVar='text'`
2. Execute
```
%pyspark
print(someVar)
```
### Questions:
* Does the licenses files need update? no
* Is there breaking changes for older versions? no
* Does this needs documentation? no
You can merge this pull request into a Git repository by running:
$ git pull https://github.com/tinkoff-dwh/zeppelin ZEPPELIN-2216
Alternatively you can review and apply these changes as the patch at:
https://github.com/apache/zeppelin/pull/2221.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 #2221
----
commit c0436a248ed67dab38630a5b6d437e723c9557dc
Author: Tinkoff DWH <[email protected]>
Date: 2017-04-04T06:42:54Z
[ZEPPELIN-2216] general solution to precode. refactoring jdbc precode
commit 39777221dc634b1d5e07401f8f9ef0fbbeb7288c
Author: Tinkoff DWH <[email protected]>
Date: 2017-04-24T04:57:45Z
Merge remote-tracking branch 'origin/master' into ZEPPELIN-2216
# Conflicts:
# jdbc/src/main/java/org/apache/zeppelin/jdbc/JDBCInterpreter.java
commit 5a482a0221d32fec2b671e1a0f197a35735a3a12
Author: Tinkoff DWH <[email protected]>
Date: 2017-04-24T06:49:51Z
[ZEPPELIN-2216] fix tests
commit e4cf72f135b130f7d22a16d8876de48b1f19da74
Author: Tinkoff DWH <[email protected]>
Date: 2017-04-24T07:05:45Z
[ZEPPELIN-2216] added tests
commit 1e3f3f717c9838ecb5abac56f252b60201d197b5
Author: Tinkoff DWH <[email protected]>
Date: 2017-04-24T07:18:55Z
[ZEPPELIN-2216] fix path
----
---
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.
---