cad> Number
etd>
Declare all the variables here Expressions ~ Expressions are means of acces,
ies or other expressions that directly yield a va
can be merged with the HTML page that ges ge
jon examples.
‘This code will display Hello World,
(v) Standard Action ~The syntax forthe following JSP standard
Tags — The syntax for custom tags is ~
sa
(b) response is subclass of HitpServletResponse.
(©) session HTTP session object associated withSoftware Architecture implomery
ti seret 2 Explain life epee explain the features of Java ser
os
(4 cere provide many avant
i ve ore beiter. Servet run
ant
pot required t0
J, servlets are
“The third and final phase ofthe servlet life-cycle
It represents the removal ofthe servlet from the con
interface defines the destroy() method to correspond to the
‘eyele phase. When a servlet isto be removed, a contane:
method.
0.31. What is the conceptual difference between JSP and ser
Ans, Coding a JSP seems to be simpler than coding the correspo
servlet. Inthe JSP, we do not have o write complex Java code and wors
HTML inside that Java code. We can
write HTML taps, and wherever I =e [timo]
needed, write Java code in between :
HTML tags, Inother words, serves a sccm] ‘ough a session involving diferent servlets
side Java, whereas ISPS. Fig. 3.17 The Conceptual Difference be to follow for the programmer, The connection between the
ide HTML. This shown ‘between Servlets ae ‘an HTML document with a form and the code that
4 ao Ab A a the form field data is often not obvious. Moreover, the
, managed through the setA\tribute/getAttribute mechanism
eee
are as follows ~
truction of HTML documentsisstil low:
re writen to an output stream, event
‘There are no compilea
se i
dard definition ofa Java servlet —
HutpServlet extends GenericServlet
public class OrderServlt extends HiipServlet
public void init)
{
system out printh
("In doGet( ) method”);
‘HiipServletRequest and HitpServletResponse obje:
information stored in the latter by the servlet method
an entire HTML document along with some HTTP head
the document content-type. When the servlet method has finished its processing
it retums control to the server. P
c (iv) The server formats the information stored in
‘HitpServletResponse objectby the servlet into an HTTP response message
__itthen sends tothe cient (i.., Web browser) that initiated the HTTP:
ssystem.out printin(“In destroy( ) method”);
class extends HitpServlet class provided by Sun. Our servlet
the service( ) Java method from this HtipServlet, Similarly,
itself, in turn, has been inherited from GenericServlet. The
capesuta
ing bean Setter methods go here got
in how Java servlets perform session handling
5 Explai A (RGPY, Dec. 2016)
mets perform session handling 2 (RGRY., June 2017)
Ta Be rHTTP a betwe
0s
Communicating a
String message
ts several Web pages,
sale atthe Web site, In this‘cookies are typically enabled, but to ensure session tracki What features does EJB pro
Rewriting, use encodeURL( in your servlets, or encodeRedi ywing features —
Transaction Management ~ A developer can specify tat your
oe eeSoftware Architecture imptementaiyy +,
piscass about session beans, as 107
ta
session bean
(ii) Remote Awareness ~ EJ
‘objects and clients can be in different parts ofthe wor
these objects are allowed to communicate
ped s, stateful session beans and stateless
~ A session bean corresponds to a
by the EJB container.
In addition to these, ee
‘new components, managing database connections, threads and sockets, ete.Software Architecture i is
Implementation
fore the eeate() method on the home
Mmggnee anda FFerence tothe remote imei
eat petining the ‘Component Interface —
terface SignOn extends EJBobject
public boolean validateUser
throws InvalidLoginExcept
}
{terface has one business method, validarey
ite interfacs
Ans, A stateful session bean
interfaces ~ a home interface (EJB!
‘and a bean class that implements the SessionBean
0.45. Describe the steps to implement a stateless session bean in deta,
(RGPY, June 2019)
‘print(“The container called the setSessionContext method”),
_print(“so that the bean instance can be initialized.\n"),qjbPassivate
throw new InvalidL oginException(:
) beceningEcepton ne
throw new InvalidLoginException (“Invalid logiy
password”);
)
void print (String s) {
System.out println(s);
J
J
Writing the Exception Class ~ The InvalidLoginExceptior
defined below. This class has been derived from java.lang Excepto
package day04;
‘Public class InvalidException extends Exception
ie ses ie
‘Public InvalidLoginException( )
Bs Stee
Software Architecture implementation T
Technologies
: super( );
}
public InvalidLoginException(Exception e)
sper(etoString( );
} :
public InvalidLoginException\ String s)
super(s);
is given below.
its bean type and st
name>students/env-entry-name>
ype>java. lang Strings/en-entry-type>
passwords/env-entry-value>
student 1
java.lang.string/env-entry-type>
password]
iding good response time.
multiple requests efficiently,
"0.49, Write short note on Message Oriented Middleware (MOM).
(R.GPV, Dec, 2010, June 201
“Ans. Asynchronous communication allows the parties to
indirectly through # message queue, The software that manages
Software Architecture Implementation Techno
fo
od as Message Oriented Middleware (MOM) Ty sen
tinues with its other work without wai
the sender A sen:
ie cage queue Sve
(R.GRV, June 2010, Dec. 2010)
(RGRY., June 2015)30 interfaces and
Prepared Statement, R
Connection Obj
Statement Object ~
execute static SQL statements
(b) PreparedStatement ~ This object is used to
execute dynamic SQL statements
(€) CallableStatement ~ This object is used to defi
execute stored procedures.
(ii) ResultSet Object The result o'
some data. This data is returned inside an object
-uting a Statement i usu
type ResultSet
iv) SQLException Object — This object is used to deal with
in JDBC.
-.
ot
An. The JDBC API
‘The JDBC Test Suite
33
drive
spac of
Explain various types of JDBC drivers in Java,
—
Sofware Archectur npemeneton Techy
what are the components of DBC? mig
“The components of JDBC drivers ae a follows —
(ti) The DBC Dri
(v) The IDBC-op}
ms,
chine to communicate
loaded onthe client, which
(054 Explain how 10 connect 10 a local MS access database using a
Write the steps of setting up an Open Database Connectivity (ODBO).
Or
What is database connec
middleware support, ODBC
Ans, We wish t0
(RGRY, June 2011, Dec. 2015)
? Explain the basic connectivity,
JDBC technologies. (R.GRY, June 2014)ceDB will appea
ea tar ide
ipeedonthavean Acces tbe
String dataSourceName
‘String dbURI = “jdbc:odbe:
uy f
Class.forName
{java.sql Connecti
con.closef );//To close the connection
,
éatch( Exception) {
ceprintSackTrace
ODBC bridge, the URLis a URN consisting of the prefix jdbe:odbe: followed
‘by an ODBC data source name, In this example, we use the data source name
EmployeeDB that we associated with the Employee database using the Dat
‘on amact
‘ting host="db.
‘ring dbname=“
String usemame
Siring password
String dbURI =
yf
‘The new!
—
Software Architecture implementation Tach
wwe have already created a MySQL
wih host name dbexamplence Mae
‘CPAP connect
Copy ths file to
lation directory. The next
R file will automatically be added othe
by the server.
exam
‘Employee’
= “someuset
= “mypasswé
*jdbe:my: host +47" + dbname +"?user=”
' usemame + “password =" + password;
work around for¥ Software Architecture implementation Tec
«what is INDI ? Explain.
ot faming and Directory Interfac
shown in fig. 3.24
Sava Application
INDIAPI (Client Layer) aI
TNDISPIG
(Server Layer)
the first call to next) positions the cursor
) secess fields inthe row pointed to by the
by ordinal (ie, 1,2 etc.) rather than name,122 sofware
‘The INDI model def
‘an API 10 access an
‘messaging system.
‘used to communicate
(ii) JMS API Unified interfa
clients,
(Gx) JMS Provider ~ The messazing sys
JMS in addition to other administrative and cont
full-featured messaging product.
‘The JMS architect
(i) IMS Messages ~ Appli
the na
send and receive messages through a JMS
defi
information betwer
and
_—
Sofware Architecture Inlementaton Technolo
Gielen ologies 123
sred Objects ~ These
r’s administra
te writing portable enterprise a
‘operational funet
les a set of application programm
infrastructure, similar to what
lcompiler can generate the— —
‘name. This returned
be sent back to the
Which, in turn, uses TCP/IP as a basic
RMI infrastructure is very
architecture based on RMI wouldFig. 3.28 Imterface and Impler
‘Software Architecture
ructure Services
afro ORB, such as secur
k Management Services
rents and transactions,
ss
* Or
ins wi
‘oot
(0 support the role of a
—
‘mplementation Technologies
(RGPY., June 2015)
Also discuss about its components,
(RGPY., June 2016)
n object request
invocation must be used. Most
because it provides a more natural
'© main components of CORBA
asta
Fig, 3.29 The Main Compon
(@) ORB Core—The 10!
(@) Operation enabling it to
(6) Operations to con
invocation,
be started and stopped.
between remote objectreferences and
Operations to provide argument lists for requests using
wa dankeé ‘Software Architecture Implementation 7, i tn
iy running. The object adapter name is used
ind activating them. An implemen
of
‘ype identifier ofan interface
itmay be used asa key to IDL.
Every CORBA remote object
type identifier of its i
© oF its type withthe interface
re
ns ot requis an
Sera gfe TpOSHIONY
and servants 10
achieved of the standardization of
“ti servants. The POA suppor
(a). Those whi
ice repository. Not all ORBs provide an
Invocation Interface ~The dynamic invocation
results in reply messages.
() Client Stubs/Proxies ~ Th
spects the contents of the request to discover its
bjt, the method to be invoked and the arguments then invokes the— =
1 NetWork to
in
re component B is located. This is shown fig 33),
[omen]
Fig, 331 ORB Forwards the Call Its Counterpary
HRB at component B's end
same machine where the called component
32,
tnsert 6] Pretara
Onn
Insert Method Gets Called
‘send takes this return value, converts
wetwark back to the ORB at component
[Papeete]
smion. aah |
ig, 3.33 Called ORB Returns Results to Calling ORB
end receives ths binary data,
it to compone itA, as shown
‘method and sends back the to the client ORB. Ho
believes that it was all a local operation.
Comer] Component
srt a»)
Coos Coos
Fig. 3.30 Component Calls an Insert Method
Component A calls the Insert method and passes two parameters
‘a, and b to this method.
(i) The ORB receives this request and
is defined in component B, How does it know
‘whenever a CORBA component i created by a3A ORBs communicate with eachother using the
{uOP). The early versions of CORBA we —
expected to run at an application
Seay asa server metbod to make it more readable.
intentio: ing | 5 some protocols passed
“in lef, some consiRMI was perceived
‘goals in the design of UML are as follows ~
tha ready-to-use, expressive, and visual modeling
guage and notations to enhance concepts to righer
rend on OO languages.
1 development concepts such as component
ievelopment, reusability interoperability, and
provided by the UML-based modeling —
of the
to include the system’s intricacies
ore suitable, where the specific complexity
account in each iteration. This enhances
(0.68. What are the different system views that can be modelled using
UL? What are the different UML diagrams which can be used to capture
cach ofthe views ?
or
Explain the use of UML for object-oriented design.
(RGBY, June 2010, 2011)
or
What are the different system views that can be modelled using UML?
(RGPY, June 2015)
using following views (models) to
nt perspectives ~ y
fines the functionalities provided_ SOFTWARE ARCHITECTURE
__ ANALYSIS
(o) Environment
and behavioural aspects of
implemented. :
Fig 336 shows he different UM
each ofthe views.
The goal with software
tem to be bui c
with the requirements,
toatheoreticaly viable software
‘an interval or absolute scale.—
20 Onting Sais, (95 White short note om domain requirements
t
ie: Requirements which are derived from the appli
ee 1d from the needs of the users ar -d dor
Software Architecture Analysis & Design 141
Search the desired ye
eT
ey
number of domain requirements.
software development lifecycle model ? Why is it important
cle model while developing a large software product ?
(RGRV, June 2010)
product starts with a request for the
product conception. Starting with
tired when it is no longer useful. This forms
ery software product. Life cycle is not strange
n fact, each business organizations conducts its
phase. A software life ¢}
descriptive representation of the software lif
the various activities conducted on a softws
retirement into a set of life cycle phases.
Fig. 4.1 Types of Non-functional Requirements the fundamental development activitiesrchitecture design and anay
(i) lication and collection of requirements145
—The inputs of CBAM a : sme incades the following steps -
Collate Seenarios Collate the scenarios elicited during the,
se! ve the stakeholders the chance to conti
bute n
hitectural d 4 Ose on satisfying the business poals ofthese
(i) The existing ar eer ssios ba s0als of the system and
ee ih Sor further study.
9
*
in calculating the architectural
of the quality attributes that concern the
lity ~ Determine the utility for each
urrent, desired, best-case) forthe
‘of concer are the ones in the lst
address the chosen scenarios
sponse levels that will result
- Given that an architectural
lation must be performed for
Expected Quality-attribute-
the elicited utility values (that
the expected quality-atribute-
Determine this utility for each
narios and relevant quality
{Conte rests with intuition
Step 8. Choose
Fig, 4.2 Process Flow Diagram for the CBAM
Investment (ROI) Subj
-ctural Strategies based on Return on
to Cost and Schedule Constraints ~ Determine
—
es “@ Software Archscture,
146 Soma Arches ‘Analysis & DesignSofware Architecture Analysis & Desion 147
; on the architecture promoting modifiabi
pe cae are ai,
(pill builders ofstems interacting wih the oneunde consideration
Fe ye ATAM Inulin the
ce ‘ten'sbusinessimission drivers
@ The Evaluation Team - This group is external to the project whose
architecture is being evaluated.
ii) Project Decision Makers— These people are empowered to speak
for the development project or have the authority to mandate changes to it
it) Architecture Stakeholders ~ Stakeholders have a vested intrest |
" {in the architecture performing as advertised. They are the ones whose abilitySofware ACRES i Software Architecture Analysis & Design 149
=
the |= The lead designer
the deoge ond was hon te esp. Dring is nediscuss how ADD uses three commons views,
‘Software Architectures
a g Software Architecture Analysis & Design 151
(9) | Approximate
duration
‘and communication
between the meetings.
0.16, Wpxa1 do you mean by attribute driven desi
Ans. The attribute driven design method (A\
‘generate and test philosophy. It keeps
validated. It produces a
‘ean be given to other pri
‘architect or architecture team cor
ADD is a five-step method
‘Next Iteration —Fither the design instep 3
ASRs or it won't. Ifit does not, then either
willbe elaborated in future iterations of ADD,
‘satisfied, allocated to children, or indicated as not ac!
‘Step 5. Repeat Steps 1-4—Until all the ASRs have been satisfied or until
‘the architecture has been elaborated sufficiently for the implementers to useit,
kfc and for determining potentidoing the same.
components whi
Disadvantages of Reused Code ~
=
rite short note on domain-specific sofeware architec
ee hate nce 0000 1
& lage of software components specialized fi
__ Ain, generalized for effective use oct
som dons),
is ‘or, alternately.
{for patterns of problem elements, si
define mappings between them.
domain-specific software architecture with construction
clements, and
hod.
“ns Domain-specific software architecture consists of a domain model,
eee requirements and referential architecture used to of
[pains in a specific problem domain, and its
‘pletion in one specific domain.
Function ~ Software development in certain domain:
@ Increased Maintenance Costs ~ If component source ce
not available then maintenance costs may be increased as the reused elem
of the system may become increasingly incompatible with system changes
ase bs prove this kindof software development more feasible.teaching.
SOFTWARE ARCHITECTURE
DOCUMENTATION
ied Vial as some sort oe
d vuntonality The granular
_ eta Comenttion being developed
sbsd ge as a major subsystem, in others it might be
2 cally component represent Systm It
os putational elements, and run-time processes.
ip ations between components are documented vi
| pec. yal such elation
|
|