automating automation - aveva na 2019 day 1... · introduction automating automation virtualization...

21
Presented by: Session ID: MAN-04 Automating Automation Best Practices and Tools © 2019 AVEVA Group plc and its subsidiaries. All rights reserved. Jim Thein, Principal Systems Engineer November 12 th , 2019

Upload: others

Post on 30-Jun-2020

8 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Automating Automation - Aveva NA 2019 Day 1... · Introduction Automating Automation Virtualization ArchestrAand InBatch APIs Automated Functional Testing Questions. ... • Technical

Presented by:

Session ID: MAN-04

Automating AutomationBest Practices and Tools

© 2019 AVEVA Group plc and its subsidiaries. All rights reserved.

Jim Thein, Principal Systems Engineer

November 12th, 2019

Page 2: Automating Automation - Aveva NA 2019 Day 1... · Introduction Automating Automation Virtualization ArchestrAand InBatch APIs Automated Functional Testing Questions. ... • Technical

Agenda

© 2019 AVEVA Group plc and its subsidiaries. All rights reserved.

Automating AutomationBest Practices and Tools

Introduction

Automating Automation

Virtualization

ArchestrA and InBatch APIs

Automated Functional Testing

Questions

Page 3: Automating Automation - Aveva NA 2019 Day 1... · Introduction Automating Automation Virtualization ArchestrAand InBatch APIs Automated Functional Testing Questions. ... • Technical

Introduction

© 2019 AVEVA Group plc and its subsidiaries. All rights reserved.

Jim Thein, Principal Systems EngineerVacaville MSAT, Automation Infrastructure

• Genentech is a biotechnology corporation that makes medicines to treat patients with serious medical conditions.

• Vacaville Operations consists of two large-scale cell culture production facilities (CCP1 and CCP2), a hub warehouse, and QC laboratories that serve both local and network production operations.

• Vacaville Manufacturing Sciences and Technology (MSAT) provides technical leadership, scientific and engineering expertise, and project delivery skills to enable the supply of high quality medicines to our patients.

Page 4: Automating Automation - Aveva NA 2019 Day 1... · Introduction Automating Automation Virtualization ArchestrAand InBatch APIs Automated Functional Testing Questions. ... • Technical

Automating Automation

© 2019 AVEVA Group plc and its subsidiaries. All rights reserved.

Page 5: Automating Automation - Aveva NA 2019 Day 1... · Introduction Automating Automation Virtualization ArchestrAand InBatch APIs Automated Functional Testing Questions. ... • Technical

Automating Automation

• Invest in tools and technologies that simplify automation engineering

• Adapt IT solutions to solve OT problems

• Design for continuous availability

• Integrate systems and deliver actionable data to users

• Reduce costs and accelerate projects and automation changes

© 2019 AVEVA Group plc and its subsidiaries. All rights reserved.

Page 6: Automating Automation - Aveva NA 2019 Day 1... · Introduction Automating Automation Virtualization ArchestrAand InBatch APIs Automated Functional Testing Questions. ... • Technical

Virtualization

© 2019 AVEVA Group plc and its subsidiaries. All rights reserved.

Page 7: Automating Automation - Aveva NA 2019 Day 1... · Introduction Automating Automation Virtualization ArchestrAand InBatch APIs Automated Functional Testing Questions. ... • Technical

$0

$1

$1

$2

$2

$3

$3

$4

$4

Physical Virtual

Mill

ion

s

Server Storage Network Support

Virtualization

© 2019 AVEVA Group plc and its subsidiaries. All rights reserved.

Reduce Total Cost of Ownership

Category Physical Virtual

Server & Licenses $1,042,860 $424,645

Storage Included $292,913

Network $158,289 $243,951

Platform Cost $1,201,149 $961,509

10yr Support $2,576,871 $1,027,953

10yr TCO $3,778,020 $1,989,462

CCP1 Production Environment

