Iglu server connection issue

Hello,

We have deployed Snowplow on AWS using secure Terraform modules. Target database is Databricks.
When we send test events from Snowplow site, we can see data in the cluster.
However, when we try to send events using our custom schemas, no data reaches the database. All default schemas and all of our custom schemas were pushed to our Iglu registry.
In the logs we can see messages like this

rg.http4s.client.ConnectionFailure: Error connecting to [http://localhost](http://localhost) using address localhost:80 (unresolved: false)

What could be the issue in our case?

Hi @cealkate it looks like your Iglu Resolver is pointing to “localhost:80” which unless your Iglu Server is running on the same VM as the other applications in your pipeline won’t be possible to connect to.

You will need to update your Iglu Resolver to point to your deployed Iglu Server connection endpoint (the load balancer).

Thanks for the reply. We checked the configuration of the resolver and the value for its uri variable comes from the load balancer DNS record, it’s not localhost.
The right value is also in the DynamoDB table sp-prod-enrich-server-config.

Hi @cealkate do you mind sharing your Terraform variables file to help you in debugging this?

Hello,
The variables file might not be very useful, since it doesn’t contain values. We split the deployment in modules. I can share those parts that involve Iglu resolver.
Here is the part of main.tf file for the pipeline that describes resolvers

custom_iglu_resolvers = [
    {
      name            = "Iglu Server"
      priority        = 0
      uri             = "${var.iglu_server_dns_name}/api"
      api_key         = var.iglu_super_api_key
      vendor_prefixes = []
    }
  ]

Variable iglu_server_dns_name is described like this in the main.tf of the general deployment

iglu_server_dns_name  = aws_route53_record.iglu-dns.name

Here is the aws_route53_record resource:

resource "aws_route53_record" "iglu-dns" {
  zone_id = aws_route53_zone.primary.zone_id
  name    = var.iglu_dns_name
  type    = var.dns_type
  ttl     = var.dns_ttl

  records = [module.iglu_server_production.iglu_server_dns_name]
}

Hi @cealkate I think you might be missing a prefix from that record in the custom_iglu_resolvers portion (like http://).

You’ll note that in the default vars file we ask for the DNS name after a default http:// prefix.

Cannot confirm without seeing the resultant Iglu Resolver file but this could potentially be the issue!

Thank you, adding http:// prefix solved it!

1 Like