Skip to content

Commit

Permalink
All users to load spec from the file system (#321)
Browse files Browse the repository at this point in the history
There's no reason why the spec needs to be on the classpath - in fact I'd say it's more normal for it to be on the filesystem - so allow this as a first class citizen of the api

Co-authored-by: Andrew Coates <mktxmac-acoates@MKTXMAC-ACOATESs-MacBook-Pro.local>
  • Loading branch information
big-andy-coates and Andrew Coates authored May 13, 2024
1 parent 83e79ae commit b370cd2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion kafka/src/main/java/io/specmesh/kafka/KafkaApiSpec.java
Original file line number Diff line number Diff line change
Expand Up @@ -375,7 +375,7 @@ public static KafkaApiSpec loadFromClassPath(final String spec, final ClassLoade
* @param spec to load
* @return loaded spec
*/
private static KafkaApiSpec loadFromFileSystem(final String spec) {
public static KafkaApiSpec loadFromFileSystem(final String spec) {
try (InputStream fis = new FileInputStream(spec)) {
return new KafkaApiSpec(new AsyncApiParser().loadResource(fis));
} catch (Exception ex) {
Expand Down

0 comments on commit b370cd2

Please sign in to comment.