Mvn clean install dataexport

Hey community, i’ve been trying to set up OpenElis from source code. When attempting to run

mvn clean install -DskipTests

on the dataexport module I get this:

[INFO] Scanning for projects...
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Build Order:
[INFO]
[INFO] Data Export                                                        [pom]
[INFO] Data Export Core                                                   [jar]
[INFO] Data Export API                                                    [jar]
[INFO]
[INFO] ------------------------< org.itech:dataexport >------------------------
[INFO] Building Data Export 0.0.0.9                                       [1/3]
[INFO]   from pom.xml
[INFO] --------------------------------[ pom ]---------------------------------
[INFO] 
[INFO] --- clean:3.2.0:clean (default-clean) @ dataexport ---
[INFO] 
[INFO] --- install:3.1.1:install (default-install) @ dataexport ---
[INFO] Installing C:\Users\osman\OpenELIS-Global-2\dataexport\pom.xml to C:\Users\osman\.m2\repository\org\itech\dataexport\0.0.0.9\dataexport-0.0.0.9.pom
[INFO] 
[INFO] ---------------------< org.itech:dataexport-core >----------------------
[INFO] Building Data Export Core 0.0.0.9                                  [2/3]
[INFO]   from dataexport-core\pom.xml
[INFO] --------------------------------[ jar ]---------------------------------
[INFO] 
[INFO] --- clean:3.2.0:clean (default-clean) @ dataexport-core ---
[INFO] Deleting C:\Users\osman\OpenELIS-Global-2\dataexport\dataexport-core\target
[INFO] 
[INFO] --- resources:3.3.1:resources (default-resources) @ dataexport-core ---
[WARNING] Using platform encoding (UTF-8 actually) to copy filtered resources, i.e. build is platform dependent!
[INFO] skip non existing resourceDirectory C:\Users\osman\OpenELIS-Global-2\dataexport\dataexport-core\src\main\resources
[INFO]
[INFO] --- compiler:3.8.0:compile (default-compile) @ dataexport-core ---
[INFO] Changes detected - recompiling the module!
[WARNING] File encoding has not been set, using platform encoding UTF-8, i.e. build is platform dependent!
[INFO] Compiling 12 source files to C:\Users\osman\OpenELIS-Global-2\dataexport\dataexport-core\target\classes
[INFO] -------------------------------------------------------------
[ERROR] COMPILATION ERROR :
[INFO] -------------------------------------------------------------
[ERROR] /C:/Users/osman/OpenELIS-Global-2/dataexport/dataexport-core/src/main/java/org/itech/fhir/dataexport/core/service/impl/DataExportTaskServiceImpl.java:[42,124] cannot find symbol
  symbol:   method getId()
  location: variable dataExportTask of type org.itech.fhir.dataexport.core.model.DataExportTask
[ERROR] /C:/Users/osman/OpenELIS-Global-2/dataexport/dataexport-core/src/main/java/org/itech/fhir/dataexport/core/service/impl/DataExportTaskServiceImpl.java:[46,52] cannot find symbol
  symbol:   method getStartTime()
  location: variable latestAttempt of type org.itech.fhir.dataexport.core.model.DataExportAttempt
[ERROR] /C:/Users/osman/OpenELIS-Global-2/dataexport/dataexport-core/src/main/java/org/itech/fhir/dataexport/core/service/impl/DataExportTaskServiceImpl.java:[48,17] cannot find symbol
  symbol:   variable log
  location: class org.itech.fhir.dataexport.core.service.impl.DataExportTaskServiceImpl
[ERROR] /C:/Users/osman/OpenELIS-Global-2/dataexport/dataexport-core/src/main/java/org/itech/fhir/dataexport/core/service/impl/DataExportTaskServiceImpl.java:[57,115] cannot find symbol
  symbol:   method getId()
  location: variable dataExportTask of type org.itech.fhir.dataexport.core.model.DataExportTask
[ERROR] /C:/Users/osman/OpenELIS-Global-2/dataexport/dataexport-core/src/main/java/org/itech/fhir/dataexport/core/service/impl/DataExportTaskServiceImpl.java:[60,52] cannot find symbol
  symbol:   method getStartTime()
  location: variable latestAttempt of type org.itech.fhir.dataexport.core.model.DataExportAttempt
[ERROR] /C:/Users/osman/OpenELIS-Global-2/dataexport/dataexport-core/src/main/java/org/itech/fhir/dataexport/core/service/impl/DataExportTaskServiceImpl.java:[62,17] cannot find symbol
  symbol:   variable log
  location: class org.itech.fhir.dataexport.core.service.impl.DataExportTaskServiceImpl
