Uploaded image for project: 'Solr'
  1. Solr
  2. SOLR-9168

Add availability to specify own oom handing script

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Open
    • Major
    • Resolution: Unresolved
    • 5.5.1
    • main (10.0)
    • scripts and tools

    Description

      Right now the start script always uses $SOLR_TIP/bin/oom_solr.sh to handle OutOfMemoryException. This script only kills instance of solr.

      We need to do some additional things (e.g sent mail about this exception)

      What do you think about adding possibility to set up own script?

      Proposition:

      if [ -z "$SOLR_OOM_SCRIPT" ]; then
        SOLR_OOM_SCRIPT=$SOLR_TIP/bin/oom_solr.sh 
      fi
      
      [...]
      
      nohup "$JAVA" "${SOLR_START_OPTS[@]}" $SOLR_ADDL_ARGS \
      	"-XX:OnOutOfMemoryError=$SOLR_OOM_SCRIPT $SOLR_PORT $SOLR_LOGS_DIR" \
              -jar start.jar "${SOLR_JETTY_CONFIG[@]}" \
      	1>"$SOLR_LOGS_DIR/solr-$SOLR_PORT-console.log" 2>&1 & echo $! > "$SOLR_PID_DIR/solr-$SOLR_PORT.pid"
      

      Attachments

        1. 0001-SOLR-9168-Allow-users-to-specify-their-own-OnOutOfMe.patch
          1 kB
          Tyler Lubeck
        2. SOLR-9168.patch
          0.1 kB
          Tyler Lubeck
        3. SOLR-9168-userdefined.patch
          3 kB
          Shawn Heisey
        4. solr-crash-oom.patch
          3 kB
          Shawn Heisey
        5. SOLR-9168-1.patch
          5 kB
          Shawn Heisey
        6. SOLR-9168-2.patch
          5 kB
          Shawn Heisey
        7. SOLR-9168-3.patch
          5 kB
          Shawn Heisey

        Issue Links

          Activity

            People

              Unassigned Unassigned
              angry_dev AngryDeveloper
              Votes:
              0 Vote for this issue
              Watchers:
              7 Start watching this issue

              Dates

                Created:
                Updated: