Skip to content

Commit 6543746

Browse files
authored
Merge pull request #342 from Accenture/341-support-otp23
341 support otp23
2 parents f1b627d + d8e86ad commit 6543746

File tree

34 files changed

+130
-127
lines changed

34 files changed

+130
-127
lines changed

.gitignore

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,3 @@ erl_crash.dump
3939
/.elixir_ls/
4040
*~
4141
*.orig
42-
43-
# asdf
44-
.tool-versions

.tool-versions

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
erlang 23.1.2
2+
elixir 1.11.2-otp-23

.travis.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,8 @@ stages:
1212

1313
.elixir-env: &elixir-env
1414
language: elixir
15-
elixir: "1.10"
16-
otp_release: "22.0"
15+
elixir: "1.11"
16+
otp_release: "23.0"
1717

1818
jobs:
1919
include:

CHANGELOG.md

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
3131
helm repo add accenture https://accenture.github.io/reactive-interaction-gateway
3232
helm install rig accenture/reactive-interaction-gateway
3333
```
34-
34+
3535
More information, follow the [deployment Readme](./deployment/README.md). [#319](https://github.com/Accenture/reactive-interaction-gateway/issues/319)
3636
- make README smaller, easier to read and highlight features. [#284](https://github.com/Accenture/reactive-interaction-gateway/issues/284)
3737

@@ -55,7 +55,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
5555

5656
<!-- ### Security -->
5757

58-
<!-- ### Technical Improvements -->
58+
### Technical Improvements
59+
60+
- Updated dependencies to support OTP 23. We've also replaced the versions file with `.tool-versions`, which makes it easier for those using the [asdf package manager](https://asdf-vm.com/) - just run `asdf install` to obtain the correct versions of Erlang and Elixir.
61+
[#341](https://github.com/Accenture/reactive-interaction-gateway/issues/341)
5962
6063
## [2.4.0] - 2020-05-07
6164

Dockerfile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,15 @@
1-
FROM elixir:1.10-alpine as build
1+
FROM elixir:1.11-alpine as build
22

33
# Install Elixir & Erlang environment dependencies
44
RUN apk add --no-cache make gcc g++
5+
COPY .tool-versions /opt/sites/rig/
56
RUN mix local.hex --force
67
RUN mix local.rebar --force
78

89
ENV MIX_ENV=prod
910
WORKDIR /opt/sites/rig
1011

1112
# Copy release config
12-
COPY version /opt/sites/rig/
1313
COPY rel /opt/sites/rig/rel/
1414
COPY vm.args /opt/sites/rig/
1515

@@ -28,7 +28,7 @@ COPY lib /opt/sites/rig/lib
2828
RUN mix compile
2929
RUN mix distillery.release
3030

31-
FROM erlang:22-alpine
31+
FROM erlang:23-alpine
3232

3333
LABEL org.label-schema.name="Reactive Interaction Gateway"
3434
LABEL org.label-schema.description="Reactive API Gateway and Event Hub"

aws.dockerfile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,18 +7,18 @@ WORKDIR /opt/sites/rig/kinesis-client
77
# Compile AWS Kinesis Java application
88
RUN mvn package
99

10-
FROM elixir:1.10-alpine as elixir-build
10+
FROM elixir:1.11-alpine as elixir-build
1111

1212
# Install Elixir & Erlang environment dependencies
1313
RUN apk add --no-cache make gcc g++
14+
COPY .tool-versions /opt/sites/rig/
1415
RUN mix local.hex --force
1516
RUN mix local.rebar --force
1617

1718
ENV MIX_ENV=prod
1819
WORKDIR /opt/sites/rig
1920

2021
# Copy release config
21-
COPY version /opt/sites/rig/
2222
COPY rel /opt/sites/rig/rel/
2323
COPY vm.args /opt/sites/rig/
2424

@@ -37,7 +37,7 @@ COPY lib /opt/sites/rig/lib
3737
RUN mix compile
3838
RUN mix distillery.release
3939

40-
FROM erlang:22-alpine
40+
FROM erlang:23-alpine
4141

4242
RUN apk add --no-cache bash
4343

config/config.exs

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -123,3 +123,9 @@ config :rig, RIG.Tracing,
123123
jaeger_service_name: {:system, :charlist, "JAEGER_SERVICE_NAME", 'rig'},
124124
zipkin_address: {:system, :charlist, "ZIPKIN_ADDR", ''},
125125
zipkin_service_name: {:system, "ZIPKIN_SERVICE_NAME", "rig"}
126+
127+
# --------------------------------------
128+
# Phoenix
129+
# ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
130+
131+
config :phoenix, :json_library, Jason

config/rig_api/config.exs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ config :rig, RigApi.Endpoint,
3737
protocol_options: cowboy_options
3838
],
3939
render_errors: [view: RigApi.ErrorView, accepts: ~w(json)],
40-
pubsub: [name: Rig.PubSub],
40+
pubsub_server: Rig.PubSub,
4141
check_origin: false
4242

4343
# Always start the HTTP endpoints on application startup:

config/rig_inbound_gateway/config.exs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ config :rig, RigInboundGatewayWeb.Endpoint,
6565
transport_options: ranch_transport_options
6666
],
6767
render_errors: [view: RigInboundGatewayWeb.ErrorView, accepts: ~w(html json xml)],
68-
pubsub: [name: Rig.PubSub],
68+
pubsub_server: Rig.PubSub,
6969
check_origin: false
7070

7171
config :mime, :types, %{

docs/rig-dev-guide.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ title: Developer's Guide to the Reactive Interaction Gateway
44
sidebar_label: Developer's Guide
55
---
66

7-
You'd like to mess with the code? Great! To get started, install Elixir and the Mix build tool on your machine. You can either follow the [instructions on the Elixir website](https://elixir-lang.org/install.html), or use [kiex](https://github.com/taylor/kiex) to install and manage Elixir runtimes. Kiex is recommended for development, because it allows you to jump to definitions inside the Elixir source code, plus you can checkout upcoming Elixir versions easily.
7+
You'd like to help hacking? Great! To get started, install Elixir and the Mix build tool on your machine. If you use [asdf](https://asdf-vm.com/), all you need to do is `asdf install`. Otherwise, either follow the [instructions on the Elixir website](https://elixir-lang.org/install.html), or use [kiex](https://github.com/taylor/kiex) to install and manage Elixir runtimes.
88

99
With Elixir installed, do this:
1010

@@ -38,11 +38,11 @@ To have the project use a newer Elixir version, make sure to change the followin
3838

3939
- `.travis.yml`: Update the Elixir and OTP versions in the `.elixir-env` section.
4040
- `Dockerfile`, `aws.dockerfile`, `smoke_tests.dockerfile`: Make sure to change the `FROM` image tag for both the build image (elixir:...-alpine) as well as the runtime image (erlang:...-alpine). If the Erlang runtime (ERTS) in the runtime image doesn't match the ERTS version in the build image, chances are the built image won't work due to missing libraries. Because of this, it's best to use the most recent versions for both images when upgrading - they should always be compatible.
41-
- `version`: Again, make sure both the Elixir and the OTP versions match what you have used in the previous steps.
41+
- `.tool-versions`: Again, make sure both the Elixir and the OTP versions match what you have used in the previous steps.
4242

4343
## Releasing a new version
4444

45-
- Increment `rig` version in the [version](../version) file
45+
- Increment `@rig_version` in [mix.exs](../mix.exs)
4646
- Increment `appVersion` in the [Helm v2 Chart.yaml](../deployment/reactive-interaction-gateway/Chart.yaml) and [Helm v3 Chart.yaml](../deployment/reactive-interaction-gateway/Chart.yaml) files
4747
- Update Helm chart README files: install [helm-docs](https://github.com/norwoodj/helm-docs) and run `helm-docs` in the root directory
4848
- Increment image tag in the [Kubernetes rig.yaml](../deployment/kubectl/rig.yaml) file

0 commit comments

Comments
 (0)