SlideShare a Scribd company logo
1 of 17
Building Custom Adapters / Connectors
© Copyright 2014, Neudesic. All rights reserved.
Building Custom Adapters / Connectors – Overview
Goals of this session
• Understand how to build custom adapters using the Adapter Framework
• Understand how to use custom adapters inside a Neuron ESB solution
© Copyright 2014, Neudesic. All rights reserved.
Building Custom Adapters / Connectors – Objectives
• Understand the Adapter Framework architecture
• Learn how to build adapters
• Learn how to integrate and deploy custom adapters
• Learn how to debug adapters using Visual Studio .NET
© Copyright 2014, Neudesic. All rights reserved.
Building Custom Adapters / Connectors – Lesson Plan
• Adapter Framework
• Creating custom metadata
• Building a custom adapter
• Integrating custom adapters into the Neuron Explorer
• Debugging adapters at both design-time and run-time
© Copyright 2014, Neudesic. All rights reserved.
Understanding the Adapter Framework Architecture
The Neuron ESB adapter framework is a Visual Studio project, that provides a
template for building adapters to be leveraged inside of the Neuron ESB Explorer
Solution:
• ESB-Name-Adapter
• Classes
• Adapter.cs
• Inherits from ESBAdapterBase
• Contains base method overrides
• Framework helper code
• CertificateConverter.cs
• Used by a sample property to show how to perform type conversion
• Sample demonstrates how to access design time Neuron ESB Configuration
• NameAdapter.cs
• The class you edit when creating a new adapter; contains methods and properties to support the
UI property grid and adapter functionality.
© Copyright 2014, Neudesic. All rights reserved.
Understanding the Adapter Framework Architecture:
Constants and Types
Two existing constants:
• MetadataPrefix
• Used within the Neuron ESB
Explorer to identify properties
specific to the adapter1
• Properties registered with this
prefix in the adapters
constructor will appear in the
Set Property process step
• AdapterName
• Defines the “user friendly”
name that will appear in the
Adapter Registration screen
© Copyright 2014, Neudesic. All rights reserved.
Understanding the Adapter Framework Architecture:
Properties
• Defined properties are
visible on the property grid
at design-time
• Properties can be set to
either be hidden or visible
based on the values of
other properties
• Type convertors can be
used for defined properties1
• Defined properties are
displayed in the Bindings
Dialog, but can be declared
as not binable, if desired
© Copyright 2014, Neudesic. All rights reserved.
Understanding the Adapter Framework Architecture:
Constructor
• Define modes your adapter
will support
• Subscriber
• Publisher
• RequestReply
• SolicitResponse
• Define the
ESBAdapterCapabilities
• AdapterName
• MetadataPrefix
• MetadataFieldInfo1
• Any properties registered in
the constructor will appear in
the Set Property process step
© Copyright 2014, Neudesic. All rights reserved.
Understanding the Adapter Framework Architecture:
Base Methods
These methods are called from
within base adapter class methods:
• ConnectAdapter
• Validation logic and initialization of
resources used by custom adapter
• DisconnectResources
• Clean up all resources used by custom
adapter
• SendToDataSource
• Called when adapter is in any subscriber
based mode (Subscribe, Solicit
Response etc..)
• ReceiveFromDataSource
• Called when adapter is in any publisher
based mode (Publish, RequestReply
etc..)
• InitializeRequestReplyListener
• Setup of the reply listener as well as
handling the retrieval of data, as well as
creating the ESB reply message
© Copyright 2014, Neudesic. All rights reserved.
Understanding the Adapter Framework Architecture:
Send Methods
• These methods are used in
the various subscribe based
modes (Subscriber, Query,
SolicitResponse etc)
• SendToDataSource
• One way send to a back
end system, protocol,
transport etc (Subscribe)
• QueryDataSource
• Used in a Query or
SolicitResponse mode to
query information from the
a back end system and
publish the resulting data
retrieval to the Bus
© Copyright 2014, Neudesic. All rights reserved.
Understanding the Adapter Framework Architecture:
Publish Methods
• These methods are used in
the various publisher based
modes (Publish,
RequestReply etc)
• PublishMessageFromSource
• Implement logic to reach
out to data source and
then publish the resulting
data to the Bus
© Copyright 2014, Neudesic. All rights reserved.
Creating Custom Metadata
• Custom Metadata can be
added to an ESBMessage
using the IncludeMetadata
property, which is
configured on the General
tab of an adapter endpoint
in the Neuron ESB Explorer
• Custom Metadata are
provided with every
message sent or received
from Neuron ESB
• Metadata is added to a
message using the
following syntax
• MessageProperties.Add(new
NameValuePair(“PropertyName",
PropertyValue));
© Copyright 2014, Neudesic. All rights reserved.
How to Integrate Custom Adapters with
the Neuron ESB Explorer
• Compile into .NET assembly
• Copy to Adapters folder:
C:Program
FilesNeudesicNeuron ESB
v3DEFAULTAdapters
• Ensure dependencies are
installed in Adapters folder
or Neuron install folder
• Register Adapter in Neuron
ESB Explorer
© Copyright 2014, Neudesic. All rights reserved.
How to Debug Adapters at Both Design Time
and Run Time
Design Time
• Attach debugger to neuronexplorer.exe from visual studio
• Supports debugging of the adapter as well as the property grid
Run time
• Attach the debugger to esbservice.exe in order to debug adapters or the adapter
business process step
• Attach the debugger to esbhost.exe in order to debug the adapter workflow activity
Purpose
Familiarize users with the Neuron ESB Adapter Framework
Objectives
Acquaint users with following aspects custom adapters
• How to build a custom adapter
• How to integrate and deploy custom adapters
Building Custom Adapters / Connectors: Demo
To acquaint users with building a custom adapter and registering it with
Neuron ESB, this lab will guide users through the following tasks:
• Use the Adapter Framework to build a custom adapter
• Copy the custom adapter DLL to Neuron’s Directories
• Register the custom adapter with Neuron ESB
Building Custom Adapters / Connectors – Lab
© Copyright 2014, Neudesic. All rights reserved.
Building Custom Adapters / Connectors – Review
• When would you build a custom adapter?
• What does Neuron ESB provide in order to facilitate the building of custom adapters?
• How would you make an adapter publish only?
• What Base Method is used when an adapter is in subscribe mode?
• What Base Method is used when an adapter is in publisher mode?
• How do you include Metadata in an adapter?

