Zeebe gateway CustomTenantInterceptor not getting picked

Hi,
I am using Zeebe 8.5.0-alpha1 using an embedded gateway on a local docker setup.
I have followed the documentation for Interceptor, but my interceptor jar is not getting picked up at all. i don’t see any log indicating as such, and when I try to specific tenant id, it doesn’t deploy.
Below is my zeebe application.yaml change


zeebe:
  broker:
    multitenancy:
      enabled: true
    gateway:
      enable: true
      multitenancy:
        enabled: true
      interceptors:
        id: IdentityInterceptor
        className: com.example.TenantProvidingInterceptor
        jarPath: /tmp/ZeebeInterceptor-1.0-SNAPSHOT.jar

I even tried providing jar config in docker file

  zeebe: # https://docs.camunda.io/docs/self-managed/platform-deployment/docker/#zeebe
    image: camunda/zeebe:${CAMUNDA_PLATFORM_VERSION}
    container_name: zeebe
    ports:
      - "26500:26500"
      - "9600:9600"
      - "8088:8080"
    environment: # https://docs.camunda.io/docs/self-managed/zeebe-deployment/configuration/environment-variables/
      - ZEEBE_BROKER_EXPORTERS_ELASTICSEARCH_CLASSNAME=io.camunda.zeebe.exporter.ElasticsearchExporter
      - ZEEBE_BROKER_EXPORTERS_ELASTICSEARCH_ARGS_URL=http://elasticsearch:9200
      - ZEEBE_BROKER_GATEWAY_MULTITENANCY_ENABLED=true
      - ZEEBE_GATEWAY_SECURITY_AUTHENTICATION_MODE=none
      # default is 1000, see here: https://github.com/camunda/zeebe/blob/fceefef401e3b5583ad4725f81f612ccec499cb0/exporters/elasticsearch-exporter/src/main/java/io/camunda/zeebe/exporter/ElasticsearchExporterConfiguration.java#L259
      - ZEEBE_BROKER_EXPORTERS_ELASTICSEARCH_ARGS_BULK_SIZE=1
      - ZEEBE_BROKER_GATEWAY_ENABLE=true
      - ZEEBE_GATEWAY_INTERCEPTORS_0_ID=IdentityInterceptor
      - ZEEBE_GATEWAY_INTERCEPTORS_0_JARPATH=/tmp/ZeebeExporter-1.0-SNAPSHOT.jar
      - ZEEBE_GATEWAY_INTERCEPTORS_0_CLASSNAME=com.example.TenantProvidingInterceptor
      - "JAVA_TOOL_OPTIONS=-Xms512m -Xmx512m -Dorg.slf4j.simpleLogger.defaultLogLevel=DEBUG"
      - "ZEEBE_LOG_LEVEL=trace"
      - "ZEEBE_DEBUG=true"

But nothing seems to help, can someone point out what I am doing wrong.

I’m not seeing anything in your Docker config that shows that you’ve added the jar to the system.

Remember Docker is its own virtual machine, with its own IP, Network, and Filesystem. If you want to use something inside a Docker session, you have to add it into the docker filesystem.

I do have above properties specified. and the jar path is added to the docker container at /tmp/

That’s just the configuration, telling Zeebe where to find the Jar file.
I still don’t see anything where you’re actually putting the Jar file into the Docker image. Usually this is a set of VOLUME lines…

Okay, that i didnt specify in docker, because I had manually copied the jar at the location

Finally found the issue: The right config to be done is


      - "ZEEBE_BROKER_GATEWAY_INTERCEPTORS_0_CLASSNAME=com.informatica.ZeebeTenantInterceptor"
      - "ZEEBE_BROKER_GATEWAY_INTERCEPTORS_0_JARPATH=/usr/local/zeebe/lib/zeebe-tenant-interceptor-1.0-SNAPSHOT.jar"

I was earlier configuring ZEEBE_GATEWAY_INTERCEPTORS

1 Like

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.