You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@zeppelin.apache.org by jo...@apache.org on 2018/08/26 04:44:32 UTC
[49/49] zeppelin git commit: [ZEPPELIN-3740] Adopt
`google-java-format` and `fmt-maven-plugin`
[ZEPPELIN-3740] Adopt `google-java-format` and `fmt-maven-plugin`
### What is this PR for?
Avoiding outdated checkstyle error.
To check format
`mvn validate`
To fix non-complying files
`mvn fmt:format`
### What type of PR is it?
[Improvement | Refactoring]
### Todos
* [x] - Adopt `fmt-maven-plugin`
### What is the Jira issue?
* https://issues.apache.org/jira/browse/ZEPPELIN-3740
### How should this be tested?
CI passs
### Screenshots (if appropriate)
### Questions:
* Does the licenses files need update? No
* Is there breaking changes for older versions? No
* Does this needs documentation? Yes for contributors
Author: Jongyoul Lee <jo...@gmail.com>
Closes #3158 from jongyoul/ZEPPELIN-3740 and squashes the following commits:
f06c50e90 [Jongyoul Lee] Adopt `fmt-maven-plugin` for google-java-format Adopt all files
Project: http://git-wip-us.apache.org/repos/asf/zeppelin/repo
Commit: http://git-wip-us.apache.org/repos/asf/zeppelin/commit/55f6c91c
Tree: http://git-wip-us.apache.org/repos/asf/zeppelin/tree/55f6c91c
Diff: http://git-wip-us.apache.org/repos/asf/zeppelin/diff/55f6c91c
Branch: refs/heads/master
Commit: 55f6c91cab2149943fd2390e0a9ca6847ac1f6ce
Parents: f71aca4
Author: Jongyoul Lee <jo...@gmail.com>
Authored: Tue Aug 21 17:45:04 2018 +0900
Committer: Jongyoul Lee <jo...@apache.org>
Committed: Sun Aug 26 13:43:14 2018 +0900
----------------------------------------------------------------------
_tools/checkstyle.xml | 289 -
alluxio/pom.xml | 7 -
.../zeppelin/alluxio/AlluxioInterpreter.java | 217 +-
.../alluxio/AlluxioInterpreterTest.java | 304 +-
angular/pom.xml | 7 -
.../zeppelin/angular/AngularInterpreter.java | 22 +-
beam/pom.xml | 7 -
.../apache/zeppelin/beam/BeamInterpreter.java | 8 +-
bigquery/pom.xml | 7 -
.../zeppelin/bigquery/BigQueryInterpreter.java | 106 +-
.../bigquery/BigQueryInterpreterTest.java | 13 +-
cassandra/pom.xml | 7 -
.../cassandra/CassandraInterpreter.java | 128 +-
.../zeppelin/cassandra/ParsingException.java | 6 +-
.../cassandra/CassandraInterpreterTest.java | 646 +-
.../cassandra/InterpreterLogicTest.java | 232 +-
.../contribution/how_to_contribute_code.md | 4 +
elasticsearch/pom.xml | 7 -
.../elasticsearch/ElasticsearchInterpreter.java | 178 +-
.../elasticsearch/action/ActionException.java | 4 +-
.../elasticsearch/action/ActionResponse.java | 5 +-
.../elasticsearch/action/AggWrapper.java | 13 +-
.../elasticsearch/action/HitWrapper.java | 4 +-
.../client/ElasticsearchClient.java | 4 +-
.../elasticsearch/client/HttpBasedClient.java | 136 +-
.../client/TransportBasedClient.java | 113 +-
.../ElasticsearchInterpreterTest.java | 208 +-
file/pom.xml | 7 -
.../apache/zeppelin/file/FileInterpreter.java | 54 +-
.../org/apache/zeppelin/file/HDFSCommand.java | 58 +-
.../zeppelin/file/HDFSFileInterpreter.java | 118 +-
.../zeppelin/file/HDFSFileInterpreterTest.java | 215 +-
flink/pom.xml | 8 -
.../apache/zeppelin/flink/FlinkInterpreter.java | 25 +-
.../zeppelin/flink/FlinkSQLInterpreter.java | 17 +-
.../zeppelin/flink/FlinkInterpreterTest.java | 147 +-
.../zeppelin/flink/FlinkSQLInterpreterTest.java | 72 +-
geode/pom.xml | 7 -
.../zeppelin/geode/GeodeOqlInterpreter.java | 91 +-
.../zeppelin/geode/GeodeOqlInterpreterTest.java | 69 +-
groovy/pom-groovy-only.xml | 11 -
groovy/pom.xml | 7 -
.../org/apache/zeppelin/groovy/GObject.java | 65 +-
.../zeppelin/groovy/GroovyInterpreter.java | 60 +-
.../zeppelin/groovy/GroovyZeppelinContext.java | 9 +-
hbase/pom.xml | 7 -
.../apache/zeppelin/hbase/HbaseInterpreter.java | 52 +-
.../zeppelin/hbase/HbaseInterpreterTest.java | 25 +-
.../apache/zeppelin/helium/DevInterpreter.java | 27 +-
.../zeppelin/helium/DevZeppelinContext.java | 10 +-
.../helium/ZeppelinApplicationDevServer.java | 67 +-
.../zeppelin/helium/ZeppelinDevServer.java | 61 +-
ignite/pom.xml | 7 -
.../zeppelin/ignite/IgniteInterpreter.java | 83 +-
.../zeppelin/ignite/IgniteInterpreterUtils.java | 5 +-
.../zeppelin/ignite/IgniteSqlInterpreter.java | 27 +-
.../zeppelin/ignite/IgniteInterpreterTest.java | 37 +-
.../ignite/IgniteSqlInterpreterTest.java | 22 +-
.../java/org/apache/zeppelin/ignite/Person.java | 9 +-
java/pom.xml | 7 -
.../apache/zeppelin/java/JavaInterpreter.java | 30 +-
.../zeppelin/java/JavaInterpreterUtils.java | 12 +-
.../org/apache/zeppelin/java/StaticRepl.java | 50 +-
jdbc/pom.xml | 7 -
.../apache/zeppelin/jdbc/JDBCInterpreter.java | 290 +-
.../zeppelin/jdbc/JDBCUserConfigurations.java | 19 +-
.../org/apache/zeppelin/jdbc/SqlCompleter.java | 218 +-
.../jdbc/security/JDBCSecurityImpl.java | 40 +-
.../jdbc/JDBCInterpreterInterpolationTest.java | 72 +-
.../zeppelin/jdbc/JDBCInterpreterTest.java | 223 +-
.../apache/zeppelin/jdbc/SqlCompleterTest.java | 270 +-
kylin/pom.xml | 7 -
.../zeppelin/kylin/KylinErrorResponse.java | 8 +-
.../apache/zeppelin/kylin/KylinInterpreter.java | 94 +-
.../zeppelin/kylin/KylinInterpreterTest.java | 136 +-
lens/pom.xml | 7 -
.../apache/zeppelin/lens/ExecutionDetail.java | 25 +-
.../org/apache/zeppelin/lens/LensBootstrap.java | 13 +-
.../apache/zeppelin/lens/LensInterpreter.java | 174 +-
.../zeppelin/lens/LensJLineShellComponent.java | 90 +-
.../lens/LensSimpleExecutionStrategy.java | 11 +-
.../zeppelin/lens/LensInterpreterTest.java | 48 +-
livy/pom.xml | 8 -
.../zeppelin/livy/APINotFoundException.java | 11 +-
.../zeppelin/livy/BaseLivyInterpreter.java | 392 +-
.../org/apache/zeppelin/livy/LivyException.java | 11 +-
.../zeppelin/livy/LivyPySpark3Interpreter.java | 6 +-
.../livy/LivyPySparkBaseInterpreter.java | 23 +-
.../zeppelin/livy/LivyPySparkInterpreter.java | 7 +-
.../zeppelin/livy/LivySharedInterpreter.java | 20 +-
.../zeppelin/livy/LivySparkInterpreter.java | 31 +-
.../zeppelin/livy/LivySparkRInterpreter.java | 9 +-
.../zeppelin/livy/LivySparkSQLInterpreter.java | 64 +-
.../org/apache/zeppelin/livy/LivyVersion.java | 8 +-
.../zeppelin/livy/SessionDeadException.java | 4 +-
.../zeppelin/livy/SessionNotFoundException.java | 4 +-
.../apache/zeppelin/livy/LivyInterpreterIT.java | 574 +-
.../zeppelin/livy/LivySQLInterpreterTest.java | 93 +-
markdown/pom.xml | 7 -
.../org/apache/zeppelin/markdown/Markdown.java | 24 +-
.../zeppelin/markdown/Markdown4jParser.java | 7 +-
.../zeppelin/markdown/MarkdownParser.java | 4 +-
.../org/apache/zeppelin/markdown/ParamVar.java | 3 +-
.../apache/zeppelin/markdown/PegdownParser.java | 17 +-
.../markdown/PegdownWebSequencelPlugin.java | 61 +-
.../zeppelin/markdown/PegdownYumlPlugin.java | 39 +-
.../zeppelin/markdown/Markdown4jParserTest.java | 6 +-
.../zeppelin/markdown/PegdownParserTest.java | 113 +-
neo4j/pom.xml | 7 -
.../graph/neo4j/Neo4jConnectionManager.java | 51 +-
.../graph/neo4j/Neo4jCypherInterpreter.java | 77 +-
.../graph/neo4j/utils/Neo4jConversionUtils.java | 26 +-
.../graph/neo4j/Neo4jCypherInterpreterTest.java | 125 +-
pig/pom.xml | 7 -
.../apache/zeppelin/pig/BasePigInterpreter.java | 29 +-
.../org/apache/zeppelin/pig/PigInterpreter.java | 30 +-
.../zeppelin/pig/PigQueryInterpreter.java | 26 +-
.../apache/zeppelin/pig/PigScriptListener.java | 37 +-
.../java/org/apache/zeppelin/pig/PigUtils.java | 13 +-
.../zeppelin/pig/PigInterpreterSparkTest.java | 93 +-
.../apache/zeppelin/pig/PigInterpreterTest.java | 86 +-
.../zeppelin/pig/PigInterpreterTezTest.java | 100 +-
.../zeppelin/pig/PigQueryInterpreterTest.java | 72 +-
pom.xml | 62 +-
python/pom.xml | 8 -
.../apache/zeppelin/python/IPythonClient.java | 206 +-
.../zeppelin/python/IPythonInterpreter.java | 145 +-
.../zeppelin/python/PythonCondaInterpreter.java | 85 +-
.../python/PythonDockerInterpreter.java | 59 +-
.../zeppelin/python/PythonInterpreter.java | 85 +-
.../python/PythonInterpreterPandasSql.java | 14 +-
.../org/apache/zeppelin/python/PythonUtils.java | 43 +-
.../zeppelin/python/PythonZeppelinContext.java | 9 +-
.../python/BasePythonInterpreterTest.java | 100 +-
.../zeppelin/python/IPythonInterpreterTest.java | 61 +-
.../python/PythonCondaInterpreterTest.java | 57 +-
.../python/PythonDockerInterpreterTest.java | 27 +-
.../python/PythonInterpreterMatplotlibTest.java | 59 +-
.../python/PythonInterpreterPandasSqlTest.java | 88 +-
.../zeppelin/python/PythonInterpreterTest.java | 27 +-
.../zeppelin/sap/UniverseInterpreter.java | 68 +-
.../zeppelin/sap/universe/UniverseClient.java | 411 +-
.../sap/universe/UniverseCompleter.java | 185 +-
.../sap/universe/UniverseException.java | 6 +-
.../zeppelin/sap/universe/UniverseInfo.java | 7 +-
.../zeppelin/sap/universe/UniverseNodeInfo.java | 7 +-
.../sap/universe/UniverseNodeInfoCompleter.java | 14 +-
.../zeppelin/sap/universe/UniverseQuery.java | 20 +-
.../sap/universe/UniverseQueryPrompt.java | 17 +-
.../zeppelin/sap/universe/UniverseUtil.java | 162 +-
.../sap/universe/UniverseCompleterTest.java | 66 +-
.../zeppelin/sap/universe/UniverseUtilTest.java | 586 +-
scalding/pom.xml | 8 -
.../zeppelin/scalding/ScaldingInterpreter.java | 52 +-
.../scalding/ScaldingInterpreterTest.java | 78 +-
.../zeppelin/scio/ScioInterpreterTest.java | 54 +-
shell/pom.xml | 7 -
.../apache/zeppelin/shell/ShellInterpreter.java | 78 +-
.../zeppelin/shell/ShellInterpreterTest.java | 13 +-
.../spark/AbstractSparkInterpreter.java | 8 +-
.../apache/zeppelin/spark/DepInterpreter.java | 94 +-
.../zeppelin/spark/IPySparkInterpreter.java | 25 +-
.../zeppelin/spark/NewSparkInterpreter.java | 66 +-
.../zeppelin/spark/OldSparkInterpreter.java | 392 +-
.../zeppelin/spark/PySparkInterpreter.java | 36 +-
.../org/apache/zeppelin/spark/PythonUtils.java | 51 +-
.../apache/zeppelin/spark/SparkInterpreter.java | 18 +-
.../zeppelin/spark/SparkRInterpreter.java | 65 +-
.../zeppelin/spark/SparkSqlInterpreter.java | 40 +-
.../org/apache/zeppelin/spark/SparkVersion.java | 10 +-
.../java/org/apache/zeppelin/spark/Utils.java | 36 +-
.../org/apache/zeppelin/spark/ZeppelinR.java | 90 +-
.../apache/zeppelin/spark/ZeppelinRContext.java | 12 +-
.../spark/dep/SparkDependencyContext.java | 37 +-
.../spark/dep/SparkDependencyResolver.java | 101 +-
.../zeppelin/spark/DepInterpreterTest.java | 25 +-
.../zeppelin/spark/IPySparkInterpreterTest.java | 164 +-
.../zeppelin/spark/NewSparkInterpreterTest.java | 309 +-
.../spark/NewSparkSqlInterpreterTest.java | 116 +-
.../zeppelin/spark/OldSparkInterpreterTest.java | 127 +-
.../spark/OldSparkSqlInterpreterTest.java | 60 +-
.../spark/PySparkInterpreterMatplotlibTest.java | 62 +-
.../zeppelin/spark/PySparkInterpreterTest.java | 23 +-
.../zeppelin/spark/SparkRInterpreterTest.java | 102 +-
.../apache/zeppelin/spark/SparkShimsTest.java | 6 +-
.../zeppelin/example/app/clock/Clock.java | 58 +-
.../org/apache/zeppelin/AbstractZeppelinIT.java | 88 +-
.../org/apache/zeppelin/CommandExecutor.java | 33 +-
.../java/org/apache/zeppelin/ProcessData.java | 159 +-
.../org/apache/zeppelin/WebDriverManager.java | 45 +-
.../org/apache/zeppelin/ZeppelinITUtils.java | 19 +-
.../zeppelin/integration/AuthenticationIT.java | 265 +-
.../zeppelin/integration/InterpreterIT.java | 21 +-
.../integration/InterpreterModeActionsIT.java | 1218 +-
.../integration/ParagraphActionsIT.java | 792 +-
.../integration/PersonalizeActionsIT.java | 318 +-
.../zeppelin/integration/SparkParagraphIT.java | 154 +-
.../apache/zeppelin/integration/ZeppelinIT.java | 203 +-
zeppelin-interpreter/pom.xml | 8 -
.../zeppelin/annotation/Experimental.java | 19 +-
.../apache/zeppelin/annotation/ZeppelinApi.java | 18 +-
.../zeppelin/common/JsonSerializable.java | 4 +-
.../zeppelin/completer/CachedCompleter.java | 18 +-
.../zeppelin/completer/CompletionType.java | 14 +-
.../zeppelin/completer/StringsCompleter.java | 36 +-
.../zeppelin/conf/ZeppelinConfiguration.java | 99 +-
.../dep/AbstractDependencyResolver.java | 30 +-
.../java/org/apache/zeppelin/dep/Booter.java | 11 +-
.../org/apache/zeppelin/dep/Dependency.java | 8 +-
.../apache/zeppelin/dep/DependencyContext.java | 27 +-
.../apache/zeppelin/dep/DependencyResolver.java | 35 +-
.../org/apache/zeppelin/dep/Repository.java | 20 +-
.../apache/zeppelin/dep/RepositoryListener.java | 11 +-
.../zeppelin/dep/RepositorySystemFactory.java | 12 +-
.../apache/zeppelin/dep/TransferListener.java | 24 +-
.../apache/zeppelin/display/AngularObject.java | 87 +-
.../zeppelin/display/AngularObjectListener.java | 4 +-
.../zeppelin/display/AngularObjectRegistry.java | 67 +-
.../display/AngularObjectRegistryListener.java | 7 +-
.../zeppelin/display/AngularObjectWatcher.java | 4 +-
.../java/org/apache/zeppelin/display/GUI.java | 30 +-
.../java/org/apache/zeppelin/display/Input.java | 85 +-
.../org/apache/zeppelin/display/OldInput.java | 21 +-
.../display/RuntimeTypeAdapterFactory.java | 54 +-
.../apache/zeppelin/display/ui/CheckBox.java | 9 +-
.../apache/zeppelin/display/ui/OptionInput.java | 7 +-
.../apache/zeppelin/display/ui/Password.java | 7 +-
.../org/apache/zeppelin/display/ui/Select.java | 9 +-
.../org/apache/zeppelin/display/ui/TextBox.java | 10 +-
.../org/apache/zeppelin/helium/Application.java | 52 +-
.../zeppelin/helium/ApplicationContext.java | 16 +-
.../helium/ApplicationEventListener.java | 18 +-
.../zeppelin/helium/ApplicationException.java | 8 +-
.../zeppelin/helium/ApplicationLoader.java | 54 +-
.../zeppelin/helium/ClassLoaderApplication.java | 5 +-
.../helium/HeliumAppAngularObjectRegistry.java | 12 +-
.../apache/zeppelin/helium/HeliumPackage.java | 45 +-
.../org/apache/zeppelin/helium/HeliumType.java | 4 +-
.../zeppelin/helium/SpellPackageInfo.java | 4 +-
.../interpreter/BaseZeppelinContext.java | 180 +-
.../apache/zeppelin/interpreter/Constants.java | 7 +-
.../interpreter/DefaultInterpreterProperty.java | 23 +-
.../zeppelin/interpreter/Interpreter.java | 144 +-
.../interpreter/InterpreterContext.java | 21 +-
.../interpreter/InterpreterException.java | 13 +-
.../zeppelin/interpreter/InterpreterGroup.java | 47 +-
.../interpreter/InterpreterHookListener.java | 14 +-
.../interpreter/InterpreterHookRegistry.java | 33 +-
.../zeppelin/interpreter/InterpreterOption.java | 14 +-
.../zeppelin/interpreter/InterpreterOutput.java | 29 +-
.../InterpreterOutputChangeListener.java | 5 +-
.../InterpreterOutputChangeWatcher.java | 7 +-
.../interpreter/InterpreterOutputListener.java | 10 +-
.../interpreter/InterpreterProperty.java | 4 +-
.../interpreter/InterpreterPropertyBuilder.java | 19 +-
.../interpreter/InterpreterPropertyType.java | 5 +-
.../zeppelin/interpreter/InterpreterResult.java | 21 +-
.../interpreter/InterpreterResultMessage.java | 4 +-
.../InterpreterResultMessageOutput.java | 21 +-
.../InterpreterResultMessageOutputListener.java | 9 +-
.../zeppelin/interpreter/InterpreterRunner.java | 9 +-
.../zeppelin/interpreter/InterpreterUtils.java | 25 +-
.../interpreter/InvalidHookException.java | 5 +-
.../interpreter/KerberosInterpreter.java | 89 +-
.../interpreter/LazyOpenInterpreter.java | 17 +-
.../RemoteZeppelinServerResource.java | 10 +-
.../zeppelin/interpreter/ResultMessages.java | 26 +-
.../interpreter/WrappedInterpreter.java | 4 +-
.../zeppelin/interpreter/graph/GraphResult.java | 50 +-
.../launcher/InterpreterLaunchContext.java | 28 +-
.../launcher/InterpreterLauncher.java | 16 +-
.../interpreter/recovery/RecoveryStorage.java | 15 +-
.../InvokeResourceMethodEventMessage.java | 11 +-
.../remote/RemoteInterpreterEventClient.java | 59 +-
.../remote/RemoteInterpreterServer.java | 487 +-
.../remote/RemoteInterpreterUtils.java | 46 +-
.../interpreter/thrift/AngularObjectId.java | 309 +-
.../thrift/AppOutputAppendEvent.java | 413 +-
.../thrift/AppOutputUpdateEvent.java | 462 +-
.../thrift/AppStatusUpdateEvent.java | 361 +-
.../thrift/InterpreterCompletion.java | 312 +-
.../interpreter/thrift/OutputAppendEvent.java | 410 +-
.../thrift/OutputUpdateAllEvent.java | 377 +-
.../interpreter/thrift/OutputUpdateEvent.java | 459 +-
.../interpreter/thrift/RegisterInfo.java | 321 +-
.../thrift/RemoteApplicationResult.java | 270 +-
.../thrift/RemoteInterpreterContext.java | 789 +-
.../thrift/RemoteInterpreterEvent.java | 295 +-
.../thrift/RemoteInterpreterEventService.java | 6093 ++++++----
.../thrift/RemoteInterpreterEventType.java | 38 +-
.../thrift/RemoteInterpreterResult.java | 443 +-
.../thrift/RemoteInterpreterResultMessage.java | 273 +-
.../thrift/RemoteInterpreterService.java | 10448 ++++++++++-------
.../interpreter/thrift/RunParagraphsEvent.java | 422 +-
.../util/InterpreterOutputStream.java | 13 +-
.../interpreter/util/LogOutputStream.java | 8 +-
.../resource/ByteBufferInputStream.java | 5 +-
.../resource/DistributedResourcePool.java | 17 +-
.../zeppelin/resource/LocalResourcePool.java | 12 +-
.../zeppelin/resource/RemoteResource.java | 26 +-
.../org/apache/zeppelin/resource/Resource.java | 50 +-
.../apache/zeppelin/resource/ResourceId.java | 10 +-
.../apache/zeppelin/resource/ResourcePool.java | 16 +-
.../resource/ResourcePoolConnector.java | 17 +-
.../apache/zeppelin/resource/ResourceSet.java | 7 +-
.../resource/WellKnownResourceName.java | 9 +-
.../zeppelin/scheduler/ExecutorFactory.java | 11 +-
.../zeppelin/scheduler/FIFOScheduler.java | 106 +-
.../java/org/apache/zeppelin/scheduler/Job.java | 43 +-
.../apache/zeppelin/scheduler/JobListener.java | 4 +-
.../zeppelin/scheduler/JobProgressPoller.java | 3 +-
.../scheduler/JobWithProgressPoller.java | 6 +-
.../zeppelin/scheduler/ParallelScheduler.java | 13 +-
.../apache/zeppelin/scheduler/Scheduler.java | 4 +-
.../zeppelin/scheduler/SchedulerFactory.java | 8 +-
.../zeppelin/scheduler/SchedulerListener.java | 4 +-
.../apache/zeppelin/tabledata/ColumnDef.java | 8 +-
.../apache/zeppelin/tabledata/GraphEntity.java | 17 +-
.../tabledata/InterpreterResultTableData.java | 12 +-
.../org/apache/zeppelin/tabledata/Node.java | 11 +-
.../zeppelin/tabledata/ProxyRowIterator.java | 7 +-
.../apache/zeppelin/tabledata/Relationship.java | 17 +-
.../java/org/apache/zeppelin/tabledata/Row.java | 8 +-
.../apache/zeppelin/tabledata/TableData.java | 8 +-
.../zeppelin/tabledata/TableDataException.java | 4 +-
.../zeppelin/tabledata/TableDataProxy.java | 10 +-
.../zeppelin/user/AuthenticationInfo.java | 25 +-
.../apache/zeppelin/user/UserCredentials.java | 8 +-
.../apache/zeppelin/user/UsernamePassword.java | 46 +-
.../java/org/apache/zeppelin/util/IdHashes.java | 14 +-
.../java/org/apache/zeppelin/util/Util.java | 21 +-
.../org/apache/zeppelin/dep/BooterTest.java | 10 +-
.../zeppelin/dep/DependencyResolverTest.java | 33 +-
.../display/AngularObjectRegistryTest.java | 47 +-
.../zeppelin/display/AngularObjectTest.java | 87 +-
.../org/apache/zeppelin/display/GUITest.java | 97 +-
.../org/apache/zeppelin/display/InputTest.java | 91 +-
.../zeppelin/helium/ApplicationLoaderTest.java | 51 +-
.../zeppelin/helium/HeliumPackageTest.java | 76 +-
.../zeppelin/helium/MockApplication1.java | 4 +-
.../interpreter/BaseZeppelinContextTest.java | 135 +-
.../interpreter/InterpreterContextTest.java | 8 +-
.../InterpreterHookRegistryTest.java | 5 +-
.../InterpreterOutputChangeWatcherTest.java | 19 +-
.../interpreter/InterpreterOutputTest.java | 17 +-
.../interpreter/InterpreterResultTest.java | 145 +-
.../zeppelin/interpreter/InterpreterTest.java | 38 +-
.../interpreter/LazyOpenInterpreterTest.java | 4 +-
.../interpreter/ZeppCtxtVariableTest.java | 33 +-
.../remote/RemoteInterpreterServerTest.java | 136 +-
.../remote/RemoteInterpreterUtilsTest.java | 25 +-
.../resource/LocalResourcePoolTest.java | 8 +-
.../zeppelin/resource/ResourceSetTest.java | 8 +-
.../apache/zeppelin/resource/ResourceTest.java | 9 +-
.../zeppelin/scheduler/FIFOSchedulerTest.java | 6 +-
.../org/apache/zeppelin/scheduler/JobTest.java | 21 +-
.../scheduler/ParallelSchedulerTest.java | 7 +-
.../apache/zeppelin/scheduler/SleepingJob.java | 12 +-
.../InterpreterResultTableDataTest.java | 15 +-
.../zeppelin/tabledata/TableDataProxyTest.java | 15 +-
.../zeppelin/user/AuthenticationInfoTest.java | 6 +-
.../apache/zeppelin/jupyter/JupyterUtil.java | 48 +-
.../zeppelin/jupyter/nbformat/Author.java | 5 +-
.../apache/zeppelin/jupyter/nbformat/Cell.java | 5 +-
.../zeppelin/jupyter/nbformat/CellMetadata.java | 5 +-
.../zeppelin/jupyter/nbformat/CodeCell.java | 4 +-
.../zeppelin/jupyter/nbformat/DisplayData.java | 31 +-
.../apache/zeppelin/jupyter/nbformat/Error.java | 9 +-
.../jupyter/nbformat/ExecuteResult.java | 8 +-
.../zeppelin/jupyter/nbformat/HeadingCell.java | 4 +-
.../zeppelin/jupyter/nbformat/Kernelspec.java | 4 +-
.../zeppelin/jupyter/nbformat/LanguageInfo.java | 5 +-
.../zeppelin/jupyter/nbformat/MarkdownCell.java | 8 +-
.../zeppelin/jupyter/nbformat/Metadata.java | 4 +-
.../zeppelin/jupyter/nbformat/Nbformat.java | 4 +-
.../zeppelin/jupyter/nbformat/Output.java | 44 +-
.../zeppelin/jupyter/nbformat/RawCell.java | 8 +-
.../jupyter/nbformat/RawCellMetadata.java | 4 +-
.../zeppelin/jupyter/nbformat/Stream.java | 10 +-
.../jupyter/types/JupyterOutputType.java | 8 +-
.../jupyter/types/ZeppelinOutputType.java | 8 +-
.../apache/zeppelin/jupyter/zformat/Note.java | 4 +-
.../zeppelin/jupyter/zformat/Paragraph.java | 4 +-
.../apache/zeppelin/jupyter/zformat/Result.java | 4 +-
.../zeppelin/jupyter/zformat/TypeData.java | 4 +-
.../jupyter/nbformat/JupyterUtilTest.java | 46 +-
.../launcher/SparkInterpreterLauncher.java | 69 +-
.../launcher/SparkInterpreterLauncherTest.java | 147 +-
.../launcher/StandardInterpreterLauncher.java | 50 +-
.../StandardInterpreterLauncherTest.java | 45 +-
.../notebook/repo/AzureNotebookRepo.java | 30 +-
.../notebook/repo/FileSystemNotebookRepo.java | 46 +-
.../repo/FileSystemNotebookRepoTest.java | 25 +-
.../zeppelin/notebook/repo/GCSNotebookRepo.java | 54 +-
.../notebook/repo/GCSNotebookRepoTest.java | 38 +-
.../zeppelin/notebook/repo/GitNotebookRepo.java | 44 +-
.../notebook/repo/GitNotebookRepoTest.java | 66 +-
.../NotebookRepoSyncInitializationTest.java | 51 +-
.../notebook/repo/NotebookRepoSyncTest.java | 229 +-
.../notebook/repo/mock/VFSNotebookRepoMock.java | 4 +-
.../notebook/repo/GitHubNotebookRepo.java | 36 +-
.../notebook/repo/GitHubNotebookRepoTest.java | 127 +-
.../notebook/repo/MongoNotebookRepo.java | 47 +-
.../zeppelin/notebook/repo/S3NotebookRepo.java | 105 +-
.../zeppelin/notebook/repo/VFSNotebookRepo.java | 22 +-
.../notebook/repo/TestVFSNotebookRepo.java | 19 +-
.../repo/zeppelinhub/ZeppelinHubRepo.java | 73 +-
zeppelin-server/pom.xml | 8 -
.../realm/ActiveDirectoryGroupRealm.java | 126 +-
.../apache/zeppelin/realm/LdapGroupRealm.java | 42 +-
.../org/apache/zeppelin/realm/LdapRealm.java | 368 +-
.../org/apache/zeppelin/realm/PamRealm.java | 22 +-
.../apache/zeppelin/realm/UserPrincipal.java | 7 +-
.../apache/zeppelin/realm/ZeppelinHubRealm.java | 65 +-
.../realm/jwt/JWTAuthenticationToken.java | 4 +-
.../realm/jwt/KnoxAuthenticationFilter.java | 34 +-
.../apache/zeppelin/realm/jwt/KnoxJwtRealm.java | 78 +-
.../zeppelin/realm/jwt/PrincipalMapper.java | 19 +-
.../realm/jwt/PrincipalMappingException.java | 25 +-
.../realm/jwt/SimplePrincipalMapper.java | 38 +-
.../apache/zeppelin/rest/AbstractRestApi.java | 7 +-
.../org/apache/zeppelin/rest/HeliumRestApi.java | 114 +-
.../zeppelin/rest/InterpreterRestApi.java | 108 +-
.../org/apache/zeppelin/rest/LoginRestApi.java | 53 +-
.../zeppelin/rest/NotebookRepoRestApi.java | 39 +-
.../apache/zeppelin/rest/NotebookResponse.java | 4 +-
.../apache/zeppelin/rest/NotebookRestApi.java | 335 +-
.../apache/zeppelin/rest/SecurityRestApi.java | 61 +-
.../apache/zeppelin/rest/ZeppelinRestApi.java | 19 +-
.../rest/exception/BadRequestException.java | 5 +-
.../rest/exception/ForbiddenException.java | 5 +-
.../rest/exception/NoteNotFoundException.java | 6 +-
.../exception/ParagraphNotFoundException.java | 5 +-
.../WebApplicationExceptionMapper.java | 6 +-
.../zeppelin/rest/message/CronRequest.java | 8 +-
.../message/NewInterpreterSettingRequest.java | 9 +-
.../zeppelin/rest/message/NewNoteRequest.java | 9 +-
.../rest/message/NewParagraphRequest.java | 16 +-
.../message/NotebookRepoSettingsRequest.java | 9 +-
.../rest/message/RenameNoteRequest.java | 10 +-
.../rest/message/RestartInterpreterRequest.java | 8 +-
.../RunParagraphWithParametersRequest.java | 9 +-
.../UpdateInterpreterSettingRequest.java | 12 +-
.../rest/message/UpdateParagraphRequest.java | 7 +-
.../org/apache/zeppelin/server/CorsFilter.java | 11 +-
.../apache/zeppelin/server/JsonResponse.java | 2 -
.../zeppelin/service/ConfigurationService.java | 41 +-
.../zeppelin/service/InterpreterService.java | 5 +-
.../zeppelin/service/JobManagerService.java | 40 +-
.../zeppelin/service/NotebookService.java | 410 +-
.../zeppelin/service/ServiceCallback.java | 10 +-
.../apache/zeppelin/service/ServiceContext.java | 8 +-
.../zeppelin/service/SimpleServiceCallback.java | 10 +-
.../zeppelin/socket/ConnectionManager.java | 94 +-
.../apache/zeppelin/socket/NotebookServer.java | 1724 +--
.../apache/zeppelin/socket/NotebookSocket.java | 13 +-
.../zeppelin/socket/NotebookSocketListener.java | 6 +-
.../socket/NotebookWebSocketCreator.java | 16 +-
.../zeppelin/types/InterpreterSettingsList.java | 11 +-
.../AnyOfRolesUserAuthorizationFilter.java | 10 +-
.../apache/zeppelin/utils/CommandLineUtils.java | 5 +-
.../apache/zeppelin/utils/ExceptionUtils.java | 8 +-
.../zeppelin/utils/InterpreterBindingUtils.java | 21 +-
.../apache/zeppelin/utils/SecurityUtils.java | 141 +-
.../configuration/RequestHeaderSizeTest.java | 10 +-
.../zeppelin/display/AngularObjectBuilder.java | 4 +-
.../apache/zeppelin/realm/LdapRealmTest.java | 35 +-
.../org/apache/zeppelin/realm/PamRealmTest.java | 7 +-
.../apache/zeppelin/recovery/RecoveryTest.java | 48 +-
.../zeppelin/rest/AbstractTestRestApi.java | 220 +-
.../rest/ConfigurationsRestApiTest.java | 48 +-
.../apache/zeppelin/rest/HeliumRestApiTest.java | 109 +-
.../zeppelin/rest/InterpreterRestApiTest.java | 113 +-
.../apache/zeppelin/rest/KnoxRestApiTest.java | 41 +-
.../zeppelin/rest/NotebookRepoRestApiTest.java | 63 +-
.../zeppelin/rest/NotebookRestApiTest.java | 104 +-
.../rest/NotebookSecurityRestApiTest.java | 130 +-
.../zeppelin/rest/SecurityRestApiTest.java | 52 +-
.../zeppelin/rest/ZeppelinRestApiTest.java | 194 +-
.../zeppelin/rest/ZeppelinServerTest.java | 5 +-
.../zeppelin/rest/ZeppelinSparkClusterTest.java | 247 +-
.../apache/zeppelin/security/DirAccessTest.java | 12 +-
.../zeppelin/security/SecurityUtilsTest.java | 73 +-
.../apache/zeppelin/server/CorsFilterTest.java | 52 +-
.../service/ConfigurationServiceTest.java | 24 +-
.../zeppelin/service/NotebookServiceTest.java | 94 +-
.../zeppelin/socket/NotebookServerTest.java | 211 +-
.../zeppelin/ticket/TicketContainerTest.java | 1 -
.../java/org/apache/zeppelin/helium/Helium.java | 90 +-
.../helium/HeliumApplicationFactory.java | 127 +-
.../zeppelin/helium/HeliumBundleFactory.java | 319 +-
.../org/apache/zeppelin/helium/HeliumConf.java | 37 +-
.../zeppelin/helium/HeliumLocalRegistry.java | 15 +-
.../zeppelin/helium/HeliumOnlineRegistry.java | 95 +-
.../helium/HeliumPackageSearchResult.java | 5 +-
.../helium/HeliumPackageSuggestion.java | 23 +-
.../apache/zeppelin/helium/HeliumRegistry.java | 8 +-
.../helium/HeliumRegistrySerializer.java | 28 +-
.../org/apache/zeppelin/helium/NpmPackage.java | 7 +-
.../apache/zeppelin/helium/WebpackResult.java | 8 +-
.../zeppelin/interpreter/ConfInterpreter.java | 33 +-
.../interpreter/InterpreterFactory.java | 17 +-
.../zeppelin/interpreter/InterpreterInfo.java | 21 +-
.../interpreter/InterpreterInfoSaving.java | 31 +-
.../InterpreterNotFoundException.java | 7 +-
.../interpreter/InterpreterSetting.java | 304 +-
.../interpreter/InterpreterSettingManager.java | 366 +-
.../zeppelin/interpreter/LifecycleManager.java | 10 +-
.../interpreter/ManagedInterpreterGroup.java | 46 +-
.../RemoteInterpreterEventServer.java | 249 +-
.../interpreter/SessionConfInterpreter.java | 21 +-
.../interpreter/SparkDownloadUtils.java | 42 +-
.../interpreter/install/InstallInterpreter.java | 72 +-
.../lifecycle/NullLifecycleManager.java | 17 +-
.../lifecycle/TimeoutLifecycleManager.java | 66 +-
.../recovery/FileSystemRecoveryStorage.java | 43 +-
.../recovery/NullRecoveryStorage.java | 23 +-
.../interpreter/recovery/StopInterpreter.java | 20 +-
.../interpreter/remote/AppendOutputBuffer.java | 6 +-
.../interpreter/remote/AppendOutputRunner.java | 39 +-
.../interpreter/remote/ClientFactory.java | 9 +-
.../interpreter/remote/RemoteAngularObject.java | 23 +-
.../remote/RemoteAngularObjectRegistry.java | 66 +-
.../interpreter/remote/RemoteInterpreter.java | 231 +-
.../remote/RemoteInterpreterManagedProcess.java | 53 +-
.../remote/RemoteInterpreterProcess.java | 22 +-
.../RemoteInterpreterProcessListener.java | 24 +-
.../remote/RemoteInterpreterRunningProcess.java | 26 +-
.../zeppelin/notebook/ApplicationState.java | 16 +-
.../zeppelin/notebook/FileSystemStorage.java | 187 +-
.../org/apache/zeppelin/notebook/Folder.java | 31 +-
.../zeppelin/notebook/FolderListener.java | 4 +-
.../apache/zeppelin/notebook/FolderView.java | 39 +-
.../java/org/apache/zeppelin/notebook/Note.java | 166 +-
.../zeppelin/notebook/NoteEventListener.java | 6 +-
.../org/apache/zeppelin/notebook/NoteInfo.java | 5 +-
.../zeppelin/notebook/NoteNameListener.java | 5 +-
.../org/apache/zeppelin/notebook/Notebook.java | 203 +-
.../notebook/NotebookAuthorization.java | 83 +-
.../NotebookAuthorizationInfoSaving.java | 7 +-
.../notebook/NotebookEventListener.java | 7 +-
.../notebook/NotebookImportDeserializer.java | 29 +-
.../org/apache/zeppelin/notebook/Paragraph.java | 157 +-
.../zeppelin/notebook/ParagraphJobListener.java | 11 +-
.../zeppelin/notebook/ParagraphRuntimeInfo.java | 23 +-
.../notebook/ParagraphWithRuntimeInfo.java | 5 +-
.../zeppelin/notebook/repo/NotebookRepo.java | 40 +-
.../notebook/repo/NotebookRepoSettingsInfo.java | 8 +-
.../notebook/repo/NotebookRepoSync.java | 138 +-
.../notebook/repo/NotebookRepoWithSettings.java | 5 +-
.../repo/NotebookRepoWithVersionControl.java | 39 +-
.../repo/zeppelinhub/model/Instance.java | 5 +-
.../zeppelinhub/model/UserSessionContainer.java | 10 +-
.../zeppelinhub/model/UserTokenContainer.java | 39 +-
.../repo/zeppelinhub/rest/HttpProxyClient.java | 109 +-
.../rest/ZeppelinhubRestApiHandler.java | 95 +-
.../zeppelinhub/security/Authentication.java | 42 +-
.../repo/zeppelinhub/websocket/Client.java | 13 +-
.../zeppelinhub/websocket/ZeppelinClient.java | 113 +-
.../websocket/ZeppelinhubClient.java | 43 +-
.../websocket/listener/WatcherWebsocket.java | 13 +-
.../websocket/listener/ZeppelinWebsocket.java | 10 +-
.../listener/ZeppelinhubWebsocket.java | 10 +-
.../websocket/protocol/ZeppelinHubOp.java | 4 +-
.../websocket/protocol/ZeppelinhubMessage.java | 20 +-
.../websocket/scheduler/SchedulerService.java | 6 +-
.../websocket/scheduler/ZeppelinHeartbeat.java | 9 +-
.../scheduler/ZeppelinHubHeartbeat.java | 15 +-
.../websocket/session/ZeppelinhubSession.java | 16 +-
.../websocket/utils/ZeppelinhubUtils.java | 47 +-
.../zeppelin/notebook/socket/Message.java | 243 +-
.../notebook/socket/WatcherMessage.java | 23 +-
.../zeppelin/notebook/utility/IdHashes.java | 12 +-
.../apache/zeppelin/plugin/PluginManager.java | 80 +-
.../zeppelin/scheduler/RemoteScheduler.java | 67 +-
.../apache/zeppelin/search/SearchService.java | 21 +-
.../apache/zeppelin/storage/ConfigStorage.java | 23 +-
.../storage/FileSystemConfigStorage.java | 19 +-
.../zeppelin/storage/LocalConfigStorage.java | 24 +-
.../apache/zeppelin/ticket/TicketContainer.java | 24 +-
.../org/apache/zeppelin/user/Credentials.java | 46 +-
.../zeppelin/user/CredentialsInfoSaving.java | 7 +-
.../org/apache/zeppelin/user/Encryptor.java | 8 +-
.../apache/zeppelin/util/ReflectionUtils.java | 53 +-
.../zeppelin/util/WatcherSecurityKey.java | 5 +-
.../conf/ZeppelinConfigurationTest.java | 43 +-
.../zeppelin/display/AngularObjectBuilder.java | 10 +-
.../helium/HeliumApplicationFactoryTest.java | 145 +-
.../helium/HeliumBundleFactoryTest.java | 167 +-
.../helium/HeliumLocalRegistryTest.java | 31 +-
.../helium/HeliumOnlineRegistryTest.java | 47 +-
.../org/apache/zeppelin/helium/HeliumTest.java | 140 +-
.../zeppelin/helium/HeliumTestApplication.java | 8 +-
.../zeppelin/helium/HeliumTestRegistry.java | 1 -
.../interpreter/AbstractInterpreterTest.java | 56 +-
.../interpreter/ConfInterpreterTest.java | 75 +-
.../interpreter/DoubleEchoInterpreter.java | 14 +-
.../zeppelin/interpreter/EchoInterpreter.java | 17 +-
.../interpreter/FlinkIntegrationTest.java | 60 +-
.../interpreter/InterpreterFactoryTest.java | 43 +-
.../InterpreterSettingManagerTest.java | 75 +-
.../interpreter/InterpreterSettingTest.java | 261 +-
.../ManagedInterpreterGroupTest.java | 43 +-
.../zeppelin/interpreter/MiniHadoopCluster.java | 42 +-
.../zeppelin/interpreter/MiniZeppelin.java | 39 +-
.../interpreter/SessionConfInterpreterTest.java | 24 +-
.../zeppelin/interpreter/SleepInterpreter.java | 23 +-
.../interpreter/SparkIntegrationTest.java | 112 +-
.../install/InstallInterpreterTest.java | 25 +-
.../lifecycle/TimeoutLifecycleManagerTest.java | 135 +-
.../interpreter/mock/MockInterpreter1.java | 202 +-
.../interpreter/mock/MockInterpreter2.java | 149 +-
.../recovery/FileSystemRecoveryStorageTest.java | 35 +-
.../remote/AppendOutputRunnerTest.java | 116 +-
.../remote/RemoteAngularObjectTest.java | 37 +-
.../RemoteInterpreterOutputTestStream.java | 65 +-
.../remote/RemoteInterpreterTest.java | 204 +-
.../mock/GetAngularObjectSizeInterpreter.java | 19 +-
.../remote/mock/GetEnvPropertyInterpreter.java | 31 +-
.../remote/mock/MockInterpreterA.java | 24 +-
.../remote/mock/MockInterpreterAngular.java | 45 +-
.../mock/MockInterpreterOutputStream.java | 28 +-
.../mock/MockInterpreterResourcePool.java | 23 +-
.../apache/zeppelin/notebook/FolderTest.java | 83 +-
.../zeppelin/notebook/FolderViewTest.java | 64 +-
.../org/apache/zeppelin/notebook/NoteTest.java | 229 +-
.../apache/zeppelin/notebook/NotebookTest.java | 632 +-
.../apache/zeppelin/notebook/ParagraphTest.java | 93 +-
.../resource/DistributedResourcePoolTest.java | 139 +-
.../zeppelin/scheduler/RemoteSchedulerTest.java | 318 +-
.../apache/zeppelin/user/CredentialsTest.java | 5 +-
.../org/apache/zeppelin/user/EncryptorTest.java | 7 +-
.../java/org/apache/zeppelin/util/UtilTest.java | 21 +-
633 files changed, 32412 insertions(+), 28298 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/zeppelin/blob/55f6c91c/_tools/checkstyle.xml
----------------------------------------------------------------------
diff --git a/_tools/checkstyle.xml b/_tools/checkstyle.xml
deleted file mode 100644
index aa53d30..0000000
--- a/_tools/checkstyle.xml
+++ /dev/null
@@ -1,289 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
-Licensed to the Apache Software Foundation (ASF) under one or more
-contributor license agreements. See the NOTICE file distributed with
-this work for additional information regarding copyright ownership.
-The ASF licenses this file to You under the Apache License, Version 2.0
-(the "License"); you may not use this file except in compliance with
-the License. You may obtain a copy of the License at
- http://www.apache.org/licenses/LICENSE-2.0
-Unless required by applicable law or agreed to in writing, software
-distributed under the License is distributed on an "AS IS" BASIS,
-WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-See the License for the specific language governing permissions and
-limitations under the License.
--->
-
-<!DOCTYPE module PUBLIC
- "-//Puppy Crawl//DTD Check Configuration 1.3//EN"
- "http://www.puppycrawl.com/dtds/configuration_1_3.dtd">
-
-<!-- This is a checkstyle configuration file. For descriptions of what the
- following rules do, please see the checkstyle configuration page at http://checkstyle.sourceforge.net/config.html -->
-
-<module name="Checker">
-
- <module name="FileTabCharacter">
- <!-- Checks that there are no tab characters in the file. -->
- </module>
-
- <module name="NewlineAtEndOfFile">
- <property name="lineSeparator" value="lf"/>
- </module>
-
- <module name="RegexpSingleline">
- <!-- Checks that FIXME is not used in comments. TODO is preferred. -->
- <property name="format" value="((//.*)|(\*.*))FIXME"/>
- <property name="message"
- value='TODO is preferred to FIXME. e.g. "TODO(johndoe): Refactor when v2 is released."'/>
- </module>
-
- <module name="RegexpSingleline">
- <!-- Checks that TODOs are named. (Actually, just that they are followed
- by an open paren.) -->
- <property name="format" value="((//.*)|(\*.*))TODO[^(]"/>
- <property name="message"
- value='All TODOs should be named. e.g. "TODO(johndoe): Refactor when v2 is released."'/>
- </module>
-
- <!-- <module name="JavadocPackage"> - Checks that each Java package has
- a Javadoc file used for commenting. Only allows a package-info.java, not
- package.html. </module> -->
- <!-- All Java AST specific tests live under TreeWalker module. -->
- <module name="TreeWalker">
-
- <!-- IMPORT CHECKS -->
-
- <module name="RedundantImport">
- <!-- Checks for redundant import statements. -->
- <property name="severity" value="error"/>
- </module>
- <module name="ImportOrder">
- <property name="severity" value="warning"/>
- <property name="groups" value="com.google,junit,net,org,java,javax,*,org.apache.zeppelin"/>
- <property name="option" value="top"/>
- <property name="tokens" value="STATIC_IMPORT, IMPORT"/>
- </module>
- <!-- JAVADOC CHECKS -->
-
- <!-- Checks for Javadoc comments. -->
- <!-- See http://checkstyle.sf.net/config_javadoc.html -->
- <module name="JavadocMethod">
- <property name="scope" value="protected"/>
- <property name="severity" value="warning"/>
- <property name="allowMissingJavadoc" value="true"/>
- <property name="allowMissingParamTags" value="true"/>
- <property name="allowMissingReturnTag" value="true"/>
- <property name="allowMissingThrowsTags" value="true"/>
- <property name="allowThrowsTagsForSubclasses" value="true"/>
- <property name="allowUndeclaredRTE" value="true"/>
- </module>
-
- <module name="JavadocStyle">
- <property name="severity" value="warning"/>
- </module>
-
- <!-- NAMING CHECKS -->
-
- <!-- Item 38 - Adhere to generally accepted naming conventions -->
-
- <module name="PackageName">
- <!-- Validates identifiers for package names against the supplied expression. -->
- <!-- Here the default checkstyle rule restricts package name parts to
- seven characters, this is not in line with common practice at Google. -->
- <property name="format" value="^[a-z]+(\.[a-z][a-z0-9]{1,})*$"/>
- <property name="severity" value="warning"/>
- </module>
-
- <module name="TypeNameCheck">
- <!-- Validates static, final fields against the expression "^[A-Z][a-zA-Z0-9]*$". -->
- <metadata name="altname" value="TypeName"/>
- <property name="severity" value="warning"/>
- </module>
-
- <module name="ConstantNameCheck">
- <!-- Validates non-private, static, final fields against the supplied
- public/package final fields "^[A-Z][A-Z0-9]*(_[A-Z0-9]+)*$". -->
- <metadata name="altname" value="ConstantName"/>
- <property name="applyToPublic" value="true"/>
- <property name="applyToProtected" value="true"/>
- <property name="applyToPackage" value="true"/>
- <property name="applyToPrivate" value="false"/>
- <property name="format" value="^([A-Z][A-Z0-9]*(_[A-Z0-9]+)*|FLAG_.*)$"/>
- <message key="name.invalidPattern"
- value="Variable ''{0}'' should be in ALL_CAPS (if it is a constant) or be private (otherwise)."/>
- <property name="severity" value="warning"/>
- </module>
-
- <module name="StaticVariableNameCheck">
- <!-- Validates static, non-final fields against the supplied expression
- "^[a-z][a-zA-Z0-9]*_?$". -->
- <metadata name="altname" value="StaticVariableName"/>
- <property name="applyToPublic" value="true"/>
- <property name="applyToProtected" value="true"/>
- <property name="applyToPackage" value="true"/>
- <property name="applyToPrivate" value="true"/>
- <property name="format" value="^[a-z][a-zA-Z0-9]*_?$"/>
- <property name="severity" value="warning"/>
- </module>
-
- <module name="MemberNameCheck">
- <!-- Validates non-static members against the supplied expression. -->
- <metadata name="altname" value="MemberName"/>
- <property name="applyToPublic" value="true"/>
- <property name="applyToProtected" value="true"/>
- <property name="applyToPackage" value="true"/>
- <property name="applyToPrivate" value="true"/>
- <property name="format" value="^[a-z][a-zA-Z0-9]*$"/>
- <property name="severity" value="warning"/>
- </module>
-
- <module name="MethodNameCheck">
- <!-- Validates identifiers for method names. -->
- <metadata name="altname" value="MethodName"/>
- <property name="format" value="^[a-z][a-zA-Z0-9]*(_[a-zA-Z0-9]+)*$"/>
- <property name="severity" value="warning"/>
- </module>
-
- <module name="ParameterName">
- <!-- Validates identifiers for method parameters against the expression
- "^[a-z][a-zA-Z0-9]*$". -->
- <property name="severity" value="warning"/>
- </module>
-
- <module name="LocalFinalVariableName">
- <!-- Validates identifiers for local final variables against the expression
- "^[a-z][a-zA-Z0-9]*$". -->
- <property name="severity" value="warning"/>
- </module>
-
- <module name="LocalVariableName">
- <!-- Validates identifiers for local variables against the expression
- "^[a-z][a-zA-Z0-9]*$". -->
- <property name="severity" value="warning"/>
- </module>
-
-
- <!-- LENGTH and CODING CHECKS -->
-
- <module name="LineLength">
- <!-- Checks if a line is too long. -->
- <property name="max"
- value="${com.puppycrawl.tools.checkstyle.checks.sizes.LineLength.max}"
- default="100"/>
- <property name="severity" value="error"/>
-
- <!-- The default ignore pattern exempts the following elements: - import
- statements - long URLs inside comments -->
-
- <property name="ignorePattern"
- value="${com.puppycrawl.tools.checkstyle.checks.sizes.LineLength.ignorePattern}"
- default="^(package .*;\s*)|(import .*;\s*)|( *\* *https?://.*)$"/>
- </module>
-
- <module name="LeftCurly">
- <!-- Checks for placement of the left curly brace ('{'). -->
- <property name="severity" value="warning"/>
- </module>
-
- <module name="RightCurly">
- <!-- Checks right curlies on CATCH, ELSE, and TRY blocks are on the same
- line. e.g., the following example is fine: <pre> if { ... } else </pre> -->
- <!-- This next example is not fine: <pre> if { ... } else </pre> -->
- <property name="option" value="same"/>
- <property name="severity" value="warning"/>
- </module>
-
- <!-- Checks for braces around if and else blocks -->
- <module name="NeedBraces">
- <property name="severity" value="warning"/>
- <property name="tokens"
- value="LITERAL_IF, LITERAL_ELSE, LITERAL_FOR, LITERAL_WHILE, LITERAL_DO"/>
- </module>
-
- <module name="UpperEll">
- <!-- Checks that long constants are defined with an upper ell. -->
- <property name="severity" value="error"/>
- </module>
-
- <module name="FallThrough">
- <!-- Warn about falling through to the next case statement. Similar to
- javac -Xlint:fallthrough, but the check is suppressed if a single-line comment
- on the last non-blank line preceding the fallen-into case contains 'fall
- through' (or some other variants which we don't publicized to promote consistency). -->
- <property name="reliefPattern"
- value="fall through|Fall through|fallthru|Fallthru|falls through|Falls through|fallthrough|Fallthrough|No break|NO break|no break|continue on"/>
- <property name="severity" value="error"/>
- </module>
-
-
- <!-- MODIFIERS CHECKS -->
-
- <module name="ModifierOrder">
- <!-- Warn if modifier order is inconsistent with JLS3 8.1.1, 8.3.1, and
- 8.4.3. The prescribed order is: public, protected, private, abstract, static,
- final, transient, volatile, synchronized, native, strictfp -->
- </module>
-
-
- <!-- WHITESPACE CHECKS -->
-
- <module name="WhitespaceAround">
- <!-- Checks that various tokens are surrounded by whitespace. This includes
- most binary operators and keywords followed by regular or curly braces. -->
- <property name="tokens"
- value="ASSIGN, BAND, BAND_ASSIGN, BOR,
- BOR_ASSIGN, BSR, BSR_ASSIGN, BXOR, BXOR_ASSIGN, COLON, DIV, DIV_ASSIGN,
- EQUAL, GE, GT, LAND, LE, LITERAL_CATCH, LITERAL_DO, LITERAL_ELSE,
- LITERAL_FINALLY, LITERAL_FOR, LITERAL_IF, LITERAL_RETURN,
- LITERAL_SYNCHRONIZED, LITERAL_TRY, LITERAL_WHILE, LOR, LT, MINUS,
- MINUS_ASSIGN, MOD, MOD_ASSIGN, NOT_EQUAL, PLUS, PLUS_ASSIGN, QUESTION,
- SL, SL_ASSIGN, SR_ASSIGN, STAR, STAR_ASSIGN"/>
- <property name="severity" value="error"/>
- </module>
-
- <module name="WhitespaceAfter">
- <!-- Checks that commas, semicolons and typecasts are followed by whitespace. -->
- <property name="tokens" value="COMMA, SEMI, TYPECAST"/>
- </module>
-
- <module name="NoWhitespaceAfter">
- <!-- Checks that there is no whitespace after various unary operators.
- Linebreaks are allowed. -->
- <property name="tokens"
- value="BNOT, DEC, DOT, INC, LNOT, UNARY_MINUS,
- UNARY_PLUS"/>
- <property name="allowLineBreaks" value="true"/>
- <property name="severity" value="error"/>
- </module>
-
- <module name="NoWhitespaceBefore">
- <!-- Checks that there is no whitespace before various unary operators.
- Linebreaks are allowed. -->
- <property name="tokens" value="SEMI, DOT, POST_DEC, POST_INC"/>
- <property name="allowLineBreaks" value="true"/>
- <property name="severity" value="error"/>
- </module>
-
- <module name="ParenPad">
- <!-- Checks that there is no whitespace before close parens or after open
- parens. -->
- <property name="severity" value="warning"/>
- </module>
-
- <module name="Indentation">
- <!-- Checks code indentation -->
- <property name="basicOffset" value="2"/>
- <property name="caseIndent" value="2"/>
- </module>
-
- <module name="EmptyCatchBlock">
- <property name="exceptionVariableName" value="expected"/>
- </module>
- <module name="CommentsIndentation"/>
- <module name="UnusedImports"/>
- <module name="RedundantImport"/>
- <module name="RedundantModifier"/>
- <module name="AvoidStarImport"/>
- </module>
-</module>
http://git-wip-us.apache.org/repos/asf/zeppelin/blob/55f6c91c/alluxio/pom.xml
----------------------------------------------------------------------
diff --git a/alluxio/pom.xml b/alluxio/pom.xml
index af23c87..6ef7a01 100644
--- a/alluxio/pom.xml
+++ b/alluxio/pom.xml
@@ -137,13 +137,6 @@
<plugin>
<artifactId>maven-resources-plugin</artifactId>
</plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-checkstyle-plugin</artifactId>
- <configuration>
- <skip>false</skip>
- </configuration>
- </plugin>
</plugins>
</build>
http://git-wip-us.apache.org/repos/asf/zeppelin/blob/55f6c91c/alluxio/src/main/java/org/apache/zeppelin/alluxio/AlluxioInterpreter.java
----------------------------------------------------------------------
diff --git a/alluxio/src/main/java/org/apache/zeppelin/alluxio/AlluxioInterpreter.java b/alluxio/src/main/java/org/apache/zeppelin/alluxio/AlluxioInterpreter.java
index be912ec..29648f7 100644
--- a/alluxio/src/main/java/org/apache/zeppelin/alluxio/AlluxioInterpreter.java
+++ b/alluxio/src/main/java/org/apache/zeppelin/alluxio/AlluxioInterpreter.java
@@ -1,26 +1,21 @@
/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
+ * Licensed to the Apache Software Foundation (ASF) under one or more contributor license
+ * agreements. See the NOTICE file distributed with this work for additional information regarding
+ * copyright ownership. The ASF licenses this file to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance with the License. You may obtain a
+ * copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * <p>http://www.apache.org/licenses/LICENSE-2.0
*
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
+ * <p>Unless required by applicable law or agreed to in writing, software distributed under the
+ * License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing permissions and
* limitations under the License.
*/
-
package org.apache.zeppelin.alluxio;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
+import alluxio.Configuration;
+import alluxio.shell.AlluxioShell;
import java.io.ByteArrayOutputStream;
import java.io.IOException;
import java.io.PrintStream;
@@ -29,22 +24,18 @@ import java.util.Arrays;
import java.util.LinkedList;
import java.util.List;
import java.util.Properties;
-
-import alluxio.Configuration;
-import alluxio.shell.AlluxioShell;
-
import org.apache.zeppelin.completer.CompletionType;
import org.apache.zeppelin.interpreter.Interpreter;
import org.apache.zeppelin.interpreter.InterpreterContext;
import org.apache.zeppelin.interpreter.InterpreterResult;
import org.apache.zeppelin.interpreter.InterpreterResult.Code;
import org.apache.zeppelin.interpreter.thrift.InterpreterCompletion;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
-/**
- * Alluxio interpreter for Zeppelin.
- */
+/** Alluxio interpreter for Zeppelin. */
public class AlluxioInterpreter extends Interpreter {
-
+
Logger logger = LoggerFactory.getLogger(AlluxioInterpreter.class);
protected static final String ALLUXIO_MASTER_HOSTNAME = "alluxio.master.hostname";
@@ -58,13 +49,40 @@ public class AlluxioInterpreter extends Interpreter {
private final String alluxioMasterHostname;
private final String alluxioMasterPort;
- protected final List<String> keywords = Arrays.asList("cat", "chgrp",
- "chmod", "chown", "copyFromLocal", "copyToLocal", "count",
- "createLineage", "deleteLineage", "du", "fileInfo", "free",
- "getCapacityBytes", "getUsedBytes", "listLineages", "load",
- "loadMetadata", "location", "ls", "mkdir", "mount", "mv",
- "persist", "pin", "report", "rm", "setTtl", "tail", "touch",
- "unmount", "unpin", "unsetTtl");
+ protected final List<String> keywords =
+ Arrays.asList(
+ "cat",
+ "chgrp",
+ "chmod",
+ "chown",
+ "copyFromLocal",
+ "copyToLocal",
+ "count",
+ "createLineage",
+ "deleteLineage",
+ "du",
+ "fileInfo",
+ "free",
+ "getCapacityBytes",
+ "getUsedBytes",
+ "listLineages",
+ "load",
+ "loadMetadata",
+ "location",
+ "ls",
+ "mkdir",
+ "mount",
+ "mv",
+ "persist",
+ "pin",
+ "report",
+ "rm",
+ "setTtl",
+ "tail",
+ "touch",
+ "unmount",
+ "unpin",
+ "unsetTtl");
public AlluxioInterpreter(Properties property) {
super(property);
@@ -75,8 +93,11 @@ public class AlluxioInterpreter extends Interpreter {
@Override
public void open() {
- logger.info("Starting Alluxio shell to connect to " + alluxioMasterHostname +
- " on port " + alluxioMasterPort);
+ logger.info(
+ "Starting Alluxio shell to connect to "
+ + alluxioMasterHostname
+ + " on port "
+ + alluxioMasterPort);
System.setProperty(ALLUXIO_MASTER_HOSTNAME, alluxioMasterHostname);
System.setProperty(ALLUXIO_MASTER_PORT, alluxioMasterPort);
@@ -99,18 +120,18 @@ public class AlluxioInterpreter extends Interpreter {
String[] lines = splitAndRemoveEmpty(st, "\n");
return interpret(lines, context);
}
-
+
private InterpreterResult interpret(String[] commands, InterpreterContext context) {
boolean isSuccess = true;
totalCommands = commands.length;
completedCommands = 0;
-
+
ByteArrayOutputStream baos = new ByteArrayOutputStream();
PrintStream ps = new PrintStream(baos);
PrintStream old = System.out;
-
+
System.setOut(ps);
-
+
for (String command : commands) {
int commandResult = 1;
String[] args = splitAndRemoveEmpty(command, " ");
@@ -130,14 +151,14 @@ public class AlluxioInterpreter extends Interpreter {
System.out.flush();
System.setOut(old);
-
+
if (isSuccess) {
return new InterpreterResult(Code.SUCCESS, baos.toString());
} else {
return new InterpreterResult(Code.ERROR, baos.toString());
}
}
-
+
private String[] splitAndRemoveEmpty(String st, String splitSeparator) {
String[] voices = st.split(splitSeparator);
ArrayList<String> result = new ArrayList<>();
@@ -158,7 +179,7 @@ public class AlluxioInterpreter extends Interpreter {
}
@Override
- public void cancel(InterpreterContext context) { }
+ public void cancel(InterpreterContext context) {}
@Override
public FormType getFormType() {
@@ -171,15 +192,15 @@ public class AlluxioInterpreter extends Interpreter {
}
@Override
- public List<InterpreterCompletion> completion(String buf, int cursor,
- InterpreterContext interpreterContext) {
+ public List<InterpreterCompletion> completion(
+ String buf, int cursor, InterpreterContext interpreterContext) {
String[] words = splitAndRemoveEmpty(splitAndRemoveEmpty(buf, "\n"), " ");
String lastWord = "";
if (words.length > 0) {
- lastWord = words[ words.length - 1 ];
+ lastWord = words[words.length - 1];
}
-
- List<InterpreterCompletion> voices = new LinkedList<>();
+
+ List<InterpreterCompletion> voices = new LinkedList<>();
for (String command : keywords) {
if (command.startsWith(lastWord)) {
voices.add(new InterpreterCompletion(command, command, CompletionType.command.name()));
@@ -193,61 +214,81 @@ public class AlluxioInterpreter extends Interpreter {
sb.append("Commands list:");
sb.append("\n\t[help] - List all available commands.");
sb.append("\n\t[cat <path>] - Prints the file's contents to the console.");
- sb.append("\n\t[chgrp [-R] <group> <path>] - Changes the group of a file or directory " +
- "specified by args. Specify -R to change the group recursively.");
- sb.append("\n\t[chmod -R <mode> <path>] - Changes the permission of a file or directory " +
- "specified by args. Specify -R to change the permission recursively.");
- sb.append("\n\t[chown -R <owner> <path>] - Changes the owner of a file or directory " +
- "specified by args. Specify -R to change the owner recursively.");
- sb.append("\n\t[copyFromLocal <src> <remoteDst>] - Copies a file or a directory from " +
- "local filesystem to Alluxio filesystem.");
- sb.append("\n\t[copyToLocal <src> <localDst>] - Copies a file or a directory from the " +
- "Alluxio filesystem to the local filesystem.");
- sb.append("\n\t[count <path>] - Displays the number of files and directories matching " +
- "the specified prefix.");
- sb.append("\n\t[createLineage <inputFile1,...> <outputFile1,...> " +
- "[<cmd_arg1> <cmd_arg2> ...]] - Creates a lineage.");
- sb.append("\n\t[deleteLineage <lineageId> <cascade(true|false)>] - Deletes a lineage. If " +
- "cascade is specified as true, dependent lineages will also be deleted.");
+ sb.append(
+ "\n\t[chgrp [-R] <group> <path>] - Changes the group of a file or directory "
+ + "specified by args. Specify -R to change the group recursively.");
+ sb.append(
+ "\n\t[chmod -R <mode> <path>] - Changes the permission of a file or directory "
+ + "specified by args. Specify -R to change the permission recursively.");
+ sb.append(
+ "\n\t[chown -R <owner> <path>] - Changes the owner of a file or directory "
+ + "specified by args. Specify -R to change the owner recursively.");
+ sb.append(
+ "\n\t[copyFromLocal <src> <remoteDst>] - Copies a file or a directory from "
+ + "local filesystem to Alluxio filesystem.");
+ sb.append(
+ "\n\t[copyToLocal <src> <localDst>] - Copies a file or a directory from the "
+ + "Alluxio filesystem to the local filesystem.");
+ sb.append(
+ "\n\t[count <path>] - Displays the number of files and directories matching "
+ + "the specified prefix.");
+ sb.append(
+ "\n\t[createLineage <inputFile1,...> <outputFile1,...> "
+ + "[<cmd_arg1> <cmd_arg2> ...]] - Creates a lineage.");
+ sb.append(
+ "\n\t[deleteLineage <lineageId> <cascade(true|false)>] - Deletes a lineage. If "
+ + "cascade is specified as true, dependent lineages will also be deleted.");
sb.append("\n\t[du <path>] - Displays the size of the specified file or directory.");
sb.append("\n\t[fileInfo <path>] - Displays all block info for the specified file.");
- sb.append("\n\t[free <file path|folder path>] - Removes the file or directory(recursively) " +
- "from Alluxio memory space.");
+ sb.append(
+ "\n\t[free <file path|folder path>] - Removes the file or directory(recursively) "
+ + "from Alluxio memory space.");
sb.append("\n\t[getCapacityBytes] - Gets the capacity of the Alluxio file system.");
sb.append("\n\t[getUsedBytes] - Gets number of bytes used in the Alluxio file system.");
sb.append("\n\t[listLineages] - Lists all lineages.");
- sb.append("\n\t[load <path>] - Loads a file or directory in Alluxio space, makes it " +
- "resident in memory.");
- sb.append("\n\t[loadMetadata <path>] - Loads metadata for the given Alluxio path from the " +
- "under file system.");
+ sb.append(
+ "\n\t[load <path>] - Loads a file or directory in Alluxio space, makes it "
+ + "resident in memory.");
+ sb.append(
+ "\n\t[loadMetadata <path>] - Loads metadata for the given Alluxio path from the "
+ + "under file system.");
sb.append("\n\t[location <path>] - Displays the list of hosts storing the specified file.");
- sb.append("\n\t[ls [-R] <path>] - Displays information for all files and directories " +
- "directly under the specified path. Specify -R to display files and " +
- "directories recursively.");
- sb.append("\n\t[mkdir <path1> [path2] ... [pathn]] - Creates the specified directories, " +
- "including any parent directories that are required.");
+ sb.append(
+ "\n\t[ls [-R] <path>] - Displays information for all files and directories "
+ + "directly under the specified path. Specify -R to display files and "
+ + "directories recursively.");
+ sb.append(
+ "\n\t[mkdir <path1> [path2] ... [pathn]] - Creates the specified directories, "
+ + "including any parent directories that are required.");
sb.append("\n\t[mount <alluxioPath> <ufsURI>] - Mounts a UFS path onto an Alluxio path.");
sb.append("\n\t[mv <src> <dst>] - Renames a file or directory.");
- sb.append("\n\t[persist <alluxioPath>] - Persists a file or directory currently stored " +
- "only in Alluxio to the UnderFileSystem.");
- sb.append("\n\t[pin <path>] - Pins the given file or directory in memory (works " +
- "recursively for directories). Pinned files are never evicted from memory, unless " +
- "TTL is set.");
+ sb.append(
+ "\n\t[persist <alluxioPath>] - Persists a file or directory currently stored "
+ + "only in Alluxio to the UnderFileSystem.");
+ sb.append(
+ "\n\t[pin <path>] - Pins the given file or directory in memory (works "
+ + "recursively for directories). Pinned files are never evicted from memory, unless "
+ + "TTL is set.");
sb.append("\n\t[report <path>] - Reports to the master that a file is lost.");
- sb.append("\n\t[rm [-R] <path>] - Removes the specified file. Specify -R to remove file or " +
- "directory recursively.");
- sb.append("\n\t[setTtl <path> <time to live(in milliseconds)>] - Sets a new TTL value for " +
- "the file at path.");
+ sb.append(
+ "\n\t[rm [-R] <path>] - Removes the specified file. Specify -R to remove file or "
+ + "directory recursively.");
+ sb.append(
+ "\n\t[setTtl <path> <time to live(in milliseconds)>] - Sets a new TTL value for "
+ + "the file at path.");
sb.append("\n\t[tail <path>] - Prints the file's last 1KB of contents to the console.");
- sb.append("\n\t[touch <path>] - Creates a 0 byte file. The file will be written to the " +
- "under file system.");
+ sb.append(
+ "\n\t[touch <path>] - Creates a 0 byte file. The file will be written to the "
+ + "under file system.");
sb.append("\n\t[unmount <alluxioPath>] - Unmounts an Alluxio path.");
- sb.append("\n\t[unpin <path>] - Unpins the given file or folder from memory " +
- "(works recursively for a directory).");
+ sb.append(
+ "\n\t[unpin <path>] - Unpins the given file or folder from memory "
+ + "(works recursively for a directory).");
sb.append("\n\\t[unsetTtl <path>] - Unsets the TTL value for the given path.");
- sb.append("\n\t[unpin <path>] - Unpin the given file to allow Alluxio to evict " +
- "this file again. If the given path is a directory, it recursively unpins " +
- "all files contained and any new files created within this directory.");
+ sb.append(
+ "\n\t[unpin <path>] - Unpin the given file to allow Alluxio to evict "
+ + "this file again. If the given path is a directory, it recursively unpins "
+ + "all files contained and any new files created within this directory.");
return sb.toString();
}
}