Connector For Jira

Transcription

USU Service ManagementConnector for JiraUser Guide

1 Content1CONTENT22 INTRODUCTION43 INSTALLATION53.1 JIRA PLUGIN3.1.1 INSTALLATION FROM ATLASSIAN MARKETPLACE3.1.2 MANUAL INSTALLATION WITH .JAR PACKAGE3.2 USU SERVICE MANAGEMENT PACKAGE (VALUEMATION)3.2.1 INSTALLATION556884 CONFIGURATION114.1 CONFIGURATION OF JIRA PLUGIN4.1.1 DEFAULT OBJECT MAPPINGS4.1.2 CREATE JIRA USER FOR THE CONNECTOR4.1.3 CREATE CUSTOM FIELDS IN JIRA FOR THE CONNECTOR4.1.4 CONFIGURATION OF JIRA CUSTOM FIELD4.1.5 CONFIGURATION OF ALLOWLIST4.2 CONFIGURATION OF SCRIPT RUNNER4.3 CONFIGURATION OF USU SERVICE MANAGEMENT PACKAGE (VALUEMATION)4.3.1 CONFIGURATION VM GENERIC INTERFACES4.3.2 CONFIGURATION OF INTERFACE MAPPING111116171719202121235 USE CASES245.1 USE CASE 1: CREATE JIRA ISSUE5.1.1 CREATE NEW ISSUE IN JIRA5.2 USE CASE 2: ADD COMMENTS5.2.1 CREATE A COMMENT IN JIRA5.2.2 CREATE A COMMENT IN USU5.3 USE CASE 3: CHANGE WORKFLOW STATUS IN JIRA5.4 USE CASE 4: MANUAL SYNCHRONIZATION TO USU5.5 USE CASE 5: GENERATE USU SYSTEMS AND USU MODEL TICKETS6 MONITORING2424272728293032346.1 JIRA6.1.1 CONNECTOR LOG6.1.2 STANDARD JIRA LOG3434342

6.2 USU SERVICE MANAGEMENT PACKAGE (VALUEMATION)6.2.1 GENERIC INTERFACE DATA QUEUES6.2.2 PROCESS INSTANCES FOR MONITORING6.2.3 USU LOG FILE7EXAMPLE OF FIELD MAPPINGS35353535367.1 SCENARIO 1: SIMPLE FIELD MAPPING IN THE DIRECTION FROM JIRA TO USU7.2 SCENARIO 2: SIMPLE FIELD MAPPING IN THE DIRECTION FROM USU TO JIRA (IN THE RESPONSE)7.3 SCENARIO 1 AND 2: RESULT8 LIST OF SUPPORTED FIELD NAMES364042438.1 SUPPORTED EXPRESSIONS473

2 IntroductionWelcome to the User Guide for USU Service Management Connector for Jira. This manual is madefor users who Administer Jira Issues and USU Tickets. This connecting tool provides two-way datatransfer between Jira and USU.The connector is based on Object and Field Mapping. Here you can find basic and advancedinformation about default functions of our Connector. Of course the admin users also have manyoptions for setting up Object and Field Mapping of our Connector according to their needs. Our UserGuide provides basic instructions on how to do this.Our Team hopes that USU Service Management Connector for Jira will help you transfer databetween Jira and USU more efficiently and make your work more successful. We are ready to helpyou if you would need anything else. Don t hesitate to contact us (contact information can be foundon the last page of our User Guide).Your SykoraIT4

3 Installation3.1 Jira plugin3.1.1 Installation from Atlassian Marketplace Search for application USU Service Management Connector for Jira in the AtlassianMarketplace. Download and install the connector. Input license key.5

3.1.2 Manual installation with .jar package Login into Jira as Administrator (or user with Administrator s permissions). Go to Jira Administration – Manage apps. Upload USU Service Management Connector for Jira. Select Jar format of the file.6

Install the connector for Jira. Get started working with USU Service Management Connector for Jira.7

