Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

Version 1 Next »

Overview

This document describes all the steps to be followed to set up a new instance of Finance. When a new State is to be set up, there are some activities to be executed in a defined order. Setting up an instance of an application server and configuration changes etc are a few of the key activities.

  • Centralised Server hosting all the ULBs within a state

  • All ULBs access the software over API calls.

  • Uniform code base supporting all the ULBs for the state. City-specific changes are maintained using client-specific implementation repositories.

  • A separate schema for each ULB in the database.

Prerequisites

  • Prior Knowledge of Java/J2EE.

  • Prior Knowledge of Spring and Hibernate

  • Prior knowledge of Maven

  • Prior knowledge of Git.

Install the below version of the software in local machine

  • Maven v3.2.x

  • PostgreSQL v9.6

  • JBoss Wildfly v11.x

  • Git 2.8.3

  • JDK 8 update 112 or higher

Configurations and Setup

The Co-existence repository is the base repository for the finance product and the client specific data needs to be defined in the Client implementation repository

How to set up a client implementation repository

  1. Branch out and create a client implementation repository from Client implementation repository to keep client specific data and configurations.

  2. Any configurations and data specific to the client should be added in the client repository.

Application Configuration

Setup schema based multi tenant database

Finance co-existence service uses schema based multi tenancy i.e . multi-tenancy with a single multi-tenant database. The following are the configuration changes to setup schema based multi tenant database.

The configurations to be done either in the /egov-egi/src/main/resources/config/application-config.properties or in the ${HOME_DIR}/wildfly-11.0.0.Final/modules/system/layers/base/org/egov/settings/main/config/egov-erp-override.properties

  • Enable multi tenancy by enabling the following property

multitenancy.enabled=true
  • The state schema is configured by adding the following property

statewide.schema.name=generic

generic is the statewide schema name.

Default schema name and the state wide schema name should be same. Default schema name is configured using the following property

default.schema.name=generic

CurrentTenantIdentifierResolver will take the default schema if no schema is present in the ApplicationThreadLocals.

  • Each ULB is enabled by adding a schema name and domain name. Schema names should follow a naming standard, It should be the same as that of the city name.

  • Each ULB can be configured by adding an entry like tenant.<domain_name>=schema_name (city_name)

Ex:

tenant.citya.egovernments.org=citya
tenant.cityb.egovernments.org=cityb
  • Insert data into eg_city, in the city table, domain URL value should be the same as configured tenant domain_name

Ex:

For citya, domain url should be citya.egovernments.org
For cityb, domain url should be cityb.egovernments.org

DB migration settings

  • Enable flyway db migration by adding the following property. The SQL scripts will be executed if the below property is enabled.

db.migration.enabled=true
  • The following are the SQL file locations to pick and execute according to the properties configured in the properties file.

  • The SQL files present in the following locations will be executed on all the schemas present in the database.

db.flyway.main.migration.file.path=classpath:/db/migration/main/
  • Sample scripts will be executed if dev.mode=true enabled.

db.flyway.sample.migration.file.path=classpath:/db/migration/sample/
  • City wise scripts will be executed on the city’s schema

db.flyway.tenant.migration.file.path=classpath:/db/migration/%s/
  • State wide scripts will be executed on the configured statewide schema if the state wide migration is enabled.

statewide.schema.name=generic
statewide.migration.required=true
db.flyway.statewide.migration.file.path=classpath:/db/migration/statewide/

System Integration User Details Configuration

Add the following System integrator user details

si.microservice.user=SIFINANCE
si.microservice.password=sifinance123@
si.microservice.usertype=SYSTEM
si.microservice.scope=read
si.microservice.granttype=password

Elastic Dashboard Configuration

Enable/Disable event to push the created/updated bill/vouchers to ES indexer

finance.esk.dashboard.event.enabled=false

Micro-service integration configuration

Finance service reads data from multiple other micro services. The following are the different services finance system reads data from. Update the domain URL of the respective service based on the service where it is running.

egov.default.services.endpoint=https://egov-micro-dev.egovernments.org/
egov.hrms.service.endpoint=https://egov-micro-dev.egovernments.org/
egov.accesscontrol.service.endpoint=https://egov-micro-dev.egovernments.org/
egov.hr.masters.service.endpoint=https://egov-micro-dev.egovernments.org/
egov.user.service.endpoint=https://egov-micro-dev.egovernments.org/
egov.common.masters.endpoint=https://egov-micro-dev.egovernments.org/
egov.billing.service.endpoint=https://egov-micro-dev.egovernments.org/
egov.collection.service.endpoint=https://egov-micro-dev.egovernments.org/
egov.egf.master.service.endpoint=https://egov-micro-dev.egovernments.org/
egov.egf.instrument.service.endpoint=https://egov-micro-dev.egovernments.org/
egov.mdms.service.endpoint=https://egov-micro-dev.egovernments.org/
egov.indexer.service.endpoint=https://egov-micro-dev.egovernments.org/
egov.filestore.service.endpoint=https://egov-micro-dev.egovernments.org/

Changes required to setup workspace in local machine

  1. Setup Finance service workspace by following the instructions provided in README.

  2. After set up is done, make the changes to the host file in the local machine, by mapping the domain URLs with a local IP address and save the changes. Restart your local machine to make the host mapping effective.

$ vim /etc/hosts

127.0.0.1 egov-micro-dev.egovernments.org

MDMS Configuration

Department, Designation, BusinessServiceMapping, TaxHeadMasterGlCodeMapping, InstrumentGLcodeMapping, AccountCodeTemplate, FinanceInstrumentStatusMapping, tenants (Finance), OnlineGLCodeMapping, BankAccountServiceMapping

  • Define all the departments in the Departments json

  • Define all the designations in the Designations json

  • Configure finance tenants in the Citymodule json to enable finance module in the ULB

{
      "module": "Finance",
      "code": "Finance",
      "tenants": [
        {
          "code": "pb.jalandhar"
        },
        {
          "code": "pb.nawanshahr"
        }
      ]
    },
  • Define business services mapping in the Business Service Mapping json to integrate different business services like Property Tax, Trade License and FireNOC etc with Finance System and to post vouchers like demand and receipt vouchers. Enabling/disabling voucher posting and different masters for voucher can be configured here.

  • Define the Tax head and instrument glcode mappings in the Account Head Mapping json. This file contains each tax head wise glcode mapping and each instrument wise glcode mappings.

  • Different instrument statuses can be defined in the Instrument Status Mapping json file.

  • Different types of contractor bill templates are defined in the AccountCode Template file. These templates will be used in the contractor bill creation screen to auto populate the account codes.

  • Service wise glcode mapping for the online instrument type for the particular ulb is defined in the Online Instrument Type json.

  • Define the business service wise bank account mappings in the BankAccount Service Mapping json file. These details to be configured city wise as the bank details are specific to a city.

Add the property and update the MDMS search URL, egov.services.master.mdms.search.url=/egov-mdms-service/v1/_search in application-config.properties file or egov-erp-override.properties file

References


  • No labels

0 Comments

You are not logged in. Any changes you make will be marked as anonymous. You may want to Log In if you already have an account.