TEIV: topology containers exit while populating the db 21/14121/2
authorJvD_Ericsson <jeff.van.dam@est.tech>
Tue, 28 Jan 2025 17:01:39 +0000 (17:01 +0000)
committerJEFF VAN DAM <jeff.van.dam@est.tech>
Wed, 29 Jan 2025 13:17:20 +0000 (13:17 +0000)
Issue-ID: SMO-173
Change-Id: I17d2ffc0ea5560c15fb8dc2983af178ccad813ff
Signed-off-by: JvD_Ericsson <jeff.van.dam@est.tech>
docker-compose/README.md
docker-compose/docker-compose.yml

index 8133e63..25df193 100644 (file)
@@ -1,6 +1,6 @@
 # TEIV docker-compose
 
-The all the files in this directory should have everything you need to run TEIV with the default sql schemas or with
+All the files in this directory should have everything you need to run TEIV with the default sql schemas or with
 your own custom schemas generated from you own YANG files.
 
 The docker-compose.yml file in its default state is set up to run TEIV with the default sql schemas generated from the
@@ -29,6 +29,10 @@ may start and run:
 - **pgsql-schema-generator** - an optional service that allows the user to supply their own YANG files to create their
   own SQL schemas
 
+**NB:** There can be an issue where topology-ingestion-inventory and topology-exposure-inventory try to connect to
+dbpostgresql before dbpostgresql is accepting connections as reported at https://lf-o-ran-sc.atlassian.net/browse/SMO-173.
+To fix this uncomment the "command" block under topology-exposure-inventory and topology-ingestion-inventory
+
 ## Running with default sql schemas
 
 Running with the default sql schemas provided by TEIV you should just run ``docker-compose up`` without any
index d8b149c..ae9b20a 100644 (file)
@@ -56,7 +56,7 @@ services:
       - topology-ingestion-inventory
       - kafka
     restart: "no"
-    entrypoint: [ "/bin/bash", "-c", "sleep 30 && bash /cloudEventProducer.sh" ]
+    entrypoint: [ "/bin/bash", "-c", "sleep 45 && bash /cloudEventProducer.sh" ]
 
   dbpostgresql:
     container_name: dbpostgresql
@@ -93,6 +93,8 @@ services:
 #      JAVA_TOOL_OPTIONS: -agentlib:jdwp=transport=dt_socket,server=y,suspend=n,address=*:5005
     depends_on:
       - dbpostgresql
+#    Uncomment the following line if topology-exposure-inventory is trying to connect to dbpostgresql before it is ready
+#    command: ["/bin/sh", "-c", "sleep 30 && java -jar topology-exposure-inventory-app.jar"]
     deploy:
       resources:
         reservations:
@@ -107,6 +109,8 @@ services:
     image: o-ran-sc/smo-teiv-ingestion:latest
     depends_on:
       - dbpostgresql
+#    Uncomment the following line if topology-ingestion-inventory is trying to connect to dbpostgresql before it is ready
+#    command: ["/bin/sh", "-c", "sleep 30 && java -jar topology-exposure-inventory-app.jar"]
     deploy:
       resources:
         reservations: