Red Hat Jboss Enterprise Application Platform 7.3 Developing Hibernate Applications

Total Page:16

File Type:pdf, Size:1020Kb

Red Hat Jboss Enterprise Application Platform 7.3 Developing Hibernate Applications Red Hat JBoss Enterprise Application Platform 7.3 Developing Hibernate Applications Instructions and information for developers and administrators who want to develop and deploy Jakarta Persistence API (JPA) or Hibernate applications for Red Hat JBoss Enterprise Application Platform. Last Updated: 2021-09-10 Red Hat JBoss Enterprise Application Platform 7.3 Developing Hibernate Applications Instructions and information for developers and administrators who want to develop and deploy Jakarta Persistence API (JPA) or Hibernate applications for Red Hat JBoss Enterprise Application Platform. Legal Notice Copyright © 2021 Red Hat, Inc. The text of and illustrations in this document are licensed by Red Hat under a Creative Commons Attribution–Share Alike 3.0 Unported license ("CC-BY-SA"). An explanation of CC-BY-SA is available at http://creativecommons.org/licenses/by-sa/3.0/ . In accordance with CC-BY-SA, if you distribute this document or an adaptation of it, you must provide the URL for the original version. 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, the Red Hat logo, JBoss, OpenShift, Fedora, the Infinity logo, and RHCE are trademarks of Red Hat, Inc., registered in the United States and other countries. Linux ® is the registered trademark of Linus Torvalds in the United States and other countries. Java ® is a registered trademark of Oracle and/or its affiliates. XFS ® is a trademark of Silicon Graphics International Corp. or its subsidiaries in the United States and/or other countries. MySQL ® is a registered trademark of MySQL AB in the United States, the European Union and other countries. Node.js ® is an official trademark of Joyent. Red Hat is not formally related to or endorsed by the official Joyent Node.js open source or commercial project. The OpenStack ® Word Mark and OpenStack logo are either registered 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 affiliated with, endorsed or sponsored by the OpenStack Foundation, or the OpenStack community. All other trademarks are the property of their respective owners. Abstract This document provides information for developers and administrators who want to develop and deploy Jakarta Persistence or Hibernate applications with Red Hat JBoss Enterprise Application Platform. Table of Contents Table of Contents .C . H. .A . P. .T .E . R. 1.. .I .N . T. .R .O . .D . U. .C . T. .I O. N. 6. 1.1. ABOUT HIBERNATE CORE 6 1.2. HIBERNATE ENTITYMANAGER 6 .C . H. .A . P. .T .E . R. 2. H. .I .B . E. R. .N . .A .T . E. C. .O . N. F. I. G. .U . R. .A . T. .I O. .N . 8. 2.1. HIBERNATE CONFIGURATION 8 2.2. SECOND-LEVEL CACHES 8 2.2.1. About Second-level Caches 8 2.2.2. Configure a Second-level Cache for Hibernate 9 Configuring a Second-level Cache for Hibernate Using Hibernate Native Applications 9 .C . H. .A . P. .T .E . R. 3. H. I.B . E. .R .N . .A . T. E. A. .N . N. .O . .T . A. .T .I .O . N. .S . 1.0 . 3.1. HIBERNATE ANNOTATIONS 10 .C . H. .A . P. .T .E . R. 4. .H . I.B . E. .R . N. .A . T. .E . Q. U. .E . R. Y. L. .A . N. .G . .U . A. .G . E. 1. 7. 4.1. ABOUT HIBERNATE QUERY LANGUAGE 17 Introduction to Java Persistence query language 17 Introduction to HQL 17 4.2. ABOUT HQL STATEMENTS 17 About the UPDATE and DELETE Statements 19 About the INSERT Statement 20 4.3. ABOUT HQL ORDERING 21 4.4. ABOUT COLLECTION MEMBER REFERENCES 22 4.5. ABOUT QUALIFIED PATH EXPRESSIONS 22 4.6. ABOUT HQL FUNCTIONS 24 4.6.1. About HQL Standardized Functions 24 4.6.2. About HQL Non-Standardized Functions 24 4.6.3. About the Concatenation Operation 25 4.7. ABOUT DYNAMIC INSTANTIATION 25 4.8. ABOUT HQL PREDICATES 26 HQL Predicates 26 4.9. ABOUT RELATIONAL COMPARISONS 28 4.10. BYTECODE ENHANCEMENT 30 4.10.1. Lazy Attribute Loading 30 .C . H. .A . P. .T .E . R. 5. H. I.B . E. R. .N . .A . T. E. S. .E .R . V. .I C. .E . S. .3 . 2. 5.1. ABOUT HIBERNATE SERVICES 32 5.2. ABOUT SERVICE CONTRACTS 32 5.3. TYPES OF SERVICE DEPENDENCIES 32 5.3.1. The Service Registry 32 5.3.1.1. About the ServiceRegistry 32 5.3.2. Custom Services 33 5.3.2.1. About Custom Services 33 5.3.3. The Boot-Strap Registry 34 5.3.3.1. About the Boot-strap Registry 34 Using BootstrapServiceRegistryBuilder 34 5.3.3.2. BootstrapRegistry Services 34 5.3.4. SessionFactory Registry 35 5.3.4.1. SessionFactory Services 35 5.3.5. Integrators 36 5.3.5.1. Integrator Use Cases 36 1 Red Hat JBoss Enterprise Application Platform 7.3 Developing Hibernate Applications .C . H. .A . P. .T .E . R. 6. .H . I.B . E. .R .N . .A . T. E. E. .N . V. .E . R. .S . .3 . 8. 6.1. ABOUT HIBERNATE ENVERS 38 6.2. ABOUT AUDITING PERSISTENT CLASSES 38 6.3. AUDITING STRATEGIES 38 6.3.1. About Auditing Strategies 38 6.3.2. Set the Auditing Strategy 39 Define an Auditing Strategy 39 6.3.3. Adding Auditing Support to a Jakarta Persistence Entity 39 6.4. CONFIGURATION 40 6.4.1. Configure Envers Parameters 41 6.4.2. Enable or Disable Auditing at Runtime 41 6.4.3. Configure Conditional Auditing 42 6.4.4. Envers Configuration Properties 42 6.5. QUERYING AUDIT INFORMATION 44 6.5.1. Retrieve Auditing Information Through Queries 44 6.5.2. Traversing Entity Associations Using Properties of Referenced Entities 47 6.6. PERFORMANCE TUNING 48 6.6.1. Alternative Batch Loading Algorithms 48 6.6.2. Second Level Caching of Object References for Non-mutable Data 50 .C . H. .A . P. .T .E . R. 7. H. I.B . E. R. .N . .A . T. E. S. .E .A . R. .C . H. 5. .1 . 7.1. GETTING STARTED WITH HIBERNATE SEARCH 51 7.1.1. About Hibernate Search 51 7.1.2. Overview of Hibernate Search 51 7.1.3. About the Directory Provider 51 7.1.4. About the Worker 52 7.1.5. Back End Setup and Operations 52 7.1.5.1. Back End 52 7.1.5.2. Lucene 52 7.1.5.3. Jakarta Messaging 53 7.1.6. Reader Strategies 54 7.1.6.1. The Shared Strategy 54 7.1.6.2. The Not-shared Strategy 55 7.1.6.3. Custom Reader Strategies 55 7.2. CONFIGURATION 55 7.2.1. Minimum Configuration 55 7.2.2. Configuring the IndexManager 55 7.2.2.1. Directory-based 55 7.2.2.2. Near Real Time 56 7.2.2.3. Custom 56 7.2.3. DirectoryProvider Configuration 56 Directory Providers and Their Properties 57 7.2.4. Worker Configuration 59 7.2.4.1. Jakarta Messaging Master/Slave Back End 62 7.2.4.2. Slave Nodes 63 7.2.4.3. Master Node 63 7.2.5. Tuning Lucene Indexing 64 7.2.5.1. Tuning Lucene Indexing Performance 64 7.2.5.2. The Lucene IndexWriter 68 7.2.5.3. Performance Option Configuration 68 7.2.5.4. Tuning the Indexing Speed 72 7.2.5.5. Control Segment Size 72 7.2.6. LockFactory Configuration 73 2 Table of Contents 7.2.7. Index Format Compatibility 74 7.3. HIBERNATE SEARCH FOR YOUR APPLICATION 74 7.3.1. First Steps with Hibernate Search 75 7.3.2. Enable Hibernate Search Using Maven 75 7.3.3. Add Annotations 75 7.3.4. Indexing 78 7.3.5. Searching 78 7.3.6. Analyzer 79 7.4. MAPPING ENTITIES TO THE INDEX STRUCTURE 80 7.4.1. Mapping an Entity 80 7.4.1.1. Basic Mapping 81 7.4.1.2. @Indexed 81 7.4.1.3. @Field 81 7.4.1.4. @NumericField 83 7.4.1.5. @Id 84 7.4.1.6. Mapping Properties Multiple Times 85 7.4.1.7. Embedded and Associated Objects 85 7.4.1.8. Limiting Object Embedding to Specific Paths 88 7.4.2. Boosting 91 7.4.2.1. Static Index Time Boosting 91 7.4.2.2. Dynamic Index Time Boosting 91 7.4.3. Analysis 92 7.4.3.1. Default Analyzer and Analyzer by Class 92 7.4.3.2. Named Analyzers 93 7.4.3.3. Available Analyzers 95 7.4.3.4. Dynamic Analyzer Selection 97 7.4.3.5. Retrieving an Analyzer 98 7.4.4. Bridges 99 7.4.4.1. Built-in Bridges 99 7.4.4.2. Custom Bridges 100 7.4.4.2.1. StringBridge 100 7.4.4.2.2. Parameterized Bridge 101 7.4.4.2.3. Type Aware Bridge 102 7.4.4.2.4. Two-Way Bridge 102 7.4.4.2.5. FieldBridge 103 7.4.4.2.6. ClassBridge 104 7.5. USING HIBERNATE SEARCH TO EXECUTE LUCENE QUERIES 105 7.5.1. Building Queries 107 7.5.1.1. Building a Lucene Query Using the Lucene API 107 7.5.1.2. Building a Lucene Query 107 7.5.1.3. Keyword Queries 108 7.5.1.4. Fuzzy Queries 110 7.5.1.5. Wildcard Queries 110 7.5.1.6.
Recommended publications
  • Beej's Guide to Unix IPC
    Beej's Guide to Unix IPC Brian “Beej Jorgensen” Hall [email protected] Version 1.1.3 December 1, 2015 Copyright © 2015 Brian “Beej Jorgensen” Hall This guide is written in XML using the vim editor on a Slackware Linux box loaded with GNU tools. The cover “art” and diagrams are produced with Inkscape. The XML is converted into HTML and XSL-FO by custom Python scripts. The XSL-FO output is then munged by Apache FOP to produce PDF documents, using Liberation fonts. The toolchain is composed of 100% Free and Open Source Software. Unless otherwise mutually agreed by the parties in writing, the author offers the work as-is and makes no representations or warranties of any kind concerning the work, express, implied, statutory or otherwise, including, without limitation, warranties of title, merchantibility, fitness for a particular purpose, noninfringement, or the absence of latent or other defects, accuracy, or the presence of absence of errors, whether or not discoverable. Except to the extent required by applicable law, in no event will the author be liable to you on any legal theory for any special, incidental, consequential, punitive or exemplary damages arising out of the use of the work, even if the author has been advised of the possibility of such damages. This document is freely distributable under the terms of the Creative Commons Attribution-Noncommercial-No Derivative Works 3.0 License. See the Copyright and Distribution section for details. Copyright © 2015 Brian “Beej Jorgensen” Hall Contents 1. Intro................................................................................................................................................................1 1.1. Audience 1 1.2. Platform and Compiler 1 1.3.
    [Show full text]
  • Mmap and Dma
    CHAPTER THIRTEEN MMAP AND DMA This chapter delves into the area of Linux memory management, with an emphasis on techniques that are useful to the device driver writer. The material in this chap- ter is somewhat advanced, and not everybody will need a grasp of it. Nonetheless, many tasks can only be done through digging more deeply into the memory man- agement subsystem; it also provides an interesting look into how an important part of the kernel works. The material in this chapter is divided into three sections. The first covers the implementation of the mmap system call, which allows the mapping of device memory directly into a user process’s address space. We then cover the kernel kiobuf mechanism, which provides direct access to user memory from kernel space. The kiobuf system may be used to implement ‘‘raw I/O’’ for certain kinds of devices. The final section covers direct memory access (DMA) I/O operations, which essentially provide peripherals with direct access to system memory. Of course, all of these techniques requir e an understanding of how Linux memory management works, so we start with an overview of that subsystem. Memor y Management in Linux Rather than describing the theory of memory management in operating systems, this section tries to pinpoint the main features of the Linux implementation of the theory. Although you do not need to be a Linux virtual memory guru to imple- ment mmap, a basic overview of how things work is useful. What follows is a fairly lengthy description of the data structures used by the kernel to manage memory.
    [Show full text]
  • An Introduction to Linux IPC
    An introduction to Linux IPC Michael Kerrisk © 2013 linux.conf.au 2013 http://man7.org/ Canberra, Australia [email protected] 2013-01-30 http://lwn.net/ [email protected] man7 .org 1 Goal ● Limited time! ● Get a flavor of main IPC methods man7 .org 2 Me ● Programming on UNIX & Linux since 1987 ● Linux man-pages maintainer ● http://www.kernel.org/doc/man-pages/ ● Kernel + glibc API ● Author of: Further info: http://man7.org/tlpi/ man7 .org 3 You ● Can read a bit of C ● Have a passing familiarity with common syscalls ● fork(), open(), read(), write() man7 .org 4 There’s a lot of IPC ● Pipes ● Shared memory mappings ● FIFOs ● File vs Anonymous ● Cross-memory attach ● Pseudoterminals ● proc_vm_readv() / proc_vm_writev() ● Sockets ● Signals ● Stream vs Datagram (vs Seq. packet) ● Standard, Realtime ● UNIX vs Internet domain ● Eventfd ● POSIX message queues ● Futexes ● POSIX shared memory ● Record locks ● ● POSIX semaphores File locks ● ● Named, Unnamed Mutexes ● System V message queues ● Condition variables ● System V shared memory ● Barriers ● ● System V semaphores Read-write locks man7 .org 5 It helps to classify ● Pipes ● Shared memory mappings ● FIFOs ● File vs Anonymous ● Cross-memory attach ● Pseudoterminals ● proc_vm_readv() / proc_vm_writev() ● Sockets ● Signals ● Stream vs Datagram (vs Seq. packet) ● Standard, Realtime ● UNIX vs Internet domain ● Eventfd ● POSIX message queues ● Futexes ● POSIX shared memory ● Record locks ● ● POSIX semaphores File locks ● ● Named, Unnamed Mutexes ● System V message queues ● Condition variables ● System V shared memory ● Barriers ● ● System V semaphores Read-write locks man7 .org 6 It helps to classify ● Pipes ● Shared memory mappings ● FIFOs ● File vs Anonymous ● Cross-memoryn attach ● Pseudoterminals tio a ● proc_vm_readv() / proc_vm_writev() ● Sockets ic n ● Signals ● Stream vs Datagram (vs uSeq.
    [Show full text]
  • Project Dependencies Project Transitive Dependencies
    9/8/2020 Dependencies – Project Dependencies Project Dependencies compile The following is a list of compile dependencies for this project. These dependencies are required to compile and run the application: GroupId ArtifactId Version Type Licenses org.onap.policy.drools-pdp base 1.7.1-SNAPSHOT tar.gz - org.onap.policy.drools-pdp feature-active-standby-management 1.7.1-SNAPSHOT zip - org.onap.policy.drools-pdp feature-controller-logging 1.7.1-SNAPSHOT zip - org.onap.policy.drools-pdp feature-distributed-locking 1.7.1-SNAPSHOT zip - org.onap.policy.drools-pdp feature-eelf 1.7.1-SNAPSHOT zip - org.onap.policy.drools-pdp feature-healthcheck 1.7.1-SNAPSHOT zip - org.onap.policy.drools-pdp feature-lifecycle 1.7.1-SNAPSHOT zip - org.onap.policy.drools-pdp feature-mdc-filters 1.7.1-SNAPSHOT zip - org.onap.policy.drools-pdp feature-pooling-dmaap 1.7.1-SNAPSHOT zip - org.onap.policy.drools-pdp feature-session-persistence 1.7.1-SNAPSHOT zip - org.onap.policy.drools-pdp feature-state-management 1.7.1-SNAPSHOT zip - org.onap.policy.drools-pdp feature-test-transaction 1.7.1-SNAPSHOT zip - org.onap.policy.drools-pdp policy-management 1.7.1-SNAPSHOT zip - Project Transitive Dependencies The following is a list of transitive dependencies for this project. Transitive dependencies are the dependencies of the project dependencies. compile The following is a list of compile dependencies for this project. These dependencies are required to compile and run the application: GroupId ArtifactId Version Classifier Type Licenses antlr antlr 2.7.7 - jar BSD License
    [Show full text]
  • Jakarta Enhancement Guide (V6.0) Table of Contents
    Jakarta Enhancement Guide (v6.0) Table of Contents Maven . 3 Ant . 5 Command Line . 7 Runtime Enhancement . 9 Programmatic API . 10 Enhancement Contract Details . 11 Persistable . 11 Byte-Code Enhancement Myths . 12 Cloning of enhanced classes . 12 Serialisation of enhanced classes. 12 Decompilation. 13 DataNucleus requires that all Jakarta entities implement Persistable and Detachable. Rather than requiring that a user add this themself, we provide an enhancer that will modify your compiled classes to implement all required methods. This is provided in datanucleus-core.jar. • The use of this interface means that you get transparent persistence, and your classes always remain your classes; ORM tools that use a mix of reflection and/or proxies are not totally transparent. • DataNucleus' use of Persistable provides transparent change tracking. When any change is made to an object the change creates a notification to DataNucleus allowing it to be optimally persisted. ORM tools that dont have access to such change tracking have to use reflection to detect changes. The performance of this process will break down as soon as you read a large number of objects, but modify just a handful, with these tools having to compare all object states for modification at transaction commit time. • OpenJPA requires a similar bytecode enhancement process also, and EclipseLink and Hibernate both allow it as an option since they also now see the benefits of this approach over use of proxies and reflection. In the DataNucleus bytecode enhancement contract there are 3 categories of classes. These are Entity, PersistenceAware and normal classes. The Meta-Data (XML or annotations) defines which classes fit into these categories.
    [Show full text]
  • Licensing Information User Manual Release 21C (21.1) F37966-01 March 2021
    Oracle® Zero Downtime Migration Licensing Information User Manual Release 21c (21.1) F37966-01 March 2021 Introduction This Licensing Information document is a part of the product or program documentation under the terms of your Oracle license agreement and is intended to help you understand the program editions, entitlements, restrictions, prerequisites, special license rights, and/or separately licensed third party technology terms associated with the Oracle software program(s) covered by this document (the "Program(s)"). Entitled or restricted use products or components identified in this document that are not provided with the particular Program may be obtained from the Oracle Software Delivery Cloud website (https://edelivery.oracle.com) or from media Oracle may provide. If you have a question about your license rights and obligations, please contact your Oracle sales representative, review the information provided in Oracle’s Software Investment Guide (http://www.oracle.com/us/ corporate/pricing/software-investment-guide/index.html), and/or contact the applicable Oracle License Management Services representative listed on http:// www.oracle.com/us/corporate/license-management-services/index.html. Licensing Information Third-Party Notices and/or Licenses About the Third-Party Licenses The third party licensing information in Oracle Database Licensing Information User Manual, Third-Party Notices and/or Licenses and Open Source Software License Text, applies to Oracle Zero Downtime Migration. The third party licensing information included in the license notices provided with Oracle Linux applies to Oracle Zero Downtime Migration. Open Source or Other Separately Licensed Software Required notices for open source or other separately licensed software products or components distributed in Oracle Zero Downtime Migration are identified in the following table along with the applicable licensing information.
    [Show full text]
  • Table of Contents
    TABLE OF CONTENTS Chapter 1 Introduction ............................................................................................. 3 Chapter 2 Examples for FPGA ................................................................................. 4 2.1 Factory Default Code ................................................................................................................................. 4 2.2 Nios II Control for Programmable PLL/ Temperature/ Power/ 9-axis ....................................................... 6 2.3 Nios DDR4 SDRAM Test ........................................................................................................................ 12 2.4 RTL DDR4 SDRAM Test ......................................................................................................................... 14 2.5 USB Type-C DisplayPort Alternate Mode ............................................................................................... 15 2.6 USB Type-C FX3 Loopback .................................................................................................................... 17 2.7 HDMI TX and RX in 4K Resolution ........................................................................................................ 21 2.8 HDMI TX in 4K Resolution ..................................................................................................................... 26 2.9 Low Latency Ethernet 10G MAC Demo .................................................................................................. 29 2.10 Socket
    [Show full text]
  • IPC: Mmap and Pipes
    Interprocess Communication: Memory mapped files and pipes CS 241 April 4, 2014 University of Illinois 1 Shared Memory Private Private address OS address address space space space Shared Process A segment Process B Processes request the segment OS maintains the segment Processes can attach/detach the segment 2 Shared Memory Private Private Private address address space OS address address space space space Shared Process A segment Process B Can mark segment for deletion on last detach 3 Shared Memory example /* make the key: */ if ((key = ftok(”shmdemo.c", 'R')) == -1) { perror("ftok"); exit(1); } /* connect to (and possibly create) the segment: */ if ((shmid = shmget(key, SHM_SIZE, 0644 | IPC_CREAT)) == -1) { perror("shmget"); exit(1); } /* attach to the segment to get a pointer to it: */ data = shmat(shmid, (void *)0, 0); if (data == (char *)(-1)) { perror("shmat"); exit(1); } 4 Shared Memory example /* read or modify the segment, based on the command line: */ if (argc == 2) { printf("writing to segment: \"%s\"\n", argv[1]); strncpy(data, argv[1], SHM_SIZE); } else printf("segment contains: \"%s\"\n", data); /* detach from the segment: */ if (shmdt(data) == -1) { perror("shmdt"); exit(1); } return 0; } Run demo 5 Memory Mapped Files Memory-mapped file I/O • Map a disk block to a page in memory • Allows file I/O to be treated as routine memory access Use • File is initially read using demand paging ! i.e., loaded from disk to memory only at the moment it’s needed • When needed, a page-sized portion of the file is read from the file system
    [Show full text]
  • A Machine-Independent DMA Framework for Netbsd
    AMachine-Independent DMA Framework for NetBSD Jason R. Thorpe1 Numerical Aerospace Simulation Facility NASA Ames Research Center Abstract 1.1. Host platform details One of the challenges in implementing a portable In the example platforms listed above,there are at kernel is finding good abstractions for semantically- least three different mechanisms used to perform DMA. similar operations which often have very machine- The first is used by the i386 platform. This mechanism dependent implementations. This is especially impor- can be described as "what you see is what you get": the tant on modern machines which share common archi- address that the device uses to perform the DMA trans- tectural features, e.g. the PCI bus. fer is the same address that the host CPU uses to access This paper describes whyamachine-independent the memory location in question. DMA mapping abstraction is needed, the design consid- DMA address Host address erations for such an abstraction, and the implementation of this abstraction in the NetBSD/alpha and NetBSD/i386 kernels. 1. Introduction NetBSD is a portable, modern UNIX-likeoperat- ing system which currently runs on eighteen platforms covering nine processor architectures. Some of these platforms, including the Alpha and i3862,share the PCI busasacommon architectural feature. In order to share device drivers for PCI devices between different platforms, abstractions that hide the details of bus access must be invented. The details that must be hid- den can be broken down into twoclasses: CPU access Figure 1 - WYSIWYG DMA to devices on the bus (bus_space)and device access to host memory (bus_dma). Here we will discuss the lat- The second mechanism, employed by the Alpha, ter; bus_space is a complicated topic in and of itself, is very similar to the first; the address the host CPU and is beyond the scope of this paper.
    [Show full text]
  • Metro User Guide Metro User Guide Table of Contents
    Metro User Guide Metro User Guide Table of Contents Preface .............................................................................................................................. x 1. Introduction to Metro ....................................................................................................... 1 1.1. Required Software ................................................................................................ 1 1.2. What is WSIT? .................................................................................................... 1 1.2.1. Bootstrapping and Configuration ................................................................... 2 1.2.2. Message Optimization Technology ................................................................ 3 1.2.3. Reliable Messaging Technology .................................................................... 4 1.2.4. Security Technology ................................................................................... 4 1.3. How Metro Relates to .NET Windows Communication Foundation (WCF) ...................... 5 1.4. Metro Specifications ............................................................................................. 5 1.4.1. Bootstrapping and Configuration Specifications ............................................... 7 1.4.2. Message Optimization Specifications ............................................................. 8 1.4.3. Reliable Messaging Specifications ............................................................... 10 1.4.4. Security Specifications
    [Show full text]
  • Jakarta Concurrency 2.0 Specification Document
    Jakarta Concurrency Jakarta Concurrency Team, https://projects.eclipse.org/projects/ee4j.cu 2.0, 2020-10-08T19:20:31Z Table of Contents Eclipse Foundation Specification License . 1 Disclaimers. 2 Jakarta Concurrency Specification, Version 2.0 . 3 1. Introduction. 4 1.1. Overview . 4 1.2. Goals of this specification. 4 1.3. Other Java Platform and Jakarta Specifications . 4 1.4. Concurrency Utilities for Java EE Expert Group at the JCP . 5 1.5. Document Conventions. 5 2. Overview . 6 2.1. Container-Managed vs. Unmanaged Threads . 6 2.2. Application Integrity . 6 2.3. Container Thread Context . 7 2.3.1. Contextual Invocation Points. 8 2.3.1.1. Optional Contextual Invocation Points . 8 2.3.2. Contextual Objects and Tasks . 8 2.3.2.1. Tasks and Jakarta Contexts and Dependency Injection (CDI) . 9 2.4. Usage with Jakarta Connectors . 9 2.5. Security . 10 3. Managed Objects . 11 3.1. ManagedExecutorService. 11 3.1.1. Application Component Provider’s Responsibilities . 11 3.1.1.1. Usage Example. 12 3.1.2. Application Assembler’s Responsibilities . 18 3.1.3. Deployer’s Responsibilities. 18 3.1.4. Jakarta EE Product Provider’s Responsibilities. 18 3.1.4.1. ManagedExecutorService Configuration Attributes. 19 3.1.4.2. Configuration Examples . 19 3.1.4.3. Default ManagedExecutorService. 22 3.1.5. System Administrator’s Responsibilities. 22 3.1.6. Lifecycle . 22 3.1.6.1. Jakarta EE Product Provider Requirements . 23 3.1.7. Quality of Service . 24 3.1.8. Transaction Management. 24 3.1.8.1. Jakarta EE Product Provider Requirements .
    [Show full text]
  • Interprocess Communication
    06 0430 CH05 5/22/01 10:22 AM Page 95 5 Interprocess Communication CHAPTER 3,“PROCESSES,” DISCUSSED THE CREATION OF PROCESSES and showed how one process can obtain the exit status of a child process.That’s the simplest form of communication between two processes, but it’s by no means the most powerful.The mechanisms of Chapter 3 don’t provide any way for the parent to communicate with the child except via command-line arguments and environment variables, nor any way for the child to communicate with the parent except via the child’s exit status. None of these mechanisms provides any means for communicating with the child process while it is actually running, nor do these mechanisms allow communication with a process outside the parent-child relationship. This chapter describes means for interprocess communication that circumvent these limitations.We will present various ways for communicating between parents and chil- dren, between “unrelated” processes, and even between processes on different machines. Interprocess communication (IPC) is the transfer of data among processes. For example, a Web browser may request a Web page from a Web server, which then sends HTML data.This transfer of data usually uses sockets in a telephone-like connection. In another example, you may want to print the filenames in a directory using a command such as ls | lpr.The shell creates an ls process and a separate lpr process, connecting 06 0430 CH05 5/22/01 10:22 AM Page 96 96 Chapter 5 Interprocess Communication the two with a pipe, represented by the “|” symbol.A pipe permits one-way commu- nication between two related processes.The ls process writes data into the pipe, and the lpr process reads data from the pipe.
    [Show full text]