jsonschema2pojo icon indicating copy to clipboard operation
jsonschema2pojo copied to clipboard

How can I disable path evaluation?

Open yeikel opened this issue 1 year ago • 0 comments

Starting with 1.1.2, I am seeing the following error:

Execution default of goal org.jsonschema2pojo:jsonschema2pojo-maven-plugin:1.1.2:generate failed: Path not present: $%7BRFC_NUMBER%7D

Example:

"variables": {
    "${RFC_NUMBER}": "",
}

In this case, the variable ${RFC_NUMBER}" is a literal and there is no need to evaluate it

Configuration


<plugin>
                <groupId>org.jsonschema2pojo</groupId>
                <artifactId>jsonschema2pojo-maven-plugin</artifactId>
                <version>1.1.2</version>
                <configuration>
                    <sourceDirectory>${basedir}/src/main/resources/schema/</sourceDirectory>
                    <targetPackage>com.models</targetPackage>
                    <sourceType>json</sourceType>
                    <annotationStyle>gson</annotationStyle>
                </configuration>
                <executions>
                    <execution>
                        <goals>
                            <goal>generate</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>

The same code works as is in 1.1.1

yeikel avatar Sep 17 '22 22:09 yeikel