Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(core): add MikroORM.initSync() helper #4166

Merged
merged 2 commits into from
Mar 26, 2023
Merged

feat(core): add MikroORM.initSync() helper #4166

merged 2 commits into from
Mar 26, 2023

Conversation

B4nan
Copy link
Member

@B4nan B4nan commented Mar 26, 2023

As opposed to the async MikroORM.init method, you can prefer to use synchronous variant initSync. This method has some limitations:

  • database connection will be established when you first interact with the database (or you can use orm.connect() explicitly)
  • no loading of the config file, options parameter is mandatory
  • no support for folder based discovery
  • no check for mismatched package versions

Related: #4164

@codecov
Copy link

codecov bot commented Mar 26, 2023

Codecov Report

Patch coverage: 93.60% and project coverage change: -0.04 ⚠️

Comparison is base (7e53dcd) 99.54% compared to head (ac9806d) 99.51%.

Additional details and impacted files
@@            Coverage Diff             @@
##               v6    #4166      +/-   ##
==========================================
- Coverage   99.54%   99.51%   -0.04%     
==========================================
  Files         217      217              
  Lines       14100    14152      +52     
  Branches     3238     3241       +3     
==========================================
+ Hits        14036    14083      +47     
- Misses         60       66       +6     
+ Partials        4        3       -1     
Impacted Files Coverage Δ
packages/core/src/metadata/MetadataProvider.ts 92.30% <ø> (-3.15%) ⬇️
packages/mariadb/src/MariaDbMikroORM.ts 77.77% <0.00%> (-22.23%) ⬇️
packages/mongodb/src/MongoMikroORM.ts 77.77% <0.00%> (-22.23%) ⬇️
packages/mysql/src/MySqlMikroORM.ts 77.77% <0.00%> (-22.23%) ⬇️
packages/postgresql/src/PostgreSqlMikroORM.ts 77.77% <0.00%> (-22.23%) ⬇️
packages/sqlite/src/SqliteMikroORM.ts 77.77% <0.00%> (-22.23%) ⬇️
packages/core/src/MikroORM.ts 97.65% <96.00%> (-0.50%) ⬇️
packages/cli/src/commands/ClearCacheCommand.ts 100.00% <100.00%> (ø)
packages/core/src/cache/FileCacheAdapter.ts 100.00% <100.00%> (ø)
packages/core/src/cache/MemoryCacheAdapter.ts 100.00% <100.00%> (ø)
... and 12 more

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report in Codecov by Sentry.
📢 Do you have feedback about the report comment? Let us know in this issue.

@B4nan B4nan force-pushed the sync-init branch 5 times, most recently from d521b95 to 4772b56 Compare March 26, 2023 18:26
@B4nan B4nan marked this pull request as ready for review March 26, 2023 18:26
@B4nan B4nan merged commit 261d174 into v6 Mar 26, 2023
@B4nan B4nan deleted the sync-init branch March 26, 2023 19:45
B4nan added a commit that referenced this pull request Apr 6, 2023
As opposed to the async `MikroORM.init` method, you can prefer to use
synchronous variant `initSync`. This method has some limitations:

- database connection will be established when you first interact with
the database (or you can use `orm.connect()` explicitly)
- no loading of the `config` file, `options` parameter is mandatory
- no support for folder based discovery
- no check for mismatched package versions

Related: #4164
B4nan added a commit that referenced this pull request Apr 10, 2023
As opposed to the async `MikroORM.init` method, you can prefer to use
synchronous variant `initSync`. This method has some limitations:

- database connection will be established when you first interact with
the database (or you can use `orm.connect()` explicitly)
- no loading of the `config` file, `options` parameter is mandatory
- no support for folder based discovery
- no check for mismatched package versions

Related: #4164
B4nan added a commit that referenced this pull request Apr 12, 2023
As opposed to the async `MikroORM.init` method, you can prefer to use
synchronous variant `initSync`. This method has some limitations:

- database connection will be established when you first interact with
the database (or you can use `orm.connect()` explicitly)
- no loading of the `config` file, `options` parameter is mandatory
- no support for folder based discovery
- no check for mismatched package versions

Related: #4164
B4nan added a commit that referenced this pull request Apr 26, 2023
As opposed to the async `MikroORM.init` method, you can prefer to use
synchronous variant `initSync`. This method has some limitations:

- database connection will be established when you first interact with
the database (or you can use `orm.connect()` explicitly)
- no loading of the `config` file, `options` parameter is mandatory
- no support for folder based discovery
- no check for mismatched package versions

Related: #4164
B4nan added a commit that referenced this pull request May 14, 2023
As opposed to the async `MikroORM.init` method, you can prefer to use
synchronous variant `initSync`. This method has some limitations:

- database connection will be established when you first interact with
the database (or you can use `orm.connect()` explicitly)
- no loading of the `config` file, `options` parameter is mandatory
- no support for folder based discovery
- no check for mismatched package versions

Related: #4164
B4nan added a commit that referenced this pull request May 14, 2023
As opposed to the async `MikroORM.init` method, you can prefer to use
synchronous variant `initSync`. This method has some limitations:

- database connection will be established when you first interact with
the database (or you can use `orm.connect()` explicitly)
- no loading of the `config` file, `options` parameter is mandatory
- no support for folder based discovery
- no check for mismatched package versions

Related: #4164
B4nan added a commit that referenced this pull request May 24, 2023
As opposed to the async `MikroORM.init` method, you can prefer to use
synchronous variant `initSync`. This method has some limitations:

- database connection will be established when you first interact with
the database (or you can use `orm.connect()` explicitly)
- no loading of the `config` file, `options` parameter is mandatory
- no support for folder based discovery
- no check for mismatched package versions

Related: #4164
B4nan added a commit that referenced this pull request May 26, 2023
As opposed to the async `MikroORM.init` method, you can prefer to use
synchronous variant `initSync`. This method has some limitations:

- database connection will be established when you first interact with
the database (or you can use `orm.connect()` explicitly)
- no loading of the `config` file, `options` parameter is mandatory
- no support for folder based discovery
- no check for mismatched package versions

Related: #4164
B4nan added a commit that referenced this pull request Jun 11, 2023
As opposed to the async `MikroORM.init` method, you can prefer to use
synchronous variant `initSync`. This method has some limitations:

- database connection will be established when you first interact with
the database (or you can use `orm.connect()` explicitly)
- no loading of the `config` file, `options` parameter is mandatory
- no support for folder based discovery
- no check for mismatched package versions

Related: #4164
B4nan added a commit that referenced this pull request Sep 10, 2023
As opposed to the async `MikroORM.init` method, you can prefer to use
synchronous variant `initSync`. This method has some limitations:

- database connection will be established when you first interact with
the database (or you can use `orm.connect()` explicitly)
- no loading of the `config` file, `options` parameter is mandatory
- no support for folder based discovery
- no check for mismatched package versions

Related: #4164
B4nan added a commit that referenced this pull request Sep 20, 2023
As opposed to the async `MikroORM.init` method, you can prefer to use
synchronous variant `initSync`. This method has some limitations:

- database connection will be established when you first interact with
the database (or you can use `orm.connect()` explicitly)
- no loading of the `config` file, `options` parameter is mandatory
- no support for folder based discovery
- no check for mismatched package versions

Related: #4164
B4nan added a commit that referenced this pull request Sep 24, 2023
As opposed to the async `MikroORM.init` method, you can prefer to use
synchronous variant `initSync`. This method has some limitations:

- database connection will be established when you first interact with
the database (or you can use `orm.connect()` explicitly)
- no loading of the `config` file, `options` parameter is mandatory
- no support for folder based discovery
- no check for mismatched package versions

Related: #4164
B4nan added a commit that referenced this pull request Sep 30, 2023
As opposed to the async `MikroORM.init` method, you can prefer to use
synchronous variant `initSync`. This method has some limitations:

- database connection will be established when you first interact with
the database (or you can use `orm.connect()` explicitly)
- no loading of the `config` file, `options` parameter is mandatory
- no support for folder based discovery
- no check for mismatched package versions

Related: #4164
@B4nan B4nan mentioned this pull request Oct 2, 2023
22 tasks
B4nan added a commit that referenced this pull request Oct 2, 2023
As opposed to the async `MikroORM.init` method, you can prefer to use
synchronous variant `initSync`. This method has some limitations:

- database connection will be established when you first interact with
the database (or you can use `orm.connect()` explicitly)
- no loading of the `config` file, `options` parameter is mandatory
- no support for folder based discovery
- no check for mismatched package versions

Related: #4164
B4nan added a commit that referenced this pull request Oct 17, 2023
As opposed to the async `MikroORM.init` method, you can prefer to use
synchronous variant `initSync`. This method has some limitations:

- database connection will be established when you first interact with
the database (or you can use `orm.connect()` explicitly)
- no loading of the `config` file, `options` parameter is mandatory
- no support for folder based discovery
- no check for mismatched package versions

Related: #4164
B4nan added a commit that referenced this pull request Oct 21, 2023
As opposed to the async `MikroORM.init` method, you can prefer to use
synchronous variant `initSync`. This method has some limitations:

- database connection will be established when you first interact with
the database (or you can use `orm.connect()` explicitly)
- no loading of the `config` file, `options` parameter is mandatory
- no support for folder based discovery
- no check for mismatched package versions

Related: #4164
B4nan added a commit that referenced this pull request Oct 25, 2023
As opposed to the async `MikroORM.init` method, you can prefer to use
synchronous variant `initSync`. This method has some limitations:

- database connection will be established when you first interact with
the database (or you can use `orm.connect()` explicitly)
- no loading of the `config` file, `options` parameter is mandatory
- no support for folder based discovery
- no check for mismatched package versions

Related: #4164
B4nan added a commit that referenced this pull request Nov 2, 2023
As opposed to the async `MikroORM.init` method, you can prefer to use
synchronous variant `initSync`. This method has some limitations:

- database connection will be established when you first interact with
the database (or you can use `orm.connect()` explicitly)
- no loading of the `config` file, `options` parameter is mandatory
- no support for folder based discovery
- no check for mismatched package versions

Related: #4164
B4nan added a commit that referenced this pull request Nov 5, 2023
As opposed to the async `MikroORM.init` method, you can prefer to use
synchronous variant `initSync`. This method has some limitations:

- database connection will be established when you first interact with
the database (or you can use `orm.connect()` explicitly)
- no loading of the `config` file, `options` parameter is mandatory
- no support for folder based discovery
- no check for mismatched package versions

Related: #4164
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant