SlideShare a Scribd company logo
1 of 8
Until Successful Component In
Mule Demo
Abstract
• The main motto of this PPT is how to use Until
Successful component in our applications.
Introduction
• The until-successful scope processes
messages through the processors within it
until the process succeeds. By default, until-
successful’s processing occurs asynchronously
from the main flow. After passing a message
into the until-successful scope, the main flow
immediately regains control of the thread.
However, you can configure until-successful to
run synchronously relative to the main flow.
Example
• .mflow• <?xml version="1.0" encoding="UTF-8"?>
• <mule xmlns:vm="http://www.mulesoft.org/schema/mule/vm" xmlns:jdbc-ee="http://www.mulesoft.org/schema/mule/ee/jdbc"
xmlns:http="http://www.mulesoft.org/schema/mule/http" xmlns="http://www.mulesoft.org/schema/mule/core" xmlns:doc="http://www.mulesoft.org/schema/mule/documentation"
xmlns:spring="http://www.springframework.org/schema/beans" version="EE-3.4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-current.xsd
• http://www.mulesoft.org/schema/mule/core http://www.mulesoft.org/schema/mule/core/current/mule.xsd
• http://www.mulesoft.org/schema/mule/http http://www.mulesoft.org/schema/mule/http/current/mule-http.xsd
• http://www.mulesoft.org/schema/mule/ee/jdbc http://www.mulesoft.org/schema/mule/ee/jdbc/current/mule-jdbc-ee.xsd
• http://www.mulesoft.org/schema/mule/vm http://www.mulesoft.org/schema/mule/vm/current/mule-vm.xsd">
• <jdbc-ee:mssql-data-source name="MS_SQL_Data_Source" user=“****" password=“****" url="jdbc:sqlserver://localhost;databaseName=test1" transactionIsolation="UNSPECIFIED"
doc:name="MS SQL Data Source"/>
• <jdbc-ee:connector name="Database" dataSource-ref="MS_SQL_Data_Source" validateConnections="true" queryTimeout="-1" pollingFrequency="0" doc:name="Database"/>
• <spring:beans>
• <spring:bean id="Bean" name="Bean" class="org.mule.util.store.SimpleMemoryObjectStore"/>
• </spring:beans>
• <flow name="Database_ComponentFlow2" doc:name="Database_ComponentFlow2">
• <http:inbound-endpoint exchange-pattern="request-response" host="localhost" port="8087" path="UntilSuccessful" doc:name="HTTP"/>
• <logger message="--main flow--" level="INFO" doc:name="Logger"/>
• <expression-component doc:name="Expression"><![CDATA[
• sessionVars['DB_STATUS']='INITIAL';
• ]]></expression-component>
• <until-successful objectStore-ref="Bean" maxRetries="5" secondsBetweenRetries="5" doc:name="Until Successful" failureExpression="#[sessionVars['DB_STATUS']!='SUCCESS']">
• <vm:outbound-endpoint exchange-pattern="request-response" path="db" doc:name="VM"/>
• </until-successful>
• </flow>
• <flow name="Database_ComponentFlow3" doc:name="Database_ComponentFlow3">
• <vm:inbound-endpoint exchange-pattern="request-response" path="db" doc:name="VM"/>
• <jdbc-ee:outbound-endpoint exchange-pattern="request-response" queryKey="select" queryTimeout="-1" connector-ref="Database" doc:name="Database">
• <jdbc-ee:query key="select" value="select * from mytable1"/>
• </jdbc-ee:outbound-endpoint>
• <expression-component doc:name="Expression"><![CDATA[
• sessionVars['DB_STATUS']='SUCCESS';
• ]]></expression-component>
• <logger message="--success" level="INFO" doc:name="Logger"/>
• </flow>
• </mule>
• Output:
• Flow of execution:
1. URL to trigger the service from browser
http://localhost:8087/UntilSuccessful
2. Database component connects to the specific
database, executes the select query but there is
no table specified in DB, hence the until
successful component retries for 5 times and
exit the flow.
References
• https://docs.mulesoft.com/mule-user-
guide/v/3.5/until-successful-scope

