adding fileio permissions, and changes to db access
This commit is contained in:
@@ -9,11 +9,11 @@ namespace NOCQ
|
||||
{
|
||||
public RedisDatabase(){}
|
||||
|
||||
public static void SaveAlert(Alert alert, string host, string q)
|
||||
public static void SaveAlert(Alert alert, string host, string q, int port, int timeout)
|
||||
{
|
||||
using (var redis = new RedisClient(host,
|
||||
Convert.ToInt32(ConfigurationManager.AppSettings["Port"]),
|
||||
Convert.ToInt32(ConfigurationManager.AppSettings["Timeout"])
|
||||
port,
|
||||
timeout
|
||||
))
|
||||
{
|
||||
|
||||
@@ -24,12 +24,12 @@ namespace NOCQ
|
||||
|
||||
}
|
||||
|
||||
public static Alert GetNextAlert(string host, string q )
|
||||
public static Alert GetNextAlert(string host, string q, int port, int timeout )
|
||||
{
|
||||
|
||||
using (var redis = new RedisClient(host,
|
||||
Convert.ToInt32(ConfigurationManager.AppSettings["Port"]),
|
||||
Convert.ToInt32(ConfigurationManager.AppSettings["Timeout"])
|
||||
port,
|
||||
timeout
|
||||
))
|
||||
{
|
||||
var ts = redis.RPop(q);
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
using System.Reflection;
|
||||
using System.Runtime.CompilerServices;
|
||||
|
||||
using System.Security.Permissions;
|
||||
// Information about this assembly is defined by the following attributes.
|
||||
// Change them to the values specific to your project.
|
||||
[assembly: AssemblyTitle("NOCQ")]
|
||||
@@ -15,6 +15,7 @@ using System.Runtime.CompilerServices;
|
||||
// The form "{Major}.{Minor}.*" will automatically update the build and revision,
|
||||
// and "{Major}.{Minor}.{Build}.*" will update just the revision.
|
||||
[assembly: AssemblyVersion("1.0.*")]
|
||||
[assembly: FileIOPermission]
|
||||
// The following attributes are used to specify the signing key for the assembly,
|
||||
// if desired. See the Mono documentation for more information about signing.
|
||||
//[assembly: AssemblyDelaySign(false)]
|
||||
|
||||
Reference in New Issue
Block a user