FX Core Lib: Simplifying FX Service Development
Categories:
FX Core Lib: Simplifying FX Service Development
The FX Helper package, available through the fx_ef
library, offers an array of convenient functions that streamline the development of FX services. This guide walks you through the different ways you can leverage this package to access service configurations, parameters, secrets, and state within your service logic.
Accessing Package Configuration
Retrieve configuration values that influence your service’s behavior by using the context.config.get()
method:
|
|
Accessing Execution Parameters
Access parameters that affect your service’s execution using the context.params.get()
method:
|
|
Accessing Secrets
Easily access secrets stored on platform, project, or package levels with the context.secrets.get()
method:
|
|
Setting Secrets
Set secrets on project and platform levels using the context.secrets.set()
method:
|
|
Accessing Package ID and Name
Retrieve your package’s ID and name using the context.package.id
and context.package.name
attributes:
|
|
Accessing and Updating Package State
Manage your service’s execution state with context.state.get()
and context.state.put()
:
|
|
Logging
Leverage logging capabilities at different levels - DEBUG, INFO (default), ERROR, WARNING, and CRITICAL:
|
|
Scheduling Retry of Service Execution
Use the context.scheduler.retry()
method to schedule the next execution of your service from within your script:
|
|
This guide provides insight into the powerful functionalities offered by the fx_ef
library, making FX service development more efficient and intuitive. These tools empower you to create responsive and feature-rich FX services with ease.
Feedback
Was this page helpful?
Glad to hear it! Please tell us how we can improve.
Sorry to hear that. Please tell us how we can improve.