More Related Content

What's hot

Expression filter in Mule
Expression filter in MuleExpression filter in Mule
Expression filter in MuleKhan625
 
Until successful component in mule demo
Until successful component in mule demoUntil successful component in mule demo
Until successful component in mule demoSudha Ch
 
Vm component in mule
Vm component in muleVm component in mule
Vm component in mulejaveed_mhd
 
Basic example using until successful component
Basic example using until successful componentBasic example using until successful component
Basic example using until successful componentprudhvivreddy
 
Mule quartz hari_gatadi
Mule quartz hari_gatadiMule quartz hari_gatadi
Mule quartz hari_gatadiHari Gatadi
 
Howtouseforeachcomponent
HowtouseforeachcomponentHowtouseforeachcomponent
Howtouseforeachcomponentakshay yeluru
 
Basic example using for each component
Basic example using for each componentBasic example using for each component
Basic example using for each componentprudhvivreddy
 
Filter expression in mule
Filter expression in muleFilter expression in mule
Filter expression in muleRajkattamuri
 
Database component in mule
Database component in muleDatabase component in mule
Database component in muleRajkattamuri
 
Mule message processor or routers
Mule message processor or routersMule message processor or routers
Mule message processor or routerssathyaraj Anand
 
Mule esb
Mule esbMule esb
Mule esbKhan625
 
Stored procedure in Mule
Stored procedure in MuleStored procedure in Mule
Stored procedure in MuleKhasim Saheb
 
Quartz component in mule demo
Quartz component in mule demoQuartz component in mule demo
Quartz component in mule demoSudha Ch
 
Choice component in mule
Choice component in mule Choice component in mule
Choice component in mule Rajkattamuri
 

What's hot (19)

Mule Message Properties Component
Mule Message Properties ComponentMule Message Properties Component
Mule Message Properties Component
 
How to use smtp endpoint
How to use smtp endpointHow to use smtp endpoint
How to use smtp endpoint
 
How to use splitter component
How to use splitter componentHow to use splitter component
How to use splitter component
 
Expression filter in Mule
Expression filter in MuleExpression filter in Mule
Expression filter in Mule
 
Until successful component in mule demo
Until successful component in mule demoUntil successful component in mule demo
Until successful component in mule demo
 
Vm component in mule
Vm component in muleVm component in mule
Vm component in mule
 
Basic example using until successful component
Basic example using until successful componentBasic example using until successful component
Basic example using until successful component
 
Mule quartz hari_gatadi
Mule quartz hari_gatadiMule quartz hari_gatadi
Mule quartz hari_gatadi
 
Howtouseforeachcomponent
HowtouseforeachcomponentHowtouseforeachcomponent
Howtouseforeachcomponent
 
Basic example using for each component
Basic example using for each componentBasic example using for each component
Basic example using for each component
 
xslt in mule
xslt in mulexslt in mule
xslt in mule
 
Filter expression in mule
Filter expression in muleFilter expression in mule
Filter expression in mule
 
Database component in mule
Database component in muleDatabase component in mule
Database component in mule
 
Mule message processor or routers
Mule message processor or routersMule message processor or routers
Mule message processor or routers
 
Mule esb
Mule esbMule esb
Mule esb
 
Stored procedure in Mule
Stored procedure in MuleStored procedure in Mule
Stored procedure in Mule
 
Quartz component in mule demo
Quartz component in mule demoQuartz component in mule demo
Quartz component in mule demo
 
Choice component in mule
Choice component in mule Choice component in mule
Choice component in mule
 
Configurare http mule
Configurare http muleConfigurare http mule
Configurare http mule
 

Viewers also liked

Idempotent filter with simple file
Idempotent filter with simple fileIdempotent filter with simple file
Idempotent filter with simple fileSunil Komarapu
 
