Gets a schema for the specified mongo collection.
Gets a schema for the specified mongo collection. It is required that the collection provides Documents.
Utilizes the $sample
aggregation operator in server versions 3.2+. Older versions take a sample of the documents directly.
Limits the amount of data sampled to improve schema inference performance.
the MongoRDD to be sampled
the schema for the collection
ReadConfig.sampleSize
ReadConfig.samplePoolSize
Gets a schema for the specified mongo collection.
Gets a schema for the specified mongo collection. It is required that the collection provides Documents.
Utilizes the $sample
aggregation operator in server versions 3.2+. Older versions take a sample of the most recent 10k documents.
the spark context
the schema for the collection