I found out that the problem is this part : this:_a650.argument1="this is a test" Does anyone know what does this expression in XAML file mean within Activity tag?
If I take this out this:_a650.argument1="this is a test"
then I can open the workflow file in a workflow designer with no problem, but when it is there I get the follwoing error message: Workflow Designer encountered problems with your document
Please check the document for invalid content,namespace, references or reference loops.
could not find member argument1 in type _a650
Any ideas?
<Activity mc:Ignorable="sap sads" x:Class="{x:Null}" this:_a650.argument1="this is a test"
xmlns="http://schemas.microsoft.com/netfx/2009/xaml/activities"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:mva="clr-namespace:Microsoft.VisualBasic.Activities;assembly=System.Activities"
xmlns:s="clr-namespace:System;assembly=mscorlib"
xmlns:s1="clr-namespace:System;assembly=System"
xmlns:s2="clr-namespace:System;assembly=System.Core"
xmlns:s3="clr-namespace:System;assembly=System.ServiceModel"
xmlns:sads="http://schemas.microsoft.com/netfx/2010/xaml/activities/debugger"
xmlns:sap="http://schemas.microsoft.com/netfx/2009/xaml/activities/presentation"
xmlns:scg="clr-namespace:System.Collections.Generic;assembly=mscorlib"
xmlns:this="clr-namespace:"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
<x:Members>
<x:Property Name="argument1" Type="InArgument(x:String)" />
</x:Members>
<sap:VirtualizedContainerService.HintSize>526.4,369.6</sap:VirtualizedContainerService.HintSize>
<mva:VisualBasic.Settings>Assembly references and imported namespaces for internal implementation</mva:VisualBasic.Settings>
<Sequence sap:VirtualizedContainerService.HintSize="486.4,329.6">
<sap:WorkflowViewStateService.ViewState>
<scg:Dictionary x:TypeArguments="x:String, x:Object">
<x:Boolean x:Key="IsExpanded">True</x:Boolean>
</scg:Dictionary>
</sap:WorkflowViewStateService.ViewState>
<If Condition="[2 = 2]" sap:VirtualizedContainerService.HintSize="464,204.8" />
</Sequence>
</Activity>
Change the x:Class={x:Null} attribute to _a650. XAML should open fine then.
<Activity mc:Ignorable="sap" x:Class="_a650" this:_a650.argument1="this is a test" ... >
The expression this:_a650.argument1="this is a test" together with the Property definition inside Members declare an IN argument of type String (with "this is a test" as its default value) belonging to a _a650 type.
<x:Property Name="argument1" Type="InArgument(x:String)" />
The answer to this question is related to one of your other questions Visual Studio 2010 - Workflow Designer encountered problems on SO. Since, the arguments have to be declared as members of a type but the "root" activity has not been named to derive the type from; a random type name (like _a650) is generated and used.
The "root" activity name, however, is not updated and so upon XAML serialization x:Class is still generated as {x:Null}. This results in a namespace error when this same XAML is opened in Workflow Designer as the XAML parser is unable to find any x:Class declared to be of _a650 type.
Related
I am deploying simple dmn file created by camunda modeller (4.2.0, UPDATE same with 4.12.0 Release Date: January 18, 2022):
<?xml version="1.0" encoding="UTF-8"?>
<definitions xmlns="https://www.omg.org/spec/DMN/20191111/MODEL/" xmlns:dmndi="https://www.omg.org/spec/DMN/20191111/DMNDI/" xmlns:dc="http://www.omg.org/spec/DMN/20180521/DC/" xmlns:di="http://www.omg.org/spec/DMN/20180521/DI/" id="Definitions_0sib65s" name="DRD" namespace="http://camunda.org/schema/1.0/dmn" exporter="Camunda Modeler" exporterVersion="4.2.0">
<decision id="Decision_1qnsi7h" name="Decision 1">
<informationRequirement id="InformationRequirement_1n68q12">
<requiredInput href="#InputData_0cvdsfu" />
</informationRequirement>
<decisionTable id="DecisionTable_1o6i63n">
<input id="Input_1">
<inputExpression id="InputExpression_1" typeRef="string">
<text></text>
</inputExpression>
</input>
<output id="Output_1" typeRef="string" />
</decisionTable>
</decision>
<inputData id="InputData_0cvdsfu" />
<dmndi:DMNDI>
<dmndi:DMNDiagram>
<dmndi:DMNShape dmnElementRef="Decision_1qnsi7h">
<dc:Bounds height="80" width="180" x="160" y="100" />
</dmndi:DMNShape>
<dmndi:DMNShape id="DMNShape_0cj7rh9" dmnElementRef="InputData_0cvdsfu">
<dc:Bounds height="45" width="125" x="198" y="298" />
</dmndi:DMNShape>
<dmndi:DMNEdge id="DMNEdge_17tvn8k" dmnElementRef="InformationRequirement_1n68q12">
<di:waypoint x="261" y="298" />
<di:waypoint x="250" y="200" />
<di:waypoint x="250" y="180" />
</dmndi:DMNEdge>
</dmndi:DMNDiagram>
</dmndi:DMNDI>
</definitions>
but it fails with error:
java.lang.RuntimeException: org.camunda.bpm.engine.ProcessEngineException: ENGINE-08043 Exception while performing 'Deployment of Process Application application' => 'Deployment of process archive 'null': ENGINE-22004 Unable to transform DMN resource 'bpmn/diagram_1.dmn'.
...
Caused by: org.xml.sax.SAXException: Error: URI=null Line=2: cvc-elt.1.a: Cannot find the declaration of element 'definitions'.
Deployment is via resource in standard spring boot project with dependency:
<dependency>
<groupId>org.camunda.bpm.springboot</groupId>
<artifactId>camunda-bpm-spring-boot-starter-webapp</artifactId>
<version>3.4.0</version>
</dependency>
This error did come up multiple times on internet:
On camunda forum itself user does not know how/if he solved this issue.
Other search result also does not have answer.
In general looking into "Cannot find the declaration of element" error (f.e. here on SE ) I do not see any issue with the dmn file - it has default xmlns="https://www.omg.org/spec/DMN/20191111/MODEL/" and also namespace="http://camunda.org/schema/1.0/dmn" declared correctly AFAIK.
Here it is suggested to change the namespace so I used <definitions xmlns="http://www.omg.org/spec/DMN/20151101/dmn11.xsd" but that does not seem to match xml file created by camunda modeller (cvc-complex-type.3.2.2: Attribute 'id' is not allowed to appear in element 'informationRequirement') but it seems to helped with 'definitions' element (Not sure why)?.
BPMN files created and deployed same way are working without issues! They are a bit different - ...<bpmn:definitions xmlns:bpmn="http://www.omg.org/spec/BPMN/20100524/MODEL"... but that should be ok in my knowledge.
The DMN standard was upgraded to version 1.3, hence the difference in the namespace. You are using a pretty old model/er version. Try to upgrade.
Your DMN does not contain any column definitons or rules. Please try a complete valid DMN, e.g. one of those:
https://github.com/rob2universe/process-models/tree/master/dmn/dinnerDecision
I am trying to create a bootstrapper project in Visual Studio 2015 using Wix.
<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi"
xmlns:netfx="http://schemas.microsoft.com/wix/NetFxExtension"
xmlns:bal="http://schemas.microsoft.com/wix/BalExtension">
<Bundle Name="..." Version="1.0.0.0" Manufacturer="..." UpgradeCode="...">
<BootstrapperApplicationRef Id="WixStandardBootstrapperApplication.RtfLicense">
<bal:WixStandardBootstrapperApplication LicenseFile="mtel-eula-free.rtf"/>
</BootstrapperApplicationRef>
<BootstrapperApplicationRef Id="WixBootstrapperApplication:WixNetFxExtension" />
<BootstrapperApplicationRef Id="ManagedBootstrapperApplicationHost">
<Payload
Name="BootstrapperCore.config"
SourceFile="$(var.TargetDir)\BootstrapperCore.config"/>
<Payload
SourceFile="$(var.TargetPath)"/>
</BootstrapperApplicationRef>
<Chain>
<PackageGroupRef Id="NetFx45Web"/>
<MsiPackage Id="MTESetup" SourceFile="$(var.MTESetup.TargetPath)"/>
</Chain>
</Bundle>
</Wix>
The project name for the bootstrapper is MTEBootstrapper and the project name for the wix project for the MSI is MTESetup. For MTEBootstrapper, I added a reference to WixNetFxExtension.dll from Wix 3.10; In the properties of MTEBootstrapper, I added -ext WixNetFxExtension.dll. Now I am getting this error when I try to build MTEBootstrapper:
Error The extension 'Microsoft.Tools.WindowsInstallerXml.Extensions.NetFxExtension' contains a defintion for table 'NetFxNativeImage' that collides with a previously loaded table definition. Please remove one of the conflicting extensions or rename one of the tables to avoid the collision. MTEBootstrapper light.exe 0
I have no idea what is causing this. How do I fix it?
It looks like this error surfaces when I have both the reference to WixNetFxExtension added to MTEBootstrapper and the -ext option for the linker. I removed the -ext option for the linker and collision error disappeared.
(Separately I am getting an unresolved symbol WixNetFxExtension, which I will file a separate question for.)
I'm making an application that runs in XULRunner on Windows.
There I created the browser-toolbar binding that will be used in different places. While the binding needs to look the same it should execute different commands on button clicks.
I'm trying to accomplish it like this (code is simplified, namespaces are dropped):
<binding id="custom-browser-type-a">
<content>
<commandset>
<command id="TypeA:Home" oncommand="home()"/>
<command id="TypeA:Back" oncommand="back()"/>
</commandset>
<browser-toolbar cmd_home="TypeA:Home" cmd_back="TypeA:Back" ... />
<browser/>
</content>
<implementation>
...
</implementation>
</binding>
<binding id="browser-toolbar">
<content>
<toolbar>
<toolbarbutton label="Home" xbl:inherits="command=cmd_home"/>
<toolbarbutton label="Back" xbl:inherits="command=cmd_back"/>
...
</toolbar>
</content>
</binding>
Once clicked a toolbarbutton execute an assigned command just fine. The problem is when I disable a command it doesn't affect the disabled state of a corresponding toolbarbutton, it stays enabled. Does anyone have any idea why that is not working?
Thank you!
I want my install to fail if a third-party software element is not installed. I added a Fragment with a util:RegistrySearch and a bal:Condition to the Bundle, but I can't get it to work. ThirdPartyCOMLibraryInstalled never evaluates to true. I've confirmed that the key exists, and the value I use for Key is correct - I copy/pasted the name from the selected key in regedit. There aren't any errors in the log.
I'm building the installer with WiXTools 3.7 in Visual Studio 2012 on Windows 7 64-bit and testing on both Windows XP SP3 and Windows 7 64-bit.
Searching online for other examples for util:RegistrySearch I ran across the following alternative forms for the condition test expression.
ThirdPartyCOMLibraryInstalled = 0 - always False
ThirdPartyCOMLibraryInstalled <> 1 - always True
Here is the Bundle code:
<?xml version="1.0" encoding="UTF-8"?>
<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi"
xmlns:util="http://schemas.microsoft.com/wix/UtilExtension"
xmlns:netfx="http://schemas.microsoft.com/wix/NetFxExtension"
xmlns:bal="http://schemas.microsoft.com/wix/BalExtension">
<Bundle Name="!(bind.packageName.MyApp)"
Version="!(bind.packageVersion.MyApp)"
Manufacturer="!(bind.packageManufacturer.MyApp)"
UpgradeCode="a07ce1d5-a7ed-4d89-a7ee-fb13a5dd69ba"
Copyright="Copyright (c) 2013 [Bundle/#Manufacturer]. All rights reserved."
IconSourceFile="$(var.My_Application1.ProjectDir)MyCo.ico">
<bal:Condition Message="ThirdParty Application COM Library Required. Please (re)install ThirdParty Application and ensure 'Windows API' and '.NET Components' are installed."
>ThirdPartyCOMLibraryInstalled</bal:Condition>
<Variable Name="InstallFolder"
Type="string"
Value="[ProgramFilesFolder]MyCo Systems\My_Application\"/>
<BootstrapperApplicationRef
Id="WixStandardBootstrapperApplication.HyperlinkLicense" >
<bal:WixStandardBootstrapperApplication
ThemeFile="Resources\HyperlinkTheme.xml"
LaunchTarget="[InstallFolder]My_Application.exe"
LocalizationFile="Resources\HyperlinkTheme.wxl"
SuppressRepair="yes"
SuppressOptionsUI="yes"
LicenseUrl=""
LogoFile="Resources/MyCoLogoWt64.png"
/>
</BootstrapperApplicationRef>
<Chain>
<PackageGroupRef Id="NetFx40Redist"/>
<MsiPackage Id ="MyApp"
Vital="yes"
Name="My Application"
SourceFile="$(var.MyApp_Install.TargetDir)MyApp_Install.msi">
<MsiProperty Name="INSTALLLOCATION"
Value="[InstallFolder]" />
</MsiPackage>
</Chain>
</Bundle>
<Fragment>
<util:RegistrySearch
Variable="ThirdPartyCOMLibraryInstalled"
Result="exists"
Root="HKLM"
Key="SOFTWARE\Classes\ThirdPartyId.Server\CLSID"/>
</Fragment>
</Wix>
The root issue is that the RegistrySearch is in a separate Fragment that never gets referenced. Because nothing in the Fragment gets referenced the linker "optimizes away" the contents of the Fragment and the search is not included in your Bundle.
Aside: you could argue that the fact that there is a reference to the variable mentioned in the search in the Condition that the linker should be able to figure out that the search is necessary. However, that doesn't work out in all cases.
Fortunately, the solution is quite simple! You even have to choose from one of two:
Move the RegistrySearch element to the Bundle element.
Add a RegistrySearchRef element in the Bundle element to reference the RegistrySearch in the Fragment. You will also need to give the RegistrySearch and Id attribute.
Personally, I like option two and I would probably even move the Condition into the Fragment as well to group all that stuff together. Something akin to:
<Bundle ...>
<util:RegistrySearchRef Id='SearchForThirdParty' />
...
</Bundle>
<Fragment>
<util:RegistrySearch
Id='SearchForThirdParty'
Variable="ThirdPartyCOMLibraryInstalled"
Result="exists"
Root="HKLM"
Key="SOFTWARE\Classes\ThirdPartyId.Server\CLSID"/>
<bal:Condition Message="ThirdParty Application COM Library Required. Please (re)install ThirdParty Application and ensure 'Windows API' and '.Net Components' are installed.">ThirdPartyCOMLibraryInstalled</bal:Condition>
</Fragment>
</Wix>
That should do it.
I followed How to prepare database for TFS deployment walkthrough
and my build script successfully deploys the database at the end of the build process. However, I need the database to be deployed before running unit tests.
I tried copying the step and pasting it right above "Get Impacted Tests, Index Sources and Publish Symbols". However, the build process returns the following error:
* The deployment manifest file Database_Core.deploymanifest does not exist
Here is the excerpt from my xaml file for the database deploy:
<Sequence DisplayName="Deploy Database" sap:VirtualizedContainerService.HintSize="486,330">
<sap:WorkflowViewStateService.ViewState>
<scg:Dictionary x:TypeArguments="x:String, x:Object">
<x:Boolean x:Key="IsExpanded">True</x:Boolean>
<x:Boolean x:Key="IsPinned">True</x:Boolean>
</scg:Dictionary>
</sap:WorkflowViewStateService.ViewState>
<If Condition="[BuildDetail.CompilationStatus <> BuildPhaseStatus.Failed]" DisplayName="If Build Succeeded" sap:VirtualizedContainerService.HintSize="464,206">
<sap:WorkflowViewStateService.ViewState>
<scg:Dictionary x:TypeArguments="x:String, x:Object">
<x:Boolean x:Key="IsPinned">True</x:Boolean>
</scg:Dictionary>
</sap:WorkflowViewStateService.ViewState>
<If.Then>
<mtbwa:InvokeProcess Arguments="["/a:Deploy /cs:""Data Source=MyServer-SQL1\BUILD;Integrated Security=True;Pooling=False"" /dd+ /dsp:Sql /manifest:Database_Core.deploymanifest"]" DisplayName="Invoke VSDBCMD" FileName="C:\Program Files (x86)\Microsoft Visual Studio 10.0\VSTSDB\Deploy\VSDBCMD.EXE" sap:VirtualizedContainerService.HintSize="219,100" WorkingDirectory="[BuildDetail.DropLocation]">
<mtbwa:InvokeProcess.ErrorDataReceived>
<ActivityAction x:TypeArguments="x:String">
<ActivityAction.Argument>
<DelegateInArgument x:TypeArguments="x:String" Name="errOutput" />
</ActivityAction.Argument>
<mtbwa:WriteBuildError DisplayName="VSDBCMD Error" sap:VirtualizedContainerService.HintSize="200,22" Message="[errOutput]" />
</ActivityAction>
</mtbwa:InvokeProcess.ErrorDataReceived>
<mtbwa:InvokeProcess.OutputDataReceived>
<ActivityAction x:TypeArguments="x:String">
<ActivityAction.Argument>
<DelegateInArgument x:TypeArguments="x:String" Name="stdOutput" />
</ActivityAction.Argument>
<mtbwa:WriteBuildMessage DisplayName="VSDBCMD Output" sap:VirtualizedContainerService.HintSize="200,22" Importance="[Microsoft.TeamFoundation.Build.Client.BuildMessageImportance.High]" Message="[stdOutput]" mva:VisualBasic.Settings="Assembly references and imported namespaces serialized as XML namespaces" />
</ActivityAction>
</mtbwa:InvokeProcess.OutputDataReceived>
<sap:WorkflowViewStateService.ViewState>
<scg:Dictionary x:TypeArguments="x:String, x:Object">
<x:Boolean x:Key="IsPinned">False</x:Boolean>
</scg:Dictionary>
</sap:WorkflowViewStateService.ViewState>
</mtbwa:InvokeProcess>
</If.Then>
<If.Else>
<mtbwa:WriteBuildWarning DisplayName="Deployment Skipped" sap:VirtualizedContainerService.HintSize="220,100" Message="Database deployment was skipped" />
</If.Else>
</If>
</Sequence>
This is exactly what I needed as well. Please see here a PNG that depicts all points that follow:
At first I arranged a set of Arguments in my build process template, where I set the target Database host, the user & the password. (See "Argument" section)
In case the current Project's Unit tests need a running DB, I set in "Items to build" 2 different projects:
In the first slot the *.dbproj
In the second the SLN itself
Now within the Build process template I 've expanded the "Run MSBuild for project" as a Sequence (See "Sequence"), ensuring that that the MSBuild Arguments are different in the left case :
Arguments for MSBuild on the left side ("Run MSBuild + Deploy DB"):
String.Format("/p:SkipInvalidConfigurations=true /t:Build;Deploy /p:TargetConnectionString=""Data Source={0}%3Buser={1}%3Bpwd={2}"" /p:DeployToDatabase=true /p:TargetDatabase={3}_{4} {5}",
TargetMachineToDeployDB, DBUsername, DBPassword, DBName, BuildDetail.BuildNumber.Replace(".", "_"), MSBuildArguments)
In case it's not too obvious, the connection between the Arguments & the displayed params in the Definition are:
- TargetMachineToDeployDB = "PC name where Database shall be deployed"
- DBUsername = "Database Username"
- DBPassword = "Database Password"
- DBName = "Database Prefix Name" (I concat the current buildname)
Arguments for MSBuild on the right side ("Run MSBuid for SLN/Project"):
String.Format("/p:SkipInvalidConfigurations=true {0}", MSBuildArguments)
Note that if I deployed a DB on the left side, I will also set a DBHasBeenSet into TRUE, which will also trigger some file handling inside "Adaptations in Source Files". These include redirecting our NUnit DLLs to the newly constructed DB. I can set more details on that, if you 'd like.
You can change where this happens in your deployment.
I would deploy the database right after your main build command in the workflow. In 2008 with the .proj this a little more clear because you would simply add it to <Target Name=BeforeTest> Try moving it to an earlier point in the process.