मैं EC2 पर सेटअप Grails वेब आवेदन करने के लिए कोशिश कर रहा हूँMongoDB (3.0.2) Grails 2.4.3
InstanceType साथ NullPointerException: एम 3 xlarge
स्थापित जावा http://www.webupd8.org/2012/01/install-oracle-java-jdk-7-in-ubuntu-via.html
संस्करण से: जावा संस्करण "1.7.0_80" जावा (टीएम) एसई रनटाइम वातावरण (निर्माण 1.7.0_80-B15) जावा हॉटस्पॉट (टीएम) 64-बिट सर्वर वी एम (निर्माण 24.80-B11, मिश्रित मोड)
(
http://docs.mongodb.org/manual/tutorial/install-mongodb-on-ubuntu/
से https://github.com/spring-projects/spring-loaded/issues/98) GVMtools
grails version : 2.4.3
स्थापित MongoDB से
स्थापित Grails संस्करण MongoDB खोल संस्करण के साथ: जावा 8 जैसे मुद्दों चल रहा है 3.0। 2 से कनेक्ट: परीक्षण
मेरी DataSource.groovy config हैं:
environments {
development {
grails {
mongo {
host = "localhost"
port = 27017
username = "root"
password = "root"
databaseName = "someDatabase"
}
}
dataSource {
dbCreate = "create-drop" // one of 'create', 'create-drop', 'update', 'validate', ''
url = "jdbc:h2:mem:devDb;MVCC=TRUE;LOCK_TIMEOUT=10000;DB_CLOSE_ON_EXIT=FALSE"
}
}
मेरी Buildconfig.groovy नवीनतम मोंगो प्लगइन है:
compile ":mongodb:3.0.3"
लेकिन बाद सर्वर
grails run-app
शुरू करने और किसी भी पेज खोलने मुझे यह
मिल रहा हैError:
Stacktrace follows:
Message: null
Line | Method
->> 833 | executeQuery in org.grails.datastore.mapping.mongo.query.MongoQuery
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
| 542 | list in org.grails.datastore.mapping.query.Query
| 49 | invokeQuery . . in org.grails.datastore.gorm.finders.FindAllByFinder
| 43 | doInSession in org.grails.datastore.gorm.finders.FindAllByFinder$1
| 302 | execute . . . . in org.grails.datastore.mapping.core.DatastoreUtils
| 41 | execute in org.grails.datastore.gorm.finders.AbstractFinder
| 40 | doInvokeInternal in org.grails.datastore.gorm.finders.FindAllByFinder
| 152 | invoke in org.grails.datastore.gorm.finders.DynamicFinder
| 352 | invoke . . . . . in ''
| 105 | methodMissing in org.grails.datastore.gorm.GormStaticApi
| 32 | call . . . . . . in org.grails.datastore.gorm.internal.StaticMethodInvokingClosure
| 49 | function in someDomain
| 25 | listAllResources in in.org.api.APIController
| 16 | index in ''
| 198 | doFilter . . . . in grails.plugin.cache.web.filter.PageFragmentCachingFilter
| 63 | doFilter in grails.plugin.cache.web.filter.AbstractFilter
| 53 | doFilter . . . . in grails.plugin.springsecurity.web.filter.GrailsAnonymousAuthenticationFilte r
| 49 | doFilter in grails.plugin.springsecurity.web.authentication.RequestHolderAuthenticationFilter
| 82 | doFilter . . . . in grails.plugin.springsecurity.web.authentication.logout.MutableLogoutFilter
| 1145 | runWorker in java.util.concurrent.ThreadPoolExecutor
| 615 | run . . . . . . in java.util.concurrent.ThreadPoolExecutor$Worker
745 | run in java.lang.Thread
पुनश्च: मैं भी उपयोगकर्ता को बनाने और उसे (Grails - Connect to a MongoDB database using authentication)
db.createUser साथके सत्यापन की कोशिश की।
कॉन्फ़िगरेशन के साथ गलत क्या हो सकता है ठीक उसी कॉन्फ़िगरेशन मेरी स्थानीय मशीन पर ठीक चलती है।
यह सहायक होने की संभावना नहीं है, लेकिन आप तैनात किए जाने पर वसंत-लोड का उपयोग नहीं करेंगे, यह केवल 'रन-एप' के लिए है। क्या आप 2.4.5 या 2.5.0 के साथ कोशिश कर सकते हैं? –
2.4.5 –
के साथ समान त्रुटि आपकी कॉन्फ़िगरेशन ठीक दिखती है। क्या आपने अपने ऐप को '2.6.9' की तरह मोंगो के पुराने संस्करण के साथ चलाने का प्रयास किया था। v3 में 'mongodb: 3.0.3' के साथ संगतता समस्या हो सकती है। –