{ errmsg: \"exception: aggregation result exceeds maximum document size (16MB)\", code: 16389, ok: 0.0 }"} |
});
org.springframework.dao.InvalidDataAccessApiUsageException: Command execution failed: Error [exception: Exceeded memory limit for $group, but didn't allow external sort. Pass allowDiskUse:true to opt in.], Command = { "aggregate" : "tempCol" , "pipeline" : ...}; nested exception is com.mongodb.CommandResult$CommandFailure: command failed [command failed [aggregate] { "serverUsed" : "127.0.0.1:27017" , "errmsg" : "exception: Exceeded memory limit for $group, but didn't allow external sort. Pass allowDiskUse:true to opt in." , "code" : 16945 , "ok" : 0.0} |
mongos> db.tempCol.aggregate(...) assert: command failed: { "errmsg" : "exception: Exceeded memory limit for $group, but didn't allow external sort. Pass allowDiskUse:true to opt in.", "code" : 16945, "ok" : 0 } : aggregate failed Error: command failed: { "errmsg" : "exception: Exceeded memory limit for $group, but didn't allow external sort. Pass allowDiskUse:true to opt in.", "code" : 16945, "ok" : 0 } : aggregate failed at Error (<anonymous>) at doassert (src/mongo/shell/assert.js:11:14) at Function.assert.commandWorked (src/mongo/shell/assert.js:244:5) at DBCollection.aggregate (src/mongo/shell/collection.js:1149:12) at (shell):1:12 2015-01-29T11:42:31.592+0900 Error: command failed: { "errmsg" : "exception: Exceeded memory limit for $group, but didn't allow external sort. Pass allowDiskUse:true to opt in.", "code" : 16945, "ok" : 0 } : aggregate failed at src/mongo/shell/assert.js:13 |
mongos> db.tempCol.aggregate(..., {allowDiskUse: true}) |
aggregation.withOptions(aggregation.newAggregationOptions().allowDiskUse(true).build()); |
아래와 같은 오류를 접하는 경우가 있을 수 있습니다.
ObjenesisStd 클래스는 spring-core 4.0.X 버전에 존재하는 클래스로 spring 버전이 맞지 않아서 발생하는 이슈입니다.
https://github.com/spring-projects/spring-data-commons/wiki/Release-Train-Evans
구글링을 해보니 위 URL에서 아래와 같이 언급을 하고 있습니다.
Core themes
- Upgrade to Spring 4.0 as dependency baseline (previously Spring 3.2).
spring-data-common 자체의 spring baseline 버전이 4.0.X 로 올라갔습니다.
따라서 spring-core 버전을 4.0.X.RELEASE 으로 맞춰주면 정상적으로 수행이 됩니다.
'BigData > MongoDB' 카테고리의 다른 글
MongoDB Having 쿼리 적용하기 (0) | 2015.03.05 |
---|---|
MongoDB paddingFactor 옵션 (0) | 2015.03.05 |
MongoDB 인덱스 관리 (0) | 2015.03.05 |