我在azure中有一个简单的工作角色,它在SQL azure数据库上进行一些数据处理.工作人员基本上每2分钟将数据从第三方数据源添加到我的数据库.当我有两个角色实例时,这显然会不必要地加倍.我想有2个冗余实例和99.95正常运行时间,但不希望它们同时处理,因为它们只是复制相同的工作.我缺少一个标准模式吗?我知道我可以在数据库中设置标志,但我希望有另一种更简单或更好的方法来管理它.谢谢
我正在尝试为 Azure 数据工厂创建我的 Azure DevOps 发布管道。
我遵循了 Microsoft ( https://docs.microsoft.com/en-us/azure/data-factory/continuous-integration-deployment ) 关于向 ARM 模板添加额外参数的相当神秘的指南发布(https://docs.microsoft.com/en-us/azure/data-factory/continuous-integration-deployment#use-custom-parameters-with-the-resource-manager-template)
arm-template-parameters-definition.json在 master 分支的路由中创建了一个文件。当我做一个发布,则ARMTemplateParametersForFactory.json在adf_publish分支保持完全不变。我尝试了很多配置。
我在数据工厂中定义了一些管道参数,并希望它们在我的部署管道中是可配置的。对我来说似乎是一个明显的要求。
我错过了一些基本的东西吗?请帮忙!
JSON 如下:
{
"Microsoft.DataFactory/factories/pipelines": {
"*": {
"properties": {
"parameters": {
"*": "="
}
}
}
},
"Microsoft.DataFactory/factories/integrationRuntimes": {
"*": "="
},
"Microsoft.DataFactory/factories/triggers": {},
"Microsoft.DataFactory/factories/linkedServices": {},
"Microsoft.DataFactory/factories/datasets": {}
}
Run Code Online (Sandbox Code Playgroud) azure azure-data-factory azure-devops azure-rm-template azure-pipelines
我觉得我快要成功了。我已经写了一百个反序列化例程,但这一个简直要了我的命!
以下是我从服务返回的内容。我认为是一个非常简单的字符串数组。
<ArrayOfstring xmlns="http://schemas.microsoft.com/2003/10/Serialization/Arrays" xmlns:i="http://www.w3.org/2001/XMLSchema-instance">
<string>Action & Adventure</string>
<string>Comedy</string>
<string>Drama</string>
<string>Family</string>
<string>Horror</string>
<string>Independent & World</string>
<string>Romance</string>
<string>Sci-Fi/Fantasy</string>
<string>Thriller & Crime</string>
</ArrayOfstring>
Run Code Online (Sandbox Code Playgroud)
我正在使用开箱即用的反序列化
var serializer = new XmlSerializer(typeof(List<string>));
var reader = new StringReader(xmlString);
var GenreList = (List<string>)serializer.Deserialize(reader);
Run Code Online (Sandbox Code Playgroud)
但我在反序列化行上收到以下错误:
<ArrayOfstring xmlns='http://schemas.microsoft.com/2003/10/Serialization/Arrays'> was not expected
Run Code Online (Sandbox Code Playgroud)
我尝试过包含名称空间并创建各种奇异的对象,以使其正常工作。疯狂的时间。最后,我以 JSON 格式请求它,并使用 Json.net 对其进行反序列化。
但我很好奇我做错了什么!
我试图在Linq中重现以下SQL查询,并需要一些帮助.
select
dbo.Documents.DocId,
dbo.Documents.ReykerAccountRef,
dbo.Documents.ReykerClientId DocClientID,
CAAs.ClientId CAAClientIDCheck,
ClientData.FullName ClientFullName,
CAAs.IFAId,
AdvisorData.FullName AdvisorFullName
from dbo.Documents
left join
dbo.CAAs on dbo.Documents.ReykerAccountRef = dbo.CAAs.AccountRef
left join
dbo.hmsProfileDatas AS ClientData
on
dbo.CAAs.ClientId = ClientData.ReykerClientID
left join
dbo.hmsProfileDatas AS AdvisorData
on
dbo.CAAs.IFAId = AdvisorData.ReykerClientID
Run Code Online (Sandbox Code Playgroud)
我试图两次链接到同一个表,一次是客户端全名,另一次是Advisor全名.
我想在linq中生成的基本sql是
select table1.*,table2.*,a.Fullname, b.Fullname
from table1
left join
table2 on table1.t2Id = table2.Id
left join
table3 AS a
on
table2.t3Id1 = table3.id1
left join
table3 AS b
on
table2.t3Id2 = table3.id2
Run Code Online (Sandbox Code Playgroud)
因此,表1连接到table2,table2有2个外键(t3Id1和t3Id2)到table3到不同的字段(id1和id2).
这是我尝试过的一些指导,但它没有返回任何东西!出了什么问题?
var results3 = from doc in …Run Code Online (Sandbox Code Playgroud)