Skip to content

Releases: Chinlinlee/Burni

v2.8.0

10 Oct 03:34
Compare
Choose a tag to compare

Changelog

All notable changes to this project will be documented in this file. See standard-version for commit guidelines.

2.8.0 (2023-10-10)

Features

  • add _pretty in BaseFhirApiService (3f9524b)
  • add "GET" method handler of bundle transaction (3158637)
  • add env that not check ref association when delete (e456501)
  • bundle transaction prototype (918b469)
  • chain search of bundle special params (000540f)
  • change unique way of bundle (6682fd3)
  • check is referenced when delete (ef49215)
  • search interaction for bundle transaction (3b0ed0f)
  • skip special bundle parameters of chain search (bb393cf)
  • support bundle message, composition search (10bdedf)
  • update usage of node fhir validator to 1.1.0 (c1aafe8)
  • upgrade code of fhir validator v1.0.0 (e76139e)
  • use mongoose validation when validator disable (4e12601)
  • validate contained when validator disable (3cd87d5)

Bug Fixes

  • _format not working (03bb722)
  • #6 (f66d627)
  • cannot use uuid value in reference type (7d9eae2)
  • date format incorrect (7d60ee1)
  • delete return wrong object (23c8de3)
  • fullUrl cannot be a version specific reference (f09ca1f)
  • fullUrl of history not complete (519e1d6)
  • history reset after deleting (6d0da73)
  • incorrect condition (6c6a40f)
  • incorrect property of updateResult when failure (dfeea59)
  • incorrect require file (51369f8)
  • incorrect require location (fbfd78f)
  • incorrect require location (4cb1391)
  • incorrect statusCode of deletion (153ddb3)
  • incorrect variable usage (e2b80dd)
  • Location not complete of create and update (adf9d1f)
  • missing require dep (610b58a)
  • not convert to XML when request accept is XML (85501a5)
  • not response when validation failure (7e08340)
  • refNode.value.split is not a function (43c9212)
  • response content-type is not XML of uploading XML (fe1982d)
  • URL of reference type search (e2d56c8)
  • variable not defined (5a707c8)
  • xml is not working (1819305)

Refactor

  • Extract APIs (create, delete, history, read, search, update, vread) into service classes

v2.7.2

12 Nov 17:28
Compare
Choose a tag to compare

Changelog

All notable changes to this project will be documented in this file. See standard-version for commit guidelines.

2.7.2 (2022-11-12)

Bug Fixes

  • return empty body when pass validation (fc55319)

v2.7.1

12 Nov 16:39
Compare
Choose a tag to compare

Changelog

All notable changes to this project will be documented in this file. See standard-version for commit guidelines.

2.7.1 (2022-11-12)

Bug Fixes

  • ci: cannot build docker image (f8afb34)

v2.7.0

12 Nov 15:32
Compare
Choose a tag to compare

v2.7.0

Changelog

All notable changes to this project will be documented in this file. See standard-version for commit guidelines.

2.7.0 (2022-11-12)