3.2 USU Service Management Package (Valuemation)The installation package for USU Service Management (Valuemation) will be provided by Sykora IT.If you do not have it, please contact us at support@sykorait.com.3.2.1 Installation Import the file USU ServiceManagmentConnectorForJira v1 0 3.zip.8

Ignore the warning in the last file. It is caused by a missing index in USU Service ManagementStandard. Import the file by the Import button. Go into the catalog Generic VM Interfaces. You should find the interfaceSIT USU Atlassian Connector. It will run when the status is set to Active/Scheduled.9

Go into the catalog Processes for DeploymentSIT Interface.Process initialized Data queues.andactivatetheprocess Go to the Object Customizer and open the Object Type Ticketdesc. As a „Modify On Save“there should be the workflow SIT Ticketdesc Save rework assigned. If it collides withyour customizing, please contact our support team for advice.10

4 Configuration4.1 Configuration of Jira Plugin4.1.1 Default Object MappingsObject Mapping in this version of Jira Plugin contains two default interfaces: Default Interface andDefault GetMasterData Interface. The basic difference between them is in USU Webservice.Default Interface is using InterfaceTransactionStart Webservice, Default GetMasterDataInterface is working with SITGetObjectsSetLastSyncTS Webservice.Default Interface is capable of following activities: Send a Jira Issue data to USU Service Management (Valuemation), where the new Ticket willbe created. Receive back USU Ticket number and USU Ticket link to Jira Issue. Sending comments from Jira to USU and from USU to Jira. Send status change of Jira Issue (done) to USU Ticket (solved). The Default interface and mappings will be created automatically when the page ObjectMapping is loaded. Image below demonstrates user view of Default Interface Object Mapping.11

Default GetMasterData Interface is capable of following activities: Download Systems (CI s) and Model Tickets data from USU Service Management to Jira. Thedata will be stored in custom tables of the Connector and can be referenced in Jira Issues.12

You can change parameters of the request in Object Mapping Events. Default Targetconditions for System-CI are set up as gingSystemsChanged"},"sortedBy":["datchg ":"100"}}]}}13

Image below demonstrates Events dialog for System-CI. Image below demonstrates user view of Default GetMasterData Interface Object Mapping.14

Both Object Mappings are almost ready to use. What is necessary to do: Go to Manage Apps and select Object Mapping of our Connector. Click Edit button and set up a connection to USU and activate default interfaces. It ispossible to set up more Interfaces as active at the same time. USU URL:http://[HOST]/vmweb/services/api/execwf USU Password is encrypted by runCrypto.bat (from USU). External User is the user name of the Jira User which is set in the Target System of theGeneric Interface in USU. After you have saved the configuration by clicking on Edit button, you can use the buttonTest Connection to verify the configuration. If you want to copy an interface including the mappings, just rename the default interface.The current Default interface will be saved with the new name. At the same time a newDefault interface will be created with the default settings (as inactive). Create an external Jira user in Jira (go to 4.1.2). Create custom fields in Jira (go to 4.1.3).15

4.1.2 Create Jira User for the ConnectorThe communication between Jira and USU runs in the backend. It needs a special user on bothsides. It is recommended to have dedicated users for that.Follow these steps: (Link to Jira documentation - Create user) Go to User Management Administration. Create a new user for communication between Jira and USU Service Management. The created Jira user must be part of JIRA Service Desk and Jira Software groups. See the user details:16

4.1.3 Create Custom fields in Jira for the ConnectorDefault mapping expects two Jira custom fields on Issue to store the USU Ticket Number and USUTicket Link to the USU Ticket. The Default GetMasterData mapping expects two Scriptrunnerfields to store generated list of USU System-CI and generated list of USU Model Tickets. With bothdefault mappings you have to use the exact names as below. If you want to use different names,you can change the mappings.Follow these steps: (Link to Jira documentation - Create custom field) Go into the Issues Administration – Custom fields. The new custom fields must be placed at least on the edit screens. Create two standard custom fields (if you use same names (same format as technical nameof those fields) and settings for fields as model examples you don t need to change Defaultinterface settings in Object Mapping): Name: Valuemation Ticket Link; Type: Text Field (Multi-line). Name: Valuemation Ticket No; Type: Text Field (Single- line). Change Object Mapping in case of different custom field names. Image below demonstrate names of custom fields which work properly with both defaultobject mappings.4.1.4 Configuration of Jira Custom FieldThe USU Link which comes from USU Service Management to Jira Custom Field can be displayedbetter in Jira Custom Field. It needs to change Jira Custom Field configuration. Go to Issues Administration and select Field Configuration. Search for USU Link CustomField which you created. Select Action Renderers and change the Renderer to Wiki StyleRenderer.17

