1Z0-897 Premium Bundle

1Z0-897 Premium Bundle

Java Platform, Enterprise Edition 6 Web Services Developer Certified Expert Exam Certification Exam

4.5 
(16620 ratings)
0 QuestionsPractice Tests
0 PDFPrint version
November 5, 2024Last update

Oracle 1Z0-897 Free Practice Questions

Q1. A developer is asked to determine which Web services approach is correct for a new project. A SOAP-based Web service must be created and deployed in an environment where many customers will use it. These customers will be responsible for developing their own clients using different frameworks, based on the published WSDL. Which approach is correct to use first in this situation? (Choose one) 

A. Java, because the WSDL generated later will be more accurate 

B. WSDL, because the service and customers can benefit from the strongly typed schema 

C. Java, because the service must be efficient to support many customers 

D. WSDL, because tools allow existing classes to be easily mapped without modification 

Answer:

Q2. Which of the following option represents the behavior of the endpoint, when the addressing feature is enabled on the service with the use of @Addressing() annotation. 

A. The endpoint accepts only messages containing Addressing headers and rejects any messages not containing Addressing headers. 

B. The endpoint accepts any messages with or without any Addressing headers and does not validate addressing headers because "required" annotation element is not true. 

C. The endpoint accepts messages only if the messages contain wsa:Action header but does not require presence of any other addressing headers. 

D. The endpoints accepts messages with or without addressing headers. If the message contains wsa:Action header, it validates all other addressing headers in the message. 

Answer:

Q3. In the following situation, Client C sends a SOAP request to Service S and the response is to be processed by a third party response processor R. Which of the following SOAP headers in the request message convey the intention? Assume the endpoint reference of Service S is 

A. <s11:Header> 

<wsa:Action>http://example.com/action/process</wsa:Action> 

<wsa:ReplyTo> 

<wsa:Address>http://www.w3.org/2005/08/addressing/none</wsa:Address> 

<wsa:ReplyTo> 

</s11:Header> 

B. <s11:Header> 

<wsa:Action>http://example.com/action/process</wsa:Action> 

<wsa:ReplyTo> 

<wsa:Address>http://www.w3.org/2005/08/addressing/anonymous</wsa:Address> 

<wsa:ReplyTo> 

</s11:Header> 

C. <s11:Header> 

<wsa:Action>http://example.com/action/process</wsa:Action> 

<wsa:ReplyTo> 

<wsa:Address>http://example.com/responseprocessor</wsa:Address> 

<wsa:ReplyTo> 

</s11:Header> 

D. <s11:Header> 

<wsa:Action>http://example.com/action/process</wsa:Action> 

<wsa:ReplyTo> 

<wsa:Address>http://example.com/service</wsa:Address> 

<wsa:ReplyTo> 

</s11:Header> 

Answer:

Q4. Which of the following is NOT a correct way of configuring handlers on a Web Service client ? (Choose one) 

A. Specify the handlers in jaxws-catalog.xml and make it available in the classpath of the client 

B. Create a handlerchain as list of handlers and call setHandlerChain() with that list on the Binding object. 

C. Programmatically configure the handlers by setting a custom HandlerResolver on the service instance and create proxies from that service. 

D. Specify handlers in handler chain configuration XML file and add @HandlerChain referencing handler configuration file to the Web Service references for clients running in JavaEE Container. 

Answer:

Q5. Given the two classes: 

Choose the option that best evaluates the example: 

A. This is a valid example of two EJBs used as JAX-RS resources, one a root resource and the other a subresource. 

B. This is an invalid example, because EJBs that are to be used as JAX-RS subresources have to match the type of EJB of their "parent" resource. 

C. This is an invalid example, because singleton EJBs used as JAX-RS resources must explicitly state what locking strategy they will require. 

D. This is an invalid example, because the JAX-specification only allows root resource types to also be EJBs. 

Answer:

Q6. Which statement is true about StAX? 

A. StAX provides client parsing control with memory usage similar to DOM. 

B. StAX allows clients to start, pause and resume the parsing process. 

C. StAX is the only XML parsing approach supported with JAX-WS. 

D. StAX is a more efficient version of SAX, based on newer XML technology. 

Answer:

Q7. A team of developers is designing RESTful Web services for a new application. What are three properties of the services? (Choose three.) 

A. They can be stateful. 

B. They can be stateless. 

C. Components communicate by exchanging representations of the resource. 

D. Components communicate by directly performing operations on the resource. 

E. They require WSDL service API definitions. 

F. Responses can be labeled as cacheable or non-cacheable. 

Answer: BCF 

Q8. When a SOAP envelope is optimized on the wire, the following can be said about the optimized infoset : (Choose one) 

A. optimized infoset contains xop:Include elements with href attribute pointing to attachment data 

B. optimized infoset contains mtom:Import with location attribute pointing to attachment data C. optimized infoset doesn't have any specific elements for MIME attachment. 

D. optimzed infoset's element contain cid:Content-ID as the text and Content-ID refers to the associated attachment 

