This sample demonstrates how to send online prediction requests to your deployed model on CMLE. Follow the tutorial to deploy your model first.
This sample is using the Application Default Credential. You can install the Google Cloud SDK and run:
gcloud auth application-default login
Modify the OnlinePredictionSample.java with your project/model/version information.
Compile the sample code using Maven by running the following command:
mvn compile
Execute the sample code using Maven by running the following command:
mvn -q exec:java