View of the USU Link should look like image below after this change.18

4.1.5 Configuration of AllowlistIt is necessary to add your USU URL to Allowlist (System Settings of Jira). The Connector is notable to connect your USU Environment without this. This behavior of the Connector is mainly forsafety reasons. It is not possible to send data from the Connector to an unknown environment.Log Comment of our Connector informs you about it with this Error comment.19

4.2 Configuration of Script RunnerThere are more options how the Model Tickets and Cis in the Connector’s tables can be referencedfrom a Jira Issue. We recommend using Script Runner for that (made by Adaptavist, tested withversion 6.30.2).Here are the steps needed for creation of the references to Model Tickets and Cis: Create Resource in Script Runner and make a Local Database Connection. Create two Database picker Fields in Script Runner (don t forget to put created fields onIssue screen): Field Name: USU System-CI; Type: Database picker. Field Name: USU Model Tickets; Type: Database picker. Create two Jobs in Script Runner. Custom Scheduled Job for System-CI. Custom Scheduled Job for Modeltickets. Fill in the tables according to your needs (there are examples how to set up a scheduler) . Copy and paste the script bellow to Inline Script Table and set up a new URL.import groovy.json.StreamingJsonBuilderdef authString "sitjiraintegration:[your password]".getBytes().encodeBase64().toString()def body req '''{"eventTypeName": "runObjectMapping","objectMappingName" : "System-CI"}''';URL url new SITVmConnectorBackend");HttpURLConnection con (HttpURLConnection) con.setRequestProperty("Authorization", "Basic {authString}");con.doOutput true;con.setRequestProperty("Content-Type", "UTF-8") { new Streaming JsonBuilder(it, body req)}con.getOutputStream().write(body req.getBytes("UTF-8"));con.connect();println("url: " url);println("Content :" con.getContent())println("ResponseCode:" " con.getResponseMessage())con.disconnect(); You can do the Script for Model Tickets (we recommend to create a New Job for it) in thesimilar way.20

4.3 Configuration of USU Service Management Package(Valuemation)4.3.1 Configuration VM Generic Interfaces Connection to your USU Service Management (Valuemation). Go to the catalog VM Generic Interfaces. Open the Interface SIT USU Atlassian Connector. Open the Target System “SIT JIRA”. Open the Target System SIT JIRA. Input the URL of the REST Endpoint of your Jira into thefield Webservice URL.21

Click on Authorization and select the proper Authorization Method (Basic Authorization).Input the data to access your Jira. The user needs to have the rights to use the REST APIand Write permission on Jira Issues and Issue Comments.Hint: This username has to be set in the field External User in the Interface in the JiraConnector. Select or create an USU user, which will be used for communication in the directionJIRA - USU. The user should have the role SITJiraIntegration. This user information shouldbe set in the setting of the Interface in the Jira Plugin. The user must have a person assigned.22

Configuration of the USU Web Service and Web Service Client. The implementation is donewith the USU Generic Interface module. It means that the user (in our caseSITJIRAINTEGRATION) must be assigned to the Web Service Client Interface Handling. Inour case it is achieved by assignment to the User Group INTERFACE EXECUTORS.4.3.2 Configuration of Interface MappingThe Object and Field Mapping on the USU side is done by the Generic Interface module from USU.Detailed documentation can be obtained at USU or you can contact Sykora IT for support.23

5 Use Cases5.1 Use Case 1: Create Jira Issue5.1.1 Create new Issue in Jira Fill a summary field (required).Add attachments (images and documents).Fill a description.Assign the Issue to SITJIRAINTEGRATION user.24