More Related Content

Similar to Module 14 Building Custom Adapters Connectors

Introduction to neuron ESB
Introduction to neuron ESBIntroduction to neuron ESB
Introduction to neuron ESBLindsey Leggio
 
SpringOne Tour: An Introduction to Azure Spring Apps Enterprise
SpringOne Tour: An Introduction to Azure Spring Apps EnterpriseSpringOne Tour: An Introduction to Azure Spring Apps Enterprise
SpringOne Tour: An Introduction to Azure Spring Apps EnterpriseVMware Tanzu
 
Deployment and Configuration 3.7
Deployment and Configuration 3.7Deployment and Configuration 3.7
Deployment and Configuration 3.7StephenKardian
 
Asp.Net Core MVC , Razor page , Entity Framework Core
Asp.Net Core MVC , Razor page , Entity Framework CoreAsp.Net Core MVC , Razor page , Entity Framework Core
Asp.Net Core MVC , Razor page , Entity Framework Coremohamed elshafey
 
Introduction to Neuron ESB 3.7
Introduction to Neuron ESB 3.7Introduction to Neuron ESB 3.7
Introduction to Neuron ESB 3.7StephenKardian
 
JavaOne 2014 - CON2013 - Code Generation in the Java Compiler: Annotation Pro...
JavaOne 2014 - CON2013 - Code Generation in the Java Compiler: Annotation Pro...JavaOne 2014 - CON2013 - Code Generation in the Java Compiler: Annotation Pro...
JavaOne 2014 - CON2013 - Code Generation in the Java Compiler: Annotation Pro...Jorge Hidalgo
 
Spring Cloud: Why? How? What?
Spring Cloud: Why? How? What?Spring Cloud: Why? How? What?
Spring Cloud: Why? How? What?Orkhan Gasimov
 
Habitat talk at CodeMonsters Sofia, Bulgaria Nov 27 2018
Habitat talk at CodeMonsters Sofia, Bulgaria Nov 27 2018Habitat talk at CodeMonsters Sofia, Bulgaria Nov 27 2018
Habitat talk at CodeMonsters Sofia, Bulgaria Nov 27 2018Mandi Walls
 
Innovations in Sencha Tooling and Framework
Innovations in Sencha Tooling and FrameworkInnovations in Sencha Tooling and Framework
Innovations in Sencha Tooling and FrameworkSandeep Adwankar
 
Operational Security 3.7
Operational Security 3.7Operational Security 3.7
Operational Security 3.7StephenKardian
 
Understanding docker ecosystem and vulnerabilities points
Understanding docker ecosystem and vulnerabilities pointsUnderstanding docker ecosystem and vulnerabilities points
Understanding docker ecosystem and vulnerabilities pointsAbdul Khan
 
