Hi Arnold, You are right, that would be easier to have a rule which creates short names from the job names. I was thinking on this, but unfortunately did not find the reliable algorithm to automatically create unique and talkative enough names. There is another point though, that I wanted to control the short names because the display name you can update later, but the short name you can not. For the custom jobs you can of course add a script with an automatic short name generator to db/changelog/tenant/final-changelog-tenant.xml before the non-null constraint is added.
Thank you, Marta > On 29 Aug 2024, at 16:15, Arnold Galovics <arn...@apache.org> wrote: > > Hi Marta, > > I like the idea of having a short name for the jobs, thanks for that. > > Would it be possible though to generate some default short names from the > jobs' regular names automatically instead of writing custom liquibase > scripts? > > Thanks. > Best, > ARnold > > On Thu, Aug 29, 2024 at 4:12 PM Márta Jankovics <marta.jankov...@dpc.hu > <mailto:marta.jankov...@dpc.hu>> wrote: >> Hi All, >> >> I would like to notify you that with this PR >> https://github.com/apache/fineract/pull/4037 a new mandatory, length 8, >> unique field: short_name was added to the job table. >> This is great because now we have an identifier for the jobs, which are not >> auto-incremented, and are static, regardless how the system has been >> initialised. >> You are now able to use this new field, instead of the primary key, to >> address the jobs in all known job related API endpoints. >> >> GET /v1/jobs/short-name/{shortName} >> GET /v1/jobs/short-name/{shortName}/runhistory >> POST /v1/jobs/short-name/{shortName} >> PUT /v1/jobs/short-name/{shortName} >> >> I’ve filled this new field for the existing jobs. But if you have a custom >> job, which is not contributed back to the community, then you should specify >> the short_name, and add it to the liquibase script. >> >> The short_name has a naming convention. First part is like a namespace, >> second part is specific for the job, separated by _. >> Example: ACC_AATR (Add Accrual Transactions) >> >> Top namespaces: >> LA: Loan Account >> SA: Savings Account >> SH: Shares >> ACC: Accounting >> STI: Standing Instruction >> EM: Email sending >> SMS: Sms sending >> BDT: Business Date >> COM: Commands >> EXE: External Events >> >> Thank you, >> Marta