diff --git a/kube_files/services/graphql/service.yaml b/kube_files/services/graphql/service.yaml index 936b3cb..e4e4985 100644 --- a/kube_files/services/graphql/service.yaml +++ b/kube_files/services/graphql/service.yaml @@ -5,9 +5,9 @@ metadata: labels: io.kompose.service: graphql-engine spec: - type: ClusterIP + type: LoadBalancer ports: - - port: 8080 + - port: 8081 targetPort: 8080 protocol: TCP selector: diff --git a/shared-utils/src/postgres.rs b/shared-utils/src/postgres.rs index 9fea349..fde7aa9 100644 --- a/shared-utils/src/postgres.rs +++ b/shared-utils/src/postgres.rs @@ -4,6 +4,7 @@ use sqlx::{postgres::PgPoolOptions, PgPool}; pub async fn connect_to_db(database_url: &str) -> Result { PgPoolOptions::new() .min_connections(5) + .max_connections(20) .connect(database_url) .await .map_err(|error| LibError::PostgresConnectError(error.to_string()))