Upcoming TFS 2010 Admin courses
Following the success of our “TFS 2010: Configuration & Administration” course in Canberra this week, Enhance ALM has scheduled this course to run in both Canberra & Sydney next month. The Canberra course this week was a sell out and with more and more organisations wanting to adopt and manage their TFS server s as efficiently as possible.
TFS 2010: Configuration and Administration (Outline | Register)
- Sydney 14th & 15th June
- Canberra 16th & 17th June
Mastering Testing with Visual Studio 2010 (Outline | Register)
- Sydney 14th & 15th June
- Canberra 16th & 17th June
Both courses are competitively priced at $1,495 per student including GST.
New TFS 2010 course–a great success
Enhance ALM has just completed the first delivery of a new 5-day TFS course for a partner in the United States. The course, Implementing TFS 2010 Team Solutions, is a 5-day course covering a wide range of topics around TFS 2010. The course runs as both a classroom/remote classroom and an onsite course for clients on their premises.
The feedback from the attendees was overwhelmingly very positive and here are just a few of the comments provided by the students.
This was an excellent class. I would highly recommend this class to anyone from the beginner to an advanced user that wishes to expand their knowledge on TFS.
Excellent instructor with great knowledge on the software.
Great Course! This is a great course. It covers all the modules of VSTS2010 extensively.
Great Job! Anthony did a great job.
Another metric I was very pleased to see was 100% of attendees indicated they would recommend this course to their colleagues.
If you’re in the US and your interested in attending this new course, we have scheduled the course to run again on the week commencing July 18th, 2011 in Redmond, WA. You can attend the course in person or online via our remote classroom. (More info)
For people interested in this in Australia, stay tuned as I am planning on publishing the course details and scheduling the class around July/August. Register your interest.
In the last post, we detailed the Dynamics Ax installation steps. We are almost there now!
It has been a long journey to get to this point, with a lot of setup required before we can actually integrate Dynamics Ax with TFS 2010. But we made to here, so let’s jump in.
Create the MAIN Branch in Visual Studio 2010
Before we can actually integrate Dynamics Ax with TFS 2010, we will need to create a source repository or Team Project, depending on your strategy. For this blog series, we have used the following branching strategy:
As such, we created a Team Project (using the Agile 5.0 template), and created the main source folders, as can be seen below:
The branch hierarchy would look like the following:
NOTE: The example above is the completed example, and shows the branches. It also demonstrates that the project can be used for more than just Dynamics, with other project types being used as well.
- If you need a new Team Project, then create one using the desired template. This post assumes that a Team Project has already been created, and that it houses other project types (e.g. DotNet, VB6, etc.)
- On the development machine where you are performing the initial integration, create a mapping between the Source Control for the Team Project and your local drive.
- Create a folder on the local disk that will house the project. A recommendation is that the initial setup be mapped at a high level, to reduce confusion between workspaces. (This will become apparent a little later on, so for this demo follow this recommendation. Later, you may wish to change this). The example below shows a local folder of C:\Workspace\<user name>\<team project name>. This has been chosen as there may be more than 1 person logging in to the machine to do work. This will keep the workspaces separate from others on the machine.
e.g. C:\Workspace\Richard\LMApps
Create Workspace Mapping for Initial TFS Setup
To be able to create the folders etc., you will need a source to local drive mapping at the Team Project level. This will enable us to create branching structures, and will separate the Dynamics Ax workspaces from an Administration workspace. This sounds confusing at first, but if you follow these instructions, you *should* be ok. No guarantees though ![]()
- Create a local folder to house the Team Project mapping
e.g. C:\Workspace\Richard\Merge\LMApps
- Open Visual Studio 2010 Team Explorer. Connect to the TFS server, and open the Source Control node from the Team Explorer snap-in. Select the project node in the Folders pane of the Source Control Explorer. Right-click the project and select Map to local folder option
- Select the folder created above then Map. At this stage, do not get the latest as there may be other code that is not relevant to this set of posts.
- Create the initial folder structure in TFS and check-in. The higher level folders will now look something like below:
- Also set up any Areas and Iterations that you require, as well as any security.
Connect the Dynamics Ax MAIN Instance to TFS
- If you have not already done so, copy your existing source over the top of the default installed source on the development machine. For example, for the MAIN instance of Dynamics Ax installed on the machine, copy the source to the following directory:
- If you have not already done so, create a configuration file for each of the installed Dynamics Ax instances. This is done using the Microsoft Dynamics AX 2009 Configuration utility that would have been installed with the client. Ensure that the correct settings are used (e.g. that the right AOS server is selected, that the correct layer has been selected, and that the correct Development key has been entered). Save these configuration files to a central location (e.g. C:\Program Files\Microsoft Dynamics AX\LocalConfiguration)
- Also create the shortcuts and place them on the desktop. This is not necessary, but helps to standardise the installation.
- Start Dynamics Ax. Navigate to the Microsoft Dynamics –> Tools –> Development Tools –> Version Control –> Setup –> Parameters menu.
- Enter the TFS parameters on both tabs
- If you get an error like that shown below, it means that the Team ID server information will need to be entered. Double click the error.
- Enter the name of the server that is hosting the Team ID server (e.g. the TFS server) and choose the database that was setup when the Team ID Server was installed. Select OK
- An Infolog dialog will be displayed that should look similar to that shown below. Close the dialog
- Close the version Control parameters dialog, then reopen to ensure that TFS has been successfully bound. Close the Infolog screen then close Dynamics Ax. We found that this is the area that gave us the most issues, but should work as described above.
Fix the Source Control to Local Path Mappings
Assuming the above process worked as shown above, then what has happened is that Dynamics Ax has created a new workspace for the Dynamics Ax instance, and mapped the root of source control to the path selected above.
i.e. $/LMApps –> C:\Workspace\Richard\LMApps\DynamicsAx in the example shown above.
This will need to be changed so that the TFS workspace is mapped instead to:
$/LMApps/Source/MAIN/DynamicsAx –> C:\Workspace\Richard\LMApps\DynamicsAx
This is the critical part, as it will allow us to have multiple instances of Dynamics Ax on a developer machine with different mappings.
- Open Visual Studio 2010 Team Explorer and connect to TFS. Open the Source Control Explorer and open the Workspace dialog using the drop down and select Workspaces
- Select the XXXX_AXWORKSPACEX workspace and select Edit
- Change the Source Control Folder to point to the correct place in the source control tree
- Select OK. You will be notified that the workspace has been modified and that you will need to get the latest source to the local folder. Select Yes
- Close the Manage Workspaces dialog, and start Dynamics Ax from the shortcut created earlier. You should get a dialog similar to the one shown below. If not, then something has gone wrong (obviously
) and you will need to investigate further.
- If it has worked,however, we now need to add the source to source control. To do this, we are going to create a project to hold only our changes (e.g. the VAP layer), rather than place the entire base objects in TFS. To do this, open the Projects dialog. Create a new Project, and filter for the objects that you want added to TFS. (e.g. all VAP layer objects)
- Select the objects then Right-Click –>Add to Version Control.
- Depending on the number of objects selected, this may take a while. To verify that the objects are being added to TFS, open Visual Studio 2010 and open the Source Control Explorer. Select the correct workspace then navigate to the source container where the source is expected to be.
- In Dynamics Ax, right-click the selection then select Check In
- Ensure a comment is provided then select OK
Create the DEV Branch
Now that we have the main source added to TFS, we can now start to branch the code so that the other environments can be integrated into TFS. For the examples above, we are going to branch and check-in the $/<ProjectName>/Source/MAIN/DynamicsAx to $/<ProjectName>/Source/DEV/DynamicsAx
- Navigate to the source directory you want to branch in TFS Source Control Explorer, then Right-Click –> Branching and Merging –> Branch
- Choose the target location then select OK
- Check-in the branched code. Ensure a comment is provide then select Check In
- You now synchronise your code with the associated AOS server, so that the database is in synch with the code. Ensure that the Force option is selected, as this will do a full synchronise.:
Repeat the above steps for each environment that you want to set up, for example a DEV environment.
Woohoo!
If you have gotten this far, then you are almost there. Go and have a rest, and have a beverage of your choice. You have earned it. ![]()
Next Steps
In the last past, we will wrap up the process, as well as give some tips on how to manage the development process with Dynamics Ax, including how to do the check-ins and daily development tasks.
In the last post, we installed the Ax database and Application files. This post will describe installing the remainder of the Dynamics Ax bits.
Installing an AOS Instance
In order for development to occur on a developers machine, a local AOS instance will need to be installed for each branch of TFS Version Control that will be used on the developers machine. This enables a developer to be independent of other developers, while integrating their source into the ALM process of TFS 2010.
- Start the Dynamics Ax install. Select the default language then select OK
- Select Next
- Accept the software licence then select Next
- Select Custom Installation then select Next
- Select the Application Object Server (AOS) and select Next. If you are installing on Windows 7, then a warning is shown regarding Windows 7 not being supported. Select Yes
- Accept Microsoft SQL Server and select Next
- If you are warned about pre-requisites then select the Install prerequisite software
- Accept the default install location and select Next
- Ensure that the database created earlier is selected then select Next
- Accept the defaults in the AOS: Locate the application files
- Accept the instance name and the port then select Next
- Select the Network Service then select Next
- Ensure that the Start the AOS instance after installation is completed is not selected then select Install
- Select Finish
- NOTE. This will need to be repeated for each “instance”. (e.g.: DEV, MAIN,REL,HOTFIX for our example)
Install the Dynamics Ax Client
If the Dynamics Ax development client has not been installed, then install as detailed below
- Follow the steps as above until you get to the Add or Modify components section.
- Select Client in the Base section then select Next
- Select your language then Next
- Select Install
Install Other Components as Needed
The other components can also be installed at this point. Note that WSS development would not be able to be installed on a client OS (e.g. Windows 7) as WSS 3 cannot be readily installed on Windows 7. For Enterprise Portal development, a separate Server Development machine would need to be installed, following the installation procedures as described in these blog posts. This is left as an exercise for the reader.
Notes
- Create a configuration for the instance that you want to connect to using the Microsoft Dynamics AX 2009 Configuration tool. Save the configuration file to a directory (e.g. C:\Program Files\Microssoft Dynamics AX\LocalConfiguration) and create a shortcut using the newly created configuration file as the target. An example of the Target setting for a shortcut is given below:
"C:\Program Files\Microsoft Dynamics AX\50\Client\Bin\Ax32.exe" "C:\Program Files\Microsoft Dynamics AX\LocalConfiguration\LMAx5_MAIN.axc"
- Ensure that the client has been started once, and that the instance has been configured and compiled. Also, ensure that the initialisation list has been completed.
- Copy your current source to the Appl\Instance directory, overwriting the source files that are installed by default. This will ensure that when we get to the Add to TFS step in the next post that your source code will be added. Example is given below:
C:\Program Files\Microsoft Dynamics AX\50\Application\Appl\LMAx5_MAIN
- Make sure that the following hotfix has been applied. This should enable the installation of the Reporting Services bits, but your mileage may vary. We had a lot of trouble getting the reporting services developments pieces to install, and ended up leaving them on the original server that was used for development:
- If you are installing on Windows 7, then you will not be able to install the Role Centre and Enterprise Portal components, or the Enterprise Portal Development bits.
The next post will get to the interesting bits, where we actually integrate the Dynamics Ax development environment into TFS 2010.
Before you install any of the Dynamics Ax components on any of the Development machines, there are a few things that you will need to determine first.
First, you will need to determine what your branching and release strategy is. This is the key step to getting your Dynamics Ax environment setup for ALM with TFS 2010. Some really great examples of branching strategies can be found in the Visual Studio Branching Guide 2010.
The example used in his blog series is one adapted from the branching guidance:
As can be seen above, there are 4 source branches which we will use. Using the Branch Visualisation in Visual Studio 2010, we will end up with a branch hierarchy as shown below:
So, what we are going to end up with is 4 installs of Dynamics Ax that each correspond to a branch in the branching hierarchy. Note that this is only necessary if a development machine will be used for all branches. Typically, developers would only have a DEV and/or HOTFIX branch on their machines, as the other branches would be used by a team leader/manager to perform the merges and any release management.
The procedure outlined below will detail the install method used for the MAIN project. This is the first one that needs to be done,a s it is the main branch from which all the other branches will be created, and as such, makes it easier to manage the development setup process.
Install a Dynamics Ax Instance for the MAIN branch
- Start the Dynamics Ax install. Select the default language then select OK
- Select Next
- Accept the software licence then select Next
- Select Custom Installation then select Next
- Select Database and Application Files then select Next
- Enter the name for the database (e.g. LMAx5_MAIN) and then select Next
- Enter the name for the AOS server (e.g. LMAx5_MAIN) then select Next
- Select Next on the Application Files: Select a country or region
- Select Install
- Select Finish
The next post will describe installing the AOS server instance for the MAIN branch.
In the previous post, we detailed the procedure for installing a Team ID Server so that any new objects created in independent development machines would not have clashing ID’s for the objects created.
Following on from that, this post begins the Development Machine installation procedure. In order for development to occur in a team environment with independent developer machines, the components required for development need to be installed on each developer machine.
Install SQL Server 2005 and SP 2
In order to develop with the reporting services components of Dynamics Ax, you will need to install SQL Server 2005 with Reporting Services. This step can be skipped if Reporting Services development is not a requirement.
NOTE: This was done in an effort to do reporting services development. However, it was found that it was not sufficient, and at this stage we are still looking to fix this.
SQL 2005 Installation Notes
- IIS needs to be installed before you can install Reporting Services. This post details the IIS Requirements for SQL Server 2005 Reporting Services
- If you are installing on a 64-bit operating system, then some extra steps are needed to ensure that ASP.NET can run in 32-bit mode on IIS
- Run the installer and accept the prompts until you get to the Components to Install page, then select the Advanced button and ensure that the following components are installed:
- Create a non-default instance (as the SQL 2008 R2 instance will be the default) then select Next
- Run the service as the Network Service account. Ensure that the Service Account screen looks similar to below then select Next
- i. On the Authentication Mode screen, ensure that Windows Authentication Mode is selected then select Next
- Accept the default collation (provided that the locale on the base Operating System has been set correctly – check this before proceeding) then select Next
- On the Reporting Server Installation Options screen, accept the defaults then select Next
- Accept the defaults on the Error and Usage Reporting Settings page then select Next.
- On the ready to Install page, select Install
- You may be asked about installing BIDS that there are compatibility issues – Just run the application. When the install is finished, select Next
- Select Finish
SQL Server 2005 SP 2 Installation
This is left as an exercise for the reader, as it should simply be following the prompts. If you get a warning about incompatibility, simply select Run
In the next post, we will detail the installation of Dynamics Ax.
So here we are at the start of the process. In this step, we are going to prepare the TFS server so that it can accommodate Dynamics Ax.
In most Dynamics environments, there is a central server that host the AOS server (Axapta Object Server). This server is what creates global ID’s for Ax objects when they are created in the IDE.
For a distributed development environment, each development machine will host it’s own AOS server. However, to keep each developer machine from creating an ID that would clash with another developers, a central ID server is required. Dynamics Ax has a server that performs this function, called the Team ID Server, and this is what will be installed on the TFS server.
- Install TFS 2010 as you would normally, setting up SharePoint and Reporting Server reports as required
- Install a Dynamics Ax Team ID Server, either on the TFS server, or on another server. THe only requirement is that it can be accessed by the development machines, and that there is an available SQL server that can be used to store the data for the Team ID Server
- On the TFS Server, Insert the Dynamics Ax DVD and start the TeamServerSetup.exe. Accept the licence agreement and select Next
Installing a Dynamics Ax Team ID Server
- Enter the name of the server to use and select Next
- Enter a name for the Team ID Server database and select Next
- Accept the default name for the local group that will be created to give user access to the Team ID Server, then select Next
- Accept the name in the warning dialog
- Select Install
- Select Finish when installation is finished
Add Developer Machines to the Dynamics Team Server Users Group
This needs to be done so that any user that attempts to authenticate with the Team ID Server can do so. By adding the machine name to the security group, any user originating from the machine are granted access to the Team ID Server.
- Select Start –> Administrative Tools –> Server Manager
- In the Tree View, navigate to the Server Manager –> Configuration –> Local Users and Groups –> Groups. Right-Click the Dynamics Team Server Users and select Properties
- Select Add
- Change the Object Type to include Computers
- Select OK then enter the machine names of all developers that will be accessing the Team ID Server. Then select OK
And that is it for this post. the next post will be the first part of setting up a developer’s machine to user Dynamics Ax with TFS 2010.
Software development is complex, and becoming more complex every day. Consumer products such as the iPhone and iPad are driving users expectations for software to be more polished and feature rich. In the past, users were far more forgiving on software and web sites, but these days that is not the case. As software becomes more complex, so does the process involved in producing high quality software.
Software engineers are being asked to cope with more rapid change, while the expectations are constantly rising. Today, a large number of software projects fail for a number of reasons, due in part to failure to manage the development process, or using a process that does not fit the product.
Development frameworks, such as SharePoint or Dynamics Ax, are a response to this complexity. By providing a framework in which to develop an Enterprise application, the plumbing layers are abstracted away from the developers, allowing them instead focus on the problem at hand.
However, there are still issues when it comes to multi-developer development in such frameworks. Traditional software development using traditional tools such as IDE’s relied heavily on a Version Control Systems to assist developers in managing a codebase across a number of developers. These tools allowed a number of distributed developers to work concurrently on a codebase to produce a software result.
A lot of frameworks, however, are not designed with this in mind. Case in point, Dynamics Ax was not designed with Application Lifecycle Management in mind. Integrating Application Lifecycle Management tools and practices into these types of frameworks can further increase the productivity gains that come from using a framework.
This series of posts will detail one method of integrating Dynamics Ax with Team Foundation Server 2010. By integrating Dynamics Ax with TFS 2010, the Application Lifecycle Management tools and reporting that TFS 2010 gives to traditional Software Development can now be realised with Dynamics Ax.
Just to note that these posts have been written as a guide for those that, like me, have found little detailed public information on integrating Dynamics Ax 2009 with TFS 2010. Whilst a number of posts do mention that it is possible, they are short on detail and implementation guidance. I hope that these posts will be useful to someone who is looking for a realistic integration scenario.
So without further ado, lets start!
Overview of the Problem
Recently, a client approached us with an interesting problem: How to integrate TFS 2010 with Dynamics Ax. This was indeed an interesting problem for a number of reasons:
- Dynamics Ax is a recentish Microsoft acquisition, and as such has it’s own way of doing things
- Dynamics Ax is very much a Business server, with a different language (X++) and different way of developing
- Was not designed with Version Control in mind, with capability provided in later releases
- Expertise in Dynamics Ax is hard to find, as Dynamics Ax is sold more as a partner product, rather than an end-user product such as other Microsoft software.
This posed a number of challenges, one of which was the lack of public documentation. Most of the documentation (and even the service packs and patches) are only available via Partner Source or Customer Source, which are programs run by Microsoft that requires more formal registration than other Microsoft products.
So, with that in mind,we set off to investigate a method that would allow the client to use TFS 2010 to manage their current agile process.
The first problem we had to overcome was the installation of Dynamics Ax itself. Since this was the first time I had ever installed Dynamics, it was going to be an interesting process.
Installation Overview
Dynamics Ax is made up of the following components:
- An AOS Server that provides a service that manages the Dynamics object
- A database that holds the Dynamics Ax configuration
- A Client that is used to develop with
- Other development services, such as SharePoint integration and reporting services
From a high level, the following are the steps we took to integrate:
- Install TFS as usual.
- Install a Team ID Server
- Install a Development machine
- Install SQL Server 2005 + SP2
- Install Visual Studio 2008 + SP1 + TFS 2010 Cumulative Update
- Install Visual Studio 2010 Team Explorer
- Install any other software that is required (e.g. Office, SQL DB 2008 R2)
- Install an instance of Dynamics Ax
- Install an AOS client and server instance
- Install the developer instance and any supporting components (e.g. Biztalk integration)
- Prepare TFS 2010 for Dynamics Ax
- Prepare Developer machine for TFS 2010 Integration
- Integrated Dynamics Ax with TFS 2010 and the Team ID Server
- Modify the Dynamics Ax TFS Workspace
- Development tips and tricks
So look out for the first of these posts over the next week!
Dynamics AX development using TFS 2010
Enhance ALM recently assisted a local company implement TFS 2010 in their Dynamics AX development environment. This was made all the more difficult due to a lack of good documentation and best practise guidance on how to do this. ALM Consultant, Richard Angus, spent a week working through the various challenges to come up with a great solution that has both met and exceeded the expectations of the client.
Over the next few weeks, Richard will be publishing a series of informative blog posts on how you can get TFS 2010 working well for Dynamics AX development projects.
- Integrating Dynamics Ax with TFS 2010 – Part 1 (Overview)
- Integrating Dynamics Ax with TFS 2010–Part 2 (Preparing TFS for Dynamics Ax)
- Integrating Dynamics Ax with TFS 2010–Part 3 (Preparing the DEV Machine)
- Integrating Dynamics Ax with TFS 2010–Part 4 (Installing a Dynamics Ax Instance)
- Integrating Dynamics Ax with TFS 2010–Part 5 (Installing a Dynamics Ax AOS Instance)
- Integrating Dynamics Ax with TFS 2010–Part 6 (Integrating with TFs 2010)
- Final wrapup and Tips and Tricks coming soon
If your organisation develops Dynamics AX solutions and would like to find out more about using TFS 2010 to manage your development lifecycle, feel free to get in touch with us.
The 2-day Mastering Testing with Visual Studio 2010 course is currently our most popular training course. For every public delivery of the course we are usually running 4 or 5 private in-house courses for companies. So why the demand for this course?
Microsoft has invested a significant amount of time and effort focusing on improving the testing capabilities of Visual Studio. Here are a few of the key things you will learn by attending the Mastering Testing with Visual Studio 2010 course.
Test Case Management
Learn how to create a Test Plan and configure properties for the test plan including test settings and configurations. You’ll create Test Suites and link them to your requirements for traceability and reporting. During the course you’ll see how to write effective test cases and organise them for convenience and reporting.
Executing manual tests
Microsoft’s new Manual Test Runner is a purpose built application to allow you to step through your test cases and see how you need to interact with your application under test. You can record an action recording for a test case which will then allow you to fast forward one or more steps on subsequent test executions. This can be a huge time saving feature.
What’s changed?/What do I need to retest?
Using the Test Impact Data Collector, you can select two different builds (eg. 2.1.10.1 & 2.1.12.1) and with the click of a mouse button see exactly what changes (work items) have gone in the newer build. You can also find out which test cases should be executed based on what has changed between the builds. Why run 200 tests when you only need to run 20 of them?
Raising data-rich bugs
One of the challenges a tester has is knowing what information and how much information to include in a bug report. Often testers don’t have time to include as much detail as they would like and developers invest more time trying to reproduce a bug then they might otherwise need to. Using the Test Runner, you can raise data rich bug reports that can include a wealth of helpful information for the developer. Through the selection of data collectors, much of the relevant information is automatically added to the bug report when the testers raises the bug. This means less time writing the bug and for developers, possibly a significant reduction in the time it takes to reproduce the bug.
Automated UI testing
The Mastering Testing with Visual Studio 2010 course will cover creating automated user interface tests called Coded UI tests. Coded UI tests can be generated from manual test action recordings or they can be recorded using the Coded UI test recorder. These tests have the great benefit of being able to be automated completely and included as part of the build process.
Report on test progress
Another time consuming task for testers is often creating the testing reports needed for management or to record the daily progress of your testing. In the course we’ll look at how to use some of the out-of-the-box reports and how you can quickly and easily create your own reports.
While the courses covers more than I have listed above, these are some of the most important things you’ll learn how to use by attending the Mastering Testing with Visual Studio 2010 course.