Answer:

Q9. Which of the following WS-Security token profiles is not supported in Metro? 

A. X509 Token Profile 

B. Kerberos Token Profile 

C. SAML Token Profile 

D. SOAP with Attachments (SWA) profile 

E. Right Expression Language (REL) Token Profile 

Answer:

Q10. What would be the HTTP content-type header when a message is optimized using MTOM ? (Choose one) 

A. multipart/related 

B. text/xml 

C. application/soap+xml 

D. application/xop+xml 

Answer:

Q11. Where can a developer specify confidentiality or integrity constraints on communications with a Enterprise Bean exposed as a JAX-RS root resource?(Choose one) 

A. As annotations on the EJB exposed as a root resource. 

B. In the deployment descriptor for the EJB exposed as a root resource. 

C. In the deployment descriptor for the web application that is hosting the JAX-RS resource. 

D. In the vendor-specific configuration file for the container that is hosting the JAX-RS resource. 

Answer:

Q12. Which of the following is NOT true about configuring handlers on a Web Service endpoint? (Choose one) 

A. EE container automatically processes the handlers packaged in the application and configures it on the applicable endpoint 

B. Handlers can be configured using @HandlerChain annotation on endpoints configured with @WebService 

C. Handlers can be configured using @HandlerChain annotation on endpoints configured with @WebServiceProvider 

D. Handlers can be configured for endpoints in the deployment descriptor (webservices.xml) 

Answer:

Q13. When a SOAP envelope is optimized on the wire, the following can be said about the optimized infoset : (Choose one) 

A. optimized infoset contains xop:Include elements with href attribute pointing to attachment data 

B. optimized infoset contains mtom:Import with location attribute pointing to attachment data 

C. optimized infoset doesn't have any specific elements for MIME attachment. 

D. optimzed infoset's element contain cid:Content-ID as the text and Content-ID refers to the associated attachment 

Answer:

Q14. An automobile manufacturer publishes a Web service for use by their suppliers. The manufacturer has stringent security requirements that require suppliers to verify their identity. Data integrity and confidentiality must be maintained between the client and the server. Which two technologies can be used to meet the requirements? (Choose two) 

A. XACML and XKMS 

B. SSL with mutual authentication 

C. Message level security with WS-Security 

D. Private network and XML Signature 

Answer: BC 

Q15. When working directly with SOAP, which two statements are true about the encoding of compound values? (Choose two.) 

A. Compound values cannot be encoded. 

B. A compound value may NOT contain other compound values. 

C. Members of a compound value are encoded as accessor elements. 

D. Accessors with names that are local to their containing types have unqualified names. 

Answer: CD 

Q16. A developer is creating a web service endpoint using a stateless session EJB. 

What must be the value for <ejb-link> for the above service in the webservices.xml ? (Choose one) 

A. CounterEJB 

B. Counter 

C. CounterService 

D. CounterPort 

Answer:

Q17. Given the JAX-RS root resource class fragment: 

Choose the statement that best describes the configuration that would be required to support the access control constraint shown: 

A. No further configuration is required - the JavaEE runtime will pick up the security constraint and configure the web container to match. 

B. The developer will have to configure the web container to require authenticated access to the URLs corresponding to this resource, so the proper information can be propagated to the EJB container. 

C. The developer will have to turn on authentication in the web container configuration file, so that all incoming requests are authenticated in order to be processed. 

D. The developer will have to configure the web container to require authenticated access to the URLs corresponding to this resource, and then map web-tier roles to ejb-tier roles, since the JAX-RS and EJB runtimes cannot use the same set of roles. 

Answer:

Q18. If you are developing a Web Service starting from WSDL 1.1, how would you declare in wsdl that the Web Service requires the use of Addressing in a standard and interoperable way. 

A. Declare a policy as 

<wsp:Policy> 

<wsam:Addressing wsp:Optional="true"> 

<wsp:Policy/> 

</wsam:Addressing> 

</wsp:Policy> 

and attach it the corresponding wsdl:portType so that it applies to all the wsdl:operations in its 

scope. 

B. Declare a policy as 

<wsp:Policy> 

<wsam:Addressing wsp:Optional="true"> 

<wsp:Policy/> 

</wsam:Addressing> 

</wsp:Policy> 

and attach it the corresponding wsdl:binding so that it applies to all the wsdl:operations in its 

scope. 

C. Declare a policy as 

<wsp:Policy> 

<wsam:Addressing> 

<wsp:Policy/> 

</wsam:Addressing> 

</wsp:Policy> 

and attach it the corresponding wsdl:binding so that it applies to all the wsdl:operations in its 

scope. 

D. Declare a policy as 

<wsp:Policy> 

<wsam:Addressing> 

<wsp:Policy/> 

</wsam:Addressing> 

</wsp:Policy> 

and attach it the corresponding wsdl:service so that it applies to all the wsdl:ports in the service scope. 

Answer:

START 1Z0-897 EXAM