Computer Knowledge

Java Enterprise and Web Technologies

2,183 Questions

Java enterprise and web technologies questions focus on J2EE architecture, web services like SOAP, and servlet functionalities. These topics frequently appear in IT officer and specialist scale examinations. Regular practice ensures familiarity with enterprise application components.

HttpServlet methodsSOAP and web servicesEJB architecture rolesJ2EE componentsJSP servlet callingUDDI concepts

Java Enterprise and Web Technologies Questions

Multiple choice technology security
  1. SQL Injection

  2. Denial of Service

  3. XML Injection

  4. All of the above

Reveal answer Fill a bubble to check yourself
D Correct answer
Explanation

Web Services (SOAP, REST, etc.) are susceptible to the full range of web application attacks. SQL Injection can target backend databases accessed through the service. Denial of Service attacks can overwhelm service endpoints. XML External Entity (XXE) attacks and XML injection specifically target XML-based services. The integration complexity and data formats used in web services expose them to multiple attack vectors.

Multiple choice technology security
  1. Page Scope

  2. Session Scope

  3. Request Scope

  4. Application Scope

Reveal answer Fill a bubble to check yourself
B Correct answer
Explanation

Session scope specifically stores data tied to a single user's session across multiple requests. Page scope is for single-page data, request scope lasts only for one HTTP request, and application scope is shared across all users. Only session scope maintains user-specific state throughout their interaction with the application.

Multiple choice technology security
  1. The length of the User's Session

  2. The length of a single HTTP response

  3. The length of a single HTTP request

  4. Until the server is rebooted

Reveal answer Fill a bubble to check yourself
C Correct answer
Explanation

Request scope in web applications refers to data that persists only for the duration of processing a single HTTP request from client to server. It does not span multiple requests (session), responses only, or extend beyond the request lifecycle.

Multiple choice technology architecture
  1. Http Cookies

  2. Memory Flags

  3. http request ID

  4. http Request Parameters

Reveal answer Fill a bubble to check yourself
A Correct answer
Explanation

HTTP cookies are the standard mechanism for maintaining user sessions in web applications. The server sends a session identifier to the client's browser, which stores it as a cookie. The browser automatically sends this cookie with subsequent requests, allowing the server to identify and maintain the user's session state across multiple HTTP requests.

Multiple choice technology architecture
  1. Remove the node and replace it with a healthy node

  2. Debug the node to see why the application fails from the specific node and fix the issue

  3. leave the nodes as it is.

  4. None of the above.

Reveal answer Fill a bubble to check yourself
A Correct answer
Explanation

When a web application fails on specific nodes affecting overall availability, the immediate solution is to remove the faulty node and replace it with a healthy one. This restores availability quickly. Debugging can happen later on the failed node. Option A prioritizes system availability over root cause analysis, which is the correct approach for immediate resolution.

Multiple choice technology architecture
  1. Execution group

  2. Configuration Manager

  3. Queue Manager

  4. User Name Server

Reveal answer Fill a bubble to check yourself
B Correct answer
Explanation

The Configuration Manager is the component that connects the Message Broker Toolkit to the brokers, allowing developers to deploy and manage message flows. Execution groups run the flows, Queue Managers handle messaging queues, and User Name Server manages security.

Multiple choice technology architecture
  1. UDDI

  2. WSDL

  3. SOAP

  4. ESB

Reveal answer Fill a bubble to check yourself
B Correct answer
Explanation

WSDL (Web Services Description Language) is an XML-based specification that describes how to access a web service. It defines the service endpoint, operations, message formats, and protocols. UDDI is for discovery/registry, SOAP is for messaging, and ESB is an integration architecture pattern - none of these describe the access interface itself.

Multiple choice technology architecture
  1. UDDI

  2. WSDL

  3. SOAP

  4. ESB

Reveal answer Fill a bubble to check yourself
A Correct answer
Explanation

UDDI (Universal Description, Discovery, and Integration) provides a registry-based mechanism for publishing and discovering web services. It allows organizations to list their services and enables clients to search for available services by type, category, or other criteria. WSDL describes interfaces, SOAP handles messaging, and ESB is an integration pattern.

Multiple choice technology architecture
  1. UDDI

  2. WSDL

  3. SOAP

  4. RMI

Reveal answer Fill a bubble to check yourself
D Correct answer
Explanation

RMI (Remote Method Invocation) is a Java-specific remote communication technology that uses binary serialization, not XML. It's tightly coupled to the Java platform. In contrast, UDDI, WSDL, and SOAP are all XML-based specifications that form the core of web services, providing platform-neutral interoperability through XML messaging.

Multiple choice technology architecture
  1. SOAP

  2. XML

  3. UDDI

  4. WSDL

Reveal answer Fill a bubble to check yourself
A Correct answer
Explanation

SOAP (Simple Object Access Protocol) is the complete web service framework that defines the XML message format, HTTP binding conventions, and RPC representation standards. XML (B) is just the data encoding format, UDDI (C) is for service discovery registry, and WSDL (D) describes the service interface but not the message protocol itself.

Multiple choice technology architecture
  1. Accessing a UDDI description from the WSDL registry and binds to the service using SOAP

  2. Accessing a SOAP description from the UDDI registry and binds to the service using UDDI

  3. Accessing a SOAP description from the WSDL registry and binds to the service using UDDI

  4. Accessing a WSDL description from the UDDI registry and binds to the service using SOAP

Reveal answer Fill a bubble to check yourself
D Correct answer
Explanation

Web service consumption follows the pattern: discover the service in UDDI (registry), retrieve its WSDL description (interface definition), then bind using SOAP (message protocol). Option D correctly sequences these steps. Options A-C incorrectly pair the protocols with their purposes or reverse the registry relationship.

Multiple choice technology architecture
  1. Compilers for different programming languages and target machines

  2. Decision support systems

  3. Web applications

  4. Middleware

Reveal answer Fill a bubble to check yourself
C Correct answer
Explanation

Option C is correct because Apache Struts is a web application framework for Java - it specifically addresses the domain of building web-based applications and follows the Model-View-Controller (MVC) pattern. Options A (compilers), B (decision support systems), and D (middleware) are different problem domains that Struts is not designed to solve. Struts provides utilities for handling HTTP requests, managing form data, and organizing web application logic.

Multiple choice technology web technology
  1. SerivceTypeAttribute

  2. ServiceAttribute

  3. ServiceBehaviourAttribute

  4. ServiceTypeBehaviour

Reveal answer Fill a bubble to check yourself
C Correct answer
Explanation

ServiceBehaviorAttribute in WCF controls service instance lifetime through the InstanceContextMode property. This property determines whether a single instance serves all clients (Single), each client gets its own instance (PerSession), or each call gets a new instance (PerCall).