Skip to content

Data Services - uber type for body #1288

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

Closed
joecrean opened this issue Feb 8, 2021 · 3 comments
Closed

Data Services - uber type for body #1288

joecrean opened this issue Feb 8, 2021 · 3 comments

Comments

@joecrean
Copy link

joecrean commented Feb 8, 2021

So we can address your issue, please include the following:

Version of MarkLogic Java Client API

Java client 4.2.0 ,

Version of MarkLogic Server

ML 9-0-9.1

See admin gui on port 8001 or run xdmp:version() in Query Console - port 8000)

Java version

JDK 11

I would like to design a Data Service which can process a file of any type into ML. THe file will be passed in the request body. However it doesn't look like there is an uber type - i am required to create type specific interfaces and generate the corresponding java proxies..

Is there any generic way to do this?

@ehennum
Copy link
Contributor

ehennum commented Feb 8, 2021

Salutations, Mr Crean. You're right, Data Services doesn't have a format-agnostic document type at present.

It requires a server enhancement. There's is an RFE, which is an active candidate for 10.0-7

In the interim, one workaround is to use the textDocument or binaryDocument type and unquote the document values in the data service endpoint.

Another possibility is to use a data service with one of the pre-defined IO signatures and specify the document type during construction -- see:

https://github.com/marklogic/java-client-api/wiki/Data-Services-for-IO

Note: IO Data Services first showed up in 5.1.0 and only became fully baked in 5.3.0 -- which executes against 10.0-6

@joecrean
Copy link
Author

joecrean commented Feb 9, 2021

aaaahhh @ehennum great stuff thanks..
for the moment I only have the quoting workaround available to me .. i will give that a whirl.
thanks as always for the great help. If you want to close the ticket that is fine.. i will add a comment to report on how it all went.

@llinggit llinggit self-assigned this Apr 9, 2021
@llinggit llinggit added this to the java-client-api-NEXT milestone Apr 9, 2021
@llinggit
Copy link
Contributor

There is another issue tracking this anyDocument datatype work, which is #1296. Closing this one.

@llinggit llinggit removed their assignment Jun 10, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants