Git Product home page Git Product logo

skillsfundingagency.dfc-api-lmi-transformation's Introduction

dfc-api-lmi-transformation

Introduction

This function app is used to retrieve LMI data from the Graph database using the Content API. This function app collates the LMI data and transforms it into job-group oriented data which is then stored in a local Cosmos cache.

Getting Started

This is a self-contained Visual Studio 2019 solution containing a number of projects (azure function app with associated unit test project).

Installing

Clone the project and open the solution in Visual Studio 2019.

List of dependencies

Item Purpose
DFC.Compui.Cosmos Cosmos repository nuget
DFC.Content.Pkg.Netcore Content API client nuget
DFC.Compui.Subscriptions Composite UI Subscription API client

Local Config Files

Once you have cloned the public repo you need to remove the -template part from the configuration file names listed below.

Location Filename Rename to
DFC.Api.Lmi.Transformation local.settings-template.json local.settings.json

Configuring to run locally

The project contains a "local.settings-template.json" file which contains appsettings for the function app project. To use this file, copy it to "local.settings.json" and edit and replace the configuration item values with values suitable for your environment.

By default, the appsettings include local Azure Cosmos Emulator configurations using the well known configuration values for Content Page storage and. These may be changed to suit your environment if you are not using the Azure Cosmos Emulator.

This app uses the Content API to retrieve LMI data from the Graph database.

This app also subscribes to change events in Event Grid. To make use of it you will need to configure the Subscriptions service which will require an APIM API key for that service.

App Settings

App setting Value
ApiSuffix dev
Configuration__CosmosDbConnections__LmiTransformation__AccessKey CosmosAccessKey
Configuration__CosmosDbConnections__LmiTransformation__EndpointUrl CosmosEndpoint
Configuration__CosmosDbConnections__LmiTransformation__DatabaseId dfc-api-lmi-transformation
Configuration__CosmosDbConnections__LmiTransformation__CollectionId job-groups
Configuration__CosmosDbConnections__LmiTransformation__PartitionKey /PartitionKey
CmsApiClientOptions__BaseAddress https://dfc-dev-api-cont-fa.azurewebsites.net/api/execute/
CmsApiClientOptions__SummaryEndpoint lmisoc
SubscriptionSettings__Endpoint ThisFunctionAppBaseAddress/lmi/webhook
SubscriptionSettings__SubscriptionServiceEndpoint SubscriptionServiceEndpoint
SubscriptionSettings__ApiKey SubscriptionServiceApimKey
SubscriptionSettings__Filter__BeginsWith /dfc-api-lmi-import/
SubscriptionSettings__Filter__IncludeEventTypes__0 published
EventGridClientOptions__TopicEndpoint Event grid topic endpoint
EventGridClientOptions__SubjectPrefix Message subject prefix
EventGridClientOptions__TopicKey Event grid topic key
EventGridClientOptions__ApiEndpoint Content API endpoint

Running locally

To run this product locally, you will need to configure the list of dependencies, once configured and the configuration files updated, it should be F5 to run and debug locally.

To run the project, start the function app. Once running, await the timer to start the timer trigger.

Deployments

This function app will be deployed as an individual stand-alone deployment.

Built With

  • Microsoft Visual Studio 2019
  • .Net Core 3.1

References

Please refer to https://github.com/SkillsFundingAgency/dfc-digital for additional instructions on configuring individual components like Cosmos.

skillsfundingagency.dfc-api-lmi-transformation's People

Contributors

iancrisp avatar mofais avatar mofaisal123 avatar olusola-adio avatar syatessoftware avatar trivedihimanshu avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.