Uploaded image for project: 'MusicBrainz Search Server'
  1. MusicBrainz Search Server
  2. SEARCH-732

mb-solr `mvn package` sometimes fails with compilation error in MusicbrainzTokenizerImpl.java

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Normal Normal
    • mb-solr-next
    • None
    • Response Writer
    • None

       > [mb_solr 2/2] RUN sudo -E -H -u musicbrainz git clone --branch master --depth 1 --recursive https://github.com/metabrainz/mb-solr.git &&     cd mb-solr/mmd-schema/brainz-mmd2-jaxb &&     find src/main/java -type f -print0 | xargs -0 touch &&     mvn --batch-mode install &&     cd ../../mb-solr &&     mvn --batch-mode package -DskipTests:
      62.52 [INFO] ------------------------------------------------------------------------
      Error: ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.12.1:compile (default-compile) on project mb-solr: Compilation failure
      Error: ERROR] /home/musicbrainz/mb-solr/mb-solr/src/main/java/org/musicbrainz/search/analysis/MusicbrainzTokenizerImpl.java:[414,12] incompatible types: possible lossy conversion from long to int
      Error: ERROR] -> [Help 1]
      Error: ERROR] 
      Error: ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
      Error: ERROR] Re-run Maven using the -X switch to enable full debug logging.
      Error: ERROR] 
      Error: ERROR] For more information about the errors and possible solutions, please read the following articles:
      Error: ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException
      

      Although MusicbrainzTokenizerImpl.java is checked into the repo, it's sometimes regenerated during mvn package:

      #23 56.46 [INFO]   generated /home/musicbrainz/mb-solr/mb-solr/src/main/java/org/musicbrainz/search/analysis/MusicbrainzTokenizerImpl.java
      

      Weirdly, sometimes it's not generated (running the exact same steps while building the exact same Dockerfile):

      #23 58.25 [INFO] MusicbrainzTokenizerImpl.java is up to date.
      

      In the latter case the build does not fail.

            bitmap Michael Wiencek
            bitmap Michael Wiencek
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:

                Version Package
                mb-solr-next