Results 1 to 5 of 5

Thread: object adapter requires configuration

  1. #1
    dmitry.medvedev's Avatar
    dmitry.medvedev is offline Registered User
    Name: Dmitry N. Medvedev
    Organization: Personal
    Project: Casual Game Analytics Dashboard
    Join Date
    Sep 2005
    Location
    Moscow, Russia
    Posts
    47

    Unhappy object adapter requires configuration

    Hi.
    I am trying to create an IceBox application (AuthorizerService) to be deployed in IceGrid. As soon as I start AuthorizerService via IceGrid GUI it terminates with the following stack trace.

    The exception is caused by the following command:

    Code:
    public void start ( string name, Communicator communicator, string[ ] args ) {
        this._adapter = communicator.createObjectAdapter ( name );
        //...
    }
    Stack trace:
    Code:
    !! 4/26/2010 18:07:40:390 AuthorizerServer: error: IceBox.FailureException
           reason = "ServiceManager: exception while starting service AuthorizerService: Ice.InitializationException
           reason = "object adapter `AuthorizerService' requires configuration"
          at Ice.ObjectAdapterI..ctor(Instance instance, Communicator communicator, ObjectAdapterFactory objectAdapterFactory, String name, RouterPrx router, Boolean noConfig) in c:\Ice-Build\VC9\Release\cs\src\Ice\ObjectAdapterI.cs:line 899
          at IceInternal.ObjectAdapterFactory.createObjectAdapter(String name, RouterPrx router) in c:\Ice-Build\VC9\Release\cs\src\Ice\ObjectAdapterFactory.cs:line 132
          at Ice.CommunicatorI.createObjectAdapter(String name) in c:\Ice-Build\VC9\Release\cs\src\Ice\CommunicatorI.cs:line 69
          at DIAmatix.Services.TeamBuilder.Authorization.IBox.Authorizer.start(String name, Communicator communicator, String[] args) in H:\DIAmatix\TeamBuilder\src\authorization.svc\Authorization\Authorization.IBox\Authorizer.cs:line 21
          at IceBox.ServiceManagerI.startService(String service, String entryPoint, String[] args) in c:\Ice-Build\VC9\Release\cs\src\IceBox\ServiceManagerI.cs:line 709"
          at IceBox.ServiceManagerI.startService(String service, String entryPoint, String[] args) in c:\Ice-Build\VC9\Release\cs\src\IceBox\ServiceManagerI.cs:line 722
          at IceBox.ServiceManagerI.run() in c:\Ice-Build\VC9\Release\cs\src\IceBox\ServiceManagerI.cs:line 406
       Caused by: Ice.InitializationException
          at Ice.ObjectAdapterI..ctor(Instance instance, Communicator communicator, ObjectAdapterFactory objectAdapterFactory, String name, RouterPrx router, Boolean noConfig) in c:\Ice-Build\VC9\Release\cs\src\Ice\ObjectAdapterI.cs:line 899
          at IceInternal.ObjectAdapterFactory.createObjectAdapter(String name, RouterPrx router) in c:\Ice-Build\VC9\Release\cs\src\Ice\ObjectAdapterFactory.cs:line 132
          at Ice.CommunicatorI.createObjectAdapter(String name) in c:\Ice-Build\VC9\Release\cs\src\Ice\CommunicatorI.cs:line 69
          at DIAmatix.Services.TeamBuilder.Authorization.IBox.Authorizer.start(String name, Communicator communicator, String[] args) in H:\DIAmatix\TeamBuilder\src\authorization.svc\Authorization\Authorization.IBox\Authorizer.cs:line 21
          at IceBox.ServiceManagerI.startService(String service, String entryPoint, String[] args) in c:\Ice-Build\VC9\Release\cs\src\IceBox\ServiceManagerI.cs:line 709
    By the way, I have created application in the IceGrid GUI manually.
    Dmitry N. Medvedev@FaceBook

  2. #2
    mes's Avatar
    mes
    mes is offline ZeroC Staff
    Name: Mark Spruiell
    Organization: ZeroC, Inc.
    Project: Ice Developer
    Join Date
    Feb 2003
    Location
    California
    Posts
    1,445
    Hi Dmitry,

    The error message in the reason field indicates that you have created an object adapter named AuthorizerService but you have not defined any configuration properties for this adapter. When you create an adapter using createObjectAdapter, the adapter requires that at least one property be defined. Normally you would define at least the adapter.Endpoints property.

    It's also possible that you have misspelled the adapter name or its configuration properties. This error also helps developers avoid problems caused by such misspellings.

    Regards,
    Mark

  3. #3
    dmitry.medvedev's Avatar
    dmitry.medvedev is offline Registered User
    Name: Dmitry N. Medvedev
    Organization: Personal
    Project: Casual Game Analytics Dashboard
    Join Date
    Sep 2005
    Location
    Moscow, Russia
    Posts
    47
    When using IceGrid GUI I have changed the name of the adapter from, say, "MyAdapter" to ${service} variable everything starts working...

    Broken way: ${server}.${service}.MyAdapter

    Working way: ${server}.${service}.${service}-adapter

    PS:
    Obviously I do not understand adapter naming rules.

    Thank you, Mes.
    Dmitry N. Medvedev@FaceBook

  4. #4
    bernard's Avatar
    bernard is offline ZeroC Staff
    Name: Bernard Normier
    Organization: ZeroC, Inc.
    Project: Ice
    Join Date
    Feb 2003
    Location
    Palm Beach Gardens, FL
    Posts
    1,294
    Hi Dmitry,

    Perhaps you are confusing adapter names with adapter IDs?

    The adapter name is only used to distinguish object adapters within a communicator, and to associate configuration with this object adapter. This name passed as the parameter to createObjectAdapter() and must match the adapter name you use in the configuration.

    An adapter ID uniquely identifies an indirect object adapter with an IceGrid deployment.

    Typically, you would use a simple string like "AuthorizationAdapter" for your adapter name, and a more unique string for the adapter ID (such as ${server}.${service}.AuthorizationAdapter). This adapter ID is just in the configuration and not in your code.

    I hope this is clearer now!

    Cheers,
    Bernard
    Bernard Normier
    ZeroC, Inc.

  5. #5
    dmitry.medvedev's Avatar
    dmitry.medvedev is offline Registered User
    Name: Dmitry N. Medvedev
    Organization: Personal
    Project: Casual Game Analytics Dashboard
    Join Date
    Sep 2005
    Location
    Moscow, Russia
    Posts
    47
    Hi, Bernard!

    Thank you for clarification!

    With regards,
    Dmitry.
    Dmitry N. Medvedev@FaceBook

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. object adapter requires configuration
    By RonnieDay in forum Help Center
    Replies: 4
    Last Post: 03-30-2011, 11:56 AM
  2. Replies: 4
    Last Post: 10-16-2009, 06:42 PM
  3. Find object in object adapter by its proxy
    By dnnbg in forum Help Center
    Replies: 2
    Last Post: 02-25-2009, 04:09 AM
  4. Replicated Object Adapter
    By vsonnathi in forum Help Center
    Replies: 3
    Last Post: 04-13-2005, 03:30 PM
  5. how to get an object adapter from the communicator
    By paulling in forum Help Center
    Replies: 1
    Last Post: 11-26-2003, 12:29 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •