-
Notifications
You must be signed in to change notification settings - Fork 72
jsonPropertyGeospatialQuery stops working in MarkLogic Java API 5.3.0 #1263
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Will work with 5.3.0 tagged release and try to run optic tests to see if it reproduces this issue (looks like compile time). |
Thanks! |
Can you try with Java 1.8 u 261? |
I did a compile of
|
On the 2nd issue, marklogic-client-api/build.gradle should have jackson-dataformat-xml as a testCompile dependency instead of a compile dependency. Rebuilding with that change should solve the problem. On the 1st issue, can you show the jsonPropertyGeospatialQuery() call that triggers the error? Is it a compile time or runtime issue? While we of course try to maintain backward compatibility, it's possible that an enhancement mistakenly changed the signature of the method. I also wonder whether reverting our library to a Java 8 compilation might have invalidated the binding to our method in the compiled calling code of your application. If that wild speculation is correct, recompiling your application would make the issue go away. |
Interesting point..
|
The only solution for the 2nd issue, seems to me, is to either remove the Apache Spark or use the updated version +
I can revert to v5.2.0 only for this project. But I would like to upgrade other projects to v5.3.0 whenever it is tenable... |
For what it's worth, we've found that Spark doesn't upgrade dependencies very rapidly (including some dependencies with known security vulnerabilities). To use more recent versions of dependencies than Spark, we've used shadow jars sometimes known as shading. Here's a blog post that discusses that approach: https://imperceptiblethoughts.com/shadow/introduction/ On the Optic issue, thanks for providing the call, which made it possible to identify the problem, which is that the return type of box() changed from CtsBoxExpr (which derives from the CtsRegionExpr expected by the jsonPropertyGeospatialQuery() method) to ServerExpression. Unfortunately, it doesn't look like casting could provide an interim workaround while we look into the cause and assess the extent of the issue. |
Fair enough... |
Have decided to run Optic tests against previous release (or master branch) to track down these kind of issues. The time to run this verification will be around release time. |
Noting for the sake of a record trail that this commit introduced the Optic issue: |
Also noting for the sake of a record trail that Subversion commit 324540 under internal bug 52654 modified the optic-defs.json That's consistent with the fact that I've only found significant signature changes on the return types of methods constructing region values and in the removal of the sequence constructors for such values. By contrast, the return type on constructors for period values haven't changed and the sequence constructor for period values is still provided. |
Can you not just rollback the |
The bug was a side effect of an incorrectly implemented enhancement, so we need to figure out the correct implementation so we can restore backward compatibility without regressing on the other parts of the enhancement. |
Jolly good... |
FYI, the 5.3.1 release with the fixes for both of these issues has been published to Maven Central. |
Nice going! Both Maven and Gradle bear well. |
@chenfiona , thanks for confirming the point release (and reporting the original issue). @georgeajit , I've checked in the more strategic fix for the next major release. |
Not sure how the Git labels went haywire. |
cts.jsonPropertyGeospatialQuery
JAVA Optic was invalidated:The method jsonPropertyGeospatialQuery(String, CtsRegionExpr...) in the type CtsExpr is not applicable for the arguments (String, ServerExpression)
import javax.xml.stream.XMLEventReader; import javax.xml.stream.XMLStreamException; import javax.xml.stream.XMLStreamReader;
System throws error:
The package javax.xml.stream is accessible from more than one module: <unnamed>, java.xml
The text was updated successfully, but these errors were encountered: