Skip to content

sample script to load templates#85

Open
abilpraju-aot wants to merge 1 commit intoAOT-Technologies:mainfrom
abilpraju-aot:feature/M8F-137-script-template
Open

sample script to load templates#85
abilpraju-aot wants to merge 1 commit intoAOT-Technologies:mainfrom
abilpraju-aot:feature/M8F-137-script-template

Conversation

@abilpraju-aot
Copy link
Collaborator

@abilpraju-aot abilpraju-aot commented Mar 18, 2026

JIRA Ticket

https://aottech.atlassian.net/browse/M8F-137

Description

Added a new folder sample_templates to load sample templates at the startup

Type

  • Feature
  • Bug fix
  • Documentation
  • Other

Changes

  • Backend
  • Frontend
  • Documentation

Testing

Related Issues

Closes #

@sonarqubecloud
Copy link

@abilpraju-aot abilpraju-aot marked this pull request as ready for review March 19, 2026 05:51
Copy link
Collaborator

@auslin-aot auslin-aot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The loaded template BPMN file is not visible in the templates section. Could you please check?

Image

template_key,
)

logger.info("Sample template loading complete: %d loaded, %d total ZIPs.", loaded, len(zip_files))
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

BadZipFile and IntegrityError are currently handled, but failures in read_bytes(), store_file(), tenant creation, and other non-integrity database operations can still cause the startup to abort. Can we ignore all errors from this code so that it doesn’t break startup?

Copy link
Collaborator

@auslin-aot auslin-aot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please ensure that sample templates with JSON files and DMN are loaded correctly, and verify that these templates can be viewed and used in the process model without any issues.

Copy link
Collaborator

@auslin-aot auslin-aot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Performance concern: when the flag is enabled, startup performs synchronous disk I/O, ZIP extraction, and database writes during app boot. Can you check if this can be done asynchronously?

Copy link
Collaborator

@andrepestana-aot andrepestana-aot Mar 19, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Shouldn't there be more useful ready-to-use templates, instead of just one basic test model?

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.

4 participants