some updates to db indexes w/ burnettk
This commit is contained in:
parent
2f60077b82
commit
bc00f91570
|
@ -30,7 +30,7 @@ class MessageInstanceCorrelationRuleModel(SpiffworkflowBaseDBModel):
|
||||||
|
|
||||||
id = db.Column(db.Integer, primary_key=True)
|
id = db.Column(db.Integer, primary_key=True)
|
||||||
message_instance_id = db.Column(ForeignKey(MessageInstanceModel.id), nullable=False, index=True) # type: ignore
|
message_instance_id = db.Column(ForeignKey(MessageInstanceModel.id), nullable=False, index=True) # type: ignore
|
||||||
name: str = db.Column(db.String(50), nullable=False)
|
name: str = db.Column(db.String(50), nullable=False, index=True)
|
||||||
retrieval_expression: str = db.Column(db.String(255))
|
retrieval_expression: str = db.Column(db.String(255))
|
||||||
updated_at_in_seconds: int = db.Column(db.Integer)
|
updated_at_in_seconds: int = db.Column(db.Integer)
|
||||||
created_at_in_seconds: int = db.Column(db.Integer)
|
created_at_in_seconds: int = db.Column(db.Integer)
|
||||||
|
|
|
@ -61,7 +61,7 @@ class ProcessInstanceModel(SpiffworkflowBaseDBModel):
|
||||||
process_initiator = relationship("UserModel")
|
process_initiator = relationship("UserModel")
|
||||||
|
|
||||||
bpmn_process_definition_id: int | None = db.Column(
|
bpmn_process_definition_id: int | None = db.Column(
|
||||||
ForeignKey(BpmnProcessDefinitionModel.id), nullable=True # type: ignore
|
ForeignKey(BpmnProcessDefinitionModel.id), nullable=True, index=True # type: ignore
|
||||||
)
|
)
|
||||||
bpmn_process_definition = relationship(BpmnProcessDefinitionModel)
|
bpmn_process_definition = relationship(BpmnProcessDefinitionModel)
|
||||||
bpmn_process_id: int | None = db.Column(ForeignKey(BpmnProcessModel.id), nullable=True) # type: ignore
|
bpmn_process_id: int | None = db.Column(ForeignKey(BpmnProcessModel.id), nullable=True) # type: ignore
|
||||||
|
@ -90,7 +90,7 @@ class ProcessInstanceModel(SpiffworkflowBaseDBModel):
|
||||||
) # type: ignore
|
) # type: ignore
|
||||||
|
|
||||||
bpmn_json: str | None = deferred(db.Column(db.JSON)) # type: ignore
|
bpmn_json: str | None = deferred(db.Column(db.JSON)) # type: ignore
|
||||||
start_in_seconds: int | None = db.Column(db.Integer)
|
start_in_seconds: int | None = db.Column(db.Integer, index=True)
|
||||||
end_in_seconds: int | None = db.Column(db.Integer)
|
end_in_seconds: int | None = db.Column(db.Integer)
|
||||||
updated_at_in_seconds: int = db.Column(db.Integer)
|
updated_at_in_seconds: int = db.Column(db.Integer)
|
||||||
created_at_in_seconds: int = db.Column(db.Integer)
|
created_at_in_seconds: int = db.Column(db.Integer)
|
||||||
|
|
|
@ -29,9 +29,9 @@ class TaskDefinitionModel(SpiffworkflowBaseDBModel):
|
||||||
|
|
||||||
bpmn_identifier: str = db.Column(db.String(255), nullable=False, index=True)
|
bpmn_identifier: str = db.Column(db.String(255), nullable=False, index=True)
|
||||||
bpmn_name: str = db.Column(db.String(255), nullable=True, index=True)
|
bpmn_name: str = db.Column(db.String(255), nullable=True, index=True)
|
||||||
|
typename: str = db.Column(db.String(255), nullable=False, index=True)
|
||||||
|
|
||||||
properties_json: dict = db.Column(db.JSON, nullable=False)
|
properties_json: dict = db.Column(db.JSON, nullable=False)
|
||||||
typename: str = db.Column(db.String(255), nullable=False)
|
|
||||||
|
|
||||||
updated_at_in_seconds: int = db.Column(db.Integer)
|
updated_at_in_seconds: int = db.Column(db.Integer)
|
||||||
created_at_in_seconds: int = db.Column(db.Integer)
|
created_at_in_seconds: int = db.Column(db.Integer)
|
||||||
|
|
|
@ -28,11 +28,12 @@ class UserModel(SpiffworkflowBaseDBModel):
|
||||||
|
|
||||||
id: int = db.Column(db.Integer, primary_key=True)
|
id: int = db.Column(db.Integer, primary_key=True)
|
||||||
username: str = db.Column(db.String(255), nullable=False, unique=True)
|
username: str = db.Column(db.String(255), nullable=False, unique=True)
|
||||||
|
email = db.Column(db.String(255), index=True)
|
||||||
|
|
||||||
|
service = db.Column(db.String(255), nullable=False, unique=False, index=True) # not 'openid' -- google, aws
|
||||||
|
service_id = db.Column(db.String(255), nullable=False, unique=False, index=True)
|
||||||
|
|
||||||
service = db.Column(db.String(255), nullable=False, unique=False) # not 'openid' -- google, aws
|
|
||||||
service_id = db.Column(db.String(255), nullable=False, unique=False)
|
|
||||||
display_name = db.Column(db.String(255))
|
display_name = db.Column(db.String(255))
|
||||||
email = db.Column(db.String(255))
|
|
||||||
tenant_specific_field_1: str | None = db.Column(db.String(255))
|
tenant_specific_field_1: str | None = db.Column(db.String(255))
|
||||||
tenant_specific_field_2: str | None = db.Column(db.String(255))
|
tenant_specific_field_2: str | None = db.Column(db.String(255))
|
||||||
tenant_specific_field_3: str | None = db.Column(db.String(255))
|
tenant_specific_field_3: str | None = db.Column(db.String(255))
|
||||||
|
|
Loading…
Reference in New Issue