Uploaded image for project: 'Bigtop'
  1. Bigtop
  2. BIGTOP-1703

Limt override of JAVA_OPTS in install_solr.sh to cause minimal side-effects

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 1.0.0
    • Component/s: None
    • Labels:
      None

      Description

      The following line in https://github.com/apache/bigtop/blob/master/bigtop-packages/src/common/solr/install_solr.sh#L273

      1. FIXME: for some reason catalina doesn't use CATALINA_OPTS for stop action
      2. and thus doesn't know the admin port
        export JAVA_OPTS="$CATALINA_OPTS"

      appears to have been added so that "service solr-server stop" would work correctly. I see a couple of problems with this:

      1. This overwrites JAVA_OPTS even when we are not trying to stop the service (e.g. when we do a (service solr-server start" )
      2. If JAVA_OPTS is already set to something useful we will be overriding it

      I am proposing that we change it to something like

      if [ "$1" = "stop" ] ; then
      export JAVA_OPTS="$JAVA_OPTS $CATALINA_OPTS"
      fi

      so that we minimize changes to JAVA_OPTS

        Activity

        Hide
        rvg Rajendra added a comment -

        Attached a patch file

        Show
        rvg Rajendra added a comment - Attached a patch file
        Hide
        rvg Rajendra added a comment -

        Replacing with a new patch which involves a change with lesser potential for regressions

        Show
        rvg Rajendra added a comment - Replacing with a new patch which involves a change with lesser potential for regressions
        Hide
        mgrover Mark Grover added a comment -

        +1, will commit soon. Thanks Rajendra

        Show
        mgrover Mark Grover added a comment - +1, will commit soon. Thanks Rajendra
        Hide
        mgrover Mark Grover added a comment -

        Pushed. Thanks Rajendra.

        Show
        mgrover Mark Grover added a comment - Pushed. Thanks Rajendra.

          People

          • Assignee:
            rvg Rajendra
            Reporter:
            rvg Rajendra
          • Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development