David, to check the properties, you can put this somewhere in the app
startup (I put it in didFinishLaunching, but end of constructor might
work as well for you) to get a console output of "resolved"
properties. I find this useful, especially when we have user-based
Properties files, launcg argument properties and the @@myproperty@@
substitutions going on:
@Override
public void didFinishLaunching() {
super.didFinishLaunching();
// I used to need this to get the @@ substitution to work properly
for logging properties (appname, port, etc)
ERXLogger.configureLoggingWithSystemProperties();
// Other stuff here.........
if
(ERXProperties.booleanForKeyWithDefault("app.logproperties", false)) {
System.out.println("Application.didFinishLaunching(): \n"
+ ERXStringUtilities.dumpObject(ERXProperties.allProperties()));
}
}
Hope that helps you to find some clues as to what is going on
Regards, Kieran
On Aug 18, 2009, at 3:42 PM, David Avendasora wrote:
On Aug 18, 2009, at 3:11 PM, Mike Schrag wrote:
oh, right .. reading the exception = key:
"ERAttachment={}; and CommunicationCenter={plugin =
"EROraclePlugIn"; }":
that's the difference
you are declaring a plugin explicitly on your CommCenter
framework .. .declare the same on ERAttachment, or globally.
Okay, I think this is one of those things that is really obvious but
I'm not seeing it.
I really don't think it is reading the Properties values at all and
only going by what is in the EOModels.
First I added "ERAttachment.DBPlugin=EROraclePlugIn" to my
Properties file, which didn't help, then I removed all the plugin
information from the models so they would mach what ERAttachment has
in the model and then added the plugin info to the Properties file
for each Model. That stopped the original error.
Now I'm getting:
An exception occurred while trying to open a channel: The url cannot
be nullat java.sql.DriverManager.getConnection(DriverManager.java:502)
The model that it is complaining about has a URL Property set only
in the Properties file:
LogisticsManagement.URL=jdbc:oracle:thin:@server:port:schema
What am I missing??
Dave
ms
On Aug 18, 2009, at 3:05 PM, David Avendasora wrote:
On Aug 18, 2009, at 2:41 PM, Mike Schrag wrote:
dbConnectURLGLOBAL=url
dbConnectUserGLOBAL=user
dbConnectPasswordGLOBAL=pw
or also set ERAttachment.URL, ERAttachment.DBUser,
ERAttachment.DBPassword
ERAttachement's info is set, using the same pattern as
CommunicationCenter's is below.
There are 17 models in this framework, not including the Wonder
Models for ERAttachment, ERTaggables, etc.
Dave
ms
On Aug 18, 2009, at 2:37 PM, David Avendasora wrote:
Hi all,
I'm trying to define my DB connections in the
Properties.username files so I get the correct connection
depending on if I am running my app in Developement, QA or
Production.
I have removed all my connection information out of the EO
Models and have set the following properties:
CommunicationCenter.URL=jdbc:oracle:thin:@Server:Port:Schema
CommunicationCenter.DBUser=user
CommunicationCenter.DBPassword=password
But I'm getting the following error, which leads me to believe
that it is _not_ picking up my properties. The Resources/
Properties file has the default connection dictionaries in it,
so this should work, right?
A fatal exception occurred: The connection dictionaries for
ERAttachment and CommunicationCenter have the same URL and
username, but the connection dictionaries are not equal. Check
your connection dictionaries carefully! This problem is often
caused by jdbc2Info not matching between the two. One fix for
this is to set ERAttachment.removeJdbc2Info=true and
CommunicationCenter.removeJdbc2Info=true in your Properties
file. (ERAttachment={}; and CommunicationCenter={plugin =
"EROraclePlugIn"; }).
Any ideas? Am I not using the correct properties?
Thanks,
Dave
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list ([email protected])
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/mschrag%40mdimension.com
This email sent to [email protected]
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list ([email protected])
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/webobjects%40avendasora.com
This email sent to [email protected]
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list ([email protected])
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/webobjects%40avendasora.com
This email sent to [email protected]
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list ([email protected])
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/kieran_lists%40mac.com
This email sent to [email protected]
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list ([email protected])
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com
This email sent to [email protected]