• Keine Ergebnisse gefunden

CHAPTER 6: VIRTUAL MARKETPLACES

6.3 S ERVICE O FFER M ANAGEMENT

: Provider Negotiation Agent

: Communication Manager

: Decision Manager

: ACL Parser : XML Parser : Service Type Repository

: message composer list service types( )

send ACL/XML response( )

forward message( )

check request( )

send message( )

parse ACL( ) parse XML( )

list service type objects( )

compose inform message( )

Figure 26. Describe Service Type Sequence Diagram

S e r v i c e O f f e r R e p o s i t o r y n e w S e r v i c e O f f e r ( ) d e l e t e S e r v i c e O f f e r ( ) l i s t S e r v i c e O f f e r s ( ) g e t S e r v i c e O b j e c t s ( )

S e r v i c e O f f e r g e t N a m e ( ) g e t O f f e r s ( ) s e t O f f e r ( ) d e l e t e O f f e r ( ) 0 . . *

1

0 . . * 1

O f f e r g e t O f f e r I d ( ) s e t O f f e r I d ( ) g e t P r o p e r t i e s ( ) s e t P r o p e r t i e s ( ) 0 . . *

1

P r o p e r t i e s

g e t n a m e ( ) s e t N a m e ( ) g e t V a l u e ( ) s e t V a l u e ( ) g e t M o d e ( ) s e t M o d e ( ) ( f r o m S T R )

0 . . * 1

1

0 . . * 1

0 . . *

Figure 27: Service Offer Repository Class Model

The SOA agent is responsible for the management of service offers and the main operations that this agent provides are:

• register a service offer,

• withdraw a service offer,

• modify a service offer,

• describe a service offer.

When the SOA agent gets an ACL/XML request for a registration of new service offer, it first parses the content of the incoming message from the ACL and XML parser and checks the type of the request. Since the request is the registration of new service offer, the Decision Manager, based on the service type name, requests from the SOR to create a new service offer object.

Then, the Decision Manager inserts the information included in the incoming message and requests from the SOR to store it internally. The SOR returns back to the Decision Manager a unique registration id that identifies uniquely this particular offer in relation to the service type.

As soon as the request has been fulfilled, the agent composes a response ACL/XML message with the unique service offer id and sends it back to the requestor. An example of the content of the FIPA ACL/XML message concerning register service offer operation is the following.

<VMPMessage>

<SOAMessage>

<SOARequest RequestId="addoffer01">

<ExportOffer>

<type> testType1 </type>

<agent> testAgent1@fokus.gmd.de </agent>

<properties>

<property>

<pname> testprop1 </pname>

<pvalue>

<string/>

<value> teststringvalue1 </value>

</pvalue>

</property>

<property>

<pname> testprop2 </pname>

<pvalue>

<integer/>

<value> 1234561 </value>

</pvalue>

</property>

</properties>

</ExportOffer>

</SOARequest>

</SOAMessage>

</VMPMessage>

The previously described steps are further explained in the following sequence diagram.

: ACL Parser : Provider

Negotiation Agent

: Communication Manager

: XML Parser : Service Offer Repository

: message composer : Decision

Manager register offer( )

send ACL/XML response( )

forward message( )

parse ACL( ) parse XML( )

check request( )

create new service offer object( )

compose inform message( )

send message( )

Figure 28: Register Service Offer Sequence Diagram

If a VE candidate partner wants to delete an existing service offer, a request for service offer withdrawal is generated and sent to the SOA agent. This request should refer to the corresponding service type and also include the unique registration id that has been provided to this domain during offer registration. This means that only this domain can withdraw an existing service offer. When the SOA agent gets the request, it initially parses the content of the incoming message from the ACL and XML parser and checks the type of the request. Since the request is the withdrawal of service offer, the Decision Manager, based on the service type name and the unique registration id, requests from the Service Offer Repository to delete the service offer object. As soon as the SOR deleted the object, the Decision Manager composes a response ACL/XML message and sends it back to the requestor. An example of the content of the FIPA ACL/XML message concerning withdraw service offer operation is the following.

<VMPMessage>

<SOAMessage>

