Red Hat JBoss Fuse Service Works 6 Installation Guide
This guide is for installation teams.
Red Hat Content Services
Red Hat JBoss Fuse Service Works 6 Installation Guide
This guide is for installation teams.
Red Hat Co ntent Services
Legal Notice Copyright © 2014 Red Hat, Inc.. T his document is licensed by Red Hat under the Creative Commons Attribution-ShareAlike 3.0 Unported License. If you distribute this document, or a modified version of it, you must provide attribution to Red Hat, Inc. and provide a link to the original. If the document is modified, all Red Hat trademarks must be removed. Red Hat, as the licensor of this document, waives the right to enforce, and agrees not to assert, Section 4d of CC-BY-SA to the fullest extent permitted by applicable law. Red Hat, Red Hat Enterprise Linux, the Shadowman logo, JBoss, MetaMatrix, Fedora, the Infinity Logo, and RHCE are trademarks of Red Hat, Inc., ed in the United States and other countries. Linux ® is the ed trademark of Linus T orvalds in the United States and other countries. Java ® is a ed trademark of Oracle and/or its s. XFS ® is a trademark of Silicon Graphics International Corp. or its subsidiaries in the United States and/or other countries. MySQL ® is a ed trademark of MySQL AB in the United States, the European Union and other countries. Node.js ® is an official trademark of Joyent. Red Hat Software Collections is not formally related to or endorsed by the official Joyent Node.js open source or commercial project. T he OpenStack ® Word Mark and OpenStack Logo are either ed trademarks/service marks or trademarks/service marks of the OpenStack Foundation, in the United States and other countries and are used with the OpenStack Foundation's permission. We are not d with, endorsed or sponsored by the OpenStack Foundation, or the OpenStack community. All other trademarks are the property of their respective owners. Abstract T his guide teaches you how to install the Red Hat JBoss Fuse Service Works product.
T able of Contents
Table of Contents .Preface . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4. . . . . . . . . 1. Document Conventions 4 1.1. T ypographic Conventions 4 1.2. Pull-quote Conventions 5 1.3. Notes and Warnings 6 2. Getting Help and Giving 6 2.1. Do You Need Help? 6 2.2. We Need ! 7 . .art P . . .I.. Basic . . . . . .Installation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8. . . . . . . . . . .hapter C . . . . . . 1. . . Preface . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9. . . . . . . . . 1.1. What is Red Hat JBoss Fuse Service Works? 9 1.2. Core Capabilities 9 1.3. System Integration 9 1.4. Core and Components 10 1.5. Components of Red Hat JBoss Fuse Service Works 10 1.6. Red Hat JBoss Fuse Service Works Features 11 1.7. Integration Use Case 11 1.8. Back Up Your Data 12 1.9. Red Hat Documentation Site 12 . .hapter C . . . . . . 2. . . Prerequisites . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13 .......... 2.1. Prerequisites for Installing Red Hat JBoss Fuse Service Works 13 2.1.1. Prerequisites for Installing Red Hat JBoss Fuse Service Works 13 2.1.2. Java Virtual Machine 13 2.1.3. Install JBoss Enterprise Application 13 2.1.4. Install Open JDK on Red Hat Linux 14 2.1.5. Install Maven 14 2.1.6. Install JBoss Developer Studio 16 2.1.7. Install JBoss Developer Studio Integration Stack 19 . .hapter C . . . . . . 3. . . Maven . . . . . . .Repositories . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21 .......... 3.1. About Maven 21 3.2. About T he Provided Maven Repositories 21 3.3. Configuring Maven to Use the File System Repositories 21 3.4. Configuring Maven to Use the Online Repositories 25 3.5. Dependency Management 28 . .art P . . .II.. .Basic . . . . . Installation . . . . . . . . . . .and . . . .Operation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 30 .......... . .hapter C . . . . . . 4. . . . . . . . . . . .the . . . Product . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31 .......... 4 .1. Red Hat Customer Portal 31 4 .2. Packages Available for 31 4 .3. Javadocs 31 4 .4. Files From the Red Hat Customer Portal 31 4 .5. Checksum Validation 32 4 .6. the ed File 32 4 .7. Red Hat Documentation Site 33 . .hapter C . . . . . . 5. ..T . .he . . JBoss . . . . . . Fuse . . . . . Service . . . . . . . .Works . . . . . .Installer . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 34 .......... 5.1. Installing JBoss Fuse Service Works by GUI 34 5.1.1. Additional Configuration Options 36 5.2. Installing JBoss Fuse Service Works by Script 36 5.2.1. Supplying s to the Installation Script 37 . .hapter C . . . . . . 6. . . Starting . . . . . . . . and . . . . Stopping . . . . . . . . .the . . . Application . . . . . . . . . . .Server . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 39 .......... 1
Red Hat JBoss Fuse Service Works 6 Installation Guide . .hapter C . . . . . . 6. . . Starting . . . . . . . . and . . . . Stopping . . . . . . . . .the . . . Application . . . . . . . . . . .Server . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 39 .......... 6.1. Start JBoss EAP 6 as a Standalone Server 39 6.2. Stop JBoss EAP 6 as a Standalone Server 39 . .hapter C . . . . . . 7. . . Basic . . . . . .Operation . . . . . . . . . .T.utorial . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .4. 1. . . . . . . . . 7.1. Running the Quickstart 41 7.1.1. About Quickstarts 41 7.1.2. Using SwitchYard Quickstarts 41 7.1.3. Importing Quickstarts into JBDS 42 7.1.4. List of Basic Quickstart Applications 42 7.2. How the Remote Invoker Quickstart Works 43 7.2.1. Overview of the Remote Invoker Quickstart 43 7.2.2. Using the Remote Invoker Quickstart 43 7.2.3. Deploy Remote Invoker Quickstart with Maven 44 7.2.4. Working with Messages 44 7.2.5. Undeploy a Quickstart 45 . .art P . . .III. . . Additional . . . . . . . . . .Configuration . . . . . . . . . . . . .Options . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .4. 6. . . . . . . . . . .hapter C . . . . . . 8. . . Validating . . . . . . . . . .Your . . . . .Red . . . .Hat . . . JBoss . . . . . . Fuse . . . . . Service . . . . . . . Works . . . . . . Installation . . . . . . . . . . . . . . . . . . . . . . .4. 7. . . . . . . . . 8.1. Overview 47 8.2. Validate Your Red Hat JBoss Fuse Service Works Installation 47 8.3. List of FSW Runtime Components 47 . .hapter C . . . . . . 9. . . Run-T . . . . . .ime . . . .Governance . . . . . . . . . . . Configuration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .4. 9. . . . . . . . . 9.1. Configuring Run-T ime Governance 49 9.2. Overlord Run-T ime Governance Configuration 49 9.3. Common Properties 49 9.4. Server Properties 50 9.5. Client Properties 50 9.6. Database 50 9.7. Caching 50 9.8. Caching Example 51 . .hapter C . . . . . . 10. . . . .Design-T . . . . . . . .ime . . . Governance . . . . . . . . . . . .Configuration . . . . . . . . . . . . .and . . . .Workflows . . . . . . . . . . . . . . . . . . . . . . . . . . . 52 .......... 10.1. Overview 52 10.2. Design-T ime Governance Back-End Configuration 52 10.3. Design-T ime Governance Interface (UI) Configuration 52 10.4. Design-T ime Governance Configuration Properties 52 10.5. Design-T ime Governance Configuration Examples 55 10.6. Governance Workflows 55 10.7. Installing Sample Workflow 55 . .hapter C . . . . . . 11. . . . .Managing . . . . . . . . . . . . . s . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 57 .......... 11.1. Adding a New for the Management Interfaces 57 11.2. Add- Command Arguments 58 11.3. Alternate Properties Files for Management Information 59 . .hapter C . . . . . . 12. . . . .Configuring . . . . . . . . . . .Red . . . .Hat . . . JBoss . . . . . . Fuse . . . . . Service . . . . . . . Works . . . . . . to . . .Run . . . .as . . a. .Background ........................ Service 61 12.1. Introduction 61 12.2. Running JBoss Fuse Service Works as a Service on a Headless Server 61 . .hapter C . . . . . . 13. . . . Configuring . . . . . . . . . . . Red . . . . Hat . . . . JBoss . . . . . . Fuse . . . . .Service . . . . . . . Works . . . . . . to . . .Run . . . .in. .a. Clustered ......................... Environment 63 13.1. About Cluster Service Registry in SwitchYard 63 13.2. Setting Up SwitchYard in a Clustered Environment 63 13.3. Creating a Cluster of SwitchYard Instances 63 13.4. Enabling Clustering in your SwitchYard Application 64 13.5. Run-T ime Governance and S-RAMP in a Clustered Environment 64 . .hapter C . . . . . . 14 . . .. .Configuring . . . . . . . . . . .S-RAMP . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 66 .......... 2
T able of Contents . .hapter C . . . . . . 14 . . .. .Configuring . . . . . . . . . . .S-RAMP . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 66 .......... 14.1. , Install and Configure S-RAMP 66 14.2. S-RAMP Installation 67 . .art P . . .IV. . . Advanced . . . . . . . . . .Use . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 69 .......... . .hapter C . . . . . . 15. . . . .Starting . . . . . . . Red . . . . Hat . . . . JBoss . . . . . . Fuse . . . . .Service . . . . . . . Works . . . . . . in . . an . . . Enterprise . . . . . . . . . . Environment ....................... 15.1. Introduction 70 70 15.2. Specify the Network Interface 70 .Security . . . . . . . Considerations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 72 .......... A.1. Secure Ways of Running Red Hat JBoss Fuse Service Works 72 . . . . . . . . .History Revision . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 73 ..........
3
Red Hat JBoss Fuse Service Works 6 Installation Guide
Preface 1. Document Conventions T his manual uses several conventions to highlight certain words and phrases and draw attention to specific pieces of information. In PDF and paper editions, this manual uses typefaces drawn from the Liberation Fonts set. T he Liberation Fonts set is also used in HT ML editions if the set is installed on your system. If not, alternative but equivalent typefaces are displayed. Note: Red Hat Enterprise Linux 5 and later include the Liberation Fonts set by default.
1.1. Typographic Conventions Four typographic conventions are used to call attention to specific words and phrases. T hese conventions, and the circumstances they apply to, are as follows. Mono-spaced Bold Used to highlight system input, including shell commands, file names and paths. Also used to highlight keys and key combinations. For example: T o see the contents of the file m y_next_bestselling_novel in your current working directory, enter the cat m y_next_bestselling_novel command at the shell prompt and press Enter to execute the command. T he above includes a file name, a shell command and a key, all presented in mono-spaced bold and all distinguishable thanks to context. Key combinations can be distinguished from an individual key by the plus sign that connects each part of a key combination. For example: Press Enter to execute the command. Press Ctrl+Alt+F2 to switch to a virtual terminal. T he first example highlights a particular key to press. T he second example highlights a key combination: a set of three keys pressed simultaneously. If source code is discussed, class names, methods, functions, variable names and returned values mentioned within a paragraph will be presented as above, in m ono-spaced bold. For example: File-related classes include filesystem for file systems, file for files, and dir for directories. Each class has its own associated set of permissions. Proportional Bold T his denotes words or phrases encountered on a system, including application names; dialog-box text; labeled buttons; check-box and radio-button labels; menu titles and submenu titles. For example: Choose System → Preferences → Mouse from the main menu bar to launch Mouse Preferences. In the Buttons tab, select the Left-handed m ouse check box and click Close to switch the primary mouse button from the left to the right (making the mouse suitable for use in the left hand).
4
Preface T o insert a special character into a gedit file, choose Applications → Accessories → Character Map from the main menu bar. Next, choose Search → Find… from the Character Map menu bar, type the name of the character in the Search field and click Next. T he character you sought will be highlighted in the Character T able. Double-click this highlighted character to place it in the T ext to copy field and then click the Copy button. Now switch back to your document and choose Edit → Paste from the gedit menu bar. T he above text includes application names; system-wide menu names and items; application-specific menu names; and buttons and text found within a GUI interface, all presented in proportional bold and all distinguishable by context. Mono-spaced Bold Italic or Proportional Bold Italic Whether mono-spaced bold or proportional bold, the addition of italics indicates replaceable or variable text. Italics denotes text you do not input literally or displayed text that changes depending on circumstance. For example: T o connect to a remote machine using ssh, type ssh name@ domain.name at a shell prompt. If the remote machine is exam ple.com and your name on that machine is john, type ssh john@ exam ple.com . T he m ount -o rem ount file-system command remounts the named file system. For example, to remount the /hom e file system, the command is m ount -o rem ount /hom e. T o see the version of a currently installed package, use the rpm -q package command. It will return a result as follows: package-version-release. Note the words in bold italics above: name, domain.name, file-system, package, version and release. Each word is a placeholder, either for text you enter when issuing a command or for text displayed by the system. Aside from standard usage for presenting the title of a work, italics denotes the first use of a new and important term. For example: Publican is a DocBook publishing system.
1.2. Pull-quote Conventions T erminal output and source code listings are set off visually from the surrounding text. Output sent to a terminal is set in m ono-spaced rom an and presented thus: books books_tests
Desktop Desktop1
documentation s
drafts images
mss notes
photos scripts
stuff svgs
svn
Source-code listings are also set in m ono-spaced rom an but add syntax highlighting as follows: static int kvm_vm_ioctl_deassign_device(struct kvm *kvm, struct kvm_assigned_pci_dev *assigned_dev) { int r = 0; struct kvm_assigned_dev_kernel *match; mutex_lock(&kvm->lock); match = kvm_find_assigned_dev(&kvm->arch.assigned_dev_head,
5
Red Hat JBoss Fuse Service Works 6 Installation Guide assigned_dev->assigned_dev_id); if (!match) { printk(KERN_INFO "%s: device hasn't been assigned before, " "so cannot be deassigned\n", __func__); r = -EINVAL; goto out; } kvm_deassign_device(kvm, match); kvm_free_assigned_device(kvm, match); out: mutex_unlock(&kvm->lock); return r; }
1.3. Notes and Warnings Finally, we use three visual styles to draw attention to information that might otherwise be overlooked.
Note Notes are tips, shortcuts or alternative approaches to the task at hand. Ignoring a note should have no negative consequences, but you might miss out on a trick that makes your life easier.
Important Important boxes detail things that are easily missed: configuration changes that only apply to the current session, or services that need restarting before an update will apply. Ignoring a box labeled “Important” will not cause data loss but may cause irritation and frustration.
Warning Warnings should not be ignored. Ignoring warnings will most likely cause data loss.
2. Getting Help and Giving 2.1. Do You Need Help? If you experience difficulty with a procedure described in this documentation, visit the Red Hat Customer Portal at http://access.redhat.com. T hrough the customer portal, you can: search or browse through a knowledgebase of technical articles about Red Hat products. submit a case to Red Hat Global Services (GSS). access other product documentation. Red Hat also hosts a large number of electronic mailing lists for discussion of Red Hat software and technology. You can find a list of publicly available mailing lists at https://www.redhat.com/mailman/listinfo. Click on the name of any mailing list to subscribe to that list or to access the list archives.
6
Preface
2.2. We Need ! If you find a typographical error in this manual, or if you have thought of a way to make this manual better, we would love to hear from you! Please submit a report in Bugzilla: http://bugzilla.redhat.com/ against the product Red Hat JBoss Fuse Service Works. When submitting a bug report, be sure to mention the manual's identifier: Installation_Guide If you have a suggestion for improving the documentation, try to be as specific as possible when describing it. If you have found an error, please include the section number and some of the surrounding text so we can find it easily.
7
Red Hat JBoss Fuse Service Works 6 Installation Guide
Part I. Basic Installation
8
C hapter 1. Preface
Chapter 1. Preface 1.1. What is Red Hat JBoss Fuse Service Works? Red Hat JBoss Fuse Service Works is a platform for developing enterprise application integration (EAI) and service-oriented architecture (SOA) solutions. It consists of a service component framework, business rules/complex event processing, life-cycle governance, runtime governance and process automation. It is built on the same core as JBoss Fuse with enterprise messaging, Camel and CXF so, therefore, s can use it to design, deploy, integrate and orchestrate business services. Report a bug
1.2. Core Capabilities T he benefits of using Red Hat JBoss Fuse Service Works include the following: Enterprise Integration Pattern (EIP) Based Development T he versatile EIP framework is implemented in routing and transformation processes for faster and more efficient integration solutions. High Performance Messaging A high performance messaging broker s messaging patterns such as publish-subscribe, point-to-point and store-forward, and multiple cross language clients. Service Development T he web services framework exposes integration assets as services and calls external services, ing all major web services standards. It also s REST ful calls. Structured Service Development A lightweight service development framework provides full lifecycle for developing, deploying, and managing service-based applications. Automatable Registry with Workflow Manage the lifecycle of services from design, development and deployment by defining, exposing and enforcing rules or policies. Business T ransaction Monitoring Capture service activity information, define and collect metrics, and define alerts and SLAs. Report a bug
1.3. System Integration Integrating your major business systems into a cohesive infrastructure can be a challenge, especially when you have legacy applications. Red Hat JBoss Fuse Service Works has a number of ways enable you to integrate both new and legacy applications. Development is simplified with a transparent, lightweight service framework which uses EIP technology. T his allows developers to focus on higher order concepts while still working with familiar technologies such as Apache Camel, BPEL, BPMN or POJOs. T o reduce the operational costs of production and maintenance, the platform utilizes automatable, content-aware repository and service activity monitoring. T hese the entire service lifecycle and development, QA
9
Red Hat JBoss Fuse Service Works 6 Installation Guide and production teams with run-time and design-time visibility, monitoring and alerting. Report a bug
1.4. Core and Components Red Hat JBoss Fuse Service Works (FSW) provides an environment for easily applying SOA concepts to integrated applications. A SwitchYard application consists of components such as composite services and composite references. T hese provide service definitions and accessibility. Along with SwitchYard, Red Hat JBoss Fuse Service Works is made up of a number of components including a rules-based router (Apache Camel), webservices framework (Apache CFX), and message broker (Apache ActiveMQ). Report a bug
1.5. Components of Red Hat JBoss Fuse Service Works Red Hat JBoss Fuse Service Works comes with the following components: Service delivery framework (SwitchYard) Business rules engine with CEP (JBoss Rules) A service registry/repository (Design-T ime Governance) Service activity monitoring (Run-T ime Governance) Operations, istration and management tools (JBoss ON) A full JavaEE application server and EAP Camel Smooks ModeShape ActiveMQ/A-MQ Messaging (shipped with Red Hat JBoss Fuse) CXF T hese components provide benefits such as: Bean Services via CDI SwitchYard leverages the power of Java EE6 and CDI to allow Java objects to become services by adding an @Service annotation to your bean. Beans are automatically ed at run-time and references to other services can be injected as CDI beans using @Inject. Use CDI in your JSP and JSF applications to inject enterprise services into the web tier. Declarative T ransformation With declarative transformation in SwitchYard, you can define the transformation and types to which it applies. SwitchYard automatically s and executes the transformation. Choose from Smooks, Java, XSLT , JSON, and more. Decision Services with JBoss Rules
10
C hapter 1. Preface Encapsulate business rules as decision services using the JBoss Rules component in SwitchYard. Each service has a well defined contract with protocol binding details and marshaling details abstracted away by SwitchYard. Smooks T his transformation engine can be used in conjunction with Red Hat JBoss Fuse Service Works to process messages. Business Process Execution Language (BPEL) You can use web services to orchestrate business rules using this language. It is included with Red Hat JBoss Fuse Service Works for the execution of business process instructions. JBoss Rules T his is the rules engine that is packaged with Red Hat JBoss Fuse Service Works. It can infer data from the messages it receives to determine which actions need to be performed. T esting Comprehensive unit test is provided to allow you to test services as you develop them. Report a bug
1.6. Red Hat JBoss Fuse Service Works Features SwitchYard SwitchYard is a lightweight service delivery framework providing full lifecycle for developing, deploying, and managing service-oriented applications. Business Process Execution Language (BPEL) You can use web services to orchestrate business rules using this language. It is included with Red Hat JBoss Fuse Service Works for the execution of business process instructions. Smooks T his transformation engine can be used in conjunction with Red Hat JBoss Fuse Service Works to process messages. It can also be used to split messages and send them to the correct destination. JBoss Rules T his is the rules engine that is packaged with Red Hat JBoss Fuse Service Works. It can infer data from the messages it receives to determine which actions need to be performed. Report a bug
1.7. Integration Use Case Acme Equity is a large financial service. T he company possesses many databases and systems. Some are older, COBOL-based legacy systems and some are databases obtained through the acquisition of smaller companies in recent years. It is challenging and expensive to integrate these databases as business rules frequently change. T he company wants to develop a new series of client-facing ecommerce websites, but these may not synchronise well with the existing systems as they currently stand.
11
Red Hat JBoss Fuse Service Works 6 Installation Guide T he company wants an inexpensive solution but one that will adhere to the strict regulations and security requirements of the financial sector. What the company does not want to do is to have to write and maintain “glue code” to connect their legacy databases and systems. Red Hat JBoss Fuse Service Works was selected as a middleware layer to integrate these legacy systems with the new customer websites. It provides a bridge between front-end and back-end systems. Business rules implemented with Red Hat JBoss Fuse Service Works can be updated quickly and easily. As a result, older systems can now synchronise with newer ones due to the unifying methods of FSW. T here are no bottlenecks, even with tens of thousands of transactions per month. Various integration types, such as XML, JMS and FT P, are used to move data between systems. Any one of a number of enterprise-standard messaging systems can be plugged into Red Hat JBoss Fuse Service Works providing further flexibility. An additional benefit is that the system can now be scaled upwards easily as more servers and databases are added to the existing infrastructure. Report a bug
1.8. Back Up Your Data Warning Red Hat recommends that you back up your system settings and data before undertaking any of the configuration tasks mentioned in this book. Report a bug
1.9. Red Hat Documentation Site Red Hat's official documentation site is at https://access.redhat.com/site/documentation/. T here you will find the latest version of every book, including this one. Report a bug
12
C hapter 2. Prerequisites
Chapter 2. Prerequisites 2.1. Prerequisites for Installing Red Hat JBoss Fuse Service Works 2.1.1. Prerequisites for Installing Red Hat JBoss Fuse Service Works In order to install and run Red Hat JBoss Fuse Service Works, you must already have the following items on your computer: A ed Java Virtual Machine A ed Java Development Kit (for running the quickstarts) A ed database server (needed to run the JBoss Server) Apache Maven (needed to run the Database Schema Configuration T ool and deploy the SwitchYard quickstart examples) An archiving tool (to extract the contents of compressed files) JBoss Developer Studio 7 or later (obtain it from the Red Hat Customer Portal at https://access.redhat.com/home) Red Hat tests and certifies Red Hat JBoss Fuse Service Works against several different hardware platforms, Java Virtual Machines, operating systems and databases. T his is an ongoing process and the list of ed environments is always growing. Find the list of currently-ed environments at https://access.redhat.com/site/articles/626513. Report a bug
2.1.2. Java Virtual Machine A Java Virtual Machine (JVM) creates a virtual environment where the Java bytecode can run. By creating the standard environment irrespective of the underlying hardware and operating system combination, it allows programmers to write their Java code once and have confidence that it can be run on any system. Red Hat recommends customers use Java 1.7. Report a bug
2.1.3. Install JBoss Enterprise Application T his topic covers the steps to install JBoss Enterprise Application Platform 6 on your machine. 1. the zip file the JBoss Enterprise Application Platform 6 Z ip file from http://access.redhat.com. T he Z ip file installation is platform-independent and is the preferred way to install JBoss EAP 6 on all ed platforms. 2. Move the Z ip archive to the desired location Move the Z ip file to the server and directory where you will install JBoss EAP 6. T he who will start and stop the server must have read and write access to this directory. 3. Use an appropriate application to extract the Z ip archive to the desired location
13
Red Hat JBoss Fuse Service Works 6 Installation Guide In a Red Hat Enterprise Linux environment, use the unzip utility to extract the contents of the Z ip archive. unzip jboss-eap-6.x.zip
In a Microsoft Windows environment, right-click the file and select Extract All. Result JBoss Enterprise Application Platform 6 has been installed successfully. T he directory created by extracting the Z ip archive is the top-level directory for the server. Report a bug
2.1.4. Install Open JDK on Red Hat Linux T his topic covers the steps to install Open JDK on RedHat Linux. 1. Subscribe to the Base Channel Obtain the OpenJDK from the RHN base channel. (Your installation of Red Hat Enterprise Linux is subscribed to this channel by default.) 2. Install the Package. Use the yum utility to install OpenJDK: yum install java-1.7.0openjdk-devel 3. that Open JDK is now your system default. You can ensure the correct JDK is set as the system default by following the steps below. 4.
a. As a root , run the alternatives command for java: /usr/sbin/alternatives -config java b. Select /usr/lib/jvm /jre-1.7.0-openjdk/bin/java . c. Apply the same for javac: /usr/sbin/alternatives --config javac d. Select /usr/lib/jvm /java-1.7.0-openjdk/bin/java.
Result Open JDK is installed successfully on your machine. Report a bug
2.1.5. Install Maven Prerequisites T he following software must be installed: An archiving tool for extracting the contents of compressed files Java
Procedure 2.1. Install Maven 1. Maven. a. Enter http://maven.apache.org/.cgi in the address bar of a browser.
14
C hapter 2. Prerequisites b. Choose the compiled zip archive link as per your operating system and save the zip file. 2. Install and configure Maven. A. Red Hat Enterprise Linux a. Extract the zip file to the directory where you wish to install Maven. T hese instructions assume that you have chosen /usr/local/apache-m aven/apache-m aven-3.0.5. b. Open command line terminal. c. Add the M2_HOME environment variable by entering the following command: $ export M2_HOME=/usr/local/apache-m aven/apache-m aven-3.0.5 d. Add the M2 environment variable by entering the following command: $ export M2=$M2_HOME/bin e. Optional: Add the MAVEN_OPT S environment variable to specify JVM properties by entering the following command: $ export MAVEN_OPT S="-Xm s256m -Xm x512m " You can use this environment variable to supply extra options to Maven. f. Add M2 environment variable to your path by entering the following command: $ export PAT H=$M2:$PAT H g. Make sure that JAVA_HOME is set to the location of your JDK: $ export JAVA_HOME=/usr/java/jdk1.5.0-02 Make sure that $JAVA_HOME/bin is in your PAT H environment variable. h. Run the following command to that Maven is installed successfully on your machine: $ m vn --version B. Microsoft Windows a. Extract the zip file to the directory where you wish to install Maven. T hese instructions assume that you have chosen C:\Program Files\Apache Software Foundation. T he subdirectory apache-m aven-3.0.5 will be created from the archive. b. Press Start+Pause|Break. T he System Properties dialog box is displayed. c. Click the Advanced tab and then click the Environm ent Variables button. d. Under System Variables, select Path. e. Click Edit and add the two Maven paths using a semi-colon to separate each entry. Add the M2_HOME variable and set the path to C:\Program Files\Apache Software Foundation\apache-m aven-3.0.5. Add the M2 variable and set the value to %M2_HOME%\bin. f. Update or create the Path environment variable:
15
Red Hat JBoss Fuse Service Works 6 Installation Guide Add the %M2% variable to allow Maven to be executed from the command line. Add the variable %JAVA_HOME%\bin to set the path to the correct Java installation. g. Click OK to close all the dialog boxes including System Properties dialog box. h. Run the following command to that Maven is installed successfully on your machine: m vn --version Result Maven is successfully installed and configured on your machine. Report a bug
2.1.6. Install JBoss Developer Studio Procedure 2.2. Install with the Universal Installer 1. to the Customer Portal at https://access.redhat.com. 2. From the menu bar click s. 3. Under Red Hat JBoss Middleware, click Software.
Figure 2.1. Red Hat JBoss Middleware Software on the Customer Portal 4. Under Software s, select the following options: From the Product list, select JBoss Developer Studio. From the Version list, select 7.1.x. 5.
For the JBoss Developer Studio universal installer, click for the Red Hat JBoss Developer Studio 7.1.x Stand Alone Universal Binary file. For the JBoss Developer Studio and JBoss EAP universal installer, click for the Red Hat JBoss Developer Studio 7.1.x Universal Binary with JBoss EAP file. T his s a universal installer .jar file.
6. On the command line, navigate to path/to/.jar and enter
16
C hapter 2. Prerequisites java -jar jbdevstudio-product-universal-version.jar
where version is substituted to match the name of the .jar file.
Note Alternatively, to start the installer you may be able to double-click the .jar file. 7. When the Installer window opens, click Next. 8. After reading and agreeing to the of the End License Agreement, click I accept the term s of this license agreem ent and click Next. 9. In the Select the installation path field, type the path where you want JBoss Developer Studio to be installed or click Browse to navigate to the location. When the Select the installation path field shows the correct path, click Next. When you are prompted about the specified location being created or overwritten, review the message and, if satisfied, click OK or Yes as appropriate.
Figure 2.2. Installation Step 3: Select T arget Folder 10. In the Select Java VM step, Default Java VM is automatically selected. Ensure that the disabled text field contains the path of the Java developer kit you want to use. T his is based on the default Java developer kit of your system. T o change the specified Java developer kit, click Specific Java VM and type the path of the Java developer kit in the text field or use the Browse button to locate the Java developer kit. When the text field shows the correct Java developer kit path, click Next.
17
Red Hat JBoss Fuse Service Works 6 Installation Guide
Important You must specify a Java developer kit with a 32-bit JRE to install a 32-bit version of JBoss Developer Studio and a 64-bit JRE to install a 64-bit version of JBoss Developer Studio. T o change the bit version of the Java developer kit to be used for installing JBoss Developer Studio, complete the appropriate step for your operating system: On OS X operating systems, from the Installation type list click the appropriate bit version. On Linux distributions and Microsoft Windows operating systems, in the text field type the path to the appropriate bit version of the Java developer kit.
Figure 2.3. Installation Step 4 : Select Java VM 11. Review the details in the Summary Information window and, if they are correct, click Next. Installation commences. 12. When the Pack installation progress bar shows Finished, click Next. T he installation process is now complete.
18
C hapter 2. Prerequisites
Figure 2.4 . Installation Step 7: Installation Progress in Finished State 13. T o create shortcuts for starting JBoss Developer Studio, select the Create shortcuts in the Start-Menu and Create additional shortcut on the desktop check boxes and click Next. 14. T o automatically start JBoss Developer Studio when the Installer window closes, select the Run JBoss Developer Studio after installation check box. Click Done to close the Installer window.
Important Linux distributions have a maximum number of files that a process can have open at one time. If this maximum number of files is set too low, JBoss Developer Studio will not start. You must open the /etc/security/lim its.conf file and ensure that the soft nofile and hard nofile variables have values of 9216 at a minimum. If the variables have smaller values, the values must be increased to 9216. If the variables are not specified, the following lines must be added to the file: * soft nofile 9216 * hard nofile 9216
Report a bug
2.1.7. Install JBoss Developer Studio Integration Stack Prerequisites T he following software must be installed:
19
Red Hat JBoss Fuse Service Works 6 Installation Guide Red Hat JBoss Enterprise Application Platform (See Red Hat JBoss Enterprise Application Platform Installation Guide) Red Hat JBoss Developer Studio (See Red Hat JBoss Developer Studio Installation Guide) An archiving tool for extracting the contents of compressed files Open JDK (or another ed Java Virtual Machine)
Procedure 2.3. Install JBoss Developer Studio Integration Stack 1. Start your instance of Red Hat JBoss Developer Studio. 2. In Red Hat JBoss Developer Studio, click Help > Install New Software... action from the main menu. 3. On the Available Software page, click the Add ... button. 4. On the Add Repository dialog, enter following details: Enter JBDSIS (or another unique name) in the Nam e field. Enter https://devstudio.jboss.com/updates/7.0/integration-stack/ in the Location field. 5. Click OK. Report a bug
20
C hapter 3. Maven Repositories
Chapter 3. Maven Repositories 3.1. About Maven Apache Maven is a distributed build automation tool used in Java application development to build and manage software projects. Maven uses configuration XML files called POM (Project Object Model) to define project properties and manage the build process. POM files describe the project's module and component dependencies, build order, and targets for the resulting project packaging and output. T his ensures that projects are built in a correct and uniform manner. Maven uses repositories to store Java libraries, plug-ins, and other build artifacts. Repositories can be either local or remote. A local repository is a of artifacts from a remote repository cached on a local machine. A remote repository is any other repository accessed using common protocols, such as http:// when located on an HT T P server, or file:// when located on a file server. T he default repository is the public remote Maven 2 Central Repository. Configuration of Maven is performed by modifying the settings.xm l file. You can either configure global Maven settings in the M2_HOME/conf/settings.xm l file, or -level settings in the _HOME/.m 2/settings.xm l file. For more information about Maven, see Welcome to Apache Maven. For more information about Maven repositories, see Apache Maven Project - Introduction to Repositories. For more information about Maven POM files, see the Apache Maven Project POM Reference. Report a bug
3.2. About The Provided Maven Repositories A set of repositories containing artifacts required to build applications based on Red Hat JBoss Fuse Service Works is provided with this release. Maven must be configured to use these repositories and the Maven Central Repository in order to provide correct build functionality. T wo interchangeable sets of repositories ensuring the same functionality are provided. T he first set is available for and storage in a local file system, the second set is hosted online for use as remote repositories. If you provided the location of Maven's settings.xm l file during installation, Maven is already configured to use the online repositories. If you did not provide the location during installation, you need to configure Maven manually by following the procedure in Section 3.4, “Configuring Maven to Use the Online Repositories” or Section 3.3, “Configuring Maven to Use the File System Repositories”.
Important T he set of online remote repositories is a technology preview source of components. As such, it is not in scope of patching and is ed only for use in development environment. Using the set of online repositories in production environment is a potential source of security vulnerabilities and is therefore not a ed use case. For more information see https://access.redhat.com/site/maven-repository. Report a bug
3.3. Configuring Maven to Use the File System Repositories 21
Red Hat JBoss Fuse Service Works 6 Installation Guide
Procedure 3.1. 1. the following Z IP archives containing the required repositories: http://maven.repository.redhat.com/techpreview/fsw6/6.0.0/fsw-6.0.0.GA-redhat-2-repository.zip http://maven.repository.redhat.com/techpreview/eap6/6.1.1/jboss-eap-6.1.1-maven-repository.zip Alternatively, the Z IP archives can also be ed from http://access.redhat.com/jbossnetwork/. 2. Unzip the ed Z IP files into an arbitrary location in a local file system. 3. Add entries for the unzipped repositories to Maven's settings.xm l file. T he following code sample contains a profile with the repositories and an activation entry for the profile: <settings xmlns="http://maven.apache.org/SETTINGS/1.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/xsd/settings-1.0.0.xsd">
<profiles> <profile>
fsw-local-repos
fsw-6.0.0.GA-redhat-2-repository
FSW 6.0.0.GA Repository
file:///fsw-6.0.0.GA-redhat-2repository
default
<enabled>true
never
<snapshots> <enabled>false
never
jboss-eap-6.1.1.GA-maven-repository
EAP 6.1.1.GA Repository
file:///jboss-eap-6.1.1.GAmaven-repository
default
<enabled>true
never
<snapshots> <enabled>false
never
fsw-6.0.0.GA-redhat-2-repository
FSW 6.0.0.GA Repository
22
C hapter 3. Maven Repositories
file:///fsw-6.0.0.GA-redhat-2repository
default
<enabled>true
never
<snapshots> <enabled>false
never
jboss-eap-6.1.1.GA-maven-repository
EAP 6.1.1 GA Repository
file:///jboss-eap-6.1.1.GAmaven-repository
default
<enabled>true
never
<snapshots> <enabled>false
never
fsw-local-repos
4. If you modified the settings.xm l file while JBoss Developer Studio was running, you must refresh Maven settings in the IDE. From the menu, choose Window → Preferences. In the Preferences Window, expand Maven and choose Settings. Click the Update Settings button to refresh the Maven settings in JBoss Developer Studio.
23
Red Hat JBoss Fuse Service Works 6 Installation Guide
Figure 3.1. Update Maven Settings Result T he Maven repositories are ed, unzipped in a local file system, ed in Maven's settings.xm l file, and ready to be used when performing Maven builds.
24
C hapter 3. Maven Repositories
Important If your cached local Maven repository contains outdated artifacts, you may encounter one of the following Maven errors when you build or deploy your project: Missing artifact ARTIFACT_NAME [ERROR] Failed to execute goal on project PROJECT_NAME; Could not resolve dependencies for PROJECT_NAME T o resolve the issue, delete the cached local repository – the ~/.m 2/repository/ directory on Linux or the %SystemDrive%\s\NAME\.m 2\repository\ directory on Windows. T his will force Maven to correct versions of required artifacts when performing the next build.
Report a bug
3.4. Configuring Maven to Use the Online Repositories T he online repositories required for Red Hat JBoss Fuse Service Works applications are located at http://maven.repository.redhat.com/techpreview/all/ and http://repository.jboss.org/nexus/content/repositories/public/. If you provided the location of Maven's settings.xm l file during installation, Maven is already configured to use the online repositories. If you did not provide the location during installation, you need to configure Maven manually by following the procedure in Section 3.4, “Configuring Maven to Use the Online Repositories” or Section 3.3, “Configuring Maven to Use the File System Repositories”. If you did not configure the Maven repository during installation, you can configure it using the following procedure. (It is also possible to do this using the project's POM file, but this is not recommended.)
Procedure 3.2. Configuring Maven to Use the Online Repositories 1. Add entries for the online repositories to Maven's settings.xm l file as in the code sample below: <settings xmlns="http://maven.apache.org/SETTINGS/1.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/SETTINGS/1.0.0 http://maven.apache.org/xsd/settings-1.0.0.xsd"> <profiles> <profile>
fsw-online-repos
jboss-ga-repository
http://maven.repository.redhat.com/techpreview/all
<enabled>true
<snapshots> <enabled>false
25
Red Hat JBoss Fuse Service Works 6 Installation Guide
jboss-public-repository
http://repository.jboss.org/nexus/content/repositories/public/
<enabled>true
<snapshots> <enabled>false
jboss-ga-plugin-repository
http://maven.repository.redhat.com/techpreview/all
<enabled>true
<snapshots> <enabled>false
jboss-public-plugin-repository
http://repository.jboss.org/nexus/content/repositories/public/
<enabled>true
<snapshots> <enabled>false
fsw-online-repos
2. If you modified the settings.xm l file while JBoss Developer Studio was running, you must refresh Maven settings in the IDE. From the menu, choose Window → Preferences. In the Preferences Window, expand Maven and choose Settings. Click the Update Settings button to refresh the Maven settings in JBoss Developer Studio.
26
C hapter 3. Maven Repositories
Figure 3.2. Update Maven Settings Result Maven has been configured to use the online repositories provided for Red Hat JBoss Fuse Service Works.
27
Red Hat JBoss Fuse Service Works 6 Installation Guide
Important If your cached local Maven repository contains outdated artifacts, you may encounter one of the following Maven errors when you build or deploy your project: Missing artifact ARTIFACT_NAME [ERROR] Failed to execute goal on project PROJECT_NAME; Could not resolve dependencies for PROJECT_NAME T o resolve the issue, delete the cached local repository – the ~/.m 2/repository/ directory on Linux or the %SystemDrive%\s\NAME\.m 2\repository\ directory on Windows. T his will force Maven to correct versions of required artifacts during the next build.
Report a bug
3.5. Dependency Management In order to use correct Maven dependencies in your Red Hat JBoss Fuse Service Works project, relevant Bill Of Materials (BOM) and parent POM files must be added to the project's pom .xm l file. Adding the BOM and parent will ensure that correct versions of plugins and transitive dependencies from the provided Maven repositories are included in the project. T o ensure correct dependency usage in your project, declare the following parent in the project's pom .xm l file: org.jboss.ip.com ponent.m anagem ent:ip-parent:1.1-redhat-5 and add the following two BOM files as dependencies in the dependencyManagem ent section: org.jboss.ip.com ponent.m anagem ent:ip-dependency-m anagem ent-all:1.1-redhat5 org.jboss.com ponent.m anagem ent:jboss-dependency-m anagem entall:6.1.1.Final-redhat-61 Use the entries from the code sample below for this purpose. <parent>
org.jboss.ip.component.management
<artifactId>ip-parent
1.1-redhat-5
... <dependencyManagement> <dependencies> <dependency>
org.jboss.ip.component.management
<artifactId>ip-dependency-management-all
pom
1.1-redhat-5
<scope>import <dependency>
28
C hapter 3. Maven Repositories
org.jboss.component.management
<artifactId>jboss-dependency-management-all
pom
6.1.1.Final-redhat-61
<scope>import
Report a bug
29
Red Hat JBoss Fuse Service Works 6 Installation Guide
Part II. Basic Installation and Operation
30
C hapter 4 . the Product
Chapter 4. the Product 4.1. Red Hat Customer Portal T he Red Hat Customer Portal is a website located at https://access.redhat.com/home. It provides a central point from where you can manage and maintain your subscription, access the Red Hat Knowledge base and engage with Red Hat and our partners. Report a bug
4.2. Packages Available for T able 4 .1. Packages Available for Package
Description
Red Hat JBoss Fuse Service Works Package
T he Red Hat JBoss Fuse Service Works package is a complete application deployment environment that is installed on top of the JBoss EAP application server. T his installation provides a complete environment for deploying FSW applications. It includes Seam, Hibernate, clustering, and transaction services.
Red Hat JBoss Fuse Service Works Source Code Package
T he source code package contains the complete source code for the Red Hat JBoss Fuse Service Works product.
FSW Platform JavaDocs
T he JavaDocs package contains the complete JavaDocs for Red Hat JBoss Fuse Service Works' APIs.
Report a bug
4.3. Javadocs Javadocs are automatically-generated documentation for Java APIs. T hey are created from the comments developers add to source code as they write it. Javadocs have become the de facto standard way of documenting Java APIs. Report a bug
4.4. Files From the Red Hat Customer Portal Prerequisites Before you begin this task, you need a Customer Portal . Browse to https://access.redhat.com and click the link in the upper right corner to create an .
Procedure 4 .1. and Files from the Red Hat Customer Portal 1. Browse to https://access.redhat.com and click the link in the top right corner. Enter your credentials and click .
31
Red Hat JBoss Fuse Service Works 6 Installation Guide Result You are logged into RHN and you are returned to the main web page at https://access.redhat.com. 2. Navigate to the s page. Use one of the following options to navigate to the s page. A. Click the s link in the top navigation bar. B. Navigate directly to https://access.redhat.com/s/. 3. Select the product and version to . Use one of the following ways to choose the correct product and version to . A. Step through the navigation one level at a time. B. Search for your product using the search area at the top right-hand side of the screen. 4. the appropriate file for your operating system and installation method of choice. Depending on the product you choose, you may have the choice of a Z ip archive, RPM, or native installer for a specific operating system and architecture. Click either the file name or the link to the right of the file you want to . Result T he file is ed to your computer. Report a bug
4.5. Checksum Validation Checksum validation is used to ensure a ed file has not been corrupted. Checksum validation employs algorithms that compute a fixed-size datum (or checksum) from an arbitrary block of digital data. If two parties compute a checksum of a particular file using the same algorithm, the results will be identical. T herefore, when computing the checksum of a ed file using the same algorithm as the supplier, if the checksums match, the integrity of the file is confirmed. If there is a discrepancy, the file has been corrupted in the process. Report a bug
4.6. the ed File Procedure 4 .2. the ed File 1. T o that a file ed from the Red Hat Customer Portal is error-free, access the portal site and go to that package's Software Details page. T he Software Details page displays the MD5 and SHA256"checksum" values. Use the checksum values to check the integrity of the file. 2. Open a terminal window and run either the m d5sum or sha256sum command, with the filename of the ed ZIP as an argument. T he program displays the checksum value for the file as the output for the command.
32
C hapter 4 . the Product 3. Compare the checksum value returned by the command to the corresponding value displayed on the Software Details page for the file. Result If the two checksum values are identical then the file has not been altered or corrupted and is, therefore, safe to use. If the two checksum values are not identical, then the file again. A difference between the checksum values means that the file has either been corrupted during or has been modified since it was ed to the server. If, after several s, the checksum will still not successfully validate, please Red Hat for assistance. Report a bug
4.7. Red Hat Documentation Site Red Hat's official documentation site is at https://access.redhat.com/site/documentation/. T here you will find the latest version of every book, including this one. Report a bug
33
Red Hat JBoss Fuse Service Works 6 Installation Guide
Chapter 5. The JBoss Fuse Service Works Installer JBoss Fuse Service Works provides an installer, jboss-fsw-installer-6.0.0.GA-redhat-4 .jar, which can be used to initiate either a graphical or script-based installation. Report a bug
5.1. Installing JBoss Fuse Service Works by GUI Prerequisites You must have already ed the Red Hat JBoss Fuse Service Works installer file from Red Hat Customer Portal.
Procedure 5.1. Install JBoss Fuse Service Works 1. Open a new terminal and navigate to the folder where you have ed the JBoss Fuse Service Works installer file. 2. Run the following command, replacing 6.0.0.GA-redhat-4 for the version you ed if required: java -jar jboss-fsw-installer-6.0.0.GA-redhat-4.jar
3. You are presented with the End License Agreement. If you agree with the , select I accept the term s of this license agreem ent and then select Next to continue. 4. You are prompted for the location in which you want to install JBoss Fuse Service Works. Specify a location and select Next. You will be notified that an instance of JBoss EAP will be placed in the chosen location. Select OK to proceed.
Warning A warning message is displayed if the directory already exists. Red Hat does not recommend installing over the top of an existing installation. However, if you wish to proceed, select Yes to continue. 5. You are prompted for the installation packs to install. Select Next to continue with the default options.
Note Depending on your deployment, you can select packs other than the default options. For example, if you do not wish to install every pack, you could select SwitchYard and Run-T ime Governance Client only, for a basic installation. 6. You are prompted to create an istrative . Once created, this will be added to the ManagementRealm and can be used to access the Management Console and other applications secured using ManagementRealm. Enter the new name and in the appropriate fields and select Next.
34
C hapter 5. T he JBoss Fuse Service Works Installer 7. You are prompted to create a governance . It will give you access to S-RAMP, DT Gov and RT Gov consoles along with the S-RAMP Command Line Interface. Enter a name and and select Next. 8. You are then prompted to setup your Maven repository. T his will enable you to build the quickstarts provided. Specify the location of an existing or new location for your Maven settings file (typically ~/.m 2/settings.xm l). Select Next.
Note If you choose to skip the maven repository setup, you will be asked to confirm this decision. Select Yes to continue. 9. You are prompted to configure the SAML keystore. It is used by a Java KeyStore to sign authentication tokens. Enter the SAML keystore and select Next. 10. You are then prompted to enable the Java Security Manager. It enforces access rules at the JVM runtime based on one or more security polices. Enable the Java Security Manager and select Next. 11. At this point you are asked to choose between the default or advanced configuration. Select the default configuration for a basic configuration, and select Next to continue. 12. You are prompted to configure the vault. Enter the Vault keystore in the appropriate fields and select Next. 13. You are presented with a screen specifying default database settings. Change the name and to something secure and select Next. 14. You are presented with a list of packages that will be installed. Select Next to proceed. 15. T he installation will commence. A status bar for each component will display its progress. Once this is complete, select Next. 16. Additional processing of tasks will commence. When the status bar indicates this has been completed, select Next. 17. T he console displays a message to let you know that the application has been successfully installed. Also, it offers you a list of URLs for accessing the istration and BPEL Consoles, SRAMP and DT Gov Interfaces and Gadget Server. If you want to repeat the same installation on other machines, select Generate installation script and properties file and choose a location and filename for the script. 18. Select Done. Result T he basic installation is complete.
Note When running the installer on Windows, you may be asked to provide credentials during installation.
35
Red Hat JBoss Fuse Service Works 6 Installation Guide Report a bug
5.1.1. Additional Configuration Options During the JBoss Fuse Service Works installation, you can choose between a default or advanced configuration. T his section provides additional instructions if you choose to proceed with the advanced configuration.
Procedure 5.2. T ask 1. After choosing Perform advanced configuration, select the items you want to configure and select Next. 2. If you chose the Install vault option, the Configure vault screen appears. T his mechanism encrypts sensitive strings and stores them in an encrypted keystore. Enter your keystore information in the required fields and select Next. 3. If you chose the Enable SSL security option,the SSL Security screen appears. Enter the location and of a keystore under the respective fields. Confirm the and select Next. 4. If you chose the Enable LDAP authentication option, the LDAP Configuration screen appears. You can use the LDAP server as an authentication and authorization authority, both for applications and the management interface. Enter the required information to suit your system requirements and select Next. 5. A screen displaying the new security realm configurations appears. Select Next to continue. 6. If you chose the Install JDBC Driver option, the JDBC Driver Setup screen appears. T he JDBC Driver helps to convert the application code to the relevant database language. T ype the Database name and under the respective fields. Confirm the and select Next. Report a bug
5.2. Installing JBoss Fuse Service Works by Script In addition to running the installer GUI, you can also run the installer by script. T his method of installation removes the need to step through the graphical installer for every installation, enabling simplified repeat installations or installations in bulk. Prerequisites In order to install JBoss Fuse Service Works by script, you must have already run the installer in graphical mode, and saved the installation script when prompted at the end of the installation. T he script will have been saved in EAP_HOME, along with an associated .variables file; for example, InstallConfigRecord.xm l and InstallConfigRecord.xm l.variables.
Procedure 5.3. 1. You can change the installation directory by editing the script and modifying the value specified within the
element.
36
C hapter 5. T he JBoss Fuse Service Works Installer
Note You can specify either a full directory path or a path relative to the directory in which you run the script.
Warning Red Hat does not installing over an existing instance of Fuse Service Works. T herefore be sure to select a new or empty directory. 2. Run the script using the following command, replacing 6.0.0.GA-redhat-4 for the version you ed if required: java -jar jboss-fsw-installer-6.0.0.GA-redhat-4.jar InstallConfigRecord.xml
T he script runs and prompts you to provide Governance, SAML keystore, and Vault keystore s, as shown below: [ Starting automated installation ] Read pack list from xml definition. Try to add to selection [Name: Red Hat JBoss Enterprise Application Platform and Index: 0] Try to add to selection [Name: Red Hat JBoss Fuse Service Works and Index: 1] Try to add to selection [Name: Switchyard quickstarts and Index: 2] Try to remove from selection [Name: RT-Gov Client-only and Index: 3] Try to add to selection [Name: RT-Gov Server+Client and Index: 4] Try to add to selection [Name: RTGov Server quickstarts and Index: 5] Try to add to selection [Name: DT-Gov run-time and Index: 6] Try to add to selection [Name: DT-Gov quickstarts and Index: 7] Try to add to selection [Name: S-RAMP run-time and Index: 8] Try to add to selection [Name: S-RAMP quickstarts and Index: 9] Try to add to selection [Name: Red Hat JBoss Fuse Service Works quickstarts and Index: 10] Modify pack selection. Pack [Name: RT-Gov Client-only and Index: 3] removed from selection. Governance : Confirm Governance : SAML keystore : Re-enter SAML keystore : Vault keystore : Re-enter vault keystore :
Report a bug
5.2.1. Supplying s to the Installation Script When installing JBoss Fuse Service Works by script, the will be prompted to supply various s during installation by default. If you would like a fully automated installation, add the s to the associated .variables file and run the installer with the -variablefile option. For example, assuming the script is named InstallConfigRecord.xm l:
37
Red Hat JBoss Fuse Service Works 6 Installation Guide java -jar jboss-fsw-installer-6.0.0.GA-redhat-4.jar InstallConfigRecord.xml variablefile InstallConfigRecord.xml.variables
You can also supply them directly on the command line as key/value pairs by using the -variables option: java -jar jboss-fsw-installer-6.0.0.GA-redhat-4.jar InstallConfigRecord.xml variables KEY_1=VALUE_1 KEY_2=VALUE_2 ...
Warning Red Hat recommends you remove plaintext s from the .variables file after installation to avoid compromise. Report a bug
38
C hapter 6. Starting and Stopping the Application Server
Chapter 6. Starting and Stopping the Application Server You need to start the JBoss Enterprise Application Platform instance for JBoss Fuse Service Works to run. T his is because the JBoss Fuse Service Works components run on the JBoss Enterprise Application Platform container.
Note For more information about starting and stopping JBoss Enterprise Application Platform using alternative and more advanced methods, see the Red Hat JBoss Enterprise Application Platform istration and Configuration Guide. Report a bug
6.1. Start JBoss EAP 6 as a Standalone Server Summary T his topic covers the steps to start JBoss EAP 6 as a Standalone Server.
Procedure 6.1. Start the Platform Service as a Standalone Server 1. For Red Hat Enterprise Linux. Run the command: EAP_HOME/bin/standalone.sh 2. For Microsoft Windows Server. Run the command: EAP_HOME\bin\standalone.bat 3. Optional: Specify additional parameters. T o print a list of additional parameters to to the start-up scripts, use the -h parameter. Result T he JBoss EAP 6 Standalone Server instance starts. Report a bug
6.2. Stop JBoss EAP 6 as a Standalone Server You can stop JBoss Enterprise Application Platform using the Management CLI or by pressing CT RL+C in the terminal. 1. Stopping JBoss Enterprise Application Platform using the Management CLI. A. Run the EAP_HOME/bin/jboss-cli.sh command to launch the Management CLI. $ EAP_HOME/bin/jboss-cli.sh
B. Run the connect command to connect to the server.
39
Red Hat JBoss Fuse Service Works 6 Installation Guide [disconnected /] connect
C. Run the shutdown command to stop the server. [standalone@localhost:9999 /] shutdown
D. Run the quit command to close the Management CLI. [standalone@localhost:9999 /] quit
2. Stopping JBoss Enterprise Application Platform by pressing CT RL+C. Press Ctrl+C in the server window (the terminal window where JBoss Enterprise Application Platform was started). Result Each of these alternatives stops JBoss Enterprise Application Platform. Report a bug
40
C hapter 7. Basic Operation T utorial
Chapter 7. Basic Operation Tutorial 7.1. Running the Quickstart 7.1.1. About Quickstarts T he quickstarts are sample projects. Each one demonstrates how to use a specific piece of functionality in order to aid you in building services. All the sample applications are included in the quickstarts/directory of your installation.
Note Each quickstart has different requirements. T hese are documented in their individual re e.txt files. Report a bug
7.1.2. Using SwitchYard Quickstarts Prerequisites Maven 3 must be installed.
Note Make sure that you run the following command to that Maven is installed successfully on your machine:m vn --version
Procedure 7.1. T ask 1. Open a terminal. 2. Navigate to the EAP_HOME/quickstarts/switchyard directory. 3. Run the following command: mvn clean install
Note Make sure that you select the remote-invoker quickstart and then execute m vn clean install command. Result T he quickstarts compile and are ready for use. Report a bug
41
Red Hat JBoss Fuse Service Works 6 Installation Guide
7.1.3. Importing Quickstarts into JBDS Procedure 7.2. T ask 1. Open the JBoss Developer Studio. 2. Click on File → Import → Maven → Existing Maven Projects. 3. Select the quickstart that you want to import from the SwitchYard Quickstart directory. (For example, quickstarts/switchyard/bean-service.) 4. T he quickstart will appear in the Project Explorer tab. Click the tab to explore its contents. T he quickstart will appear as a new project. 5. Right-click on the project's name. A drop down menu will appear. Select Run as... → Run on server → EAP. Result T he quickstart is deployed to the server. Report a bug
7.1.4. List of Basic Quickstart Applications remote-invoker T he RemoteInvoker serves as a remote invocation client for SwitchYard services. It allows nonSwitchYard applications to invoke any service in SwitchYard which uses a
binding. It is also used by the internal clustering channel to facilitate intra-cluster communication between instances. bean-service Implements a service using a CDI bean and exposes it through a SOAP gateway. bpm-service Uses BPMN 2 to provide and utilize SwitchYard services. camel-service T his is a basic routing example that uses XML and Java DSL Camel routes. camel-jms-binding Demonstrates how a Camel component can be used as a SwitchYard gateway. demos/orders Launches a web application which invokes a SwitchYard service from a JSF.
Note You can find additional quickstarts by going to the quickstarts directory. Report a bug
42
C hapter 7. Basic Operation T utorial
7.2. How the Remote Invoker Quickstart Works 7.2.1. Overview of the Remote Invoker Quickstart T he Remote Invoker serves as a remote invocation client for SwitchYard services. It allows nonSwitchYard applications to invoke any service in SwitchYard which uses a
binding. T his section includes the use-case of Remote Invoker quickstart. It demonstrates how to use the Remote Invoker with services in SwitchYard using the SCA Binding. Remote Invoker T o evaluate an offer on an automobile and make a decision on whether to accept the offer or not. You need to implement the CreditCheck service using business rules and the Dealer service using CDI. T he Dealer service evaluates the offer and submits the applicant to a credit check, before replying with an answer to the client. T his process includes unit tests to test each service individually and a test driver called RemoteClient which demonstrates the use of an HT T P-based Remote Invoker to invoke a SwitchYard service remotely.
Figure 7.1. Remote Invoker Image Report a bug
7.2.2. Using the Remote Invoker Quickstart Prerequisites Maven 3 must be installed.
Procedure 7.3. T ask
43
Red Hat JBoss Fuse Service Works 6 Installation Guide 1. Open a terminal. 2. Navigate to the EAP_HOME/quickstarts/switchyard/rem ote-invoker directory. 3. Run the following command: mvn clean install
Result T he Remote Invoker quickstart is ready for use. Report a bug
7.2.3. Deploy Remote Invoker Quickstart with Maven Procedure 7.4 . T ask 1. Open a terminal and launch the server. For more information, see Starting the Server section. 2. Navigate to the quickstarts/ directory and choose the remote invoker quickstart. cd quickstarts/switchyard/remote-invoker
3. On a separate terminal, run the following command to deploy the quickstart: mvn package mvn jboss-as:deploy
Result T he Remote Invoker quickstart is deployed successfully by Maven. Report a bug
7.2.4. Working with Messages Procedure 7.5. T ask 1. Open a terminal and launch the server. For more information, see Starting the Server section. 2. Navigate to the quickstarts/ directory and choose the remote invoker quickstart. cd quickstarts/switchyard/remote-invoker
3. On a separate terminal, run the following command to send a request message to the service: mvn exec:java
Result T he RemoteInvoker serves as a remote invocation client for SwitchYard services and send messages successfully. Report a bug
44
C hapter 7. Basic Operation T utorial
7.2.5. Undeploy a Quickstart Procedure 7.6. T ask 1. Open a terminal and launch the server. For more information, see Starting the Server section. 2. Navigate to the quickstarts/ directory. cd quickstarts/switchyard/remote-invoker
3. On a separate terminal, run maven to undeploy the quickstart: mvn jboss-as:undeploy
Result T he Remote Invoker quickstart is undeployed successfully. Report a bug
45
Red Hat JBoss Fuse Service Works 6 Installation Guide
Part III. Additional Configuration Options
46
C hapter 8. Validating Your Red Hat JBoss Fuse Service Works Installation
Chapter 8. Validating Your Red Hat JBoss Fuse Service Works Installation 8.1. Overview After performing the JBoss Fuse Service Works installation on your machine, that the product is installed successfully. Validation feature helps you to check the FSW installation. It allows you to find the source of the problem, if the product installation fails. It also provides the functionality to the message content. Report a bug
8.2. Validate Your Red Hat JBoss Fuse Service Works Installation Procedure 8.1. T ask 1. Navigate to the EAP home directory and open the standalone/log/server.log file. 2. Check to see if there is ERROR dialogue in the log. If there is no ERROR text, it means your installation has been completed successfully. If there is, it means the installation was unsuccessful and you should try ing and installing the file again. Report a bug
8.3. List of FSW Runtime Components T able 8.1. List of FSW Runtime Components Component
Description
EAP
JBoss Enterprise Application Platform is a fast, secure, powerful middleware platform built upon open standards, and compliant with the Java Enterprise Edition specification.
Switchyard
SwitchYard is a service delivery framework that provides complete to develop, deploy and manage service-oriented applications. It allows you to deploy and run services with limited dependencies.
Camel
Camel binding in SwitchYard allows Camel components to be used as gateway bindings for services and references within an application. Every camel component binding ed by SwitchYard has it's own configuration namespace.
Riftsaw
RiftSaw provides a JBoss AS integration for the Apache ODE BPEL engine.
Drools Expert
Drools Expert is a declarative, rule based, coding environment. It uses the rules to perform reasoning.
Smooks
T his is an XML transformation engine.
47
Red Hat JBoss Fuse Service Works 6 Installation Guide Component
Description
Modeshape
ModeShape is a distributed, hierarchical, transactional, and consistent data store with for queries, full-text search, events, versioning, references, and flexible and dynamic schemas.
ActiveMQ
Apache ActiveMQ is a message store component.
Apache CXF
JBoss Web Services CXF (JBossWS-CXF) is the JBoss Web Services stack implementation internally based on Apache CXF. It aims to intercept incoming SOAP requests, extract the nameT oken, attempt to authenticate it against the Module configured in the application server's security domain, and provide any authorized roles.
Governance Components (S-RAMP, BAM)
Governance brings access control, policies, and SLAs into the way in which services are used within a business process. Real-time access to critical business performance metrics helps to improve the efficiency and effectiveness of business processes. It can achieved by using components like S-RAMP and BAM (Business Activity Monitoring). BAM encomes business intelligence as well as network and systems management that helps to improve the efficiency of a business process.
Report a bug
48
C hapter 9. Run-T ime Governance Configuration
Chapter 9. Run-Time Governance Configuration 9.1. Configuring Run-Time Governance Introduction SwitchYard uses Run-T ime Governance to facilitate complete control over the shared services by following a policy based approach. SwitchYard classifies Run-T ime Governance into two aspects: Policy definition and enforcement Collection and exposure of run-time metrics for services and service references Run-T ime Governance configurations allow you to add or modify classes to manage Run-T ime Governance and also define names and s. Report a bug
9.2. Overlord Run-Time Governance Configuration Procedure 9.1. T ask 1. T o view the Overlord Run-T ime Governance properties, access the properties file located in $JBOSS_HOME/standalone/configuration/overlord-rtgov.properties. 2. Add and modify classes to manage governance. Report a bug
9.3. Common Properties T able 9.1. Common Properties Name
Description
collectionEnabled
T his property will determine whether activity information is collected when the server is initially started. T his value can be changed at runtime using the ActivityCollector MBean.
ActivityServerLogger.maxT hreads
T his property will determine the maximum number of threads used by the activity collector to report all the activity units to the server.
ActivityServerLogger.durationBetweenFailureRepor ts
T his property controls the duration (in milliseconds) between a failure being reported, if the client is having trouble ing the activity server.
ActivityServerLogger.activityListQueueSize
T his property defines the queue size for pending activity lists, that are awaiting being reported to the activity server.
ActivityServerLogger.freeActivityListQueueSize
T his property defines the queue size to manage free activity lists that can be reused.
49
Red Hat JBoss Fuse Service Works 6 Installation Guide Name
Description
BatchedActivityUnitLogger.maxUnitCount, BatchedActivityUnitLogger.maxT imeInterval
Activity unit batch logging properties.
infinispan.container
JNDI name for default cluster to use when not specified explicitly.
Report a bug
9.4. Server Properties T able 9.2. Server Properties Name
Description
MVELSeverityAnalyzer.scriptLocation
Optional location of a MVEL script used to determine severity levels for nodes and links within the service overview diagram.
Report a bug
9.5. Client Properties T able 9.3. Client Properties Name
Description
REST ActivityServer.serverURL
T his is the URL of the activity server collecting the activity events.
REST ActivityServer.servername
T he name used to access the REST service.
REST ActivityServer.server
T he used to access the REST service.
Report a bug
9.6. Database T he installer sets up the datasources for Runtime-T ime Governance, jBPM, SRAMP, BPEL (Riftsaw), and Gadget Server. T he datasources can be configured in $JBOSS_HOME/standalone/configuration/standalone.xm l. Report a bug
9.7. Caching T he EPN and Active Collection mechanisms both have the ability to make use of caching provided by Infinispan. When running the Red Hat JBoss Fuse Service Works in clustered mode (that is, with standalone-full-ha.xm l), it provides a default clustered cache container, which is referenced in the infinispan.container property in the overlord-rtgov.properties file.
50
C hapter 9. Run-T ime Governance Configuration
Note T o make sure the individual named caches are clustered correctly, it is necessary to add an entry for each cache into the standalone-full-ha.xm l file. For more information on Infinispan configuration, refer JBoss Enterprise Application Platform 6.1 Development Guide. Report a bug
9.8. Caching Example T he following cache entry for the "Principals" cache has been defined in the standalone-full-ha.xml file:
Report a bug
51
Red Hat JBoss Fuse Service Works 6 Installation Guide
Chapter 10. Design-Time Governance Configuration and Workflows 10.1. Overview Design-T ime Governance consists of the following configurations that can be modified to suit a particular deployment and business. Design-T ime Governance Back-End Configuration - includes dtgov.properties file Design-T ime Governance Interface Configuration - includes dtgov-ui.properties file T his section describes the two configuration files so that the can configure Design-T ime Governance for their particular deployment environment and organization's unique business processes. Report a bug
10.2. Design-Time Governance Back-End Configuration You can modify the configuration of the back-end system, after you make appropriate changes to an external configuration file located under the configuration directory of the JBoss EAP. However, by default, it is located under: jboss-eap/standalone/configuration/dtgov.properties
If the configuration file does not exists, you can create the file and modify. T he Design-T ime Governance will automatically identify this file during the server startup. You can set the location of the configuration file by accessing the following Java system property: governance.file.name
Report a bug
10.3. Design-Time Governance Interface (UI) Configuration You can configure the Design-T ime Governance Interface for a specific deployment and business environment. T o modify the Interface configuration, make the appropriate changes to an external configuration file located under the configuration directory of the JBoss EAP. However, by default, the JBoss EAP configuration file is located under: jboss-eap/standalone/configuration/dtgov-ui.properties
You can set the location of the configuration file by accessing the following Java system property: dtgov-ui.config.file.name
Report a bug
10.4. Design-Time Governance Configuration Properties A number of configuration properties drive the integration between Design-T ime Governance and S-RAMP.
52
C hapter 10. Design-T ime Governance Configuration and Workflows
Note T he Design-T ime Governance back-end and the Design-T ime Governance Interface each have their own separate configuration. T his is because the back-end and Interface are separate applications that can be independently deployed. Design-T ime Governance Back-End Configuration Properties # # S-RAMP Connection details sramp.repo.url sramp.repo.auth.provider sramp.repo. sramp.repo. sramp.repo.validating sramp.repo.auth.saml.issuer sramp.repo.auth.saml.service # Location of the DTGov WAR governance.url # Frequency with which to poll S-RAMP for query matches governance.query.interval # Location in JNDI of the email service governance.jndi.email.reference # "From" information to use when sending email (domain and address) governance.email.domain governance.email.from # RHQ connection info rhq.rest. rhq.rest. rhq.base.url # BPM connection info governance.bpm. governance.bpm. governance.bpm.url # JAAS used to invoke DTGov provided services governance. governance. # Deployment targets configured for the DTGov deployment service governance.targets # Mapping of S-RAMP query to governance workflow governance.queries # Location of the DTGov UI dtgov.ui.url # S-RAMP s-ramp-wagon dtgov.s-ramp-wagon.snapshots dtgov.s-ramp-wagon.releases # DTGov Workflow maven info dtgov.workflows.group dtgov.workflows.name dtgov.workflows.version dtgov.workflows.package
53
Red Hat JBoss Fuse Service Works 6 Installation Guide
Design-T ime Governance Interface Configuration Properties # # S-RAMP API connection endpoint dtgov-ui.s-ramp.atom-api.endpoint # Whether to validate the S-RAMP connection dtgov-ui.s-ramp.atom-api.validating # What kind of authentication to use (class name) dtgov-ui.s-ramp.atom-api.authentication.provider # Only used when the provider is basic auth dtgov-ui.s-ramp.atom-api.authentication.basic.name dtgov-ui.s-ramp.atom-api.authentication.basic. # Only used when the provider is SAML bearer token auth dtgov-ui.s-ramp.atom-api.authentication.saml.issuer dtgov-ui.s-ramp.atom-api.authentication.saml.service dtgov-ui.s-ramp.atom-api.authentication.saml.sign-assertions dtgov-ui.s-ramp.atom-api.authentication.saml.keystore dtgov-ui.s-ramp.atom-api.authentication.saml.keystore- dtgov-ui.s-ramp.atom-api.authentication.saml.key-alias dtgov-ui.s-ramp.atom-api.authentication.saml.key- # Task API connection endpoint dtgov-ui.task-api.endpoint # Implementation of a task client dtgov-ui.task-client.class # Authentication to use when invoking the task API dtgov-ui.task-api.authentication.provider # Only used when using basic auth dtgov-ui.task-api.authentication.basic.name dtgov-ui.task-api.authentication.basic. # Only used when using saml bearer token auth dtgov-ui.task-api.authentication.saml.issuer dtgov-ui.task-api.authentication.saml.service dtgov-ui.task-api.authentication.saml.sign-assertions dtgov-ui.task-api.authentication.saml.keystore dtgov-ui.task-api.authentication.saml.keystore- dtgov-ui.task-api.authentication.saml.key-alias dtgov-ui.task-api.authentication.saml.key- # Deployment lifecycle base classifier dtgov-ui.deployment-lifecycle.classifiers.base dtgov-ui.deployment-lifecycle.classifiers.initial # Classifier to use when querying for all deployments dtgov-ui.deployment-lifecycle.classifiers.all dtgov-ui.deployment-lifecycle.classifiers.in-progress # This next one is a prefix for any property that will indicate a possible classifier stage that # should be displayed in the UI. In the dtgov ui configuration file, multiple properties would # be specified that begin with this prefix and have a value of the format {label}: {classifier} dtgov-ui.deployment-lifecycle.classifiers.stage # And another one that is a prefix for any property that will indicate a possible deployment type # that should be displayed in the UI. In the dtgov ui configuration file, multiple properties would # be specified that begin with this prefix and have a value of the format {label}: {type} dtgov-ui.deployment-lifecycle.types # S-RAMP UI integration properties dtgov-ui.s-ramp-browser.url-base
54
C hapter 10. Design-T ime Governance Configuration and Workflows Report a bug
10.5. Design-Time Governance Configuration Examples Back-End Configuration Example Here is an example of the back-end configuration: sramp.repo.url=http://localhost:8080/s-ramp-server/ sramp.repo.auth.provider=org.overlord.sramp.governance.auth.BasicAuthenticationProvid er sramp.repo.=dtgov sramp.repo.=DTG_ sramp.repo.validating=true
T he above configuration uses BASIC authentication when connecting to the S-RAMP repository. It connects to S-RAMP on localhost (port 8080). Interface Configuration Example Here is an example of the Interface configuration: dtgov-ui.s-ramp.atom-api.endpoint=http://localhost:8080/s-ramp-server dtgov-ui.s-ramp.atomapi.authentication.provider=org.overlord.dtgov.ui.server.services.sramp.SAMLBearerTok enAuthenticationProvider dtgov-ui.s-ramp.atom-api.authentication.saml.issuer=/dtgov-ui dtgov-ui.s-ramp.atom-api.authentication.saml.service=/s-ramp-server dtgov-ui.s-ramp.atom-api.validating=true
T he above configuration connects to S-RAMP on localhost (port 8080) and uses SAML bearer token authentication. Report a bug
10.6. Governance Workflows One of the most important features of Design-T ime Governance is the ability to trigger Governance Workflows based on changes detected in the S-RAMP repository. Once you have installed S-RAMP and Design-T ime Governance, and configured the database for S-RAMP, you can: Create a new workflow, or adapt a sample workflow. Deploy the workflow to S-RAMP. Map S-RAMP query to BPMN2 process name. T hat is, configure a workflow to execute when repository content changes. Report a bug
10.7. Installing Sample Workflow T his section provides installation steps of a sample workflow called "SimpleReleaseProcess".
55
Red Hat JBoss Fuse Service Works 6 Installation Guide 1. Navigate to jboss-eap-6.1/dtgov-data and create a local settings.xm l containing the credentials for the S-RAMP repository. T his file must also contain the Overlord that you configured during installation. Here is an example: <settings xmlns="http://maven.apache.org/SETTINGS/1.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/SETTINGS/1.0.0 http://maven.apache.org/xsd/settings-1.0.0.xsd"> <servers> <server>
local-sramp-repo
<name> <>cust0mpwd <server>
local-sramp-repo-snapshots
<name> <>cust0mpwd
2. Ensure that the server is up and running, and deploy the "SimpleReleaseProcess" sample workflow to the server by running the following command: mvn -s local-settings.xml deploy
Report a bug
56
C hapter 11. Managing s
Chapter 11. Managing s 11.1. Adding a New for the Management Interfaces Overview T he management interfaces in JBoss FSW are secured by default as there are no s initially available, unless you have installed the platform using the graphical installer. T his is a security precaution to prevent security breaches from remote systems due to simple configuration errors. Local non-HT T P access is protected by a SASL mechanism, with a negotiation happening between the client and server each time the client connects for the first time from the localhost. T his task describes how to create the initial istrative , which can use the web-based Management Console and remote instances of the Management Command Line Interface.
Note HT T P communication with JBoss EAP 6 is considered to be remote access, even if the traffic originates on the localhost. T herefore, you must create at least one in order to be able to use the management console. If you attempt to access the management console before adding a , you will receive an error because it does not even deploy until the is added.
Procedure 11.1. Create the Initial istrative for the Remote Management Interfaces 1. Invoke the add-.sh or add-.bat script. Change to the EAP_HOME/bin/ directory. Invoke the appropriate script for your operating system. Red Hat Enterprise Linux [@host bin]$ ./add-.sh
2. Choose to add a Management . Hit ENT ER to select the default option a to add a Management . T his is added to the Managem entRealm and is authorized to perform management operations using the web-based Management Console or command-line based Management CLI. T he other choice, b, adds a to the ApplicationRealm , and provides no particular permissions. T hat realm is provided for use with applications. 3. Enter the desired name and . When prompted, enter the name and . You will be prompted to confirm the . 4. Review the information and confirm. You are prompted to confirm the information. If you are satisfied, type yes. 5. Choose whether the represents a remote JBoss EAP 6 server instance.
57
Red Hat JBoss Fuse Service Works 6 Installation Guide Besides s, the other type of which occasionally needs to be added to JBoss EAP 6 in the Managem entRealm is a representing another instance of JBoss EAP 6, which must be able to authenticate to a cluster as a member. T he next prompt allows you to designate your added for this purpose. If you select yes, you will be given a hashed secret value, representing the 's , which would need to be added to a different configuration file. For the purposes of this task, answer no to this question. 6. Enter additional s. You can enter additional s if desired, by repeating the procedure. You can also add them at any time on a running system. Instead of choosing the default security realm, you can add s to other realms to fine-tune their authorizations. 7. Create s non-interactively. You can create s non-interactively, by ing in each parameter at the command line. T his approach is not recommended on shared systems, because the s will be visible in log and history files. T he syntax for the command, using the management realm, is: [@host bin]$ ./add-.sh name
T o use the application realm, use the -a parameter. [@host bin]$ ./add-.sh -a name
8. You can suppress the normal output of the add- script by ing the --silent parameter. T his applies only if the minimum parameters if nam e and have been specified. Error messages will still be shown. Result Any s you add are activated within the security realms you have specified. s active within the Managem entRealm realm are able to manage JBoss EAP 6 from remote systems. Report a bug
11.2. Add- Command Arguments T he following table describes the arguments available for the add-.sh or add-.bat command. T able 11.1. Add- Command Arguments Command Line Argument
Argument Value
Description
-a
N/A
T his argument specifies to create a in the application realm. If omitted, the default is to create a in the management realm.
-dc
DOMAIN_CONFIGURATION_DI RECTORY
T his argument specifies the domain configuration directory that will contain the properties files. If it is omitted, the default directory is EAP_HOME/dom ain/configuration/.
58
C hapter 11. Managing s Command Line Argument
Argument Value
Description
-sc
SERVER_CONFIGURATION_DI RECTORY
T his argument specifies an alternate standalone server configuration directory that will contain the properties files. If it is omitted, the default directory is EAP_HOME/standalone/configuration/.
-up
_PROPERTIES_FILE
T his argument specifies the name of the alternate properties file. It can an absolute path or it can be a file name used in conjunction with the sc or -dc argument that specifies the alternate configuration directory.
GROUP_LIST
A comma-separated list of groups to assign to this .
GROUP_PROPERTIES_FILE
T his argument specifies the name of the alternate group properties file. It can an absolute path or it can be a file name used in conjunction with the sc or -dc argument that specifies the alternate configuration directory.
T he of the . T he must satisfy the following requirements:
--properties -g --group -gp --groupproperties -p --
It can not be the same as the name. It must contain at least 8 characters. It must contain at least one alphanumeric character. It must contain at least one digit. It must contain at least one non-alphanumeric symbol -u
_NAME
T he name of the .
REALM_NAME
T he name of the realm used to secure the management interfaces. If omitted, the default is "ManagementRealm".
N/A
Run the add- script with no output to the console.
N/A
Display usage information for the add- script.
-- -r --realm -s --silent -h --help Report a bug
11.3. Alternate Properties Files for Management Information Overview
59
Red Hat JBoss Fuse Service Works 6 Installation Guide By default, and role information created using the add-.sh script is stored in properties files located in the server configuration directory. T he server configuration information is stored in the EAP_HOME/standalone/configuration/ directory and the domain configuration information is stored in the EAP_HOME/dom ain/configuration/ directory. T his topic describes how to override the default file names and locations.
Procedure 11.2. Alternate Properties Files A. T o specify an alternate directory for the server configuration, use the -sc argument. T his argument specifies an alternate directory that will contain the server configuration properties files. B. T o specify an alternate directory for the domain configuration, use the -dc argument. T his argument specifies an alternate directory that will contain the domain configuration properties files. C. T o specify an alternate configuration properties file, use the -up or ---properties argument. It can an absolute path or it can be a file name used in conjunction with the -sc or -dc argument that specifies the alternate configuration directory. D. T o specify an alternate group configuration properties file, use the -gp or --group-properties argument. It can an absolute path or it can be a file name used in conjunction with the -sc or -dc argument that specifies the alternate configuration directory.
Note T he add- command is intended to operate on existing properties files. Any alternate properties files specified in command line arguments must exist or you will see the following error: JBAS015234: No apps.properties files found
Report a bug
60
C hapter 12. Configuring Red Hat JBoss Fuse Service Works to Run as a Background Service
Chapter 12. Configuring Red Hat JBoss Fuse Service Works to Run as a Background Service 12.1. Introduction Headless mode is a mode that allows you to run JBoss Fuse Service Works on a server without a monitor attached. T he main advantage of running FSW in this particular mode is that the product will launch automatically when the server reboots, saving your valuable time. T here is no need to intervene and launch FSW manually. T o achieve this, JBoss Fuse Service Works runs as a background daemon (Linux) or service (Microsoft Windows). Report a bug
12.2. Running JBoss Fuse Service Works as a Service on a Headless Server Prerequisites Install JBoss EAP 6 or later privileges on the server are required. Summary Use the following procedure to install JBoss FSW as a service on Red Hat Enterprise Linux when the installation has been done using the graphical installer.
Procedure 12.1. Setup the Service 1. Locate the start-up script and configuration file T he start-up script and an associated configuration file are located in the EAP_HOME/bin/init.d/ directory. Open the configuration file jboss-as.conf to edit it. 2. Customize the start-up options in the jboss-as.conf file T here are several options within the jboss-as.conf file. At the minimum, specify the correct values for JBOSS_HOME and the JBOSS_ variables. If these variables are absent, add them. 3. Copy files into system directories a. Copy the modified configuration file to the /etc/jboss-as directory. [@host init.d]$ sudo mkdir /etc/jboss-as [@host init.d]$ sudo jboss-as.conf /etc/jboss-as/
b. Copy the start-up script to the /etc/init.d directory.
61
Red Hat JBoss Fuse Service Works 6 Installation Guide [@host init.d]$ sudo jboss-as-standalone.sh /etc/init.d
4. Add the start-up script as a service. Add the new jboss-as-standalone.sh service to list of automatically started services, using the chkconfig service management command. [@host init.d]$ sudo chkconfig --add jboss-as-standalone.sh
5. Start the service. T est that the service has been installed correctly by using the standard syntax for starting Red Hat Enterprise Linux services. [@host bin]$ sudo service jboss-as-standalone.sh start
If everything has gone correctly, you should get a green [OK]. If you get an error, check the error logs and make sure your paths are correct in the configuration file. 6. Make the service start automatically when you restart your server. T o add the service to the list of services which start automatically when your server restarts, issue the following command. [@host init.d]$ sudo chkconfig jboss-as-standalone.sh on
Result JBoss FSW starts automatically when the Red Hat Enterprise Linux reaches its default run-level, and stops automatically when the operating system goes through its shutdown routine. Report a bug
62
C hapter 13. Configuring Red Hat JBoss Fuse Service Works to Run in a Clustered Environment
Chapter 13. Configuring Red Hat JBoss Fuse Service Works to Run in a Clustered Environment 13.1. About Cluster Service Registry in SwitchYard T he purpose of the clustered service registry is to store information about the services that are used in a cluster of SwitchYard instances. Following are the details that are recorded in the registry for each published service: Service Name: It stores the name of a service. Domain Name: It stores the name of a domain. Endpoint Address: It stores the physical access point for the service. Node Name: It stores the cluster node on which the service is deployed. Service Contract: It stores the abstract invocation contract for the service which consists of the message exchange pattern and message types. Report a bug
13.2. Setting Up SwitchYard in a Clustered Environment T he two fundamental building blocks that are used for setting up SwitchYard in a clustered environment are: Shared Runtime Registry: A shared, distributed runtime registry that enable individual instances to publish and query service endpoint details. Remote Communication Channels: An internal communication protocol that enables a service client to invoke a service, hosted in a remote instance. T he runtime registry s a replicated Infinispan cache. Each instance in a cluster points to the same replicated cache. When a node s a cluster, it immediately has access to all remote service endpoints published in the registry. If a node leaves the cluster due to failure or shutdown, all service endpoint registrations are immediately removed for that node. T he registry is not persisted, so manual clean-up and maintenance is not required. T he communication channel is a private intra-cluster protocol used by instances to invoke a remote service. At present, the channel is based on HT T P.
Note T he SwitchYard registry is a runtime registry and not a publication registry. T he state of services within the registry is tied directly to the current state of services deployed within a cluster. Report a bug
13.3. Creating a Cluster of SwitchYard Instances T o create a cluster of SwitchYard instances, start two or more instances with a shared Infinispan cache.
63
Red Hat JBoss Fuse Service Works 6 Installation Guide # start instance 1 node1> bin/standalone.sh -c standalone-ha.xml -Djboss.node.name=node1 # start instance 2 node> bin/standalone.sh -c standalone-ha.xml -Djboss.node.name=node2 Djboss.socket.binding.port-offset=1000
When the instances are up, you can deploy applications independently to each instance. A homogeneous cluster(a cluster of identical machines) consists of identical applications deployed on each node. However, a heterogeneous cluster consists of different applications and services deployed on each instance. T o the cluster setup, deploy a consumer application to one instance and a provider application to another. Report a bug
13.4. Enabling Clustering in your SwitchYard Application T o configure a cluster: Start two or more instances on different nodes. Indicate the services that are clustered in the switchyard.xm l file.
Note By default, SwitchYard uses the default cache in the cluster cache container which comes predefined in the standalone-ha.xm l file. You can control the services in the application that can be published in the cluster's runtime registry and the references that can be resolved by clustered services. T o enable a service to be published in the cluster's runtime registry, promote the service in the application and add a
with clustering enabled to it. <sca:service name="Goodbye" promote="GoodbyeBean/Goodbye"> <sca:interface.java interface="com.example.Goodbye"/> <sca:binding.sca sy:clustered="true"/>
T o invoke a service in a cluster, promote the reference and add an SCA binding with clustering enabled. <sca:reference name="Goodbye" multiplicity="0..1" promote="GreetingBean/Goodbye"> <sca:interface.java interface="com.example.Goodbye"/> <sca:binding.sca sy:clustered="true"
Report a bug
13.5. Run-Time Governance and S-RAMP in a Clustered Environment
64
C hapter 13. Configuring Red Hat JBoss Fuse Service Works to Run in a Clustered Environment When you start the server using the HA profile, run-time governance is automatically clustered based on the clustered infinispan, hornetq, and a shared database. S-RAMP only requires a shared database. T here is no dependency between run-time governance and S-RAMP as they are installed and configured independently. In a clustered environment, it is recommended to have a dedicated run-time governance server, separate from the execution servers that hosts the run-time governance server. In this case, all servers connect to this server via the run-time governance client. Depending upon the load of the run-time governance server, it may also be necessary to set up a cluster of governance servers as well. If you have a cluster of runtime governance servers, then they only need to connect to the same database instance. However, it is possible to also configure each run-time governance server to have its own SRAMP database. T he FSW installer configures all components to use the same database by default. So run-time governance and SRAMP share the same database instance, however this is not mandatory. Report a bug
65
Red Hat JBoss Fuse Service Works 6 Installation Guide
Chapter 14. Configuring S-RAMP 14.1. , Install and Configure S-RAMP Prerequisites Java JDK 1.6 or newer Apache Ant 1.7 or newer to use the installer Maven 3.0.3 or newer to build and run the examples
Procedure 14 .1. T ask 1. S-RAMP s-ram p-
.zip (or tar.gz) archive from http://www.jboss.org/overlord website. 2. Install S-RAMP Extract the archive and run the following command: ant install
T his command first s jBPM, REST Easy and ModeShape from sourceforge. T he s are stored in the jbpm5 directory. In the same directory, it creates a jbpm-installer directory with jBPM and a sub-directory containing the application server jboss-as-7.1.1.Final. T he application server saves ModeShape and REST Easy as modules. 3. Configure S-RAMP Run the following command: ant configure
T his command adds some S-RAMP specific services to jBPM. It deploys the s-ram pserver.war, the s-ram p-ui.war and the governance.war. It then points jBPM to obtain its workflow data from the S-RAMP repository, rather than BRMS or Drools-Guvnor. At this point, you need to populate the S-RAMP repository with some initial data. T o achieve this, the repository needs to be up and running. a. Start the JBoss application server by running the following command: ant start
b. If your system s the tail command, you can run the following command: ant tail
T his monitors the startup process. It is ready as soon as you see the following in the application server console output: [exec] 12:00:13,905 INFO [org.jboss.as.server] (DeploymentScanner-threads - 2) JBAS018559: Deployed "s-ramp-ui.war" [exec] 12:00:13,910 INFO [org.jboss.as.server] (DeploymentScanner-threads
66
C hapter 14 . Configuring S-RAMP - 2) JBAS018559: Deployed [exec] 12:00:13,915 INFO - 2) JBAS018559: Deployed [exec] 12:00:13,918 INFO - 2) JBAS018559: Deployed [exec] 12:00:13,922 INFO - 2) JBAS018559: Deployed [exec] 12:00:13,925 INFO - 2) JBAS018559: Deployed [exec] 12:00:13,928 INFO - 2) JBAS018559: Deployed [exec] 12:00:13,931 INFO - 2) JBAS018559: Deployed [exec] 12:00:13,933 INFO - 2) JBAS018559: Deployed
"s-ramp-server.war" [org.jboss.as.server] (DeploymentScanner-threads "s-ramp-governance.war" [org.jboss.as.server] (DeploymentScanner-threads "jbpm-human-task-war.war" [org.jboss.as.server] (DeploymentScanner-threads "jbpm-gwt-console.war" [org.jboss.as.server] (DeploymentScanner-threads "jbpm-gwt-console-server.war" [org.jboss.as.server] (DeploymentScanner-threads "jbpm-form-builder.war" [org.jboss.as.server] (DeploymentScanner-threads "drools-guvnor.war" [org.jboss.as.server] (DeploymentScanner-threads "designer.war"
c. the application by running the following command: ant
T his completes the S-RAMP installation process. Report a bug
14.2. S-RAMP Installation Procedure 14 .2. T ask 1. T o your S-RAMP installation, start the S-RAMP GUI. T he welcome screen of the S-RAMP Explorer appears. 2. On the S-RAMP Explorer window, click Browse under Artifact and see a list of files related to the S-RAMP default workflows. Alternatively, you can start the s-ramp shell in the bin directory of the distribution: ./s-ramp.sh
Here is how the result looks:
******************************************************************* *** _____ ______ ___ ___ ________ / ___| | ___ \/ _ \| \/ | ___ \ \ `--. ______| |_/ / /_\ \ . . | |_/ / `--. \______| /| _ | |\/| | __/ /\__/ / | |\ \| | | | | | | | \____/ \_| \_\_| |_|_| |_|_| JBoss S-RAMP Kurt Stam and Eric Wittmann, Licensed under the Apache License, V2.0, Copyright 2012 ******************************************************************* *** s-ramp>
67
Red Hat JBoss Fuse Service Works 6 Installation Guide a. T o connect the shell to the server, type connect and press the tab key. T his auto-completes to: s-ramp:connect http://localhost:8080/s-ramp-server
When you press the return key, the cursor goes from red to green. b. Browse the artifacts in the repository by runninf the following query: s-ramp> s-ramp:query /s-ramp
Here is how the result of this query looks: Querying the S-RAMP repository: /s-ramp Atom Feed (9 entries) Idx Type Name ------ ---1 ImageDocument -properties.png 2 Document overlord.demo.CheckDeployment-taskform.flt 3 BrmsPkgDocument SRAMPPackage.pkg 4 ImageDocument overlord.demo.SimpleReleaseProcessimage.png 5 ImageDocument run-build-install.png 6 Document overlord.demo.SimpleReleaseProcesstaskform.flt 7 ImageDocument audio-input-microphone-3.png 8 BpmnDocument overlord.demo.SimpleReleaseProcess.bpmn 9 TextDocument HttpClientWorkDefinitions.wid
Report a bug
68
P art IV. Advanced Use
Part IV. Advanced Use
69
Red Hat JBoss Fuse Service Works 6 Installation Guide
Chapter 15. Starting Red Hat JBoss Fuse Service Works in an Enterprise Environment 15.1. Introduction Isolating services so that they are accessible only to the clients who need them increases the security of your network. JBoss EAP 6 includes two interfaces in its default configuration, both of which bind to the IP address 127.0.0.1, or localhost, by default. One of the interfaces is called m anagem ent, and is used by the Management Console, CLI, and API. T he other is called public, and is used to deploy applications. T hese interfaces are not special or significant, but are provided as a starting point. T he m anagem ent interface uses ports 9990 and 9999 by default, and the public interface uses port 8080, or port 8443 if you use HT T PS.
Warning If you expose the management interfaces to other network interfaces which are accessible from remote hosts, be aware of the security implications. Most of the time, it is not advisable to provide remote access to the management interfaces. Report a bug
15.2. Specify the Network Interface You can specify the IP address of the management interface, public interface, or both. 1. Stop JBoss EAP 6. Stop JBoss EAP 6 by sending an interrupt in the appropriate way for your operating system. If you are running JBoss EAP 6 as a foreground application, the typical way to do this is to press Ctrl+C. 2. Restart JBoss EAP 6, specifying the bind address. Use the -b command-line switch to start JBoss EAP 6 on a specific interface. Example 15.1. Specify the public interface. EAP_HOME/bin/domain.sh -b 10.1.1.1
Example 15.2. Specify the management interface. EAP_HOME/bin/domain.sh -bmanagement=10.1.1.1
Example 15.3. Specify different addresses for each interface. EAP_HOME/bin/domain.sh -bmanagement=127.0.0.1 -b 10.1.1.1
70
C hapter 15. Starting Red Hat JBoss Fuse Service Works in an Enterprise Environment Example 15.4 . Bind the public interface to all network interfaces. EAP_HOME/bin/domain.sh -b 0.0.0.0
It is possible to edit your XML configuration file directly, to change the default bind addresses. However, if you do this, you will no longer be able to use the -bcommand-line switch to specify an IP address at runtime, so this is not recommended. If you do decide to do this, be sure to stop JBoss EAP 6 completely before editing the XML file. Report a bug
71
Red Hat JBoss Fuse Service Works 6 Installation Guide
Security Considerations A.1. Secure Ways of Running Red Hat JBoss Fuse Service Works Enabling the Java Security Manager (JSM) to sandbox the evaluation of MVEL may introduce a performance hit in high load environments. Following are some secure ways of running Red Hat JBoss Fuse Service Works: If you run Red Hat JBoss Fuse Service Works without Run-T ime Governance, you can disable JSM as it does not introduce MVEL security risks. If you need Run-T ime Governance in high performance environment, Red Hat recommends running Run-T ime Governance in a separate JVM. T he JVM instance running Run-T ime Governance must have JSM enabled, whereas other application server instances can run without JSM. If you are working on testing and development environments without high loads, it is okay to run one JVM with the server, Run-T ime Governance, and JSM enabled as the performance hit is not dramatic.
Warning Red Hat does not recommend running the server with Run-T ime Governance enabled and JSM disabled in one JVM instance, as this is not secure. Report a bug
72
Revision History
Revision History Revision 6.0.0-4 5 Mon Jul 14 2014 B Long Built from Content Specification: 22586, Revision: 684216 by belong
73