PrudentialProfile_Eng
PrudentialProfile_EngPrudentialProfile_Eng
PrudentialProfile_EngFunda Erbaş
 
How to use message properties component
How to use message properties componentHow to use message properties component
How to use message properties componentSunil Komarapu
 
Aguilera melania
Aguilera melaniaAguilera melania
Aguilera melaniamelania365
 
Caching and invalidating with managed store
Caching and invalidating with managed storeCaching and invalidating with managed store
Caching and invalidating with managed storeSunil Komarapu
 
Formación del profesorado. escuela 2.0
Formación del profesorado. escuela 2.0Formación del profesorado. escuela 2.0
Formación del profesorado. escuela 2.0solfa ortega fernandez
 
Proyecto de-aula-periodo-1-nuevo-noveno-1
Proyecto de-aula-periodo-1-nuevo-noveno-1Proyecto de-aula-periodo-1-nuevo-noveno-1
Proyecto de-aula-periodo-1-nuevo-noveno-1Esteban Vega
 
Lean, aplicado a las personas y a la mejora continua
Lean, aplicado a las personas y a la mejora continuaLean, aplicado a las personas y a la mejora continua
Lean, aplicado a las personas y a la mejora continuaMaria Ruiz Romero
 
Challenge Taiwan 2016 Athlete's Guide
Challenge Taiwan 2016 Athlete's GuideChallenge Taiwan 2016 Athlete's Guide
Challenge Taiwan 2016 Athlete's GuideJeff Hung
 
JodyAllenChurch 4-21-15
JodyAllenChurch 4-21-15JodyAllenChurch 4-21-15
JodyAllenChurch 4-21-15Jody Church
 

Viewers also liked (20)

Referencia
ReferenciaReferencia
Referencia
 
Idempotent filter with simple file
Idempotent filter with simple fileIdempotent filter with simple file
Idempotent filter with simple file
 
SUJIT_NANDI_1
SUJIT_NANDI_1SUJIT_NANDI_1
SUJIT_NANDI_1
 
Método científico-01
Método científico-01Método científico-01
Método científico-01
 
PrudentialProfile_Eng
PrudentialProfile_EngPrudentialProfile_Eng
PrudentialProfile_Eng
 
How to use message properties component
How to use message properties componentHow to use message properties component
How to use message properties component
 
Mule esb stripe
Mule esb stripeMule esb stripe
Mule esb stripe
 
Maven
MavenMaven
Maven
 
Filter expression
Filter expression Filter expression
Filter expression
 
Simple web service vm
Simple web service vmSimple web service vm
Simple web service vm
 
Aguilera melania
Aguilera melaniaAguilera melania
Aguilera melania
 
Hypertrophy osteophy
Hypertrophy osteophyHypertrophy osteophy
Hypertrophy osteophy
 
Database component
Database component Database component
Database component
 
Caching and invalidating with managed store
Caching and invalidating with managed storeCaching and invalidating with managed store
Caching and invalidating with managed store
 
Jenkins3
Jenkins3Jenkins3
Jenkins3
 
Formación del profesorado. escuela 2.0
Formación del profesorado. escuela 2.0Formación del profesorado. escuela 2.0
Formación del profesorado. escuela 2.0
 
Proyecto de-aula-periodo-1-nuevo-noveno-1
Proyecto de-aula-periodo-1-nuevo-noveno-1Proyecto de-aula-periodo-1-nuevo-noveno-1
Proyecto de-aula-periodo-1-nuevo-noveno-1
 
Lean, aplicado a las personas y a la mejora continua
Lean, aplicado a las personas y a la mejora continuaLean, aplicado a las personas y a la mejora continua
Lean, aplicado a las personas y a la mejora continua
 
Challenge Taiwan 2016 Athlete's Guide
Challenge Taiwan 2016 Athlete's GuideChallenge Taiwan 2016 Athlete's Guide
Challenge Taiwan 2016 Athlete's Guide
 
JodyAllenChurch 4-21-15
JodyAllenChurch 4-21-15JodyAllenChurch 4-21-15
JodyAllenChurch 4-21-15
 

