I put a file to be read into my resources folder
src
|_main
|_resources
|_graphqls
|_test.graphqls
The following snippet reads the file
final String pathToSchemaFile = this.getClass().getClassLoader().getResource("graphqls/test.graphqls").getFile();
final File = new File(pathToSchemaFile);
this is the result I get when I evaluate the File object returned by .getFile() from the preceding snippet.
file:\C:\maven_repository\com\...\app.jar!\graphqls\test.graphqls

When running the following code new FileReader(file) this exception is being thrown
Method threw 'java.io.FileNotFoundException' exception.
file:\C:\maven_repository\com\...\app.jar!\graphqls\test.graphqls (The filename, directory name, or volume label syntax is incorrect)
java.io.FileNotFoundException: file:\C:\maven_repository\com\...\app.jar.jar!\graphqls\test.graphqls (The filename, directory name, or volume label syntax is incorrect)
line 40