• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Multiple instances of EOModel in an application.
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Multiple instances of EOModel in an application.


  • Subject: Re: Multiple instances of EOModel in an application.
  • From: Art Isbell <email@hidden>
  • Date: Wed, 23 Jun 2004 20:22:05 -1000

On Jun 23, 2004, at 6:14 PM, Marek Wawrzyczny wrote:

Has anyone tried to concurrently use many instances of the same EOModel, linked to different databases in a single application?
We are evaluating this possibility. We have several identical databases which we'd hope to update using WebServices through a single WO app. All EOs have the same business logic. This app would ideally choose the right data source depending on the login info. As far as I can tell this is only possible if the none of the EO share the same entity name.

The restriction is that the names of all entities loaded into an EOModelGroup must be unique. All eomodels in an app and in any frameworks linked to the app are loaded into a single EOModelGroup. So you'd need to rename the entities in each identical eomodel so that all entity names are unique. I'm not certain, but I don't believe there'd be any problem with identical entities with different names sharing the same EO class.


Maybe you could devise an entity name suffix that's tied to the particular database being accessed. Then any entity name reference in your code could be a String that would be dynamically assigned the appropriate entity name based on the database being accessed.

This is all off the top of my head, so I've undoubtedly overlooked some critical detail that will blow this whole thing out of the water :-)

Aloha,
Art
_______________________________________________
webobjects-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/webobjects-dev
Do not post admin requests to the list. They will be ignored.


  • Follow-Ups:
    • Re: Multiple instances of EOModel in an application.
      • From: Geoff Hopson <email@hidden>
    • Re: Multiple instances of EOModel in an application.
      • From: Marek Wawrzyczny <email@hidden>
References: 
 >Multiple instances of EOModel in an application. (From: Marek Wawrzyczny <email@hidden>)

  • Prev by Date: Project for testing, D2W question
  • Next by Date: Re: Multiple instances of EOModel in an application.
  • Previous by thread: Multiple instances of EOModel in an application.
  • Next by thread: Re: Multiple instances of EOModel in an application.
  • Index(es):
    • Date
    • Thread