Академический Документы
Профессиональный Документы
Культура Документы
Udi Dahan The Software Simplist .Net Development Expert & SOA Specialist
Email: Udi@TheSoftwareSimplist.com Web: www.TheSoftwareSimplist.com
Agenda
SOA Basics
SOA Basics
Why SOA What SOA Means 4 Tenets of SOA What the tenets mean
Inefficient for:
Small medium sized systems Non-distributed systems
7
Inefficient for:
Small medium sized systems Non-distributed systems
9
10
11
12
u.Address = txtAddress.Text;
u.Save(); }
13
14
15
16
17
private void btnSave_OnClick(object sender, System.EventArgs e) { UserRequest ur = new UserRequest( UserActions.Save, txtFirstName.Text, txtLastName.Text, txtAddress.Text);
18
19
20
private void btnSave_OnClick(object sender, System.EventArgs e) { UserRequest ur = new UserRequest( UserActions.Save, txtFirstName.Text, txtLastName.Text, txtAddress.Text); SignedRequest sr = myCertificate.Sign(ur);
BL.UserService.EnqueueRequest(sr); }
21
22
23
Client
Service
Get an Object
24
Client
Service
Get an Object
25
Service
26
Service
27
Service
28
29
Often, client code will need to temporarily store several changes in order to send a single message -> Service agents do this.
30
31
If encryption is used, messages can get bloated and negatively impact performance. Secure conversation mechanisms can help.
32
33
34
ACID is dead.
Client code needs to add logic to handle what ACID did.
It is NOT easy.
35
Scenarios
Problems
36
37
38
In order to minimize app rewrite, the new module listens for messages and updates the apps database.
Messages can NOT be lost, even if a service is down. Each order is money in the bank.
39
40
41
SOA Clients
Requirements
Compared to Services
Deadlocks Architecture Message Flow Solution Structure
42
43
45
46
Pros: This will make sure that only one thread can access a group of objects at a time without dead locking.
Cons: Wrong division of SDs will lead to poor performance negates requirements.
47
Corollaries:
All threads need their own copy of the data Writing to the database (and log) should happen on its own thread. Sending messages at high speeds burdens the system separate thread
48
Presentation Thread
Logic Thread
Communications Thread
Presentation Services
Logic Services
Communications Services
Presentation Queue
Logic Queue
Communications Queue
Yellow lines are for DeQueue operations, Red are for EnQueue operations, White are for direct calls. Small circles represent in memory objects.
49
Logic
Presentation
50
51
52
Thank you
Udi Dahan The Software Simplist .Net Development Expert & SOA Specialist
Email: Udi@TheSoftwareSimplist.com Web: www.TheSoftwareSimplist.com