public void Initialise(IConfigSource source)
        {
            if (Simian.IsSimianEnabled(source, "AvatarServices", this.Name))
            {
                IConfig gridConfig = source.Configs["AvatarService"];
                if (gridConfig == null)
                {
                    m_log.Error("[SIMIAN AVATAR CONNECTOR]: AvatarService missing from OpenSim.ini");
                    throw new Exception("Avatar connector init error");
                }

                string serviceUrl = gridConfig.GetString("AvatarServerURI");
                if (String.IsNullOrEmpty(serviceUrl))
                {
                    m_log.Error("[SIMIAN AVATAR CONNECTOR]: No AvatarServerURI in section AvatarService");
                    throw new Exception("Avatar connector init error");
                }

                if (!serviceUrl.EndsWith("/"))
                {
                    serviceUrl = serviceUrl + '/';
                }

                m_serverUrl = serviceUrl;
            }
        }
예제 #2
0
        public void Initialise(IConfigSource source)
        {
            if (Simian.IsSimianEnabled(source, "UserAccountServices", "SimianUserAccountServiceConnector"))
            {
                IConfig gridConfig = source.Configs["UserAccountService"];
                if (gridConfig == null)
                {
                    m_log.Error("[SIMIAN PROFILES]: UserAccountService missing from OpenSim.ini");
                    throw new Exception("Profiles init error");
                }

                string serviceUrl = gridConfig.GetString("UserAccountServerURI");
                if (String.IsNullOrEmpty(serviceUrl))
                {
                    m_log.Error("[SIMIAN PROFILES]: No UserAccountServerURI in section UserAccountService");
                    throw new Exception("Profiles init error");
                }

                if (!serviceUrl.EndsWith("/"))
                {
                    serviceUrl = serviceUrl + '/';
                }

                m_serverUrl = serviceUrl;
                IConfig profilesConfig = source.Configs["Profiles"];
                if (profilesConfig == null)
                {
                    // Do not run this module by default.
                    return;
                }
                else
                {
                    // if profiles aren't enabled, we're not needed.
                    // if we're not specified as the connector to use, then we're not wanted
                    if (profilesConfig.GetString("Module", String.Empty) != Name)
                    {
                        return;
                    }
                    m_log.InfoFormat("[SIMIAN ACCOUNT CONNECTOR]: Initializing {0}", this.Name);
                }
            }
        }
예제 #3
0
        public void Initialise(IConfigSource source)
        {
            if (Simian.IsSimianEnabled(source, "GridServices", this.Name))
            {
                IConfig gridConfig = source.Configs["GridService"];
                if (gridConfig == null)
                {
                    m_log.Error("[SIMIAN GRID CONNECTOR]: GridService missing from OpenSim.ini");
                    throw new Exception("Grid connector init error");
                }

                string serviceUrl = gridConfig.GetString("GridServerURI");
                if (String.IsNullOrEmpty(serviceUrl))
                {
                    m_log.Error("[SIMIAN GRID CONNECTOR]: No Server URI named in section GridService");
                    throw new Exception("Grid connector init error");
                }

                m_serverUrl = serviceUrl;
            }
        }
예제 #4
0
        public void Initialise(IConfigSource source)
        {
            if (Simian.IsSimianEnabled(source, "AuthenticationServices", this.Name))
            {
                IConfig assetConfig = source.Configs["AuthenticationService"];
                if (assetConfig == null)
                {
                    m_log.Error("[SIMIAN AUTH CONNECTOR]: AuthenticationService missing from OpenSim.ini");
                    throw new Exception("Authentication connector init error");
                }

                string serviceURI = assetConfig.GetString("AuthenticationServerURI");
                if (String.IsNullOrEmpty(serviceURI))
                {
                    m_log.Error("[SIMIAN AUTH CONNECTOR]: No Server URI named in section AuthenticationService");
                    throw new Exception("Authentication connector init error");
                }

                m_serverUrl = serviceURI;
            }
        }
예제 #5
0
        public void Initialise(IConfigSource source)
        {
            if (Simian.IsSimianEnabled(source, "UserAccountServices", this.Name))
            {
                IConfig assetConfig = source.Configs["UserAccountService"];
                if (assetConfig == null)
                {
                    m_log.Error("[SIMIAN ACCOUNT CONNECTOR]: UserAccountService missing from OpenSim.ini");
                    throw new Exception("User account connector init error");
                }

                string serviceURI = assetConfig.GetString("UserAccountServerURI");
                if (String.IsNullOrEmpty(serviceURI))
                {
                    m_log.Error("[SIMIAN ACCOUNT CONNECTOR]: No UserAccountServerURI in section UserAccountService, skipping SimianUserAccountServiceConnector");
                    throw new Exception("User account connector init error");
                }

                m_accountCache = new ExpiringCache <UUID, UserAccount>();
                m_serverUrl    = serviceURI;
            }
        }
예제 #6
0
        public void Initialise(IConfigSource source)
        {
            if (Simian.IsSimianEnabled(source, "InventoryServices", this.Name))
            {
                IConfig gridConfig = source.Configs["InventoryService"];
                if (gridConfig == null)
                {
                    m_log.Error("[SIMIAN INVENTORY CONNECTOR]: InventoryService missing from OpenSim.ini");
                    throw new Exception("Inventory connector init error");
                }

                string serviceUrl = gridConfig.GetString("InventoryServerURI");
                if (String.IsNullOrEmpty(serviceUrl))
                {
                    m_log.Error("[SIMIAN INVENTORY CONNECTOR]: No Server URI named in section InventoryService");
                    throw new Exception("Inventory connector init error");
                }

                m_serverUrl = serviceUrl;

                gridConfig = source.Configs["UserAccountService"];
                if (gridConfig != null)
                {
                    serviceUrl = gridConfig.GetString("UserAccountServerURI");
                    if (!String.IsNullOrEmpty(serviceUrl))
                    {
                        m_userServerUrl = serviceUrl;
                    }
                    else
                    {
                        m_log.Info("[SIMIAN INVENTORY CONNECTOR]: No Server URI named in section UserAccountService");
                    }
                }
                else
                {
                    m_log.Warn("[SIMIAN INVENTORY CONNECTOR]: UserAccountService missing from OpenSim.ini");
                }
            }
        }