Skip to content

Commit

Permalink
[CALCITE-2376] License header for XML file and javadoc (Andrei Sereda)
Browse files Browse the repository at this point in the history
  • Loading branch information
Andrei Sereda authored and snuyanzin committed Jul 16, 2018
1 parent 56c11b2 commit 1947d5d
Show file tree
Hide file tree
Showing 3 changed files with 24 additions and 28 deletions.
Expand Up @@ -38,7 +38,8 @@

/**
* Represents a single elastic search node which can run embedded in a java application.
* Intended for unit and integration tests. Settings and plugins are crafted for Calcite.
*
* <p>Intended for unit and integration tests. Settings and plugins are crafted for Calcite.
*/
class EmbeddedElasticsearchNode implements AutoCloseable {

Expand All @@ -49,7 +50,6 @@ private EmbeddedElasticsearchNode(Node node) {
this.node = Objects.requireNonNull(node, "node");
}


/**
* Creates an instance with existing settings
* @param settings configuration parameters of ES instance
Expand Down Expand Up @@ -116,8 +116,8 @@ public TransportAddress httpAddress() {
/**
* Exposes elastic
* <a href="https://www.elastic.co/guide/en/elasticsearch/client/java-api/current/transport-client.html">transport client</a>
*
* (use of HTTP client is preferred).
*
* @return current elastic search client
*/
public Client client() {
Expand Down
Expand Up @@ -32,7 +32,7 @@
* Used to initialize a single elastic node. For performance reasons (node startup costs),
* same instance is usually shared across multiple tests.
*
* This rule should be used as follows:
* <p>This rule should be used as follows:
* <pre>
* public class MyTest {
* &#64;ClassRule
Expand All @@ -45,7 +45,7 @@
*
* &#64;Test
* public void myTest() {
* TransportAddress address = RULE.httpAddress();
* RestClient client = RULE.restClient();
* // ....
* }
* }
Expand Down Expand Up @@ -91,8 +91,8 @@ ObjectMapper mapper() {
}

/**
* Low-level http rest client to elastic search
* @return current ES rest client
* Low-level http rest client connected to current embedded elastic search instance.
* @return http client connected to ES cluster
*/
RestClient restClient() {
if (client != null) {
Expand All @@ -110,7 +110,7 @@ RestClient restClient() {
* HTTP address for rest clients (can be ES native or any other).
* @return http address to connect to
*/
TransportAddress httpAddress() {
private TransportAddress httpAddress() {
return node.httpAddress();
}

Expand Down
36 changes: 16 additions & 20 deletions elasticsearch/src/test/resources/log4j2.xml
@@ -1,26 +1,22 @@
<?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.
~ */
~
-->
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
<Configuration status="WARN">
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.
-->

<Configuration status="WARN">
<Appenders>
<Console name="console" target="SYSTEM_OUT">
<PatternLayout
Expand All @@ -33,4 +29,4 @@
<AppenderRef ref="console" />
</Root>
</Loggers>
</Configuration>
</Configuration>

0 comments on commit 1947d5d

Please sign in to comment.