02 introduction to neuron esb
02   introduction to neuron esb02   introduction to neuron esb
02 introduction to neuron esbStephenKardian
 
Chef for Openstack
Chef for OpenstackChef for Openstack
Chef for OpenstackMohit Sethi
 
Web Sphere Administration guide – Packaging and Deploying Jee Applications
Web Sphere Administration guide – Packaging and Deploying Jee ApplicationsWeb Sphere Administration guide – Packaging and Deploying Jee Applications
Web Sphere Administration guide – Packaging and Deploying Jee ApplicationsGagandeep Singh
 
CICD for the modern data platform
CICD for the modern data platformCICD for the modern data platform
CICD for the modern data platformDavid Bojsen
 
Software design with Domain-driven design
Software design with Domain-driven design Software design with Domain-driven design
Software design with Domain-driven design Allan Mangune
 
Zure Azure PaaS Zero to Hero - DevOps training day
Zure Azure PaaS Zero to Hero - DevOps training dayZure Azure PaaS Zero to Hero - DevOps training day
Zure Azure PaaS Zero to Hero - DevOps training dayOkko Oulasvirta
 

Similar to Module 14 Building Custom Adapters Connectors (20)

Introduction to neuron ESB
Introduction to neuron ESBIntroduction to neuron ESB
Introduction to neuron ESB
 
SpringOne Tour: An Introduction to Azure Spring Apps Enterprise
SpringOne Tour: An Introduction to Azure Spring Apps EnterpriseSpringOne Tour: An Introduction to Azure Spring Apps Enterprise
SpringOne Tour: An Introduction to Azure Spring Apps Enterprise
 
Deployment and Configuration 3.7
Deployment and Configuration 3.7Deployment and Configuration 3.7
Deployment and Configuration 3.7
 
Asp.Net Core MVC , Razor page , Entity Framework Core
Asp.Net Core MVC , Razor page , Entity Framework CoreAsp.Net Core MVC , Razor page , Entity Framework Core
Asp.Net Core MVC , Razor page , Entity Framework Core
 
Introduction to Neuron ESB 3.7
Introduction to Neuron ESB 3.7Introduction to Neuron ESB 3.7
Introduction to Neuron ESB 3.7
 
JavaOne 2014 - CON2013 - Code Generation in the Java Compiler: Annotation Pro...
JavaOne 2014 - CON2013 - Code Generation in the Java Compiler: Annotation Pro...JavaOne 2014 - CON2013 - Code Generation in the Java Compiler: Annotation Pro...
JavaOne 2014 - CON2013 - Code Generation in the Java Compiler: Annotation Pro...
 
Spring Cloud: Why? How? What?
Spring Cloud: Why? How? What?Spring Cloud: Why? How? What?
Spring Cloud: Why? How? What?
 
Habitat talk at CodeMonsters Sofia, Bulgaria Nov 27 2018
Habitat talk at CodeMonsters Sofia, Bulgaria Nov 27 2018Habitat talk at CodeMonsters Sofia, Bulgaria Nov 27 2018
Habitat talk at CodeMonsters Sofia, Bulgaria Nov 27 2018
 
Innovations in Sencha Tooling and Framework
Innovations in Sencha Tooling and FrameworkInnovations in Sencha Tooling and Framework
Innovations in Sencha Tooling and Framework
 
Operational Security 3.7
Operational Security 3.7Operational Security 3.7
Operational Security 3.7
 
NServiceBus
NServiceBusNServiceBus
NServiceBus
 
Chef for openstack
Chef for openstackChef for openstack
Chef for openstack
 
Understanding docker ecosystem and vulnerabilities points
Understanding docker ecosystem and vulnerabilities pointsUnderstanding docker ecosystem and vulnerabilities points
Understanding docker ecosystem and vulnerabilities points
 
02 introduction to neuron esb
02   introduction to neuron esb02   introduction to neuron esb
02 introduction to neuron esb
 
Chef for Openstack
Chef for OpenstackChef for Openstack
Chef for Openstack
 
Power of Azure Devops
Power of Azure DevopsPower of Azure Devops
Power of Azure Devops
 
Web Sphere Administration guide – Packaging and Deploying Jee Applications
Web Sphere Administration guide – Packaging and Deploying Jee ApplicationsWeb Sphere Administration guide – Packaging and Deploying Jee Applications
Web Sphere Administration guide – Packaging and Deploying Jee Applications
 
CICD for the modern data platform
CICD for the modern data platformCICD for the modern data platform
CICD for the modern data platform
 
Software design with Domain-driven design
Software design with Domain-driven design Software design with Domain-driven design
Software design with Domain-driven design
 
Zure Azure PaaS Zero to Hero - DevOps training day
Zure Azure PaaS Zero to Hero - DevOps training dayZure Azure PaaS Zero to Hero - DevOps training day
Zure Azure PaaS Zero to Hero - DevOps training day
 

Recently uploaded

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
 
CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):comworks
 
Pigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping ElbowsPigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping ElbowsPigging Solutions
 
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 3652toLead Limited
 
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...shyamraj55
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsMark Billinghurst
 
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure serviceWhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure servicePooja Nehwal
 
Snow Chain-Integrated Tire for a Safe Drive on Winter Roads
Snow Chain-Integrated Tire for a Safe Drive on Winter RoadsSnow Chain-Integrated Tire for a Safe Drive on Winter Roads
Snow Chain-Integrated Tire for a Safe Drive on Winter RoadsHyundai Motor Group
 
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j
 
Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Allon Mureinik
 
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
 
AI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsAI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsMemoori
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slidespraypatel2
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreternaman860154
 
Install Stable Diffusion in windows machine
Install Stable Diffusion in windows machineInstall Stable Diffusion in windows machine
Install Stable Diffusion in windows machinePadma Pradeep
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesSinan KOZAK
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsEnterprise Knowledge
 
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | DelhiFULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhisoniya singh
 

Recently uploaded (20)

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...
 
Vulnerability_Management_GRC_by Sohang Sengupta.pptx
Vulnerability_Management_GRC_by Sohang Sengupta.pptxVulnerability_Management_GRC_by Sohang Sengupta.pptx
Vulnerability_Management_GRC_by Sohang Sengupta.pptx
 
CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):
 
Pigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping ElbowsPigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping Elbows
 
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
 
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR Systems
 
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure serviceWhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
 
Snow Chain-Integrated Tire for a Safe Drive on Winter Roads
Snow Chain-Integrated Tire for a Safe Drive on Winter RoadsSnow Chain-Integrated Tire for a Safe Drive on Winter Roads
Snow Chain-Integrated Tire for a Safe Drive on Winter Roads
 
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
 
Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)
 
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
 
AI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsAI as an Interface for Commercial Buildings
AI as an Interface for Commercial Buildings
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slides
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreter
 
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
 
Install Stable Diffusion in windows machine
Install Stable Diffusion in windows machineInstall Stable Diffusion in windows machine
Install Stable Diffusion in windows machine
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen Frames
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
 
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | DelhiFULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
 

