2
votes

I'd like to use MarkLogic's JVM to run some custom Java code.

Using the MarkLogic JVM would dramatically reduce the infrastructure/deployment footprint.

The custom Java code that I want to run within the JVM will extract data from legacy excel spreadsheets. I will be using the Apache POI Java APIs to do this.

Apache POI Spreadsheet API => http://poi.apache.org/spreadsheet/index.html

I know that there's some undocumented ways to call the MarkLogic JVM directly. I assume this is being done for the HDFS and Amazon S3 features.

Is there a way to use the MarkLogic Java VM and if so how?

1
+1 because I would also like to know, but I suspect the answer will be an emphatic no.wst

1 Answers

1
votes

"Empathetic No"

Where "No" means that if there was such a feature that was safe, efficient, tested, and supported and guaranteed to work with with the same enterprise quality and reliability as documented features, it would be documented.

Since its not - don't do it, no matter how tempting.

Alternatively:

There is the excellent and well used public domain "MLJAM" library

http://developer.marklogic.com/learn/2006-05-mljam

And this uses 100% documented features.

You can also go the other way and start from java, query and push to ML ... the overhead can actually be minimal if you design it right. Sometimes even more efficient by splitting out the workload then by doing it all in one process or system. Take a look at the Java Client API, this can run on the same host as MarkLogic or on a different host.

-David