<SOARequest RequestId="removeoffer01">

<WithDrawOffer>

<offerid> testType1/R0 </offerid>

</WithDrawOffer>

</SOARequest>

</SOAMessage>

</VMPMessage>

The previously described steps are further explained in the following sequence diagram.

: message composer : Provider

Negotiation Agent

: Communication Manager

: ACL Parser : XML Parser : Service Offer Repository : Decision

Manager withdraw service offer( )

send ACL/XML response( )

forward message( )

parse ACL( ) parse XML( )

check request( )

delete service offer object( )

compose inform message( ) send message( )

Figure 29: Withdraw Service Offer Sequence Diagram

If a VE candidate partner wants to modify an existing service offer, a request for service offer modification is generated and sent to the SOA agent. This request should refer to the corresponding service type and also include the unique registration id that has been provided to this domain during offer registration and also the new values for specific properties of the service type. When the SOA agent gets the request, it initially parses the content of the incoming message from the ACL and XML parser and checks the type of the request. Since the request is the modification of an existing service offer, the Decision Manager, based on the service type name and the unique registration number, requests from the SOR to locate the service offer object from the SOR. In the sequel, the Decision Manager modifies the valu es of properties included into the message and stores the service offer object again in the SOR. In that case the SOR do not generate a new service offer registration id. As soon as the SOR modified the object, the Decision Manager composes a response ACL/XML message and sends it back to the requestor. An example of the content of the FIPA ACL/XML message concerning modify service offer operation is the following.

<VMPMessage>

<SOAMessage>

<SOARequest RequestId="modifyoffer02">

<ModifyOffer>

<offerid> testType2/R0 </offerid>

<delete>

<prop_name> testprop1 </prop_name>

<prop_name> testprop3 </prop_name>

</delete>

<modify>

<properties>

<property>

<pname> testprop2 </pname>

<pvalue>

<integer/>

<value> 7654321 </value>

</pvalue>

</property>

<property>

<pname> testprop4 </pname>

<pvalue>

<integerseq/>

<seq_value>

<value> 9999999 </value>

<value> 8888888 </value>

<value> 7777777 </value>

</seq_value>

</pvalue>

</property>

</properties>

</modify>

</ModifyOffer>

</SOARequest>

</SOAMessage>

</VMPMessage>

The previously described steps are further explained in the following sequence diagram.

: Provider Negotiation Agent

: Communication Manager

: ACL Parser : XML Parser : Service Offer Repository

: Message composer : Decision

Manager modifyServiceOffer( )

send ACL/XML response( )

forward message( )

parse ACL( ) parse XML( )

check request( )

getServiceOffer( )

compose inform message( )

send message( )

modifyServiceOffer( )

setServiceOffer( )

Figure 30: Modify Service Offer Sequence Diagram

Finally, if a VE candidate partner wants to get the properties and values of an existing service offer, a request for service offer description is generated and sent to the SOA agent. This request should refer to the corresponding service type and also include the unique registration id that has been provided to this domain during offer registration. When the agent gets the request, it initially parses the content of the incoming message from the ACL and XML parser and checks the type of the request. Since the request is the description of an existing service offer, the Decision Manager, based on the service type name and the unique registration number, requests from the SOR to locate the corresponding service offer object from the SOR. In the sequel, the Decision Manager gets the values of the properties included into service offer, composes a response ACL/XML message and sends it back to the requestor. An example of the content of the FIPA ACL/XML message concerning describe service offer operation is the following.

<VMPMessage>

<SOAMessage>

<SOARequest RequestId="describeoffer01">

<DescribeOffer>

<offerid> testType1/R0 </offerid>

</DescribeOffer>

</SOARequest>

</SOAMessage>

</VMPMessage>

The previously described steps are further explained in the following sequence diagram.

: ACL Parser : Provider

Negotiation Agent

: Communication Manager

: XML Parser : Service Offer Repository

: Message composer : Decision

Manager describeServiceOffer( )

send ACL/XML response( )

forward message( )

parse ACL( ) parse XML( )

check request( )

getServiceOffer( )

compose inform message( ) send message( )

Figure 31: Modify Service Offer Sequence Diagram