Page 8: Automating Automation - Aveva NA 2019 Day 1... · Introduction Automating Automation Virtualization ArchestrAand InBatch APIs Automated Functional Testing Questions. ... • Technical

Virtualization and System Lifecycle Upgrades

• Simplify and accelerate building parallel system

to test and qualify major system upgrades and

migrations before cutover

• Know it works before taking the plant down!

• 2013 replaced legacy Siemens APS platform

(Direktor, RTAP, UNIX servers) with AVEVA

InBatch, ArchestrA, and virtual Windows servers

• Technical cutover was 12 hours

• 2018 upgraded ArchestrA 2012 and InBatch 9.6

to ArchestrA and InBatch 2014R2

• Technical cutover was 5 hours

© 2019 AVEVA Group plc and its subsidiaries. All rights reserved.

Safely and quickly perform system upgrades and migrations

Page 9: Automating Automation - Aveva NA 2019 Day 1... · Introduction Automating Automation Virtualization ArchestrAand InBatch APIs Automated Functional Testing Questions. ... • Technical

Automating Virtualization

{ "vms": [ {

"name": "c1palm01", "cpu": 2, "memgb": 8, "folder": "CCP1-B10DC/CCP1/Production",

"compute": "ProdCluster02", "storage": "ccp1_prod1",

"template": "TMPL-W2012R2Std Prod 1 NIC", "custspec": "CCP1 Windows Prod 1 NIC",

"description": "CCP1 Production Wonderware Alarm Database Server 1",

"disk": [

{"name": "Hard Disk 1", "sizegb": 150}, {"name": "Hard Disk 2", "sizegb": 20}

],

"net": [

{"ip": "10.1.2.3", "mask": "255.255.255.0", "gateway": "10.34.13.254", "dns": ["10.1.2.1","10.1.2.2"]}

]

}

] }

© 2019 AVEVA Group plc and its subsidiaries. All rights reserved.

foreach( $vm in ((Get-Content .\vm-design.json) -join "`n" | ConvertFrom-Json).vms ) {

$new = New-VM –Name $vm.name -Location (Get-FolderByPath -Path $vm.folder) `

-ResourcePool (Get-Cluster -Name $vm.compute) -Datastore (Get-Datastore -Name $vm.storage) `

–Template (Get-Template -Name $vm.template) -OSCustomizationSpec (Get-OSCustomizationSpec –Name $vm.name)

$new | Set-VM -Description $vm.description -Confirm:$false | Start-VM

}

Automatically Build and Test Virtual Servers

Page 10: Automating Automation - Aveva NA 2019 Day 1... · Introduction Automating Automation Virtualization ArchestrAand InBatch APIs Automated Functional Testing Questions. ... • Technical

Automating AVEVA Software Installation

<responsefile>

<install>

AdminUserForm.SUserName=WWADMINUSER

AdminUserForm.SPassword=WWPASSWORD

AdminUserForm.SDomainName=WWDOMAIN

AdminUserForm.SCreateLocal=false

FeatureForm.SFeatureList=Application

Server.Bootstrap,Licensing.LicenseManager,Application Server.IDE,Application

Server.Galaxy_Repository,Application Server Documentation.PDF_Documentation,Application

Server Documentation.BootstrapDoc,Application Server Documentation.IDEDoc,Application

Server Documentation.GRDoc

FeatureForm.SInstallDir=C:\Program Files (x86)

</install>

</responsefile>

© 2019 AVEVA Group plc and its subsidiaries. All rights reserved.

Start-Process -FilePath "\\path\to\sqlserver\setup.exe" -ArgumentList "/ConfigurationFile=C:\TEMP\sql-install.ini" -Wait

Start-Process -FilePath "\\path\to\archestra\setup.exe" -ArgumentList "/silent C:\TEMP\archestra-install.xml" -Wait

Microsoft and AVEVA Unattended Installations

;SQL Server 2014 Configuration File

[OPTIONS]

; Specifies a Setup work flow, like INSTALL, UNINSTALL, or UPGRADE. This is a required

parameter.

ACTION="Install"

; Use the /ENU parameter to install the English version of SQL Server on your localized

Windows operating system.

ENU="True"

; Parameter that controls the user interface behavior. Valid values are Normal for the full

UI,AutoAdvance for a simplied UI, and EnableUIOnServerCore for bypassing Server Core setup GUI

block.

; UIMODE="Normal"

; Setup will not display any user interface.

QUIET="True"

; Required to acknowledge acceptance of the license agreement

IACCEPTSQLSERVERLICENSETERMS="True“

<snip>

Automate the installation of .NET, SQL Server, System Platform, Service Packs, and Hot Fixes, set registry keys, configuration changes …

Page 11: Automating Automation - Aveva NA 2019 Day 1... · Introduction Automating Automation Virtualization ArchestrAand InBatch APIs Automated Functional Testing Questions. ... • Technical

ArchestrA and InBatch APIs

© 2019 AVEVA Group plc and its subsidiaries. All rights reserved.

Page 12: Automating Automation - Aveva NA 2019 Day 1... · Introduction Automating Automation Virtualization ArchestrAand InBatch APIs Automated Functional Testing Questions. ... • Technical

InBatch Stateless API

Add-Type -AssemblyName 'InBatch.API, Version=1.0.0.0, Culture=neutral, PublicKeyToken=23106a86e706d0ae'

'c1pib01a','c1pib01b' | ForEach-Object {

[pscustomobject] @{ 'Server' = $_; 'Redundancy' = [InBatch.API.Utility]::GetRedundancyState($_);

'Runtime' = [InBatch.API.Utility]::GetBatchRuntimeStatus($_) }

} | Select-Object Server,Redundancy,Runtime | Sort-Object Server | Out-GridView -Title 'InBatch Status'

© 2019 AVEVA Group plc and its subsidiaries. All rights reserved.

Automate Batch Server Management

Page 13: Automating Automation - Aveva NA 2019 Day 1... · Introduction Automating Automation Virtualization ArchestrAand InBatch APIs Automated Functional Testing Questions. ... • Technical

InBatch Recipe XML Exports

© 2019 AVEVA Group plc and its subsidiaries. All rights reserved.

Simplify User Access to Recipe Design and Data

Compare Recipe Parameters

Page 14: Automating Automation - Aveva NA 2019 Day 1... · Introduction Automating Automation Virtualization ArchestrAand InBatch APIs Automated Functional Testing Questions. ... • Technical

InBatch Recipe XML Exports

© 2019 AVEVA Group plc and its subsidiaries. All rights reserved.

Simplify User Access to Recipe Design and Data

Extract Recipe Instructions for Searching Transform XML to HTML

Page 15: Automating Automation - Aveva NA 2019 Day 1... · Introduction Automating Automation Virtualization ArchestrAand InBatch APIs Automated Functional Testing Questions. ... • Technical

System Interfaces

• GRAccess finds equipment’s

derived template for ArchestrA

alarms and events

• Alarms and events derived

from process templates are

sent to batch history and

appear on batch reports

• Filters out system alarms and

events not related to the

manufacturing process

© 2019 AVEVA Group plc and its subsidiaries. All rights reserved.

• Add custom logic to extend

InBatch functionality

• Extend the InBatch phase start

and stop logic to watch for

special phases that trigger

interface transactions

• Extend equipment allocation

and release logic to add many

additional hygienic statuses

• MXAccess provides

programmatic access to

runtime data

• Interface transactions trigger

MXAccess tag reads and writes

to controllers

ArchestrA GRAccess Toolkit InBatch Batch Hooks Library ArchestrA MX Access Toolkit

Page 16: Automating Automation - Aveva NA 2019 Day 1... · Introduction Automating Automation Virtualization ArchestrAand InBatch APIs Automated Functional Testing Questions. ... • Technical

Automated Functional Testing

