Re: Eclipse/WOLips not seeing multiple databases
Re: Eclipse/WOLips not seeing multiple databases
- Subject: Re: Eclipse/WOLips not seeing multiple databases
- From: David Ress <email@hidden>
- Date: Mon, 19 Jan 2009 14:51:39 -0500
Hmm....
3) You might want to create one of your frameworks in Eclipse, then
have your app project reference and see if that gives you the
models in that framework. Then look at the differences in the two
frameworks as they are built.
Thanks - this suggestion eliminates the "Failed to load file" error
and also fixes the database issues.
7) Do you _need_ 5 frameworks? Even in the normal use cases, the
way that WO resolves resource paths can be tweaky. If you can
simplify your packaging, that would probably help.
Yes, actually though, I have 11 different custom frameworks (just 5
with EOs), plus Project Wonder, rolled into this application.
But, now I am on to my next problem that has me stumped.... probably
because I was trying too many improvements at once.
I get the error:
<com.istl.dmp.infoscribe.Application>: Unable to create page 'Main'.
One of the "improvements" I was attempting was adding packages, and I
am wondering if having the Main component (and its java file) in a
separate package from the Application class is a no-no, as I am
seeing WOPageNotFoundException with the above error.
Any ideas on this one?
Thanks,
David
---
David Ress, PhD CEO - Chief Entertainment Officer
ISTL, Inc. Beavercreek Ohio, 45434
www.infoscribe.com Phone: (937) 431-8870
On Jan 19, 2009, at 2:15 PM, Ray Kiddy wrote:
On Jan 19, 2009, at 5:56 AM, David Ress wrote:
I have finally ported a large project over to the Eclipse/WOLips
(3.3.2/3.3.5563) environment.
However, I am still not able to run the program.
When I try running the program, I see messages in the console like
<main> Failed to load file:////Library/Framework/xxxxxEO.framework/
Resources/Info.plist. Treating as empty.
I see the above the message for 5 frameworks, each of which
contains EOModels of a database (yes, this program actively
connects to 5 databases concurrently). The 5 EO frameworks are
built with XCode 3, and yes, the file is in the Resources
directory. Oh, I have these frameworks installed in the
WebObjects Frameworks "directory" in the eclipse project, correct?
In the Application class, I have a line to print out the model
names in the default group of EOModelGroup. I see in this listing
only 1 model instead of the 5 I have seen when the project ran in
XCode. The program then terminates saying it does not have a model
for a particular table which it is trying to read from.
Any ideas why the program is not seeing the Info.plist? I cannot
figure out why I see 4 forward-slashes after "file:" - are they a
I believe that since the Info.plist are not loading, the
EOModelGroup is not seeing all the databases. Do you concur? Is
there something I might try?
Thanks,
David
---
Hey David -
The reasons for what you are seeing may be complex. WO apps
construct an NSBundleSearchPath to find things. Essentially, the
ideas here came from when WO was written in ObjC. There is a bunch
of voodoo in application initialization code that sets up the java
structures needed, which came free with the ObjC runtime.
I assume there is a reason you cannot build all of your frameworks
in eclipse. That probably _would_ be simplest.
You probably want to investigate making the problem go away instead
of understanding it. This is probably how I would start, probably
not in order. Actually, I can almost guarantee most of these will
have nothing to do with the solution, but something might trigger
something and you did ask....
1) Is 'Resources' in the Xcode-built framework a soft link to
'Versions/A/Resources'? If so, does the target of that link exist?
The links have gotten confused in the past.
2) Are the Info.plist files of the frameworks you are trying to
build proper XML? Xcode and Eclipse use different parsers and may
have different ideas about things like what needs to be quoted and
what does not.
3) You might want to create one of your frameworks in Eclipse, then
have your app project reference and see if that gives you the
models in that framework. Then look at the differences in the two
frameworks as they are built.
4) There have been problems with case mixing in frameworks or saved
resource paths. Are names in files spelled using the correct mix of
capital letters? You do not say what platform you are on, but Mac
OS X using a case-insensitive file system by default and there can
be problems copying things to and from other systems when they have
case-sensitive file systems.
5) Are there jar files in the correct places in all of your
frameworks? Weird stuff gets done with a framework that does not
contain any java code to make sure that a proper jar is created. At
least weird stuff got done in Xcode. When the app is launched, the
jar is the only thing that triggers the NSBundle stuff to say "ah,
I have found a framework thing...."
6) I do not think the four slashes in "file:////" are actually a
problem. For some reason, I think the java URL class can deal with
that. But it may indicate that something is wrong. There may be
some variable, like $(SYSTEM) but perhaps something less obvious,
which should be putting a real word in front of that 4th slash.
Look for occurrences of the paths to the frameworks in other parts
of the project and see if there are any variable references there.
7) Do you _need_ 5 frameworks? Even in the normal use cases, the
way that WO resolves resource paths can be tweaky. If you can
simplify your packaging, that would probably help.
Well, let me know if any of this helps. Now I have to go knock my
head against something to get all of that NSBundleSearchPath noise
out of my head. Thanks for reminding me about all this.... :-)
cheers - ray
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
40infoscribe.com
This email sent to email@hidden
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden