Futurescale, Inc. PureMVC Home

The PureMVC Framework Code at the Speed of Thought


Over 10 years of community discussion and knowledge are maintained here as a read-only archive.

New discussions should be taken up in issues on the appropriate projects at https://github.com/PureMVC

Pages: [1]
Print
Author Topic: MultiCore load module into another module issue  (Read 6089 times)
meatnugget
Newbie
*
Posts: 6


View Profile Email
« on: April 07, 2009, 05:56:20 »

Hi,

I'm having a frustrating problem with loaded modules:

In my application I load modules into other modules at run time. All modules are loaded using the module manager and everything loads fine. The problem happens with any outbound notifications originating from the modules loaded at run time into another module - they are being sent twice.

If the same module is loaded into the main shell instead of into another module the notifications behave as expected.

I know there isn't much info to go on - and no source code, but if it sounds familiar I'd really appreciate if anyone has experienced a similar problem and found a solution.

Thanks!
Logged
puremvc
Global Moderator
Hero Member
*****
Posts: 2871



View Profile WWW Email
« Reply #1 on: April 08, 2009, 12:18:59 »

That's strange behavior, to be sure.

However, you shouldn't be sending 'outbound' notifications between modules. If you want to send info between modules, you should use the Pipes utility, where you can send strongly-typed messages.

Why? Notification constants may be duplicated in different modules, with different meanings. Sure you may control all of the notification constants in your closed application, but in an application which may load third party modules may not have any control over notification namespace. A best practice must include all reasonable uses, so this possibility governs the inter-module communication practice.

-=Cliff>
Logged
Pages: [1]
Print