© 2019 AVEVA Group plc and its subsidiaries. All rights reserved.

Page 17: Automating Automation - Aveva NA 2019 Day 1... · Introduction Automating Automation Virtualization ArchestrAand InBatch APIs Automated Functional Testing Questions. ... • Technical

System Lifecycle Upgrade

• Migrate legacy Siemens Moore APACS hardware to a modern platform with minimum issues or risks

• Maintain licensed status for all currently registered products

• Minimize plant downtime during the control layer replacement

• Design and build in alignment with established network business processes

• Provide sufficient system capacity to enable potential future expansions and upgrades

• Provide sufficient system redundancy to ensure no product loss resulting from unplanned downtime

© 2019 AVEVA Group plc and its subsidiaries. All rights reserved.

Replace Legacy Control Layer

How can we verify functional equivalency of the new control layer?

Page 18: Automating Automation - Aveva NA 2019 Day 1... · Introduction Automating Automation Virtualization ArchestrAand InBatch APIs Automated Functional Testing Questions. ... • Technical

Micro Focus Unified Functional Testing (UFT)

• UFT is like a robot that automates

repetitive tasks (using a script)

• Significant savings compared to manual

testing; especially over time

• UFT recognizes ArchestrA Object Viewer

objects (in particular, the watch list)

• Concept is to use UFT + Object Viewer to

functionally test control logic in both

hardware platforms, comparing results

© 2019 AVEVA Group plc and its subsidiaries. All rights reserved.

Widely used software for automating functional or regression testing

Page 19: Automating Automation - Aveva NA 2019 Day 1... · Introduction Automating Automation Virtualization ArchestrAand InBatch APIs Automated Functional Testing Questions. ... • Technical

Automated Control Module Testing

' 2.Initial Step

' Using 4-mation, initialize the control module by forcing a cold start condition.

Window("Object Viewer").Activate

' 3. CheckPointStep

' In 4-mation, verify the status of the following variables:

CheckValue "TestIO.fastscan.CM003.ISA", ""

CheckValue "TestIO.fastscan.CM003.ALARM1.EN1", "FALSE"

' 4. CheckPointStep

' From the APS faceplate, verify the status of the following variables:

CheckValue "TestIO.fastscan.CM003.IN1", "FALSE“

5. SetValueStep

' Using the APS faceplate configure ALARM1 with a status of TRUE. Enable this alarm.

SetValue "TestIO.fastscan.CM003.ALM1", "TRUE"

SetValue "TestIO.fastscan.CM003.EN1", "TRUE"

' 6. CheckPointStep

' Using 4-mation verify the status of the following variables;

CheckValue "TestIO.fastscan.CM003.ALARM1.EN1", "TRUE"

© 2019 AVEVA Group plc and its subsidiaries. All rights reserved.

Control Module Test Script

Page 20: Automating Automation - Aveva NA 2019 Day 1... · Introduction Automating Automation Virtualization ArchestrAand InBatch APIs Automated Functional Testing Questions. ... • Technical

Questions?

© 2019 AVEVA Group plc and its subsidiaries. All rights reserved.

Page 21: Automating Automation - Aveva NA 2019 Day 1... · Introduction Automating Automation Virtualization ArchestrAand InBatch APIs Automated Functional Testing Questions. ... • Technical

linkedin.com/company/aveva

@avevagroup

ABOUT AVEVA

AVEVA is a global leader in engineering and industrial software driving digital transformation across the entire asset and operational l ife cycle of capital -intensive industries.

The company’s engineering, planning and operations, asset performance, and monitoring and control solutions deliver proven results to over 16,000 customers across the globe. Its customers are supported by the largest industrial software ecosystem, including 4,200 partners and 5,700 certified developers. AVEVA is headquartered in Cambridge, UK, with over 4,400 employees at 80 locations in over 40 countries.

aveva.com

© 2019 AVEVA Group plc and its subsidiaries. All rights reserved.