public FriendsRequestHandler(FriendsModule fmodule) : base("POST", "/friends", new BasicDosProtectorOptions() { AllowXForwardedFor = true, ForgetTimeSpan = TimeSpan.FromMinutes(2), MaxRequestsInTimeframe = 20, ReportingName = "FRIENDSDOSPROTECTOR", RequestTimeSpan = TimeSpan.FromSeconds(5), ThrottledAction = BasicDOSProtector.ThrottleAction.DoThrottledMethod }) { m_FriendsModule = fmodule; }
public FriendsRequestHandler(FriendsModule fmodule) : base("POST", "/friends", new BasicDosProtectorOptions() { AllowXForwardedFor = true, ForgetTimeSpan = TimeSpan.FromMinutes(2), MaxRequestsInTimeframe = 20, ReportingName = "FRIENDSDOSPROTECTOR", RequestTimeSpan = TimeSpan.FromSeconds(5), ThrottledAction = BasicDOSProtector.ThrottleAction.DoThrottledMethod }) { m_FriendsModule = fmodule; }
public void Init() { IConfigSource config = new IniConfigSource(); config.AddConfig("Modules"); // Not strictly necessary since FriendsModule assumes it is the default (!) config.Configs["Modules"].Set("FriendsModule", "FriendsModule"); config.AddConfig("Friends"); config.Configs["Friends"].Set("Connector", "OpenSim.Services.FriendsService.dll"); config.AddConfig("FriendsService"); config.Configs["FriendsService"].Set("StorageProvider", "OpenSim.Data.Null.dll"); m_scene = SceneHelpers.SetupScene(); m_fm = new FriendsModule(); SceneHelpers.SetupSceneModules(m_scene, config, m_fm); }
public void Init() { // We must clear friends data between tests since Data.Null holds it in static properties. This is necessary // so that different services and simulator can share the data in standalone mode. This is pretty horrible // effectively the statics are global variables. NullFriendsData.Clear(); IConfigSource config = new IniConfigSource(); config.AddConfig("Modules"); // Not strictly necessary since FriendsModule assumes it is the default (!) config.Configs["Modules"].Set("FriendsModule", "FriendsModule"); config.AddConfig("Friends"); config.Configs["Friends"].Set("Connector", "OpenSim.Services.FriendsService.dll"); config.AddConfig("FriendsService"); config.Configs["FriendsService"].Set("StorageProvider", "OpenSim.Data.Null.dll"); m_scene = new SceneHelpers().SetupScene(); m_fm = new FriendsModule(); SceneHelpers.SetupSceneModules(m_scene, config, m_fm); }
public FriendsRequestHandler(FriendsModule fmodule) : base("POST", "/friends") { m_FriendsModule = fmodule; }
public FriendsRequestHandler(FriendsModule fmodule) : base("POST", "/friends") { m_FriendsModule = fmodule; }
/* * public FriendsRequestHandler(FriendsModule fmodule) * : base("POST", "/friends", new BasicDosProtectorOptions() * { * AllowXForwardedFor = true, * ForgetTimeSpan = TimeSpan.FromMinutes(2), * MaxRequestsInTimeframe = 20, * ReportingName = "FRIENDSDOSPROTECTOR", * RequestTimeSpan = TimeSpan.FromSeconds(5), * ThrottledAction = BasicDOSProtector.ThrottleAction.DoThrottledMethod * }) */ public FriendsSimpleRequestHandler(FriendsModule fmodule) : base("/friends") { m_FriendsModule = fmodule; }