Rename targets (#5950)

changelog_begin
changelog_end
This commit is contained in:
Shayne Fletcher 2020-05-12 16:00:15 -04:00 committed by GitHub
parent 9ff36a13cf
commit 221c6db0ae
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 31 additions and 5 deletions

View File

@ -10,8 +10,10 @@ load(
load("@build_environment//:configuration.bzl", "sdk_version")
da_scala_library(
name = "trigger-service-lib",
name = "trigger-service",
srcs = glob(["src/main/scala/**/*.scala"]),
# Uncomment this if/when the target is published to maven.
# tags = ["maven_coordinates=com.daml:trigger-service:__VERSION__"],
visibility = ["//visibility:public"],
runtime_deps = [
"@maven//:ch_qos_logback_logback_classic",
@ -46,11 +48,11 @@ da_scala_library(
)
da_scala_binary(
name = "trigger-service",
name = "trigger-service-binary",
main_class = "com.daml.lf.engine.trigger.ServiceMain",
visibility = ["//visibility:public"],
deps = [
":trigger-service-lib",
":trigger-service",
],
)
@ -60,7 +62,7 @@ da_scala_test(
data = [":test-model.dar"],
resources = glob(["src/test/resources/**/*"]),
deps = [
":trigger-service-lib",
":trigger-service",
"//bazel_tools/runfiles:scala_runfiles",
"//daml-lf/archive:daml_lf_archive_reader",
"//daml-lf/archive:daml_lf_dev_archive_java_proto",
@ -111,3 +113,5 @@ EOF
tools = ["//compiler/damlc"],
visibility = ["//visibility:public"],
)
exports_files(["release/trigger-service-logback.xml"])

View File

@ -24,10 +24,15 @@ until nc -z $LEDGER_HOST $LEDGER_PORT; do
done
echo "Connected to sandbox."
bazel run //triggers/service:trigger-service -- \
bazel run //triggers/service:trigger-service-binary -- \
--ledger-host $LEDGER_HOST --ledger-port $LEDGER_PORT --wall-clock-time &
TRIGGER_SERVICE_PID=$!
# A smoke test:
# curl -X GET \
# -H "Content-type: application/json" -H "Accept: application/json" \
# "http://localhost:8080/test"
kill_everything() {
kill $TRIGGER_SERVICE_PID || true
kill $SANDBOX_PID || true

View File

@ -0,0 +1,17 @@
<configuration>
<appender name="STDOUT" class="ch.qos.logback.core.ConsoleAppender">
<encoder>
<pattern>%d{HH:mm:ss.SSS} [%thread] %-5level %logger{36} - %msg%n</pattern>
</encoder>
</appender>
<logger name="io.netty" level="WARN">
<appender-ref ref="stderr-appender"/>
</logger>
<logger name="io.grpc.netty" level="WARN">
<appender-ref ref="stderr-appender"/>
</logger>
<root level="INFO">
<appender-ref ref="STDOUT" />
</root>
</configuration>