On Mar 26, 2015, at 6:53 AM, HOUNKPONOU Ronald <[email protected]> wrote:
> Hi Ramsey, > I have done the Resources/Properties file modification and now the project is > building but when I try to access it fron browser i get an "An Internal > Server Error Has Occurred." error. You haven’t set up your connection dictionary. To do that, you need to set up a database (I’d recommend postgresql), add the database driver to your project and build path, and add the correct database properties to your Resources/Properties file. dbConnectURLGLOBAL=jdbc:postgresql://localhost/mydatabase?ssl=true&sslfactory=org.postgresql.ssl.NonValidatingFactory dbConnectUserGLOBAL=username dbConnectPasswordGLOBAL=password dbConnectPluginGLOBAL=com.webobjects.jdbcadaptor.PostgresqlPlugIn dbConnectDriverGLOBAL=org.postgresql.Driver dbConnectAdaptorGLOBAL=JDBC dbEOPrototypesEntityGLOBAL=EOJDBCPostgresqlPrototypes > > I also have a miss comprehention about this steps in one of your previous > mail: > My problem here is about the "Login,Logout". Is is the only one modification > I have to make in the NavigationMenu.plist ? It’s the only change you need to make to enable user login/logout. You will most likely want to make other changes related to your own application, but these are sufficient to provide user management. > > and i am not able to get copy of the model in my project. The proper way to add a model is via a framework. You will create an Application project, that is where you customize rules for your particular use case. To add a custom model, you should create a wonder framework. In the wonder framework, you then add the model to the Resources directory. I recommend my templates, which you use by copying the Templates folder from ERR2D2W/Support/Templates into your framework. Then in your model.eogen file, you set "Templates Folder: Templates” so wolips knows where to find them. > Can I add a database to your model? Or how can I use on? See above. See also http://www.wocommunity.org/podcasts/WOWODC09E-ThisYearModel.mov https://developer.apple.com/legacy/library/documentation/WebObjects/UsingEOModeler/Introduction/Introduction.html https://jenkins.wocommunity.org/job/Wonder/javadoc/er/extensions/migration/package-summary.html http://www.wocommunity.org/podcasts/EOModelCreation.mov > > open the Navigation.plist for the new app and add "Login,Logout” to your root > children > > You should now have a basic project with authentication built in. If you want > to customize the ERUser class in some way, then you can create a new Wonder > framework, create your model, add my eogen templates to it, and then subclass > ERUser with your own User EO > > https://wiki.wocommunity.org/display/documentation/Modeling+Inheritance+with+Entity+Modeler?src=search > > and add a rule to your own user framework > > 100 : *true* => userEntity = “MyUser" > [com.webobjects.directtoweb.EntityAssignment] > > This way you can customize the user class and add whatever additional > relationships you may need. Be aware that if you add any mandatory > fields/relationships, you must set them in your user's init() method or fix > the user creation process yourself. > > > It also seems that i miss a step for database configuration because i get > this trace in the console: > > ERROR (ERXJDBCConnectionAnalyzer.java:94) - JDBC Connection Analysis: Missing > plugin or driver. > WARN (ERXNSLogLog4jBridge.java:44) - <WOWorkerThread id=12 > socket=Socket[addr=/127.0.0.1,port=36785,localport=53162]> Exception occurred > while responding to client: java.lang.IllegalStateException: > _obtainOpenChannel -- com.webobjects.eoaccess.EODatabaseContext > com.webobjects.eoaccess.EODatabaseContext@a77b84: failed to open database > channel. Check your connection dictionary, and ensure your database is > correctly configured. > [2015-3-26 13:24:56 GMT] <WorkerThread12> java.lang.IllegalStateException: > _obtainOpenChannel -- com.webobjects.eoaccess.EODatabaseContext > com.webobjects.eoaccess.EODatabaseContext@a77b84: failed to open database > channel. Check your connection dictionary, and ensure your database is > correctly configured. > at > com.webobjects.eoaccess.EODatabaseContext._obtainOpenChannel(EODatabaseContext.java:1967) > at > com.webobjects.eoaccess.EODatabaseContext._objectsWithFetchSpecificationEditingContext(EODatabaseContext.java:3054) > at > com.webobjects.eoaccess.EODatabaseContext.objectsWithFetchSpecification(EODatabaseContext.java:3195) > at > com.webobjects.eocontrol.EOObjectStoreCoordinator.objectsWithFetchSpecification(EOObjectStoreCoordinator.java:488) > at > com.webobjects.eocontrol.EOEditingContext.objectsWithFetchSpecification(EOEditingContext.java:4069) > at > er.extensions.eof.ERXEC.objectsWithFetchSpecification(ERXEC.java:1308) > at > com.webobjects.eocontrol.EOEditingContext.objectsWithFetchSpecification(EOEditingContext.java:4444) > at > com.webobjects.eoaccess.EOUtilities.objectsMatchingValues(EOUtilities.java:216) > at > com.webobjects.eoaccess.EOUtilities.objectsMatchingKeyAndValue(EOUtilities.java:190) > at > er.extensions.eof.EOEnterpriseObjectClazz.objectsMatchingKeyAndValue(EOEnterpriseObjectClazz.java:350) > at > er.extensions.eof.EOEnterpriseObjectClazz.objectMatchingKeyAndValue(EOEnterpriseObjectClazz.java:375) > at > er.persistentsessionstorage.ERPersistentSessionStore.saveSessionForContext(ERPersistentSessionStore.java:39) > at > com.webobjects.appserver.WOSessionStore.checkInSessionForContext(WOSessionStore.java:234) > at > com.webobjects.appserver.WOApplication.saveSessionForContext(WOApplication.java:1892) > at > er.extensions.appserver.ERXApplication.saveSessionForContext(ERXApplication.java:2399) > at > com.webobjects.appserver._private.WOActionRequestHandler._handleRequest(WOActionRequestHandler.java:328) > at > com.webobjects.appserver._private.WOActionRequestHandler.handleRequest(WOActionRequestHandler.java:158) > at > er.extensions.appserver.ERXDirectActionRequestHandler.handleRequest(ERXDirectActionRequestHandler.java:128) > at > com.webobjects.appserver.WOApplication.dispatchRequest(WOApplication.java:1687) > at > er.extensions.appserver.ERXApplication.dispatchRequestImmediately(ERXApplication.java:2127) > at > er.extensions.appserver.ERXApplication.dispatchRequest(ERXApplication.java:2092) > at > com.webobjects.appserver._private.WOWorkerThread.runOnce(WOWorkerThread.java:144) > at > com.webobjects.appserver._private.WOWorkerThread.run(WOWorkerThread.java:226) > at java.lang.Thread.run(Thread.java:745) > > > Thanks you very much and best regards. _______________________________________________ Do not post admin requests to the list. They will be ignored. Webobjects-dev mailing list ([email protected]) Help/Unsubscribe/Update your Subscription: https://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com This email sent to [email protected]
