Welcome, Guest
  • Author Topic: Tracing Application Instances  (Read 2855 times)

    kofi addaquay

    • Global Moderator
    • Senior Programmer
    • *****
    • Posts: 450
      • View Profile
      • Scripton Interactive
      • Email
    Tracing Application Instances
    « on: 10/07/08, 02:07 »
    Hello...i have got a question about tracing application instances...:)

    my application is called BuiPower. within that folder i have BuiPower.asc.

    Then i have another folder called VideoConferenceRooms and within that folder, another folder called Room1. Room1 has a Room1.asc file. I can connect to the Room1 instance fine...the only problem is that i cant see the traces in the administration panel for Room1. BUT i can always see the trace/log for BuiPower..just not Room1

    i am writing this trace within the application.onAppStart function ...for both BuiPower and Room1 ASC

    trace(application.name + " is starting now");

    i only see it for BuiPower logs and not Room1. did i miss something?


    Ronald Wernecke

    • Global Moderator
    • Systems Administrator
    • *****
    • Posts: 6203
      • View Profile
      • Professional Support
      • Email
    Re: Tracing Application Instances
    « Reply #1 on: 10/07/08, 04:46 »
    I usualy use trace(this); inside of the instance, to findout the current path of the object
    or trace(this.name); to findout the instances name.
    happy flashing
    8)
    Ronald

    Jorge Solis

    • Global Moderator
    • Systems Administrator
    • *****
    • Posts: 14616
      • View Profile
    Re: Tracing Application Instances
    « Reply #2 on: 10/07/08, 05:58 »
    Hi Koffi

    Except special setups (an Application acting as client of another application) you connect to a single application and the server create instances on the fly. So if you want to connect to the main application use:

    rtmp://yourhost/BuiPower

    This will create an instance named _default_

    Now if you use:

    rtmp://yourhost/BuiPower/room1

    The instance name will be of course room1, and is automatically created by the main application. That means, you connect to an application, and pass an instance name if needed following this pattern:

    protocol:[//host][:port]/appname/[instanceName]

    So, in others words, your room1 inner folder will be never reached

    Jorge

    kofi addaquay

    • Global Moderator
    • Senior Programmer
    • *****
    • Posts: 450
      • View Profile
      • Scripton Interactive
      • Email
    Re: Tracing Application Instances
    « Reply #3 on: 10/07/08, 12:56 »
    Yes Ronald... using the 'this' keyword on the server side refers to the application...therefore

    this.name and application.name is the same thing.


    Jorge...i am still trying to understand what you are saying... are you saying to use

    rtmp://yourhost/BuiPower/room1

    instead of

    rtmp://yourhost/BuiPower/VideoConferenceRooms/room1

    because when i do..i still see only the traces that are within the BuiPower.asc and not for room1. when i disconnection from Room1 i still the onDisconnect call for BuiPower  ??? ??? and when i connect to Room1 i see the onStart for BuiPower.

    Jorge Solis

    • Global Moderator
    • Systems Administrator
    • *****
    • Posts: 14616
      • View Profile
    Re: Tracing Application Instances
    « Reply #4 on: 10/07/08, 13:06 »
    Rigth, you connect to an Application and pass an instance in the path, the server siede logic is in the application, not in the instance

    Jorge