Features

  • add _pretty parameter (a5fcf45)

  • add _total parameter (fc8eb70)

  • add layout for logger (65b90db)

  • change token auth into plugin (3b9ecfd)

  • change validator storepath;add empty profile (36ea1e1)

    • BREAKING CHANGE: Deleted
  • configure auth source of mongo manually (3d7799e)

  • generate search parameter of date choiceType (abdfb53)

    • If field is not in StructureDefinition, that might be choice type
      1. map every name of date type
      2. check if field is in StructureDefinition
      3. If true, refresh the search fields
  • java FHIR validator instead of C# (3c10036)

  • move storedID variable to if block (cb84d14)

    • When disable ENABLE_CHECK_ALL_RESOURCE_ID, the storedID unused that will cause the performance problem
  • move FHIR XML to JSON into route.js (5133ae1)

    • Use before plugin loading,
      for converting XML FHIR content to JSON and use in the plugin
    • Remove function of converting XML to JSON
      in each resourceType's entry route
    • avoid convert again
  • remove unique of index of id (3fc33c1)

    • The id in FHIRStoredId collection may have duplicate id when disable
      ENABLE_CHECK_ALL_RESOURCE_ID
  • separate check reference process to plugin (7558cd7)

    • Configurations
      • In plugins/config.js
      • Set enable and before to true of checkReference
  • support chain search (3cb4c6f)

    • The chain search can search parameter's type is
      reference like organization.name in Patient
    • This will join Organization resource and search
      with name in Organization and return orginal Patient resource
    • Note: WIP
  • update chain search logic (687978b)

    1. When search coming, check parameter is chain or not

    chain rule
    Have dot
    the parameter must be reference type

    1. If is chain, combine the mongodb query
    2. support colon chain parameter
  • update chained parameter logic (a7b6cfa)

    1. Use dot to split to know how depth of chain parameter
    2. If colon (:) present, that mean user specific the resource type of current reference parameter
    3. Else, record all information (resourceType, searchParameter, searchFieldInResource) of resource type from current reference parameter
    4. If multiple dot(.) in parameter and it is reference type search parameter record its information(present above, parent's key, key)
  • use _doc instead of toObject in getFHIRField (19b05e5)

    • The _doc is mongoose document that we can directly
      set value of property
    • The toObject convert mongoose document to object
      again, that cause performance issue
  • use countDocument to check doc is exist (ec60904)

    • The countDocument is faster than findOne to check the doc is exist
    • Change doUpdateData, doInsertData into
      async funtion instead return new Promise
  • use joi control _pretty, _total (2029166)

    • Convert _pretty to boolean, and default to true
    • Check _total value, and default to "estimate"
  • use jsonpath, countDocuments (7f88750)

    • Use jsonpath instead of searching reference field

    Fix the problem with reference.reference field cannot parse
    For better coding way

    • Remove checkReference in apiService

    unused

    • Use countDocuments instead of findOne for better performance

    findOne will return full document when exist we just need to check document is exist countDocuments may faster

  • use uuid package to validate reference str (78e26bb)

    • Use uuid instead of RegExp

    For supporting multiple uuid versions v1, v3, v4, v5

  • validation when op (create, update) (97d5414)

    • refactor, move getValidateResult into models/FHIR/fhir-validator
    • add variable to store user.checkTokenPermission and
      using it in condition
    • remove all filename logs, because log4js already log filename

Bug Fixes

  • accept header undefiend cannot use include (aeee9ff)

    • Add empty default value for accept header
  • cannot access http csharp validator (2593f98)

    • Deleted
  • duplicate doc when use chainedParam (179c3b9)

    • Group by _id and replace root with document
  • field collection is missing when store (817fed6)

    • The mongoose is not allow the field name collection
    • myCollection is missing because of
      I rename the collection into myCollection,
      but processing flow is not complete cause the bug
    • Add renameCollectionFieldName in apiService

    Before storing, rename collection into myCollection in resource

    • Use cloned req.body to store

    The req.body is polluting by some funcitons with mongoose,
    it will turn into mongoose document

    • Deps
      • Add jsonpath package
  • field contains .as(type) not generate (b17e408)

    • The field name contains .as(type) of search parameters not generate search function
  • fix mongodb auth parameter (97224e3)

    • Change 'user' field to 'username’
  • incorrect log information in read, update (c88b296)

  • increase request body size limit (ebc3a79)

  • limit of json body not working (6674105)

    • limit of bodyParser.json not
      overwrite original limit of json body
    • Move limit option into every express.json() functions
  • mongoose authSource param not working (501129a)

    • authSource is not in auth property, It should in toplevel property like { authSource: "admin" }
  • not accept meta and text field (15ee9b8)

    • Remove delete pre-process
  • not default json format response (ace8422)

    • Use exactly match of accept header to determine is XML format
  • not response content with XML format (b767df5)

    • The item will be mongoose object that cannot convert to XML
    • Use item._doc to get the JSON to fix
  • remove unsupported mongoose parameters (c081573)

  • token.replace is not a function (4b87e27)

    • Use empty string replace false boolean of lodash default value
  • typo (86acd98)

  • typo (8568e0d)

  • update mongoose package (921769a)

中文版

WIP...

v2.6.0

07 Mar 12:39
Compare
Choose a tag to compare

2.6.0 (2022-03-07)

Features

  • add logger (ce60bf2)

    • use log4js for logger
  • add logger in FHIRAPI and refactor resFunc (bff8643)

    • extract resFunc to global variable to reduce complexity
    • add warn logger
  • add new method for $validate API (5b82908)

    • add fhir-validator
      • add refreshResourceResolver to call C# API to reload profiles
      • add storeValidationFile to store StructureDefinition, ValueSet, CodeSystem
      • add fetchValueSet to get ValueSet resource by URL
      • add fetchCodeSystem to get CodeSystem resource by URL
      • add validateByProfile to validate resource by specific profile URL in URL path
      • add validateByMetaProfile to validate resource by profiles URL from meta.profile
    • add FHIRValidationFiles MongoDB schema to store data about validation files
    • add schedule to update validation files in MongoDB
    • The validation workflow note can retrieve from
  • remove custom fhir.js and $validate API (867e2b4)

    • The fhir.js is not completly to do
      validation, need to find another solution
    • implement validator by self is too hard...
  • resource interaction in metadata from config (9c59674)

    • The interation of resource in metadata correspond to config

Bug Fixes

  • empty array entry of Bundle present (fddf2f6)
    • refact unique to bundle function
    • replace condition of total to entry length. I think check entry length better than total

中文版

功能

  • 新增 logger (ce60bf2)
    • 使用 log4js 作為 logger 的工具
  • 在 FHIRAPI 新增 logger 以及重構 resFunc (bff8643)
    • 將 resFunc 變成全域變數,減少 Function 內的複雜度
    • 新增 warn logger
  • 新增新的方法處理 $validate API (5b82908)
    • 新增 fhir-validator
      • 新增refreshResourceResolver呼叫 C# API讓Server重新讀取profiles
      • 新增storedValidationFile 儲存StructureDefinition, ValueSet,
        CodeSystem
      • 新增 fetchValueSet 將指定 URL 的 ValueSet 爬下來並轉為JSON
      • 新增 fetchCodeSystem 將指定 URL 的 CodeSystem 爬下來並轉為JSON
      • 新增 validateByProfile 使用在URL指定的 profile 驗證 resource
      • 新增 validateByMetaProfile 使用 resource 當中的 meta.profile 進行驗證
  • 移除自己模改的 fhir.js 以及 $validate API (867e2b4)
    • javascript 實作的 fhir.js 還未有完整的驗證功能,需要找其他的替代方案
    • 自己實作FHIR 驗證器實在是太難了....
  • 新增使用config產生metadata中resource的interaction功能 (9c59674)

Bug修正

  • 修正 Bundle 中的 entry 回傳空陣列(fddf2f6)
    • 重構 unique 功能移至建立 bundle 的 function
    • 更改移除 bundle entry; total 的判斷,我認為使用 bundle.entry 的長度判斷比total更好

v2.5.0

24 Feb 07:19
Compare
Choose a tag to compare

2.5.0 (2022-02-24)

Features

  • * wildcard for _include and revinclude (0361c7d)
  • add custom error class and _include param (44af66f)
  • add search mode in entry and change url (2a9d2e8)
  • handle _revinclude param in search API (eb1e37c)
  • api-generate: add apidoc in create api (a83808b)
  • api-generate: add apidoc in update api (14fd32e)
  • api-generator: add read api doc comment (e155de7)
  • apidoc: delete, swagger try in redoc, resource filter, layout (bc57589)
  • apidoc: add search api doc (cc770a2)
  • docs: reload page when click resource button (d09547d)
  • schema: completly validate reference string (d0a615c)

Bug Fixes

  • cannot access even disable the token control (2434a8e)
  • cofused condition set search mode is include (92e7659)
  • duplicate resource in bundle entry (1567a12)
  • incorrect name in premision of delete API (d9a4f9a)
  • infinite loop in reinlcude and include (62ce4a0)
  • missing Last-Modified in headers (1fc14df)
  • missing handle error coming from express (2fe878e)
  • not allowed #id contained reference id (381fc0b)
  • token permission not working (750709f)

v2.4.0

07 Feb 14:34
Compare
Choose a tag to compare

2.4.0 (2022-02-07)

Features

  • add all resources definition json files (0c34d96)
  • add condition delete API (bf4b3a0)
  • add general string query builder (7cb186e)
  • add modifier of type of string and comma $or query in address query (f12fca5)
  • change validateContained to async funtion (0a30cd1)
  • change count of searching result method (2b9751b)
  • handle comma , query and esacaping \, and \| (1a5bef6)
  • handle expression where(type='${type}') in the reference type search parameter (17fe9b2)
  • separate parameter search functions to single file (695219e)
  • api-generator: add getPrefixCodeString and change TokenParameter method (a3a761b)
  • api-generator: add and change feature (de51fea)
  • api-generator: add type of quantity search parameter (0aab652)
  • api-generator: new way to handle all data types of search parameter, change token query build and add jsdoc comments to methods (c3d9e24)
  • mongodb: change connection url (4b97705)
  • quantityQuery: hanlde escaping \ and using $and to handle query value (f49edeb)
  • queryBuild: add new query builder about date (468ad6e)
  • schema: support unicode string (597aba5)

Bug Fixes

  • error of eslint rules (1624240)
  • eslint rule semi, no-async-promise-executor (38ad62d)
  • generate incorrect back bone element schema (0665447)
  • incorrect check is number condition in numberQuery (8e29a16)
  • incorrect connection url (2249d4a)
  • incorrect shard collection process flow (1f853ce)
  • missing :exact in object name (5201ec1)
  • not allow array field=1&field=2 parameter (cbda323)
  • api,create: model save() method not using await (cab23f0)
  • api,update: isDocExist return empty object (630ac3d)
  • api,update: missing Last-modified in header (45f4c2a)
  • model not load all dependencis type (2d102d8)
  • resources-generator: incorrect require path (dc6b62b)
  • resources-generator: mongoose circular dependency warnings (d02a4ba)

v2.3.1

23 Jan 08:01
Compare
Choose a tag to compare

2.3.1 (2022-01-23)

Bug Fixes

  • incorrect data type of Date when choice type[x] (d32cb2d)

v2.3.0

22 Jan 15:57
Compare
Choose a tag to compare

2.3.0 (2022-01-22)

Features

  • add shardKey config in history schema (419bae7)

Bug Fixes

  • remove choice type [x] generate in schema (f3a35b7)
  • remove choice type [x] generate in schema (309ce6b)

v2.2.0

21 Jan 14:54
Compare
Choose a tag to compare

Changelog

All notable changes to this project will be documented in this file. See standard-version for commit guidelines.

2.2.0 (2022-01-21)

Features

  • add _lastUpdated search parameter (6ab6f04)
  • add contained field in schema (7712dc2)
  • add check reference switch (9c5e860)
  • add condition that whether response item in body or not (807154b)
  • add condition whether check the stored resource ID (d21442a)
  • add last-modified in headers (25c84cb)
  • add refresh_token (e30ac2c)
  • apply specific rule with List resource (b688eb2)
  • refresh_token api (095efb7)
  • remove method that response empty when create and update (56f8358)
  • shard database and every collections when starting up (c58c8a4)

Bug Fixes

  • _doc is not function, (f6a2678)
  • history mongoose response document will fill undefined in not exist field (7d7bf85)
  • resource.meta incorrect after updating (9439334)
  • backBoneElement not use getter with mongoose schema (0776c38)
  • FHIR package not import (ce1a85b)
  • generate incorrect code at numer query search parametr (789b435)
  • generate incorrect search field of type of token (e377476)
  • incorrect argument name err is not defined (9bc9ac9)
  • incorrect countDocuments collection in history (8a7cb9b)
  • incorrect date format (7788eb9)
  • incorrect format of metadata rest (2f6ec60)
  • incorrect log when error occur (2a60bcc)
  • incorrect name of type, is instant not instance (e876ce6)
  • incorrect variable name (d7a834d)
  • missing Location in headers when statu code 201 (8092545)
  • missing condition that server is enable token auth (d335756)
  • missing delete __v in doc (fe0401e)
  • missing placeholder in search input (04c2403)
  • missing variable name and require modules (d40cf7f)
  • mongoose response document will fill undefined in not exist field (fa5a73d)
  • not handle convert XML to JSON when content is XML which using PUT (543f7b7)
  • port is not defiend (2d8fc29)
  • put list missing double quote (68d4ad0)
  • resolve body in a request is empty when content-type is XML (d7eabc3)
  • resolve problem that port with bundle url and http server is same (d50e66c)
  • resolve that input is null the getter will response the default value (eb9e361)
  • resolve that missing store history data when PUT recovery data after deleting (12188cc)
  • resolve the delete not exist resource return incorrect HTTP response code (f63be17)
  • resolve the problem that time of primitive type can't store in schema (672fb63)
  • the filed name collection cannot in schema (ca90dba)
  • uri and url occur document fill undefiend in not exist field (5e14881)
  • URI values cannot have whitespace (e3096e2)
  • use toObject will fil undefiend in not exist field (bd98969)