[INFO] 6 errors
[INFO] -------------------------------------------------------------
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Summary for Data Export 0.0.0.9:
[INFO]
[INFO] Data Export ........................................ SUCCESS [  0.246 s]
[INFO] Data Export Core ................................... FAILURE [  1.844 s]
[INFO] Data Export API .................................... SKIPPED
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time:  2.185 s
[INFO] Finished at: 2025-03-25T16:15:08-05:00
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.8.0:compile (default-compile) on project dataexport-core: Compilation failure: Compilation failure:
[ERROR] /C:/Users/osman/OpenELIS-Global-2/dataexport/dataexport-core/src/main/java/org/itech/fhir/dataexport/core/service/impl/DataExportTaskServiceImpl.java:[42,124] cannot find symbol
[ERROR]   symbol:   method getId()
[ERROR]   location: variable dataExportTask of type org.itech.fhir.dataexport.core.model.DataExportTask
[ERROR] /C:/Users/osman/OpenELIS-Global-2/dataexport/dataexport-core/src/main/java/org/itech/fhir/dataexport/core/service/impl/DataExportTaskServiceImpl.java:[46,52] cannot find symbol

it seems like my dataexport module points to the most recent remote repository version:

PS C:\Users\osman\OpenELIS-Global-2\dataexport> git branch -vv
* (HEAD detached at fad9327) fad9327 update spring data

what java version are you running ??

what does mvn -v return?

PS C:\Users\osman\OpenELIS-Global-2> java -version
java version "23.0.2" 2025-01-21
Java(TM) SE Runtime Environment (build 23.0.2+7-58)                       
Java HotSpot(TM) 64-Bit Server VM (build 23.0.2+7-58, mixed mode, sharing)

PS C:\Users\osman\OpenELIS-Global-2> mvn -v
Apache Maven 3.9.6 (bc0240f3c744dd6b6ec2920b3cd08dcc295161ae)                          
Maven home: C:\Program Files\Apache Software Foundation\apache-maven                   
Java version: 23.0.2, vendor: Oracle Corporation, runtime: C:\Program Files\Java\jdk-23
Default locale: en_US, platform encoding: UTF-8                                        
OS name: "windows 10", version: "10.0", arch: "amd64", family: "windows"               
PS C:\Users\osman\OpenELIS-Global-2> 


Can you first try installing java 21 and run again ??


I have the same issue. I am also using java version 21

You can try deleting the local cache and building the app again

@mxhdiqaim I was able to find a fix

make sure both mvn -v and java -v show the following:

PS C:\Users\osman\OpenELIS-Global-2\dataexport> java -version
java version "21.0.5" 2024-10-15 LTS
Java(TM) SE Runtime Environment (build 21.0.5+9-LTS-239)
Java HotSpot(TM) 64-Bit Server VM (build 21.0.5+9-LTS-239, mixed mode, sharing)
PS C:\Users\osman\OpenELIS-Global-2\dataexport> mvn -version
Apache Maven 3.9.6 (bc0240f3c744dd6b6ec2920b3cd08dcc295161ae)
Maven home: C:\Program Files\Apache Software Foundation\apache-maven
Java version: 21.0.5, vendor: Oracle Corporation, runtime: C:\Program Files\Java\jdk-21
Default locale: en_US, platform encoding: UTF-8
OS name: "windows 10", version: "10.0", arch: "amd64", family: "windows"

in the pom file of the dataexport module, the current pom xml points to a java version of 11 and compiler release of 11, set both to 21 like so:

	<properties>
		<java.version>21</java.version>
		<maven.compiler.release>21</maven.compiler.release>
	</properties>

from here it should be able to compile with no problems

1 Like

@OsmanR Of course, I followed the steps above and it still wouldn’t compile. see below.

@mxhdiqaim from what I see, its showing “release version 11 not supported”, and since your java jdk version is 21, I can think of two more things

  1. Go to File → Project Structure… ensure that both SDK and Language Level point to ver 21, also on modules for both sources and dependencies, ensure that it shows the same, screenshots below:



  1. double check both pom xmls ( pom.xml (openelisglobal) and dataexport\pom.xml) and ensure that both are using java 21 in compilation.

For the main pom xml, ensure you have:

    <properties>
        <maven.java.release>21</maven.java.release>

the dataexport pom xml is like before

	<properties>
		<java.version>21</java.version>
		<maven.compiler.release>21</maven.compiler.release>
	</properties>
1 Like

could you just clone the repository again from your fork and again follow the readme document

I faced some setup issues. So, I cloned the repository again and followed the README instructions — everything was up and running in just a few minutes.

1 Like

great! happy codding :grin: @Dev