You are on page 1of 30

SOA 11g Interview Questions 1

This Document is only a SAMPLE

We have published only a few slides on Scribd, out of our 107 total slides You c an buy this complete document for $39 by sending an email to soagang@gmail.com Y ou can buy this whether you are in US, UK, India, Australia or anywhere else Che ck out our website http://soatraining.hpage.com for more exciting information on SOA 2

Contents (total 102 questions) SOA Installation New features introduced in 11g What is SCA, its benefits BPEL M ultiple Receive Activities BPEL How to Call Java BPEL WSDL Concepts BPEL Type of variables BPEL Optional responses BPEL Multiple Operations BPEL Correlation Set s BPEL No Dehydration BPEL Transactions 3

Contents (total 102 questions) My Role PartnerRole difference Multiple Service Bindings Various options for Sch eduling SOA composites Preferences SOA Infra Key Tables Read files in binary for mat Fault Policy Framework (16 questions) Java actions in Fault policy Fwk File Adapter (13 questions) DB Adapter (8 questions) JMS Adapter (1 question) Transac tion (9 questions) Scenario Based Questions (12 questions) 4

SOA General Questions 1. 2. 3. 4. What is SOA? Why is it so popular Explain SCA. What is the benefit it brings to table How can you deploy a composite without JDeveloper What are some of the new features that have been introduced in SOA 11g 5

SOA General Answers What is SOA. Why is it so popular SOA is a design methodology that advocates exposing of product functionality as services. This enables to Reuse functionality Have loose coupling between functionalities Abstract impleme ntation Allow multiple protocols to talk to each other SOA isnt a solution to world hunger ! Nor is it: A specific Technology The Ultimate answer to reuse A New name for EAI A New way to do RPC 6

SOA Installation Answers What is SCA SCA provides a programming model That model allows Creating servic e components written with a wide range of technologies Assembling the service c omponents into a SOA composite application Please read the presentation on SOA Architecture for complete details. 7

SCA Benefits SCA simplified the entire lifecycle Development JDev can be used to develop all components. Deployment All components are grouped together in a composite and during compilation, we ge t a single file called SAR SAR can be versioned as one, deployed as one and mana ged as one

Monitoring EM allows to trace the entire flow, giving ability to drill down into components of a composite 8

What are some of the new features that have been introduced in SOA 11g

SCA Adapter properties can be set easily. Direct support built in JDeveloper Sin gle console to manage everything, the Enterprise Manager End-to-end flow trackin g possible using ECID Business rules can be authored in JDeveloper itself Mediat or is versionable EDN Config Plans 9

SCA

What is the difference between Service component, Service binding and reference binding Can a composite have multiple service bindings 10

SCA What is the difference between Service component, Service binding and reference binding

Service components are the building blocks that you use to construct a SOA compo site application. Examples - BPEL, Human Task, Business Rules, Mediators, Spring . Binding component establish a connection between a SOA composite and the exter nal world. They are categorized as Service binding component and Reference bindi ng components. Service binding components provide the entry point to the composite Reference bi nding components provides access to the external service in the outside world. E xamples include JCA adapters, HTTP binding, Direct binding etc. Can a composite have multiple service bindings Yes, there can be multiple service bindings for a composite 11

Fault Policy Framework

What needs to be done (steps) If a bpel has catch and we also have policies, whi ch will take precedence Can we handle xpath errors. Can we handle errors from As ynchronous PL. Can we throw errors from bpel explicitly (using throw) and expect fwk will handle them OR Can the framework handle custom faults? If no, How we c an make it handle custom faults. Is it possible to handle database faults using fwk What are the various actions possible How can we use the fwk to send email 12

Fault Policy Framework What needs to be done (steps) The policies are setup per application. Define a bindings file in the applicatio n. Create policy file in the application and define what type of faults we want to catch and what actions need to get executed

If a bpel has catch and we also have policies, which will take precedence The policies take precedence. 13

Threading Questions Explain the threading model in SOA Suite OR What happens when a one way message comes to SOA Server and What happens when a sync message comes 14

Threading Questions

A One-way invocation offers several advantages in terms of scalability, because the service engines thread pool (invoker threads) executes when a thread is availa ble. However, the disadvantage is that there is no guarantee that it executes im mediately. How to ensure that the one way invocations are synchronous 15

ThreadingAnswers If you require a synchronous-type call based on a one-way operation, then you ca n use the onewayDeliveryPolicy property Specify this in composite.xml The follow ing values are possible. async.persist: Messages are persisted in the database hash map. async.cache: Mes sages are stored in memory. sync: Direct invocation occurs on the same thread.

This allows us to trade-off reliability of delivery and coupling with the client for speed of delivery. Using the sync option offers the best performance, but t he requestor will perceive that it took longer to post the message due to the in creased coupling between the requestor and the target. Similarly, using the asyn c.cache option reduces the performance overhead of storing the message in memory . However, if the server fails before the message is processed, it will be lost as it is stored in memory. 16

WSDL Can you describe a WSDL file Which element of WSDL gives the location of service 17

Adapters File Adapter

What is JCA How will you set the filename dynamically for a write file adapter H ow will you find the size of the file read How will you change the directory at runtime How will you change the directory through EM console (not at runtime, no t at design time either, but rather after the process has been deployed) If a me ssage gets rejected, where does it go Can the file/ftp adapter poll multiple dir ectories What is distributed polling wrt the file/ftp adapter 18

Adapters DB Adapter You have three physically different databases, one for each geography APAC, US, E urope. You are getting customer data. Based on the location, you want to insert into the appropriate database. How can this be achieved. Discuss possible approa ches and benefits and drawbacks Copyright - http://soatraining.hpage.com 19

Adapters DB Adapter: Answers We can use the following approaches 1. Use a mediator and do content based routi ng. Each DB has its JNDI set 2. Use a bpel, and use dynamic partnerlink. The DB parameters are passed as input (or read from some source like DVM) Approach 1 Pr os 1. Easy to change rules 2. Easy to add new targets 3. User id passwords dont ge t exposed as we can use JNDI Approach 1 Cons 1. If we need to add a new target, it cannot be done dynamically. We need to manually go and add a new routing rule App roach 2 Pros 1. A new target database can be referred to very easily, as we just need to change the inputs Approach 2 Cons 2. UserId and pwd is exposed, unless you write java code that retrieves user id and pwd from jndi 3. If you use the j ava code, then you need to use Copyright - http://soatraining.hpage.com 20

Transactions

If A calls B, both BPEL composites, do they share a transaction How can you make B share a transaction What happens if A inserts data in DB, then calls B synchr onously, B inserts a row in DB and then throws a remote exception What happens i f A inserts data in DB, then calls B synchronously, B shares the transaction wit h A, B inserts a row in DB and then throws a remote exception 21

Transactions : Answers

If A calls B, both BPEL composites, do they share a transaction The default behavior is that they dont. B shall create its own transaction.

How can you make B share a transaction It can be changed by putting transaction=required in Bs composite.xml. Default is transaction=requiredNew

What happens if A inserts data in DB, then calls B synchronously, B inserts a ro w in DB and then throws a remote exception A handles the error. Note, B was in a different transaction than A. So B rolls b ack as it has a unhandled exception. So insert of A stays, insert of B is rolled back.

What happens if A inserts data in DB, then calls B synchronously, B shares the t ransaction with A, B inserts a row in DB and then throws a remote exception A handles the error. Note, B was in a different transaction than A. So B rolls b ack as it has a unhandled exception. So insert of A stays, insert of B is rolled back.

Copyright - http://soatraining.hpage.com 22

Transactions

What happens if A inserts data in DB, then calls B synchronously, B inserts a ro w in DB and then throws a rollback exception What happens if A inserts data in D B, then calls B synchronously, B shares the transaction with A, B inserts a row in DB and then throws a rollback exception If a DB adapter inserts into DB, then an unhandled error is thrown, does the DB insert rollback? If a DB adapter inse rts into DB, then there is a dehydration point, then an unhandled error is throw n, does the DB insert rollback? 23

More Questions Where do you see logs How to see messages in JMS You have a java class. How can you use it in bpel program 24

Scenario Question - 1 I have 5 departments who want to communicate Customer data. Each team is interes ted in some common attributes and some attributes that are specific to their app lication. The provider application serves only the relevant fields to the depart ments. What kind of problems do you foresee and what can be a solution. 25

Scenario Question - 1

As each system requires a different set of data, there would be a problem of dev eloping large number of transformations if we start connecting each system to ev ery other system. There would be n(n-1)/2 transformations required Using a canon ical data model to convert an application specific message to a common message c an solve the issue. See http://www.soapatterns.org/canonical_schema.php for deta ils about this SOA design pattern 26

Scenario Question - 2 I want to design a system that would process orders during the night and despatc h them to the suppliers. However, I want the system to be capable of accepting o rders all throughout the day. What kind of architecture do you propose 27

Scenario Question - 2

We need to design a system with asynchronousity built into it. We can go for sto ring the messages in queues. However EDN would be an even better alternative 28

This Document is only a SAMPLE

We have published only a few slides out of our 107 total slides You can buy this complete document for $39 by sending an email to soagang@gmail.com You can buy this whether you are in US, UK, India, Australia or anywhere else Check out our website http://soatraining.hpage.com for more exciting information on SOA 29

You might also like