Skip to content

Commit

Permalink
remove janino and conditional logging (typedb#5088)
Browse files Browse the repository at this point in the history
Removes dependency on janino library which was only needed to enable conditional statements in logback.xml file.
The conditional check we were doing is unnecessary, so removing that also allows us to get rid of the runtime dependency.
  • Loading branch information
Marco Scoppetta authored Apr 4, 2019
1 parent 8f36622 commit 335e308
Show file tree
Hide file tree
Showing 7 changed files with 1 addition and 49 deletions.
3 changes: 0 additions & 3 deletions console/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -44,9 +44,6 @@ java_library(
"//dependencies/maven/artifacts/jline:jline",
"//dependencies/maven/artifacts/org/slf4j:slf4j-api",
],
runtime_deps = [
"//dependencies/maven/artifacts/org/codehaus/janino:janino", # Needed to avoid Logback error
],
visibility = ["//console/test:__subpackages__"],
resources = ["LICENSE"],
resource_strip_prefix = "console",
Expand Down
1 change: 0 additions & 1 deletion daemon/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,6 @@ java_library(
runtime_deps = [
"//dependencies/maven/artifacts/ch/qos/logback:logback-classic",
"//dependencies/maven/artifacts/ch/qos/logback:logback-core",
"//dependencies/maven/artifacts/org/codehaus/janino:janino",
],
resources = ["LICENSE"],
resource_strip_prefix = "daemon",
Expand Down
26 changes: 0 additions & 26 deletions dependencies/maven/artifacts/org/codehaus/janino/BUILD

This file was deleted.

2 changes: 0 additions & 2 deletions dependencies/maven/dependencies.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -586,8 +586,6 @@ def list_dependencies():
# - com.sun.jersey:jersey-json:1.9 wanted version 1.8.3
# - org.apache.hadoop:hadoop-yarn-common:2.7.2 wanted version 1.9.13
{"artifact": "org.codehaus.jackson:jackson-xc:1.9.13", "lang": "java", "sha1": "e3480072bc95c202476ffa1de99ff7ee9149f29c", "sha256": "2d2905fcec7d1c55b775995617685dbb03672350704d9e40b492eab5b54d0be7", "repository": "https://repo.maven.apache.org/maven2/", "url": "https://repo.maven.apache.org/maven2/org/codehaus/jackson/jackson-xc/1.9.13/jackson-xc-1.9.13.jar", "source": {"sha1": "5b45f8e8027858e8a455f031a32638b615a307df", "sha256": "e8963ebfd0bfa4e23e45998914e224f5907f6bb516b8eb36823a91b3f5e98025", "repository": "https://repo.maven.apache.org/maven2/", "url": "https://repo.maven.apache.org/maven2/org/codehaus/jackson/jackson-xc/1.9.13/jackson-xc-1.9.13-sources.jar"} , "name": "org-codehaus-jackson-jackson-xc", "actual": "@org-codehaus-jackson-jackson-xc//jar", "bind": "jar/org/codehaus/jackson/jackson-xc"},
{"artifact": "org.codehaus.janino:commons-compiler:2.7.8", "lang": "java", "sha1": "fe224c801f296af125316178300dfc633675a8ff", "sha256": "69094456b227ec07d908938c8f90eb57e51ca6d0e82f96475770af7224b508b2", "repository": "https://repo.maven.apache.org/maven2/", "url": "https://repo.maven.apache.org/maven2/org/codehaus/janino/commons-compiler/2.7.8/commons-compiler-2.7.8.jar", "source": {"sha1": "9b4872aac6baca858a8ca0466d5fb38aa686d7b6", "sha256": "ef20715b2eec0ea397023b40a836f60890d64a4e1c49fa9907d526ae662ede42", "repository": "https://repo.maven.apache.org/maven2/", "url": "https://repo.maven.apache.org/maven2/org/codehaus/janino/commons-compiler/2.7.8/commons-compiler-2.7.8-sources.jar"} , "name": "org-codehaus-janino-commons-compiler", "actual": "@org-codehaus-janino-commons-compiler//jar", "bind": "jar/org/codehaus/janino/commons-compiler"},
{"artifact": "org.codehaus.janino:janino:2.7.8", "lang": "java", "sha1": "109852ba81725a1ca29cc9aa0688455bd7be4b0f", "sha256": "60f05562c22b6de06641a1f76148692ef336ad1f6712fe6a76f9e2611f766344", "repository": "https://repo.maven.apache.org/maven2/", "url": "https://repo.maven.apache.org/maven2/org/codehaus/janino/janino/2.7.8/janino-2.7.8.jar", "source": {"sha1": "70a377c52fa7d733cbfc1f94cded7b101bc5bc4b", "sha256": "02459209304a0fa412a0619dd1b0f1524cd57a68c39c5ca340caf63f266bf6da", "repository": "https://repo.maven.apache.org/maven2/", "url": "https://repo.maven.apache.org/maven2/org/codehaus/janino/janino/2.7.8/janino-2.7.8-sources.jar"} , "name": "org-codehaus-janino-janino", "actual": "@org-codehaus-janino-janino//jar", "bind": "jar/org/codehaus/janino/janino"},
# duplicates in org.codehaus.jettison:jettison promoted to 1.3.8
# - com.netflix.astyanax:astyanax-cassandra:3.10.2 wanted version 1.3.8
# - com.sun.jersey:jersey-json:1.9 wanted version 1.1
Expand Down
5 changes: 0 additions & 5 deletions dependencies/maven/dependencies.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -307,11 +307,6 @@ dependencies:
exclude:
- "org.slf4j:slf4j-log4j12"

org.codehaus.janino:
janino:
version: "2.7.8"
lang: java

org.hamcrest:
hamcrest-all:
version: "1.3"
Expand Down
1 change: 0 additions & 1 deletion server/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,6 @@ java_library(
"//dependencies/maven/artifacts/ch/qos/logback:logback-core",
"//dependencies/maven/artifacts/io/grpc:grpc-netty",
"//dependencies/maven/artifacts/javax/servlet:javax-servlet-api", # PREVIOUSLY UNDECLARED
"//dependencies/maven/artifacts/org/codehaus/janino:janino",
],
resources = ["LICENSE"] + glob(["resources/*"]),
resource_strip_prefix = "server",
Expand Down
12 changes: 1 addition & 11 deletions server/conf/logback.xml
Original file line number Diff line number Diff line change
Expand Up @@ -22,18 +22,8 @@

<!--Configure a properties file (located on the classpath) from which values can be referenced-->
<property resource="grakn.properties"/>
<property name="configuredLogDir" value="${log.dirs}" />

<!--Extract the directory of the grakn logs from the properties file. If the path is relative it
will be appended to the directory containing grakn (system property grakn.dir). Otherwise the absolute
path is used. -->
<if condition='property("log.dirs").startsWith("/")'>
<then>
<property name="configuredLogDir" value="${log.dirs}" />
</then>
<else>
<property name="configuredLogDir" value="${grakn.dir}/${log.dirs}" />
</else>
</if>

<!--Configure the standard out appender used to print the Grakn logo-->
<appender name="STDOUT" class="ch.qos.logback.core.ConsoleAppender">
Expand Down

0 comments on commit 335e308

Please sign in to comment.