Sink as stdout gives `Configured sink is not Kinesis` error

Hi everyone,

I am trying to set up snowplow collector with stdout sink, aiming to have a local stack to play with. My collector config is as

collector {
  interface = "0.0.0.0"
  port = 9045

  ssl {
    enable = false
    redirect = false
    port = 8443
  }

  p3p {
    policyRef = "/w3c/p3p.xml"
    CP = "NOI DSP COR NID PSA OUR IND COM NAV STA"
  }

  crossDomain {
    enabled = true
    domains = [ "*" ]
    secure = true
  }

  cookie {
    enabled = true
    expiration = "365 days"
    name = "sp"
    fallbackDomain = "localhost"
    domains = [

    ]
    secure = true
    httpOnly = false
    sameSite = "None"
  }

  doNotTrackCookie {
    enabled = false
    name = ""
    value = ""
  }

  cookieBounce {
    enabled = false
    name = n3pc
    fallbackNetworkUserId = ""
    forwardedProtocolHeader = "X-Forwarded-Proto"
  }

  paths {

  }

  redirectMacro {
    enabled = false
    placeholder = ""
  }

  rootResponse {
    enabled = false
    statusCode = 302
    headers = {
        Location = "",
        X-Custom = ""
    }
    body = "302, redirecting"
  }

  streams {
    good = "good_steam"
    bad = "bad_steam"

    useIpAddressAsPartitionKey = false

    sink {
      enabled = stdout
    }

    buffer {
      byteLimit = 10000
      recordLimit = 40
      timeLimit = 1000
    }
  }

  cors {
    accessControlMaxAge = 5s
  }

  prometheusMetrics {
    enabled = true
  }
}

akka {
  loglevel = DEBUG
  loggers = ["akka.event.slf4j.Slf4jLogger"]

  http.server {
    remote-address-header = on
    raw-request-uri-header = on
    parsing {
      max-uri-length = 32740
      uri-parsing-mode = relaxed
    }
  }

  ssl-config {
    debug = {
      ssl = true
    }

    keyManager = {
      stores = [
        {type = "PKCS12", classpath = false, path = "/etc/snowplow/ssl/collector.p12", password = "" }
      ]
    }

    loose {
      disableHostnameVerification = true
    }
  }
}

However, I got such an error:

Exception in thread "main" java.lang.IllegalArgumentException: Configured sink is not Kinesis
	at com.snowplowanalytics.snowplow.collectors.scalastream.KinesisCollector$.main(KinesisCollector.scala:32)
	at com.snowplowanalytics.snowplow.collectors.scalastream.KinesisCollector.main(KinesisCollector.scala)

Well I didn’t want to have a kinesis sink for now, just want a stdout sink to see what would happen.

Am I missing anything? Thanks you in advance!

1 Like

Hi,
It sounds like you might be using the scala-stream-collector-kinesis build rather than scala-stream-collector-stdout.

If you’re using the docker images, then you’ll want the version with the stdout sink: Docker Hub

2 Likes

Hi Paul,

Thanks very much!! Yeah I used snowplow/scala-stream-collector-kinesis:1.0.1 previously. Now I tried
snowplow/scala-stream-collector-stdout:1.0.1 it can work!

It’s really cool!! Thank you!!!