The USU Ticket is automatically created with all values from Jira Issue attachmentsincluded.25

Created Jira Issue is automatically updated. Jira Issue update contains Valuemation TicketNumber and Valuemation Ticket Link. Click the link and view the Ticket in USU ServiceManagement.26

5.2 Use Case 2: Add comments5.2.1 Create a Comment in Jira Make a Comment to a created Issue. The Comment from Jira is automatically created in the USU Ticket. It appears as a TicketDescription in the USU Ticket.27

5.2.2 Create a Comment in USU Add a Ticket Description to a Ticket in USU Service Management (Valuemation). The Ticketmust be assigned to an Issue (via a value in the field sitJiraKey). Comment from USU is automatically created in Jira Issue after refreshing Jira page.28

5.3 Use Case 3: Change workflow status in Jira Change workflow status of Jira Issue to Done. Status of USU Ticket is automatically changed to Solved (IN).29

5.4 Use Case 4: Manual synchronization to USUIn addition to the automatic event-driven synchronization, there is the button Sync with USU in theMore menu in Jira Issue. It sends the Issue data to USU. If the Issue is already linked to an USUTicket, the Ticket will be updated. Otherwise, the new Ticket is created. The button is useful whenyou have older Issues which should be synchronized and were created before the installation of theConnector. Or if you want to synchronize only specific Issues. Go to the Connector settings and turn on Sync with USU button. Open one of the created Jira Issue and click the Sync with USU button. POP-UP message is sent automatically from USU about successful synchronization.30

The USU Ticket is automatically created in USU Service Management. Jira Issue is automatically updated (Valuemation Ticket No and Valuemation Ticket Link areadded from USU Service Management).31

5.5 Use Case 5: Generate USU Systems and USU Model Tickets Run the Script Runner Scheduler and open the Connector Administration – Model ticketsand CI s.32

There should be added CI s and Modeltickets to the tables of our Connector. Create an Issue and see the new Script Runner Fields USU System-CI and USU ModelTickets. You should be able to pick one or more Items from a list of synchronized USU Items.33

6 Monitoring6.1 Jira6.1.1 Connector Log Logs are situated in Object Mapping of our connector. It is possible to set up different levels of logging. We recommend the ERROR level. The capacity of the log is 10 000 records (you can see the current number of records on thecounter). If there are more than 10 000 records the oldest ones are deleted. Set up the level of LOG, create an issue and refresh the LOG page.6.1.2 Standard Jira Log Another place to search for troubleshooting is the standard log files of JIRA.34

6.2 USU Service Management Package (Valuemation)6.2.1 Generic Interface Data Queues Each incoming and outgoing REST Message is stored in the catalog Generic Interface DataQueues. There you can check the status of the messages and find hints for troubleshooting.6.2.2 Process Instances for Monitoring The messages about newly created Ticket descriptions are sent in the Background by theprocess engine. For each new Ticket description there should be an instance of the processSIT Inteface.Process initialized Data queue.6.2.3 USU Log file Another place to search for an explanation is the log file of the USU Process Engine or theUSU Web Server.35

7 Example of field MappingsThis chapter describes examples of possible Mappings between fields in Jira and USU ServiceManagement (Valuemation).7.1 Scenario 1: Simple Field Mapping in the direction from Jirato USUThere is a single line text custom field in Jira with the name myTextField. The value of the customfield should be sent to USU and stored in the new field name myTextFieldUSU in Ticket.Follow those steps:1. Create a field in Jira and USU Objects (in our connector configuration). Go to Issues Management and create Custom Field myTextField. Create a field in USU Service Management called myTextFieldUSU. Go to Objects of our Connector and select Jira Issue (Jira Objects). Click the Fields button and see all created fields. Click the Field button and create fieldmyTextField. Do it the same way also for the Valuemation Ticket (USU Objects) and name the fieldmyTextFieldUSU.36

