arakelian / java-jq

Lightweight Java wrapper around JQ, a flexible JSON processor available for multiple platforms
MIT License
82 stars 10 forks source link

Support Windows amd64 architecture #26

Open timothygruetzner opened 6 months ago

timothygruetzner commented 6 months ago

Hi

For me, executing a JqRequest fails for the amd64 on Windows:

java.lang.IllegalStateException: Unsupported architecture: windows 11:amd64
        at com.arakelian.jq.NativeLib.getPath(NativeLib.java:154)
        at com.arakelian.jq.ImmutableNativeLib.access$1001(ImmutableNativeLib.java:31)
        at com.arakelian.jq.ImmutableNativeLib$InitShim.getPath(ImmutableNativeLib.java:144)

I'm using the library according to the documentation:

JqRequest request = ImmutableJqRequest.builder()
            .lib(jq)
            .input(payload)
            .filter(".data.result[] | .metric.instance +\": \"+ .value[1]")
            .build();

Judging from NativeLib.getPath() it seems like amd64 is not supported for Windows, only x86.

Any chance to get a native implementation for my system?