Uploaded image for project: 'Samza'
  1. Samza
  2. SAMZA-1765

Containers fail to start on YARN with Error: Main method not found in class SamzaContainer

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Blocker
    • Resolution: Information Provided
    • 0.13.0, 0.14.0, 0.14.1
    • 1.0
    • container, yarn
    • None
    • Hadoop/YARN 2.7.4

    Description

      This issue is a critical blocker as we try to upgrade to Samza's latest release 0.14.1. I have also tested versions 0.14.0 and 0.13.0, where I saw the same behavior. The version of Samza we are upgrading from is 0.11.0. 

      When I deploy a Samza app built against the new versions to YARN, I observe the following:

      Application Manager container gets launched and runs successfully.

      AM launches application containers, but the containers crash, before even samza-container-*.log is created and written to - stderr contains the following:

      openjdk version "1.8.0_161"
      OpenJDK Runtime Environment (build 1.8.0_161-b14)
      OpenJDK 64-Bit Server VM (build 25.161-b14, mixed mode)
      Error: Main method not found in class org.apache.samza.container.SamzaContainer, please define the main method as:
      public static void main(String[] args)
      or a JavaFX application class must extend javafx.application.Application

       

      Sure enough, looking at version 0.11.0, SamzaContainer.scala used to have a main method, and in newer versions it does not. Beyond that, I'm not sure where to start investigating.

      It may be worth noting that our Samza apps implement StreamTask, not the newer API of StreamApplication. There may be some straightforward change required to run apps implementing the older API on YARN, but I didn't find anything about that in the documentation.

      It may also be helpful to note that I can run Samza apps with the newer version locally via the LocalThreadJobRunner, and the run loop is successfully entered.

      Attachments

        Activity

          People

            spvenkat Shanthoosh Venkataraman
            erikaellison Erika Ellison
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: