public class MongoSession extends AbstractMongoSession
A org.grails.datastore.mapping.core.Session implementation for the Mongo document store.
Fields inherited from class | Fields |
---|---|
class AbstractMongoSession |
MONGO_SET_OPERATOR, MONGO_UNSET_OPERATOR, declaredWriteConcerns, defaultDatabase, errorOccured, mongoCollections, mongoDatabases, mongoDatastore, writeConcern |
Constructor and description |
---|
MongoSession(MongoDatastore datastore, org.grails.datastore.mapping.model.MappingContext mappingContext, org.springframework.context.ApplicationEventPublisher publisher) |
MongoSession(MongoDatastore datastore, org.grails.datastore.mapping.model.MappingContext mappingContext, org.springframework.context.ApplicationEventPublisher publisher, boolean stateless) |
Type Params | Return Type | Name and description |
---|---|---|
|
protected org.grails.datastore.mapping.transactions.Transaction<com.mongodb.client.MongoClient> |
beginTransactionInternal() |
|
protected void |
cacheEntry(java.io.Serializable key, java.lang.Object entry, java.util.Map<java.io.Serializable, java.lang.Object> entryCache, boolean forDirtyCheck) |
|
protected org.grails.datastore.mapping.engine.Persister |
createPersister(java.lang.Class cls, org.grails.datastore.mapping.model.MappingContext mappingContext) |
|
public org.grails.datastore.mapping.query.Query |
createQuery(java.lang.Class type) |
|
protected org.bson.Document |
createSetAndUnsetDoc(org.bson.Document updateDoc) |
|
public java.lang.Object |
decode(java.lang.Class type, java.lang.Object nativeObject) |
|
public void |
delete(java.lang.Iterable objects) |
|
public long |
deleteAll(org.grails.datastore.mapping.query.api.QueryableCriteria criteria) |
|
public void |
disconnect() |
|
public void |
flush(com.mongodb.WriteConcern writeConcern) |
|
protected void |
flushPendingUpdates(java.util.Map<org.grails.datastore.mapping.model.PersistentEntity, java.util.Collection<org.grails.datastore.mapping.core.impl.PendingUpdate>> updates) |
|
protected java.util.Map<org.grails.datastore.mapping.model.PersistentEntity, java.util.List> |
getDeleteMap(java.lang.Iterable objects) |
|
protected java.util.List<com.mongodb.client.model.WriteModel<org.bson.Document>> |
getWriteModelsForEntity(org.grails.datastore.mapping.model.PersistentEntity persistentEntity, java.util.Map<org.grails.datastore.mapping.model.PersistentEntity, java.util.List<com.mongodb.client.model.WriteModel<org.bson.Document>>> writeModels) |
|
public void |
run() |
|
public long |
updateAll(org.grails.datastore.mapping.query.api.QueryableCriteria criteria, java.util.Map<java.lang.String, java.lang.Object> properties) |
Methods inherited from class | Name |
---|---|
class AbstractMongoSession |
addPostFlushOperations, decode, flush, flush, getCollection, getCollectionName, getDatabase, getDatastore, getDeclaredWriteConcern, getDefaultDatabase, getDocumentMappingContext, getMappingContext, getNativeInterface, getWriteConcern, hasTransaction, setWriteConcern, useCollection, useDatabase |