Module 14 Building Custom Adapters Connectors

  • 2. © Copyright 2014, Neudesic. All rights reserved. Building Custom Adapters / Connectors – Overview Goals of this session • Understand how to build custom adapters using the Adapter Framework • Understand how to use custom adapters inside a Neuron ESB solution
  • 3. © Copyright 2014, Neudesic. All rights reserved. Building Custom Adapters / Connectors – Objectives • Understand the Adapter Framework architecture • Learn how to build adapters • Learn how to integrate and deploy custom adapters • Learn how to debug adapters using Visual Studio .NET
  • 4. © Copyright 2014, Neudesic. All rights reserved. Building Custom Adapters / Connectors – Lesson Plan • Adapter Framework • Creating custom metadata • Building a custom adapter • Integrating custom adapters into the Neuron Explorer • Debugging adapters at both design-time and run-time
  • 5. © Copyright 2014, Neudesic. All rights reserved. Understanding the Adapter Framework Architecture The Neuron ESB adapter framework is a Visual Studio project, that provides a template for building adapters to be leveraged inside of the Neuron ESB Explorer Solution: • ESB-Name-Adapter • Classes • Adapter.cs • Inherits from ESBAdapterBase • Contains base method overrides • Framework helper code • CertificateConverter.cs • Used by a sample property to show how to perform type conversion • Sample demonstrates how to access design time Neuron ESB Configuration • NameAdapter.cs • The class you edit when creating a new adapter; contains methods and properties to support the UI property grid and adapter functionality.
  • 6. © Copyright 2014, Neudesic. All rights reserved. Understanding the Adapter Framework Architecture: Constants and Types Two existing constants: • MetadataPrefix • Used within the Neuron ESB Explorer to identify properties specific to the adapter1 • Properties registered with this prefix in the adapters constructor will appear in the Set Property process step • AdapterName • Defines the “user friendly” name that will appear in the Adapter Registration screen
  • 7. © Copyright 2014, Neudesic. All rights reserved. Understanding the Adapter Framework Architecture: Properties • Defined properties are visible on the property grid at design-time • Properties can be set to either be hidden or visible based on the values of other properties • Type convertors can be used for defined properties1 • Defined properties are displayed in the Bindings Dialog, but can be declared as not binable, if desired
  • 8. © Copyright 2014, Neudesic. All rights reserved. Understanding the Adapter Framework Architecture: Constructor • Define modes your adapter will support • Subscriber • Publisher • RequestReply • SolicitResponse • Define the ESBAdapterCapabilities • AdapterName • MetadataPrefix • MetadataFieldInfo1 • Any properties registered in the constructor will appear in the Set Property process step
  • 9. © Copyright 2014, Neudesic. All rights reserved. Understanding the Adapter Framework Architecture: Base Methods These methods are called from within base adapter class methods: • ConnectAdapter • Validation logic and initialization of resources used by custom adapter • DisconnectResources • Clean up all resources used by custom adapter • SendToDataSource • Called when adapter is in any subscriber based mode (Subscribe, Solicit Response etc..) • ReceiveFromDataSource • Called when adapter is in any publisher based mode (Publish, RequestReply etc..) • InitializeRequestReplyListener • Setup of the reply listener as well as handling the retrieval of data, as well as creating the ESB reply message
  • 10. © Copyright 2014, Neudesic. All rights reserved. Understanding the Adapter Framework Architecture: Send Methods • These methods are used in the various subscribe based modes (Subscriber, Query, SolicitResponse etc) • SendToDataSource • One way send to a back end system, protocol, transport etc (Subscribe) • QueryDataSource • Used in a Query or SolicitResponse mode to query information from the a back end system and publish the resulting data retrieval to the Bus
  • 11. © Copyright 2014, Neudesic. All rights reserved. Understanding the Adapter Framework Architecture: Publish Methods • These methods are used in the various publisher based modes (Publish, RequestReply etc) • PublishMessageFromSource • Implement logic to reach out to data source and then publish the resulting data to the Bus
  • 12. © Copyright 2014, Neudesic. All rights reserved. Creating Custom Metadata • Custom Metadata can be added to an ESBMessage using the IncludeMetadata property, which is configured on the General tab of an adapter endpoint in the Neuron ESB Explorer • Custom Metadata are provided with every message sent or received from Neuron ESB • Metadata is added to a message using the following syntax • MessageProperties.Add(new NameValuePair(“PropertyName", PropertyValue));
  • 13. © Copyright 2014, Neudesic. All rights reserved. How to Integrate Custom Adapters with the Neuron ESB Explorer • Compile into .NET assembly • Copy to Adapters folder: C:Program FilesNeudesicNeuron ESB v3DEFAULTAdapters • Ensure dependencies are installed in Adapters folder or Neuron install folder • Register Adapter in Neuron ESB Explorer
  • 14. © Copyright 2014, Neudesic. All rights reserved. How to Debug Adapters at Both Design Time and Run Time Design Time • Attach debugger to neuronexplorer.exe from visual studio • Supports debugging of the adapter as well as the property grid Run time • Attach the debugger to esbservice.exe in order to debug adapters or the adapter business process step • Attach the debugger to esbhost.exe in order to debug the adapter workflow activity
  • 15. Purpose Familiarize users with the Neuron ESB Adapter Framework Objectives Acquaint users with following aspects custom adapters • How to build a custom adapter • How to integrate and deploy custom adapters Building Custom Adapters / Connectors: Demo
  • 16. To acquaint users with building a custom adapter and registering it with Neuron ESB, this lab will guide users through the following tasks: • Use the Adapter Framework to build a custom adapter • Copy the custom adapter DLL to Neuron’s Directories • Register the custom adapter with Neuron ESB Building Custom Adapters / Connectors – Lab
  • 17. © Copyright 2014, Neudesic. All rights reserved. Building Custom Adapters / Connectors – Review • When would you build a custom adapter? • What does Neuron ESB provide in order to facilitate the building of custom adapters? • How would you make an adapter publish only? • What Base Method is used when an adapter is in subscribe mode? • What Base Method is used when an adapter is in publisher mode? • How do you include Metadata in an adapter?

Editor's Notes

  1. The MetadataPrefix is the prefix used for properties in both the data.Context.SetProperty() and data.Context.GetProperty() methods.
  2. Type convertors are useful when you wish to populate a dropdown list in the properties grid
  3. MetadataFieldInfo is a comma delimited string with the syntax <prefix>.<property name>:<description>