Account Creation Sample
Account Creation Sample
2.1 Description
The Solution should provide a Middleware Integration which receives request from external systems and
interact with BRM system to perform the required operation and provide response back to the external
systems.
2.2 Assumptions
BSS Middleware should provide the queue names along with IP and credentials of RabbitMQ for BRM
Broker to consume messages.
3.1 Description
Solution must provide a real time interface to allow external applications to perform queries relating to
balances, expiry date etc.
3.2 Assumptions
BSS MW should send appropriate input JSON to RabbitMQ Request queue with all the mandatory
attributes require to complete operation in BRM. The POST and GET input JSON format should have the
following format.
Description:
The Customer Account Creation at BRM will form a Three Level Hierarchy called CA, BA and SA with the
customer information received from BSS MW like customer Personal Information, Billing Information, and
Order Information and so on. Once account got created in BRM, BRM broker will provide a response back
to BSS MW regarding the account details, billing and subscription information.
Assumptions:
Proposed Solution:
Customer account creation service will be triggered by BSS MW with input JSON. If BRM Broker received
a valid json for customer creation then it will connect to BRM and initiated a global transaction for account
creation. BRM Broker first create customer CA account and then in the same call it create BA account and
then in the same call it will create SA account. After successful completion of three accounts BRM Broker
commits the transaction and sends a response back to BSS MW. If any of the three accounts fails then
BRM broker aborts the transaction and return back failure message to BSS MW through RabbitMQ.
Pseudo Code Commented [C1]: Please provide more details like how
the json is converted to Flist format and how the relative
1. First the stand alone listener [StandAloneListener.class] will receive the request JSON and checks the opcode is getting called in BRM. More about the BRM
operation attribute of it. If the ‘operation’ value is ‘createCustomerAccount’ then it will convert the broker customization.
JSON object into ‘CustomerAccountJSon.class’ POJO with the help of Gson library and pass it as
parameter to ‘customerAccountService.class’ for further processing in BRM.
2. The POJO of Customer Account creation process mainly contains the following classes which intern
are POJO.
CustomerAccountJson
AccountArguments
location String O
planName String M
@Valid
PaymentGateway POJO class M @NotNull
@Valid
OrderInformation POJO class M @NotNull
@Valid
PersonalInformation POJO class M @NotNull
@Valid
AccountData POJO class M @NotNull
3. Once the "customerAccountService” receives POJO from StandAloneListener then it will validate the
POJO along with its inner classes with the help of ValidationFactory of javax.
4. If the POJO validation successfully completed then the service class will check whether the
information provided in the JSON attribute is valid for BRM or not with various utility classes.
5. In the next step the service will connect to BRM with the help of BRM Java PCM library and its
property file infranet.properties and define a HashMap called “failureMsg” which will hold the
information regarding errorCode and errorMessage return by various utility classes to the service
class.
6. After connecting with BRM the service will call JsonRequestValidator for validating the information
of JSON, This class with the help of AccountJsonSecondaryValidator and PlanCustomizationValidator
will validate the information provided in JSON like planName, accountInformation, orderInformation,
advancePayment and so on.
7. The AccountJsonSecondaryValidator class will validate the account information with the following
utility classes. All the utility classed will create a HashMap resultMap for returning whether the
operation was success or failure which intern validate by the calling class up to the service class.
Finally the service class will verify whether the service is a failure or success and as per that it will
send response back to BSS MW.
8. Similarly the PlanCustomizationValidator will validate the advancePayment and customer plan with
the following utility classes.
9. After completion of secondary validations the service will open a global transaction for customer
account creation. The class AccountAndAdvancePayProcessor will create customer CA, BA and SA
account with the help of following utility classes.
for forming nameinfo, invoiceinfo, balance and billing Flist of BRM respectively.
10. If all the three customer accounts CA, BA and SA complete successfully with the profile objects than
the service will commit the transaction. If any of the account creation fails or any error occurred
while fetching the require information then the service will abort the transaction and send a failure
response.
11. Once the account creation completes successfully then the service will start a new transaction for
processing the advancePayment [If present in the JSON request] with the help of
AccountSubscritpionProcessor and AdvancePaymentCreator.
12. The AccountSubscriptionProcess will use the following utility classes for completing the deal
subscription process.
14. If the advance payment operation along with subscription process successfully completes in BRM
then the service will commit the transaction otherwise it will abort the transaction. After successful
completion of advancePayment the AdvancePaymentResponseCreator is used to create the
advance payment related data of the response JSON.
15. If the request JSON contains “customerPlan” with addOns and components then the service will
open a new transaction for customer plan purchase and with the help of
PlanCustomizationProcessor and DataSmsVoiceProcessor will subscribe the deal provided and
prepare the appropriate information for the response.
16. In the final step the service class after calling appropriate utilities and receives response from them
will check any of the process fails with the help of failureMsg HashMap. If the HashMap is empty
which means all the internal processed completes successfully then the service will send a success
response to BSS MW. In case the failureMsg Hash Map is not empty then the service class will
retrieve the errorCode and message from the map and sends a failure response to BSS MW.
Input & Output Flist Commented [C2]: Only Input Flist is provided.
MSISDN Search flist is missing.
Plan Search Flist. Please provide more details like how the json is
converted to Flist format and how the relative opcode is
getting called in BRM. More about the BRM broker
0 PIN_FLD_RESULTS ARRAY [1] allocated 1, used 1 customization.
1 PIN_FLD_POID POID [0] 0.0.0.1 /plan -1 0
0 PIN_FLD_POID POID [0] 0.0.0.1 /search -1 0
0 PIN_FLD_ARGS ARRAY [1] allocated 1, used 1
1 PIN_FLD_NAME STR [0] "CirclesOne"
0 PIN_FLD_TEMPLATE STR [0] "select X from /plan where F1 = V1 "
0 PIN_FLD_FLAGS INT [0] 256