2. Create Field Mapping in the Issue-created Mapping. Go to Object Mapping of our Connector a select Issue-Ticket-Created. Click the Field Map button and fill the table with created fields (new fields should be a partof roll down menu of Jira/USU field) and select direction from Jira to USU.37

3. Create Mapping in USU Generic Interface Action Go to catalog Generic VM Interfaces and select SIT USU Atlassian Connector. Then select from Interface Actions SIT USU Atlassian Connector CreateTicket. Select Input Interface Values Mapping to Valuemation and click button Add ValuemationAttribute. Select the created field myTextFieldUSU and click OK.38

Fill the name of the text field from Jira and click ok. See the details of USU Input Mapping.39

7.2 Scenario 2: Simple Field Mapping in the direction from USUto Jira (in the response)There is a single line text custom field in Jira with the name myTextField2. When a new USU Ticketis created for a new Jira Issue, the value of the USU field named myTextFieldUSU2 should bestored into the custom field in Jira Issue.1. Create field in Jira and USU Objects (in our connector configuration) The procedure is the same as for step one in 7.1. One important difference. Set up thedefault value in the USU field as “Hello from USU!”.2. Create Field Mapping in the Issue-created Mapping (direction Jira -USU) Go to Object Mapping of our Connector a select Issue-Ticket-Created. Click the Field Map button and fill the table with created fields and select direction fromUSU to Jira.40

3. Create Field Mapping in USU Generic Interface Action Go to Generic VM Interfaces - SIT USU Atlassian Connector CreateTicket (outputMappings) Select Output Interface Values Mapping to Valuemation and continue as in the third step.You can check your work in the images below.41

7.3 Scenario 1 and 2: Result Create a Jira Issue and fill the custom field myTextField with text “Hi from Jira!”. Customfield myTextField 2 leave empty. See the USU Ticket. See the Jira Issue.42

8 List of supported field namesList of supported field names in the Jira Connector in the Object Issue.Technical field nameTypeDescriptionassigneeObjectAssigned Jira User sCollectionCollection of AttachmentscommentsCollectionCollection of Issue teColumn(seconds)outwardLinksCollectionCollection of Issue Links (outward)parentObjectParent of subtask IssuepriorityObject(seconds)Collection of Issue Links (inward)43

umntimeSpentColumn(seconds)typeObjectIssueType for this ation Ticket LinkColumnValuemation Ticket NoColumnworkflowIdColumnCustom FieldsIssue Status ObjectCollection of Sub Tasks (Issues)Your custom fields can be used as well. The standardJira Custom field types are supported.44

List of supported field names in the Jira Connector in the Object Jira Project.Technical field tIdColumnDescriptionList of supported field names in the Jira Connector in the Object Issue Comment.Technical field ptionIssue ObjectList of supported field names in the Jira Connector in the Object Jira User.Technical field nameTypeemailColumnusernameColumnDescriptionList of supported field names in the Jira Connector in the Object Attachment.Technical field 5

eColumnIssue ObjectBase 64 encoded content ofthe attachmentList of supported field names in the Jira Connector in the Object Issue Link.Technical field ion IssuesourceObjectObjectSource IssueList of supported field names in the Jira Connector in the Object CI s.Technical field st of supported field names in the Jira Connector in the Object Model Tickets.Technical field nameTypedescriptionColumnnameColumnDescription46

olumnRecursive Mapping: for some advanced use cases it is possible to use the name this in the case ofMapping of the type Object or Collection. It allows to create a dummy structure in the JSON whenit is needed on the USU Side. The depth of the recursion is limited to 10 levels.8.1 Supported stemname":" S06415612"}]47

USU Service ManagementConnector for JiraSýkora IT s. r. o.support@sykorait.com48www.sykorait.com 420 608 031 240

2 1 content 1 content 2 2 introduction 4 3 installation 5 3.1 jira plugin 5 3.1.1 installation from atlassian marketplace 5 3.1.2 manual installation with .jar package 6 3.2 usu service management package (valuemation) 8 3.2.1 installation 8 4 configuration 11 4.1 configuration of jira plugin 11 4.1.1 default objec