Similar to Use Until Successful Component in Mule Apps

Message properties component
Message properties component Message properties component
Message properties component Sunil Komarapu
 
Message properties component
Message properties componentMessage properties component
Message properties componentF K
 
Message properties component in mule
Message properties component in muleMessage properties component in mule
Message properties component in mulejaveed_mhd
 
How to use message properties component
How to use message properties componentHow to use message properties component
How to use message properties componentKhasim Saheb
 
Message properties component in Mule
Message properties component in MuleMessage properties component in Mule
Message properties component in MuleKhan625
 
How to use message properties component
How to use message properties componentHow to use message properties component
How to use message properties componentAnand kalla
 
How to use message properties component
How to use message properties componentHow to use message properties component
How to use message properties componentirfan1008
 
How to use message properties component
How to use message properties componentHow to use message properties component
How to use message properties componentPhaniu
 
How to use message properties component
How to use message properties componentHow to use message properties component
How to use message properties componentmdfkhan625
 
How to use message properties component
How to use message properties componentHow to use message properties component
How to use message properties componentprinceirfancivil
 
Filter expression
Filter expression Filter expression
Filter expression F K
 
Filter expression in mule
Filter expression in muleFilter expression in mule
Filter expression in mulejaveed_mhd
 
How to use message properties component
How to use message properties componentHow to use message properties component
How to use message properties componentmaheshtheapex
 

Similar to Use Until Successful Component in Mule Apps (20)

How to use splitter component
How to use splitter componentHow to use splitter component
How to use splitter component
 
How to use processor chain
How to use processor chainHow to use processor chain
How to use processor chain
 
Message properties component
Message properties component Message properties component
Message properties component
 
Message properties component
Message properties componentMessage properties component
Message properties component
 
Message properties component in mule
Message properties component in muleMessage properties component in mule
Message properties component in mule
 
How to use jms outbound endpoint
How to use jms outbound endpointHow to use jms outbound endpoint
How to use jms outbound endpoint
 
How to use message properties component
How to use message properties componentHow to use message properties component
How to use message properties component
 
Message properties component in Mule
Message properties component in MuleMessage properties component in Mule
Message properties component in Mule
 
How to use message properties component
How to use message properties componentHow to use message properties component
How to use message properties component
 
How to use message properties component
How to use message properties componentHow to use message properties component
How to use message properties component
 
How to use message properties component
How to use message properties componentHow to use message properties component
How to use message properties component
 
How to use message properties component
How to use message properties componentHow to use message properties component
How to use message properties component
 
How to use message properties component
How to use message properties componentHow to use message properties component
How to use message properties component
 
How to use jms inbound endpoint
How to use jms inbound endpointHow to use jms inbound endpoint
How to use jms inbound endpoint
 
How to use not filter
How to use not filterHow to use not filter
How to use not filter
 
How to use or filter
How to use or filterHow to use or filter
How to use or filter
 
Filter expression
Filter expression Filter expression
Filter expression
 
Filter expression
Filter expressionFilter expression
Filter expression
 
Filter expression in mule
Filter expression in muleFilter expression in mule
Filter expression in mule
 
How to use message properties component
How to use message properties componentHow to use message properties component
How to use message properties component
 

More from Sunil Komarapu

More from Sunil Komarapu (20)

WebServices
WebServicesWebServices
WebServices
 
Mule for each scope headerc ollection
Mule for each scope headerc ollectionMule for each scope headerc ollection
Mule for each scope headerc ollection
 
Mule esb Basics
Mule esb BasicsMule esb Basics
Mule esb Basics
 
Mule esb api layer
Mule esb api layerMule esb api layer
Mule esb api layer
 
Mmc rest api user groups
Mmc rest api user groupsMmc rest api user groups
Mmc rest api user groups
 
Mapping and listing with mule
Mapping and listing with muleMapping and listing with mule
Mapping and listing with mule
 
How to use expression filter
How to use expression filterHow to use expression filter
How to use expression filter
 
Data weave
Data weave Data weave
Data weave
 
Anypoint data gateway
Anypoint data gatewayAnypoint data gateway
Anypoint data gateway
 
Caching and invalidating with managed store
Caching and invalidating with managed storeCaching and invalidating with managed store
Caching and invalidating with managed store
 
Automatic documantation with mule
Automatic documantation with muleAutomatic documantation with mule
Automatic documantation with mule
 
Cache for community edition
Cache for community editionCache for community edition
Cache for community edition
 
Converting with custom transformer
Converting with custom transformerConverting with custom transformer
Converting with custom transformer
 
Creating dynamic json
Creating dynamic jsonCreating dynamic json
Creating dynamic json
 
Groovy with mule
Groovy with muleGroovy with mule
Groovy with mule
 
Jenkins
JenkinsJenkins
Jenkins
 
Jenkins2
Jenkins2Jenkins2
Jenkins2
 
Maven part 1
Maven part 1Maven part 1
Maven part 1
 
Maven ii
Maven iiMaven ii
Maven ii
 
Maven iii
Maven iiiMaven iii
Maven iii
 

Recently uploaded

Build your next Gen AI Breakthrough - April 2024
Build your next Gen AI Breakthrough - April 2024Build your next Gen AI Breakthrough - April 2024
Build your next Gen AI Breakthrough - April 2024Neo4j
 
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Patryk Bandurski
 
Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Scott Keck-Warren
 
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Alan Dix
 
Bluetooth Controlled Car with Arduino.pdf
Bluetooth Controlled Car with Arduino.pdfBluetooth Controlled Car with Arduino.pdf
Bluetooth Controlled Car with Arduino.pdfngoud9212
 
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptxMaking_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptxnull - The Open Security Community
 
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticsKotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticscarlostorres15106
 
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationBeyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationSafe Software
 
Scanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL CertsScanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL CertsRizwan Syed
 
Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Enterprise Knowledge
 
New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024
New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024
New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024BookNet Canada
 
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)Bun (KitWorks Team Study 노별마루 발표 2024.4.22)
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)Wonjun Hwang
 
CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):comworks
 
Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitecturePixlogix Infotech
 
SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge GraphSIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge GraphNeo4j
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024Scott Keck-Warren
 

Recently uploaded (20)

Build your next Gen AI Breakthrough - April 2024
Build your next Gen AI Breakthrough - April 2024Build your next Gen AI Breakthrough - April 2024
Build your next Gen AI Breakthrough - April 2024
 
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
 
Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024
 
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
 
Bluetooth Controlled Car with Arduino.pdf
Bluetooth Controlled Car with Arduino.pdfBluetooth Controlled Car with Arduino.pdf
Bluetooth Controlled Car with Arduino.pdf
 
Hot Sexy call girls in Panjabi Bagh 🔝 9953056974 🔝 Delhi escort Service
Hot Sexy call girls in Panjabi Bagh 🔝 9953056974 🔝 Delhi escort ServiceHot Sexy call girls in Panjabi Bagh 🔝 9953056974 🔝 Delhi escort Service
Hot Sexy call girls in Panjabi Bagh 🔝 9953056974 🔝 Delhi escort Service
 
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptxMaking_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
 
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticsKotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
 
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationBeyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
 
Scanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL CertsScanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL Certs
 
Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024
 
DMCC Future of Trade Web3 - Special Edition
DMCC Future of Trade Web3 - Special EditionDMCC Future of Trade Web3 - Special Edition
DMCC Future of Trade Web3 - Special Edition
 
New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024
New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024
New from BookNet Canada for 2024: BNC BiblioShare - Tech Forum 2024
 
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)Bun (KitWorks Team Study 노별마루 발표 2024.4.22)
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)
 
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptxE-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
 
CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):
 
Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC Architecture
 
The transition to renewables in India.pdf
The transition to renewables in India.pdfThe transition to renewables in India.pdf
The transition to renewables in India.pdf
 
SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge GraphSIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024
 

Use Until Successful Component in Mule Apps

  • 2. Abstract • The main motto of this PPT is how to use Until Successful component in our applications.
  • 3. Introduction • The until-successful scope processes messages through the processors within it until the process succeeds. By default, until- successful’s processing occurs asynchronously from the main flow. After passing a message into the until-successful scope, the main flow immediately regains control of the thread. However, you can configure until-successful to run synchronously relative to the main flow.
  • 5. • .mflow• <?xml version="1.0" encoding="UTF-8"?> • <mule xmlns:vm="http://www.mulesoft.org/schema/mule/vm" xmlns:jdbc-ee="http://www.mulesoft.org/schema/mule/ee/jdbc" xmlns:http="http://www.mulesoft.org/schema/mule/http" xmlns="http://www.mulesoft.org/schema/mule/core" xmlns:doc="http://www.mulesoft.org/schema/mule/documentation" xmlns:spring="http://www.springframework.org/schema/beans" version="EE-3.4.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-current.xsd • http://www.mulesoft.org/schema/mule/core http://www.mulesoft.org/schema/mule/core/current/mule.xsd • http://www.mulesoft.org/schema/mule/http http://www.mulesoft.org/schema/mule/http/current/mule-http.xsd • http://www.mulesoft.org/schema/mule/ee/jdbc http://www.mulesoft.org/schema/mule/ee/jdbc/current/mule-jdbc-ee.xsd • http://www.mulesoft.org/schema/mule/vm http://www.mulesoft.org/schema/mule/vm/current/mule-vm.xsd"> • <jdbc-ee:mssql-data-source name="MS_SQL_Data_Source" user=“****" password=“****" url="jdbc:sqlserver://localhost;databaseName=test1" transactionIsolation="UNSPECIFIED" doc:name="MS SQL Data Source"/> • <jdbc-ee:connector name="Database" dataSource-ref="MS_SQL_Data_Source" validateConnections="true" queryTimeout="-1" pollingFrequency="0" doc:name="Database"/> • <spring:beans> • <spring:bean id="Bean" name="Bean" class="org.mule.util.store.SimpleMemoryObjectStore"/> • </spring:beans> • <flow name="Database_ComponentFlow2" doc:name="Database_ComponentFlow2"> • <http:inbound-endpoint exchange-pattern="request-response" host="localhost" port="8087" path="UntilSuccessful" doc:name="HTTP"/> • <logger message="--main flow--" level="INFO" doc:name="Logger"/> • <expression-component doc:name="Expression"><![CDATA[ • sessionVars['DB_STATUS']='INITIAL'; • ]]></expression-component> • <until-successful objectStore-ref="Bean" maxRetries="5" secondsBetweenRetries="5" doc:name="Until Successful" failureExpression="#[sessionVars['DB_STATUS']!='SUCCESS']"> • <vm:outbound-endpoint exchange-pattern="request-response" path="db" doc:name="VM"/> • </until-successful> • </flow> • <flow name="Database_ComponentFlow3" doc:name="Database_ComponentFlow3"> • <vm:inbound-endpoint exchange-pattern="request-response" path="db" doc:name="VM"/> • <jdbc-ee:outbound-endpoint exchange-pattern="request-response" queryKey="select" queryTimeout="-1" connector-ref="Database" doc:name="Database"> • <jdbc-ee:query key="select" value="select * from mytable1"/> • </jdbc-ee:outbound-endpoint> • <expression-component doc:name="Expression"><![CDATA[ • sessionVars['DB_STATUS']='SUCCESS'; • ]]></expression-component> • <logger message="--success" level="INFO" doc:name="Logger"/> • </flow> • </mule>
  • 7. • Flow of execution: 1. URL to trigger the service from browser http://localhost:8087/UntilSuccessful 2. Database component connects to the specific database, executes the select query but there is no table specified in DB, hence the until successful component retries for 5 times and exit the flow.