Concrii® configuration
General
All settings must be done within appsettings.json file. This file must be placed besides the concrii executable.
Example appsettings.json file
Here is an example appsettings.json with some basic settings which are very likely mandatory. For further information proceed to System settings and Application settings.
{
"Schedule": "0/10 * * * * *",
"ScheduleFrequencyMs": "5000",
"License": "*put your license key here",
"AllowedHosts": "*",
"AllowedClientCertificates": {
"Filter": [
"Subject.EndsWith(\"localhost\")"
]
},
"Access": {
"Roles": [
{
"Name": "GuiAdmin",
"Policies": [],
"SubRoles": [
"GuiWriter",
"GuiUser"
]
},
{
"Name": "GuiWriter",
"Policies": [
"ColumnSetDecrypted",
"ColumnSetEncrypted",
"ColumnEncrypt",
"ColumnDecrypt",
"ColumnCancelOperation",
"ColumnClearInformation",
"IndexCreate",
"IndexErase",
"IndexCancelOperation",
"IndexClearInformation",
"SystemRestart",
"SystemReloadConfiguration",
"DiagnosticsForceGarbageCollection"
],
"SubRoles": [
"GuiReader"
]
},
{
"Name": "GuiReader",
"Policies": [
"ColumnRead",
"StatusRead",
"ConfigurationRead",
"FriendsRead",
"IndexesRead",
"IndexRead",
"SearchRead",
"Search",
"ValueSearchRead",
"ValueSearch",
"SystemRead",
"SystemReloadConfiguration",
"ExceptionRead",
"DiagnosticsRead"
],
"SubRoles": [
"GuiUser"
]
},
{
"Name": "ApiAdmin",
"Policies": [],
"SubRoles": [
"ApiWriter",
"ApiUser"
]
},
{
"Name": "ApiWriter",
"Policies": [
"FriendSetMeOnline",
"FriendSetMeOffline",
"FriendIUpdatedMe",
"FriendIUpdatedAnIndex",
"IndexCancelOperation",
"IndexClearInformation",
"IndexCreate",
"IndexUpdate",
"IndexErase"
],
"SubRoles": [
"ApiReader"
]
},
{
"Name": "ApiReader",
"Policies": [
"FriendStatus",
"IndexRead",
"IndexesRead",
"IndexSearch",
"IndexSearchGet",
"IndexSearchIds",
"IndexSearchIdsGet",
"IndexSearchValues",
"IndexSearchValuesGet",
"IndexGetFromIds",
"IndexGetAll",
"IndexGetValuesFromIds",
"Search",
"ValueSearch",
"ExceptionRead"
],
"SubRoles": [
"ApiUser"
]
},
{
"Name": "ApiUser",
"Policies": [
"ApiAccess"
]
},
{
"Name": "GuiUser",
"Policies": [
"GuiAccess",
"AccessInformationRead"
]
}
],
"Contexts": [],
"Basic": {
"Active": true,
"Realm": "concrii",
"AllowInsecureProtocol": false,
"SuppressWWWAuthenticateHeader": true
},
"User": [
{
"Name": "Admin",
"Password": "*Put Admin password here and cipher it*"
},
{
"Name": "Superadmin",
"Password": "*Put Superadmin password here and cipher it*"
}
],
"UserAssignments": [
{
"Filter": [
"Identity.Name.Equals(\"Admin\")"
],
"Roles": [
"GuiAdmin"
]
},
{
"Filter": [
"Identity.Name.Equals(\"Superadmin\")"
],
"Roles": [
"GuiAdmin",
"ApiAdmin"
],
"Policies": [
"ConfigurationWrite",
"ExceptionStackTraceRead"
]
}
],
"ClientCertificate": {
"Active": true,
"EnableCrlCheck": false,
"Assignments": [
{
"Filter": [
"Subject.Equals(\"CN=localhost\")"
],
"Roles": [
"ApiAdmin"
]
}
]
},
"OAuth": []
},
"Client": {
"Certificate": {
"Path": "certificates\\localhost.pfx",
"Password": "*Put password of localhost.pfx here and cipher it*"
}
},
"Server": {
"Endpoints": [
{
"Host": "*",
"Scheme": "https",
"Port": "443",
"CertificateMode": "none",
"SslProtocol": "Tls12",
"SslCertificate": {
"Path": "certificates\\localhost.pfx",
"Password": "*Put password of localhost.pfx here and cipher it*"
}
},
{
"Host": "*",
"Scheme": "https",
"Port": "444",
"CertificateMode": "require",
"SslProtocol": "Tls12",
"SslCertificate": {
"Path": "certificates\\localhost.pfx",
"Password": "*Put password of localhost.pfx here and cipher it*"
}
}
]
},
"MaxSearchResults": "35000",
"Serilog": {
"Using": [
"Serilog.Sinks.File",
"Serilog.Expressions"
],
"MinimumLevel": {
"Default": "Error",
"Override": {
"bizconAG": "Debug"
}
},
"WriteTo": [
{
"Name": "File",
"Args": {
"path": "logs\\log.txt",
"rollingInterval": "Day",
"outputTemplate": "{Timestamp:yyyy-MM-dd HH:mm:ss.fff} [{ThreadId}][{Level:u3}]{RequestId} {Message:lj} <s:{SourceContext}>{NewLine}{Exception}"
}
}
],
"Enrich": [
"FromLogContext",
"WithMachineName",
"WithThreadId"
],
"Properties": {
"Application": "concrii"
}
},
"Id": "concrii.1",
"OfflineForFriends": false,
"Friends": [],
"Schedules": [
{
"Name": "Update friends",
"Schedule": "0/60 0/1 * * * *",
"Configuration": {
"type:bizconAG.concrii.Worker.ScheduledWorker.UpdateFriendsConfiguration, bizconAG.concrii.Worker": {}
}
},
{
"Name": "Set indexes",
"Schedule": "0/60 0/2 * * * *",
"Configuration": {
"type:bizconAG.concrii.Worker.ScheduledWorker.SetIndexesConfiguration, bizconAG.concrii.Worker": {}
}
},
{
"Name": "Create indexes",
"Schedule": "0/60 0/5 * * * *",
"Configuration": {
"type:bizconAG.concrii.Worker.ScheduledWorker.CreateIndexesConfiguration, bizconAG.concrii.Worker": {}
}
},
{
"Name": "Update indexes",
"Schedule": "0/60 0/3 * * * *",
"Configuration": {
"type:bizconAG.concrii.Worker.ScheduledWorker.UpdateIndexesConfiguration, bizconAG.concrii.Worker": {}
}
},
{
"Name": "Heal indexes",
"Schedule": "0/60 0/20 * * * *",
"Configuration": {
"type:bizconAG.concrii.Worker.ScheduledWorker.HealIndexesConfiguration, bizconAG.concrii.Worker": {}
}
},
{
"Name": "Update table status",
"Schedule": "0/60 0/10 * * * *",
"Configuration": {
"type:bizconAG.concrii.Worker.ScheduledWorker.UpdateTableStatusConfiguration, bizconAG.concrii.Worker": {}
}
},
{
"Name": "Update column status",
"Schedule": "0/60 0/5 * * * *",
"Configuration": {
"type:bizconAG.concrii.Worker.ScheduledWorker.UpdateColumnStatusConfiguration, bizconAG.concrii.Worker": {}
}
}
],
"Databases": [],
"Tables": [],
"EncryptorProvider": {},
"Encryptors": {},
"Columns": [],
"Indexes": [],
"Limiter": [],
"ValuePatcher": {
"whitespaceSplitter:bizconAG.concrii.Index.ValuePatcher.RegexSplitterConfiguration, bizconAG.concrii.Index": {
"Regex": "\\s+"
}
},
"Filter": {
"removeEvenIds:bizconAG.concrii.Index.Filter.ByLinqQueryConfiguration, bizconAG.concrii.Index": {
"Query": "id => int.Parse(id)%2 != 0"
},
"removeOddIds:bizconAG.concrii.Index.Filter.ByLinqQueryConfiguration, bizconAG.concrii.Index": {
"Query": "id => int.Parse(id)%2 == 0"
},
"removeLongValues:bizconAG.concrii.Index.Filter.ByLinqQueryConfiguration, bizconAG.concrii.Index": {
"Query": "Length < 10"
},
"removeShortValues:bizconAG.concrii.Index.Filter.ByLinqQueryConfiguration, bizconAG.concrii.Index": {
"Query": "Length > 9"
}
},
"Utils": {
"GC": {
"Enforce": {
"Search": { "Generation": 1 } ,
"Create": { "Generation": 1 } ,
"Erase": { "Generation": 1 } ,
"Update": { "Generation": 1 }
}
}
}
}