Skip to content

Commit 1e874ae

Browse files
author
Haik Asatryan
committed
.net 9 upgrade
1 parent dc31985 commit 1e874ae

File tree

95 files changed

+357
-2174
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

95 files changed

+357
-2174
lines changed

.gitignore

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -480,4 +480,5 @@ $RECYCLE.BIN/
480480
# Added by me
481481
.idea
482482
logs
483-
LocalFileStorage
483+
LocalFileStorage
484+
*.db*

Directory.Build.props

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<Project>
22
<PropertyGroup>
33
<TreatWarningsAsErrors>false</TreatWarningsAsErrors>
4-
<TargetFramework>net8.0</TargetFramework>
4+
<TargetFramework>net9.0</TargetFramework>
55
<Nullable>enable</Nullable>
66
<ImplicitUsings>enable</ImplicitUsings>
77
</PropertyGroup>

Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
FROM mcr.microsoft.com/dotnet/aspnet:8.0 AS base
1+
FROM mcr.microsoft.com/dotnet/aspnet:9.0 AS base
22
WORKDIR /app
33
COPY ["./publish/", "./"]
44
ENTRYPOINT ["dotnet", "Pandatech.ModularMonolith.dll"]

Dockerfile.Local

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
1-
FROM mcr.microsoft.com/dotnet/aspnet:8.0 AS base
1+
FROM mcr.microsoft.com/dotnet/aspnet:9.0 AS base
22
USER $APP_UID
33
WORKDIR /app
44
EXPOSE 80
55

6-
FROM mcr.microsoft.com/dotnet/sdk:8.0 AS build
6+
FROM mcr.microsoft.com/dotnet/sdk:9.0 AS build
77
ARG BUILD_CONFIGURATION=Release
88
WORKDIR /build
99
COPY ["Directory.Build.props", "."]

docker-compose.yml

Lines changed: 85 additions & 140 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
version: '3.8'
2-
31
volumes:
42
# elasticsearch:
53
# driver: local
@@ -44,68 +42,76 @@ services:
4442
volumes:
4543
- ~/.aspnet/https:/https:ro
4644

47-
#####################################################################################
48-
49-
# elasticsearch:
50-
# container_name: finhub_elasticsearch
51-
# image: docker.elastic.co/elasticsearch/elasticsearch:8.12.2
52-
# restart: always
53-
# ports:
54-
# - 9200:9200
55-
# environment:
56-
# - bootstrap.memory_lock=true
57-
# - discovery.type=single-node
58-
# - xpack.security.enabled=false
59-
# - xpack.security.http.ssl.enabled=false
60-
# - xpack.security.transport.ssl.enabled=false
61-
# ulimits:
62-
# memlock:
63-
# soft: -1
64-
# hard: -1
65-
# volumes:
66-
# - elasticsearch:/usr/share/elasticsearch/data
67-
# healthcheck:
68-
# test: ["CMD-SHELL", "curl --silent --fail localhost:9200/_cluster/health || exit 1"]
69-
# interval: 30s
70-
# timeout: 10s
71-
# retries: 5
72-
73-
#################################################################################
45+
# ---------------------------------------------------------------------------------
46+
# Elastic search
47+
# ---------------------------------------------------------------------------------
7448

75-
# kibana:
76-
# depends_on:
77-
# elasticsearch:
78-
# condition: service_healthy
79-
# container_name: finhub_kibana
80-
# image: docker.elastic.co/kibana/kibana:8.12.2
81-
# restart: always
82-
# ports:
83-
# - 5601:5601
84-
# environment:
85-
# - ELASTICSEARCH_HOSTS=http://elasticsearch:9200
86-
# volumes:
87-
# - kibana:/usr/share/kibana/data
49+
# elasticsearch:
50+
# container_name: elasticsearch
51+
# image: docker.elastic.co/elasticsearch/elasticsearch:8.16.1
52+
# restart: always
53+
# ports:
54+
# - 9200:9200
55+
# environment:
56+
# - bootstrap.memory_lock=true
57+
# - discovery.type=single-node
58+
# - xpack.security.enabled=false
59+
# - xpack.security.http.ssl.enabled=false
60+
# - xpack.security.transport.ssl.enabled=false
61+
# ulimits:
62+
# memlock:
63+
# soft: -1
64+
# hard: -1
65+
# volumes:
66+
# - elasticsearch:/usr/share/elasticsearch/data
67+
# healthcheck:
68+
# test: [ "CMD-SHELL", "curl --silent --fail localhost:9200/_cluster/health || exit 1" ]
69+
# interval: 30s
70+
# timeout: 10s
71+
# retries: 5
72+
73+
# ---------------------------------------------------------------------------------
74+
# Kibana
75+
# ---------------------------------------------------------------------------------
8876

89-
################################a###################################################
77+
# kibana:
78+
# depends_on:
79+
# elasticsearch:
80+
# condition: service_healthy
81+
# container_name: kibana
82+
# image: docker.elastic.co/kibana/kibana:8.16.1
83+
# restart: always
84+
# ports:
85+
# - 5601:5601
86+
# environment:
87+
# - ELASTICSEARCH_HOSTS=http://elasticsearch:9200
88+
# volumes:
89+
# - kibana:/usr/share/kibana/data
9090

91+
# ---------------------------------------------------------------------------------
92+
# PgAdmin
93+
# ---------------------------------------------------------------------------------
94+
9195
# pg-admin:
92-
# container_name: finhub_pg_admin
93-
# image: dpage/pgadmin4:8.4
96+
# container_name: pg_admin
97+
# image: dpage/pgadmin4:latest
9498
# restart: always
9599
# ports:
96100
# - "5050:80"
97-
# #in pgAdmin set Host name/address to host.docker.internal
101+
# #in pgAdmin set Host name/address to host.docker.internal or postgres_db in linux
98102
# environment:
99103
# - PGADMIN_DEFAULT_EMAIL=test@pandatech.it
100104
# - PGADMIN_DEFAULT_PASSWORD=test
101105
# volumes:
102106
# - pgadmin:/var/lib/pgadmin
103-
104-
###################################################################################
105-
107+
108+
# ---------------------------------------------------------------------------------
109+
# RabbitMQ
110+
# ---------------------------------------------------------------------------------
111+
106112
rabbitmq:
107-
container_name: finhub_rabbitmq
108-
image: rabbitmq:3.13.0-management-alpine
113+
container_name: rabbitmq
114+
image: rabbitmq:4-management-alpine
109115
restart: always
110116
ports:
111117
- "5672:5672"
@@ -115,106 +121,45 @@ services:
115121
RABBITMQ_DEFAULT_PASS: test
116122
volumes:
117123
- rabbitmq:/var/lib/rabbitmq
118-
119-
###################################################################################
120-
124+
125+
# ---------------------------------------------------------------------------------
126+
# Redis
127+
# ---------------------------------------------------------------------------------
128+
121129
redis:
122-
container_name: finhub_redis
123-
image: redis:7.2.4
130+
container_name: redis
131+
image: redis:latest
124132
restart: always
125133
ports:
126134
- "6379:6379"
127135
volumes:
128136
- redis:/data
129-
130-
###################################################################################
131-
132-
redisinsight:
133-
container_name: finhub_redisinsight
134-
image: redislabs/redisinsight:1.14.0
135-
restart: always
136-
ports:
137-
- "8001:8001"
138-
volumes:
139-
- redisinsight:/db
140-
141-
###################################################################################
142-
137+
138+
# ---------------------------------------------------------------------------------
139+
# Redis Insight
140+
# ---------------------------------------------------------------------------------
141+
142+
# redisinsight:
143+
# container_name: redisinsight
144+
# image: redis/redisinsight:latest
145+
# restart: always
146+
# ports:
147+
# - "5540:5540"
148+
# volumes:
149+
# - redisinsight:/db
150+
151+
# ---------------------------------------------------------------------------------
152+
# Postgres
153+
# ---------------------------------------------------------------------------------
154+
143155
postgres_db:
144-
container_name: finhub_postgres
145-
image: postgres:16.2
156+
container_name: postgres
157+
image: postgres:latest
146158
restart: always
147159
environment:
148160
- POSTGRES_USER=test
149161
- POSTGRES_PASSWORD=test
150162
ports:
151163
- "5432:5432"
152164
volumes:
153-
- postgres:/var/lib/postgresql/data
154-
155-
#Check optimal configurations with PandaPostgres
156-
command:
157-
- "-c"
158-
- "log_connections=on"
159-
- "-c"
160-
- "log_disconnections=on"
161-
- "-c"
162-
- "log_duration=on"
163-
- "-c"
164-
- "log_line_prefix=%m [%p-%l] %u@%d app=%a "
165-
- "-c"
166-
- "log_lock_waits=on"
167-
- "-c"
168-
- "log_min_duration_statement=1s"
169-
- "-c"
170-
- "log_statement=all"
171-
- "-c"
172-
- "log_timezone=Asia/Yerevan"
173-
- "-c"
174-
- "log_temp_files=0"
175-
- "-c"
176-
- "shared_preload_libraries=pg_stat_statements"
177-
- "-c"
178-
- "track_commit_timestamp=on"
179-
- "-c"
180-
- "track_functions=pl"
181-
- "-c"
182-
- "track_io_timing=on"
183-
- "-c"
184-
- "hot_standby_feedback=on"
185-
- "-c"
186-
- "TimeZone=Asia/Yerevan"
187-
- "-c"
188-
- "effective_io_concurrency=200"
189-
- "-c"
190-
- "cpu_tuple_cost=0.03"
191-
- "-c"
192-
- "random_page_cost=1.1"
193-
- "-c"
194-
- "max_connections=24"
195-
- "-c"
196-
- "idle_in_transaction_session_timeout=5min"
197-
- "-c"
198-
- "max_locks_per_transaction=128"
199-
- "-c"
200-
- "synchronous_commit=off"
201-
- "-c"
202-
- "default_transaction_read_only=off"
203-
- "-c"
204-
- "transaction_read_only=off"
205-
- "-c"
206-
- "archive_mode=on"
207-
- "-c"
208-
- "checkpoint_timeout=15min"
209-
- "-c"
210-
- "checkpoint_completion_target=0.9"
211-
- "-c"
212-
- "max_wal_senders=64"
213-
- "-c"
214-
- "wal_buffers=-1"
215-
- "-c"
216-
- "wal_compression=on"
217-
- "-c"
218-
- "wal_level=logical"
219-
- "-c"
220-
- "wal_log_hints=on"
165+
- postgres:/var/lib/postgresql/data

global.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"sdk": {
3-
"version": "8.0.200",
4-
"rollForward": "latestMajor"
3+
"version": "9.0.100",
4+
"rollForward": "latestMinor"
55
}
66
}
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
namespace Pandatech.ModularMonolith.ApiGateway;
2+
3+
public struct AssemblyReference;

src/Pandatech.ModularMonolith.ApiGateway/Configurations/Options/SwaggerOptions.cs

Lines changed: 0 additions & 6 deletions
This file was deleted.

src/Pandatech.ModularMonolith.ApiGateway/Configurations/Options/SwaggerVersionOptions.cs

Lines changed: 0 additions & 10 deletions
This file was deleted.

0 commit comments

Comments
 (0)