My Profile
Help
Hot Topics
Top Community Contributors
Bert Dingemans
I am an independent (data) architect and EA consultant working often with enterprise architect mostly for UML class diagrams and ArchiMate 2.0. I am using enterprise architect for generating documentation, XSD files and modelling enterprise architectures with ArchiMate 2.0. I have developed an Open Source Web Publication Platform for EA. I also participate in Eaxpertise.nl. You can reach me at [email protected]
Tickets available for the Dutch EAUG event on June 10th
Would you like to contribute to a worthwhile day of sharing knowledge and techniques around the use of Sparx Enterprise Architect?
Whether you wish to talk about user experiences tools, methodologies and/or your experiences in this field, you are welcome to present your (non commercial) ideas on June 10th at the Dutch Enterprise Architect User Group event.
At this event EAUG we will offer three tracks:
• Modelling experiences in EA
• Howto (changing the functionality of EA or use extensions)
• EA@ (use cases of EA in various organisations)
Do you want more information please contact us via: This email address is being protected from spambots. You need JavaScript enabled to view it. or visit the Enterprise Architect User Group website for more details.
A web publication platform for an ArchiMate model
A web publication platform for an ArchiMate model
Introduction
As an independent Enterprise Architect (EA) consultant I often get the question what the possibilities are for publishing the repository content over the web. Of course in EA there is the possibility to generate a HTML version of the model but in most cases my customers demand extra functionality like key word search or a discussion module.
In my current assignment for the National Health Broker in The Netherlands the introduction of a webbased solution was evident. One of the most important product of this organisation is the architectural documentation of the interfaces of the broker component. The organisation itself is quite small but the external stakeholders like software suppliers, software developers and policy makers is large.
In the current situation the architectural documentation is published in pdf documents. Keeping these documents up to date and correctly linked and integrated with each other is a tedious job. Introduction of an Architecture Repository based on ArchiMate 2.0 and EA helped us a lot. The web-based solution is however an essential part of the solution. This article describes solution we introduced: the Web Publication Platform.
Implementation model
Because the current solution is the implementation of an ArchiMate 2.0 architecture model we use limited data entities from the EA repository. The model is rather large, over 3500 elements and 5000 associations. In the image below the most important elements are displayed and described.
· Packages are extensively used for grouping and sorting elements and diagrams
· Diagrams are used for given summary views of the entities to various stakeholders
· Elements are used to describe the architectural entities. Therefore we use the notes, alias, key word attributes and extra entities which are mentioned below
· Associations for modelling the associations between the elements
· Attributes for data modelling in data objects and artficats within ArchiMate (this is an extension on the methodology)
· Tagged values for extra describing attributes of the elements
· Linked files, because the broker has to keep track of legislation and standardisation constraints which are maintained by other organisations hyperlinks to webpages are essential.
For the implementation of the WPP we decided to use an Open Source Framework for content and form management. It is unnecessary to start from scratch developing a solution. Not only implementing the forms for the architecture repository the form factory solution has a web based interface for the governance of its own (form) entities. In the image below an overview of the functionality
The form factory has various form types that can be used to display information from a relational database. Since the EA repository is also a relational database the interface to the database is implemented in a number of SQL statements and are connected to a form type. The Form Factory engine now handles the request made by the user when using the web application. The views are summarized below:
· Lists and sublists are used to display multiple elements in a screen and make selections to display in detail views
· Detail views to display elements and diagrams including links to associations, attributes and tagged values etc.
· Explorer view is a combination of a tree view and a detail view
· Discussion platform for adding comments to elements by authorized stakeholders
· Search, for key words in combination with a number of filter options
In the image below a sample of an explorer view screen
Some challenges
When implementing the interface to the repository we faced a number of difficulties. We used two architecture principles that limited our options:
· All governance modelling and administrative activies are done by architects via the desktop application of Sparx. The WPP is only used for publication of the information not for modification.
· There are no modifications made to the EA database (eap file). Therefore no tables for the form factory component are implemented in this database.
Below a number of specific challenges are briefly described
Configuring the Form Management System
Because of the second principle we faced the problem that in one detail screen (for example the element detail) we have to display information from two databases in one screen. The Form Factory was not configured for this constraint. Therefore we introduced an abstract class where the sql statements are combined with a connection string so before the sql statement is executed to retrieve the data the connection to the right database is opened. In the code snippet below an
Public Function Detail(entity As String, id As String) As String
Dim strRet As String
Dim strSql As String
Select Case entity.ToUpper
Case "ELEMENT"
Me.ViewerHtml("<H1>Details element</H1>")
Me.ViewerDetail("SELECT name as elementnaam, stereotype, note as toelichting, '<a href=FrmDetail.aspx?module=package&id=' & package_id & '>Module informatie</a>' as [module] FROM [t_object] WHERE [object_id]=" & id)
Dim strCon As String
strCon = "SELECT start_object_id, '<img src=images/' & t_object.stereotype & '.png >' as logo, connector_type as type, t_object.name as element FROM [t_connector], [t_object] WHERE [t_connector].start_object_id = t_object.object_id AND [end_object_id]=" & id
strCon += " UNION "
strCon += "SELECT end_object_id, '<img src=images/' & t_object.stereotype & '.png >' as logo, connector_type as type, t_object.name as element FROM [t_connector], [t_object] WHERE [t_connector].end_object_id = t_object.object_id AND [start_object_id]=" & id
strCon += " ORDER BY 2, 3 "
Me.ViewerList(strCon, "FrmDetail.aspx?module=element&id=", "<H2>Associaties</H2>")
Me.ViewerList("SELECT t_diagram.diagram_id, t_diagram.name as diagramnaam FROM [t_diagramobjects], [t_diagram] WHERE [t_diagramobjects].diagram_id = [t_diagram].diagram_id AND [t_diagramobjects].object_id=" & id & " ORDER BY 2 ", "FrmDetail.aspx?module=diagram&id=", "<H2>Weergegeven in diagrammen</H2>")
Me.ViewerList("SELECT object_id, filename as bestandsnaam, '<a target=_blank href=' & filename & ' >Open bestand</a>' as link FROM [t_objectfiles] WHERE [object_id]=" & id, "", "<H2>Gekoppelde bestanden</H2>")
Me.ViewerList("SELECT ID, name as naam, container as [afkomstig van], lowerbound as mincard, upperbound as maxcard, notes as toelichting FROM [t_attribute] WHERE [object_id]=" & id, "", "<H2>Attributen</H2>")
Me.ViewerList("SELECT propertyid, property as eigenschap, value as waarde, notes as toelichting FROM [t_objectproperties] WHERE property LIKE 'Vz%' AND [object_id]=" & id, "", "<H2>Extra items</H2>")
If ViewerFactoryHelper.IsDiscussieLid() Then
Me.ViewerList("SELECT ea_discussion_id, EA_DISCUSSION.datum, EA_DISCUSSION.onderwerp, EA_DISCUSSION.toelichting, '<a class=''ddbutton'' href=cmsForm.aspx?formid=50315&ea_discussion_id=' & ea_discussion_id & ' >Detail en Reageer</a>' as link FROM EA_DISCUSSION WHERE EA_DISCUSSION.element_id = " & id & " ORDER BY 1 DESC", "", "<h2>Gestarte discussies over dit element</h2>", ConfigurationManager.AppSettings("connectionstring"))
Me.ViewerHtml("<a class='ddbutton' href='cmsForm.aspx?formid=50301&element_id=" & id & "' >Start Nieuwe discussie over dit element</a><br>")
End If
Case Else
MyBase.objSB.Append("Niet gevonden")
End Select
strRet = MyBase.objSB.ToString()
Return strRet
End Function
In the code you can see a number of statements in combination with a connectionstring. The sql statements are also very informative because it gives an idea of how the information is retrieved from the repository. The viewer functions like ViewerHTML are used to call the right formtype in the form factory engine.
Exporting diagrams
One of the powerful aspects of EA is the diagramming tool in combination with the relational database to store the information. Reason to re use the diagrams in the WPP, but how to export the diagram’s from EA to a file readable in a web application.
The automation or scripting interface of EA offered a solution that was easy to implement. We export all the diagrams to a png file in a certain folder on a disk and this folder is published over FTP to the implementation of the WPP application. The code to export the diagrams is given below (the script can also be found on the WPP website.
option explicit
!INC Local Scripts.EAConstants-VBScript
' WARNING Change this constant for your own Export Directory
public const DirName = "c:\testbert"
sub OnProjectBrowserScript()
' Get the type of element selected in the Project Browser
dim treeSelectedType
treeSelectedType = Repository.GetTreeSelectedItemType()
' Handling Code: Uncomment any types you wish this script to support
' NOTE: You can toggle comments on multiple lines that are currently
' selected with [CTRL]+[SHIFT]+[C].
select case treeSelectedType
case otPackage
' Code for when a package is selected
dim thePackage as EA.Package
set thePackage = Repository.GetTreeSelectedObject()
ExportDiagrams(thePackage)
Session.Prompt "Diagrams exported to " & DirName, promptOK
case else
' Error message
Session.Prompt "This script does not support items of this type.", promptOk
end select
end sub
Sub ExportDiagrams(objPackage)
Dim objProject as EA.Project
Dim objDiagram as EA.Diagram
set objProject = Repository.GetProjectInterface()
For Each objDiagram In objPackage.Diagrams
Repository.OpenDiagram(objDiagram.DiagramID)
objProject.SaveDiagramImageToFile(DirName & "\" & objDiagram.DiagramID & ".png")
Repository.CloseDiagram(objDiagram.DiagramID)
Next
Dim objChild
For Each objChild In objPackage.Packages
ExportDiagrams(objChild)
Next
End Sub
OnProjectBrowserScript
The export diagram routine in the code does the job. We loop through a collection of diagrams in a package and each diagram is saved with the objProject.SaveDiagramImageToFile() method. The parameters and naming is connected to the naming convention in the WPP implementation.
The open source solution
For this WPP platform we decided to publish it as an Open Source Solution in the hope that a community of users will emerge to continue the development of this solution. This means that the code can be downloaded from the WPP website. This WPP website is by the way an example of a architecture repository view based on the form factory framework. It is actually a WPP publication of a sample repository in an eap file in combination with some extra information pages about the product.
More information
More information about the WPP is available at the WPP website: http://wpp.interactory.nl . Please subscribe to the community and use the material in your own situation. Also take part in the forums to report bugs or discuss new functionality. In the blog section I with regularly describe functionality etc. When you want to have more information about modelling in ArchiMate or the usage of architecture repository please contact me via the contact page of the wpp website.
Duplicate validation in Enterprise Architect
Duplicatevalidation in Enterprise Architect
Introduction
This article is an example of using Enterprise Architect in a team. In our team of four architects we use Enterprise Architect for modelling the enterprise architecture in ArchiMate 2.0. For this government agency with approximately 1200 employees there is a large repository of architectural elements, building blocks and diagrams.
Because we maintain this repository with four architects a number of challenges arise:
-
Everybody uses the same definition of elements and concepts
-
The repository structure is managed by one authorized team-member (the custodian)
-
There is agreement about the architecture process and products
These activities are embedded in the team structure and process and gives us the opportunity to cooperate in producing our architect documents and products. However one problem is hard to solve: the duplication of architecture elements. This article introduces a solution based on a automation extension for Enterprise Architect.
The problem
The repository in our organisation has around 2000 ArchiMate elements stored in a relational database. The repository explorer has therefor a tree-structure with multiple layers and multiple entrypoints. For creating a model and the containing elements these is a description of an architecture modelling process, see the paragraph below. However this process is not always followed.
This causes a problem of duplication of elements. In the figure below we see an example of this problem. There are three architects that created a model for their one document or project and they did not validate the repository for existence of the elements. This causes that there are elements with the same characteristics in the repository
Figure: Duplication problem
This duplication problem has a number of disadvantages like:
-
Associations of elements with other elements and diagrams are incomplete
-
Documentation and notes are scattered over the duplicated elements
-
Future use of elements can cause further inconsistencies and duplications
-
Merging of duplicated elements is a time-consuming activity
Therefor we search for a solution to tackle this problem based on the automation model of Enterprise Architect.
The modellingprocess
The modelling process has a number of steps based on the structure of the user interface in Enterprise Architect. In the figure below you can see the steps of this process in an ArchiMate notation. The steps in the figure is the correct process and it includes a step to check for existence of each element in the repository before creating it.
Figure Correct modelling process
Unfortunately this correct process has an extra step which is easily forgotten when the model is created. For example in an interactive workshop with the stakeholders, the validation step is time-consuming for the architect and therefor forgotten. In the figure below you see the incomplete process.
Figure Incomplete modelling process
A repository which is based on an incomplete modelling process will slowly be polluted with duplicate elements and is therefor harder to maintain and use for future diagrams. To reduce this risk the following solution is introduced.
The solution
The solution is an automation extension developed in VB.Net and attached to Enterprise Architect as an extension. There are a number of entries available:
-
After creating or modifying an element in the repository the element properties like stereotype and name are validated for existence in the repository. When this is the case the user gets a warning.
In a diagram or in a package in the explorer the extension menu has an extra option for validating all the elements in the diagram or packages. When there are duplicated elements these are displayed in a overview dialog window.
In the figure below you see an example of the validation screen. When an element is visible in this screen it has one or more duplicates
Figure: Duplicate screen
Implementation of the extension
For the implementation of the extension I used the examples on the website of Sparx. Furthermore the article of Geert Bellekens was of great value see http://bellekens.com/2011/01/29/tutorial-create-your-first-c-enterprise-architect-addin-in-10-minutes/
Unfortunalety I am a developer older than fourty and therefore experienced in VB.Net and less in C#. Howeverthere is a web converterfor C# and VB.Net that is of great assistance in this situation. See http://www.developerfusion.com/tools/convert/csharp-to-vb/ for more information.
The source code of the extension is divided in threesections:
-
Handling the events
-
Do the validation checks
-
Display warnings or lists of elements
The first section is an implemention three events of the mentioned examples. The second section is of more interest and a codesnippet is given below:
Private Function CheckUniqueElement(oElement As EA.Element,_
oRepo As EA.Repository) As Boolean
Dim sSql As String
If oElement.Stereotype.Length > 0 Then
sSql = "SELECT Count(*) as aantal FROM t_object
WHERE t_object.name = '#name#' AND t_object.Stereotype='#stereotype#'
AND t_object.ea_guid<>'#guid#' "
sSql = Replace(sSql, "#name#", oElement.Name)
sSql = Replace(sSql, "#stereotype#", oElement.Stereotype)
sSql = Replace(sSql, "#guid#", oElement.ElementGUID)
strVal As String
strVal = oRepo.SQLQuery(sSql)
Return strVal.Contains("<aantal>0</aantal>")
End If
Return True
End Function
In the codesnippet a simple check is made based on a SQL statement. This statement checks for duplication on name and stereotype of the element. For ArchiMate this is sufficient, possibly for other notations another combination of attributes is necessary.
Another part of the validation section is looping through the collection of elements in a package or diagram. The code below shows the example of the diagram function:
If Location.ToUpper() = "DIAGRAM" Then
Dim oElement As EA.Element
Dim oDiagramObject As EA.DiagramObject
For EachoDiagramObject In _
Repository.GetCurrentDiagram().DiagramObjects
oElement = Repository.GetElementByID(oDiagramObject.ElementID)
If Me.CheckUniqueElement(oElement, Repository) = FalseThen
oWnd.AddElement(oElement)
End If
Next
End If
The last section of the display on the screen of the validation results is handled. In the source code files of the download you can find the example.
Using the extension
This extension is developed as a solution in Visual Studio Express. The solution is available in a zip file and can be downloaded from http://www.interactory.nl/frmFormManager.aspx?webpage=dla2ea
When you compile the solution in Visual Studio it is automatically registered for automation usage in the registry. For deployment without Visual Studio you have to use regasm.exe. Make sure that you use the correct version of regasm.exe, especially when you have multiple versions of the DotNet framework on your environment.
The DLL is available in the BIN/Release folder and is compiled under DotNet 4.0. Furthermore you have to make a registry entry with regedit under the EA AddIns The value that you have to add points to the entry class in the DLL. The value is:DLA2EA.DLA2EAAddIn.
The extension is at the moment still limited in functionality. In our organisation we are thinking about a number of extra functions like merging elements to one element based on the attributes of elements or via a user interface.
Enterprise Architect for an Enterprise Architecture
Introduction
In the last year I have done a number of projects for a Dutch government agency as a data architect. This organisation has an architecture team with four members. There is a problem in producing architecture documents like Project Start Architectures, it takes too much time and the result has limited value for the projects. This is mainly caused by the lack of overview on the baseline and the target architecture. There is no overview of the business processes, the application and the infrastructure.
For every project, an architect has to do a lot of research on the baseline architecture first, sometimes this activity takes weeks to get a architecture view that is input for working on the target architecture. Another problem is that every architect has his own tools and techniques for the architecture notations and documents. Although there is an architecture document template, there are large differences in the quality and presentation of these documents. However due to the differences in tools and techniques, every architect starts from scratch for every project.
To tackle these problems the team decided to synchronize their activities, techniques, notation and tools. Therefore the following questions where formulated:
· Which notation is best to support our architecture documents and diagrams?
· Based on the selected notation, which tool can help us to make our documents more efficiently?
· What do we have to change in our team to encourage reuse of existing documents and diagrams?
Below I will describe how we looked for answers to these questions and what lessons we have learned.
ArchiMate
In the Netherlands, there are a lot of architecture methods available like Togaf, Zachman, Dragon1, Demo, DyA and ArchiMate. Each method has its own characteristics. However which are important for our own organisation. The architecture team did an interactive workshop to formulate the following requirements for the architecture methodology:
· It must be an open standard and is used in other government agencies for exchanging models.
· Applicable for all aspects of an enterprise architecture, from business to infrastructure and data architecture.
· It must be easy to use and easy to read for non IT professionals.
In this interactive workshop a number of extra requirements where formulated and most important we defined a multiplier define the importance for each requirement. The requirements were mapped on a number of architecture methodologies and ArchiMate was the methodology with the highest score.
ArchiMate is an open standard with a powerful notation for all the aspects of enterprise architecture. Since ArchiMate 2.0 there are even extensions for motivation like principles, requirements and stakeholders and project management for plateaus, gaps and work packages. In the figure below you see a sample ArchiMate 2.0 diagram.
Figure 1 Sample ArchiMate notation
After this methodology selection the next step was to evaluate it in a number of projects. For ArchiMate there are Visio Stencils and a number of open source tools. Every architect used the notation for a period of time and during this period we organized a number of sessions to discuss the results. We also organized an interactive session with our non IT stakeholders to evaluate the selected methodology.
In these evaluations we discovered that the ArchiMate notation is valuable for describing the architecture in our organisation. For the notation instruction material was made with example diagrams and describing when to use what ArchiMate viewpoints. However the notation is too rich for most of the situations. So the following categories were introduced:
· Primary diagrams, should be present in every architecture document
· Secondary diagrams, only available in complex documents for extra description
During the evaluations it became clear that the Visio stencils and open source tooling had insufficient functionality for the next phase, the implementation of the methodology.
Using Enterprise Architect
Like we did with the notation we formulated a number of requirements including a multiplier for each architect and compared a number of tools with each other. This was done with a simple spreadsheet. In the figure below a part of the spreadsheet
Figure 2: Requirement-Tool matrix
Based on the results of this matrix Enterprise Architect had the best score and we introduced the product. This introduction was done in a number of planned steps. There was a risk that the organisation returned to old habits of working in an unstructured way and introducing a architecture methodology combined with tooling has to be embedded in all the activities of the architects.
In the following sessions I will describe a number of important aspects for introducing Enterprise Architect with ArchiMate.
Repository setup
Already in an early phase of the tool introduction we discovered that the repository content can become messy when you do not think about structuring the elements. Although there is a good project browser search function structuring the project so you can browse for elements is a good aid for the users of the system.
The repository is divided in three sections:
· Projects, actual project documents in various stages of completion
· Reference architecture, elements and diagrams from previous projects that are generic and probably reusable in future projects. This section is subcategorized in a structured manner comparable with the ArchiMate layers and columns
· Archive, diagrams and elements from projects that are probably not reusable.
Figure 3: Repository setup
Document generation
Introducing an architecture methodology in combination with tooling asks a lot of effort from the involved professionals. It was therefore important to seek for a solution to reduce the production time of the architecture documents, this was the reason why we started this project in the first place.
Already in an early phase of the project document generation was investigated as part of the overall solution. Document generation proved to be a great help to achieve this goal. The standard document templates were changed to our own corporate layout and the layout of the elements was changed for a better readability. The repository setup was changed so it was possible to change ordering and exclude packages from the document generation.
Sharepoint Wiki
In the organisation Microsoft SharePoint is the application for team- and project collaboration. The architecture team used this already and has made a lot of information available in a SharePoint wiki. First approach was to transfer this information to Enterprise Architect. However making links to files and Wiki content from the Enterprise Architect packages and elements turned out to be a good solution. With the links from the screens and the generated documentation to the wiki content people can easily get access to background information.
Custodian
In the repository setup a distinct difference is made to project data and generic data of the reference architecture. Especially this reference architecture is an important aspect of introducing standardization and reusability. Therefore the reference architecture needs special governance. The team decided to introduce a custiodian role. This custodian is responsible for the reference architecture package in the repository. To keep this reference architecture up to date the custodian has the following activities:
· Give information and instructions to team members about the setup of the reference architecture and how to use the elements and diagrams.
· Give feedback on diagrams and notation made by team members in project documentation.
· Select generic diagrams and elements from project documentation for transfer to the reference architecture.
This custodian role turned out to be a very good decision to help introduce the ArchiMate notation, the new methodology and the usage of the tooling in a right manner.
Lessons Learned
In one year the organisation introduced a new architecture methodology, notation and tooling. Furthermore the production of architecture documents changed dramatically. Some aspects were successful, while others werenot. The most important lessons we learned are
· Team involvement, this is most important to make this a success. Every team member must see the advantages of the new methodology. Furthermore, everybody must be an ambassador and therefore should have sufficient influence on the final product.
· Notation governance, especially in projects under time pressure, it is so tempting to make an simple diagram in Visio or PowerPoint for a few team members. The role of the custodian is in this important to keep everybody involved!
· Communicate! A new architecture methodology, notation and tooling has a great impact, not only for the team members but for every stakeholder in the organisation. Take care of informing everybody about results, products and other notifications. We made a number of posters of architecture diagrams for important projects and that helped a lot (see figure 4)
· ArchiMate 1 and 2, there are two versions of ArchiMate in notation and in Enterprise Architect. At first we decided that we used these notation together. This turned out to be a wrong decision. Not only was it confusing, the tooling has strange behaviour when using the versions simultaneous.
Figure 4 Project Poster
Conclusion
The introduction of ArchiMate in combination with tooling was not always easy. There are a lot of options and it was difficult to make the right choice, especially for the methodology. Introducing a new working proceedure was not simple for evberybody. The custodian role helped a lot here. Enterprise Architect in combination with ArchiMate 2.0 turned out to be a good choice. The tooling is easy to use, has sufficient search capabilities, can be adapted easily for document generation and connection with existing applications like SharePoint.