|
code
app/jobs/create_automatic_diagnosis_job.rb:2
|
84%
|
app/jobs/create_automatic_diagnosis_job.rb:2
- Average Self
-
2,792ms
- Average calls
- 1x
- Total Self
- 2,792ms
- Total Children
- 514ms
- Total runtime
- 3,306ms
CreateAutomaticDiagnosisJob#perform
|
|
sql
app/services/diagnosis_creation/create_or_update_facility_and_company.rb:50
|
4%
|
app/services/diagnosis_creation/create_or_update_facility_and_company.rb:50
- Average Self
-
145ms
- Average calls
- 0.97x
- Total Self
- 140ms
- Total Children
- 0ms
- Total runtime
- 140ms
SELECT "facilities".* FROM "facilities" WHERE "facilities"."siret" = ? LIMIT ?
|
|
sql
app/models/expert.rb:256
|
2%
|
app/models/expert.rb:256
- Average Self
-
88ms
- Average calls
- 0.87x
- Total Self
- 77ms
- Total Children
- 0ms
- Total runtime
- 77ms
SELECT "experts"."id" FROM "experts" LEFT OUTER JOIN "antennes" ON "antennes"."id" = "experts"."antenne_id" LEFT OUTER JOIN "territorial_zones" ON "territorial_zones"."zoneable_type" = ? AND "territorial_zones"."zoneable_id" = "antennes"."id" WHERE "experts"."id" NOT IN (?) AND ("territorial_zones"."zone_type" = ? AND "territorial_zones"."code" = ? OR "territorial_zones"."zone_type" = ? AND "territorial_zones"."code" IS NULL OR "territorial_zones"."zone_type" = ? AND "territorial_zones"."code" = ? OR "territorial_zones"."zone_type" = ? AND "territorial_zones"."code" = ? OR "antennes"."territorial_level" = ?)
|
|
sql
app/services/diagnosis_creation/create_or_update_facility_and_company.rb:22
|
2%
|
app/services/diagnosis_creation/create_or_update_facility_and_company.rb:22
- Average Self
-
62ms
- Average calls
- 0.98x
- Total Self
- 61ms
- Total Children
- 0ms
- Total runtime
- 61ms
SELECT "companies".* FROM "companies" WHERE "companies"."siren" = ? LIMIT ?
|
|
sql
app/services/diagnosis_creation/create_or_update_facility_and_company.rb:53
|
1%
|
app/services/diagnosis_creation/create_or_update_facility_and_company.rb:53
- Average Self
-
25ms
- Average calls
- 1.9x
- Total Self
- 49ms
- Total Children
- 0ms
- Total runtime
- 49ms
SELECT ? AS one FROM "facilities" WHERE "facilities"."siret" = ? AND "facilities"."id" != ? LIMIT ?
UPDATE "facilities" SET "updated_at" = ?, "naf_code" = ?, "code_effectif" = ?, "naf_libelle" = ?, "naf_code_a10" = ?, "opco_id" = ?, "effectif" = ? WHERE "facilities"."id" = ?
|
|
gc
ruby/gc.c
|
1%
|
ruby/gc.c
- Average Self
-
42ms
- Average calls
- 1.1x
- Total Self
- 45ms
- Total Children
- 0ms
- Total runtime
- 45ms
GC.start
|
|
sql
app/models/expert.rb:247
|
<1%
|
app/models/expert.rb:247
- Average Self
-
24ms
- Average calls
- 0.87x
- Total Self
- 21ms
- Total Children
- 0ms
- Total runtime
- 21ms
SELECT "experts"."id" FROM "experts" INNER JOIN "territorial_zones" ON "territorial_zones"."zoneable_type" = ? AND "territorial_zones"."zoneable_id" = "experts"."id" WHERE "experts"."deleted_at" IS NULL
|
|
sql
app/services/diagnosis_creation/create_or_update_facility_and_company.rb:25
|
<1%
|
app/services/diagnosis_creation/create_or_update_facility_and_company.rb:25
- Average Self
-
10ms
- Average calls
- 1.8x
- Total Self
- 18ms
- Total Children
- 0ms
- Total runtime
- 18ms
SELECT ? AS one FROM "companies" WHERE "companies"."siren" = ? AND "companies"."id" != ? LIMIT ?
UPDATE "companies" SET "updated_at" = ?, "code_effectif" = ?, "forme_exercice" = ? WHERE "companies"."id" = ?
|
|
sql
app/services/diagnosis_creation/find_relevant_expert_subjects.rb:36
|
<1%
|
app/services/diagnosis_creation/find_relevant_expert_subjects.rb:36
- Average Self
-
20ms
- Average calls
- 0.87x
- Total Self
- 18ms
- Total Children
- 0ms
- Total runtime
- 18ms
SELECT "experts_subjects".* FROM "experts_subjects" INNER JOIN "experts" ON "experts"."deleted_at" IS NULL AND "experts"."id" = "experts_subjects"."expert_id" INNER JOIN "institutions_subjects" ON "institutions_subjects"."id" = "experts_subjects"."institution_subject_id" INNER JOIN "institutions" ON "institutions"."id" = "institutions_subjects"."institution_id" WHERE "experts_subjects"."expert_id" IN (?) OR "experts"."id" IN (?))) AND "institutions_subjects"."subject_id" = ? AND "institutions_subjects"."institution_id" IN (?) AND "institutions_subjects"."institution_id" != ? AND "institutions_subjects"."institution_id" != ? AND "institutions_subjects"."institution_id" != ? AND "institutions_subjects"."institution_id" NOT IN (?)
|
|
sql
app/services/diagnosis_creation/create_automatic_diagnosis.rb:36
|
<1%
|
app/services/diagnosis_creation/create_automatic_diagnosis.rb:36
- Average Self
-
4.1ms
- Average calls
- 3x
- Total Self
- 12ms
- Total Children
- <0.01ms
- Total runtime
- 12ms
BEGIN
SELECT ? AS one FROM "facilities" WHERE "facilities"."siret" = ? AND "facilities"."id" != ? LIMIT ?
ROLLBACK
|
|
sql
app/models/expert_subject.rb:99
|
<1%
|
app/models/expert_subject.rb:99
- Average Self
-
1.6ms
- Average calls
- 7.3x
- Total Self
- 11ms
- Total Children
- 0ms
- Total runtime
- 11ms
SELECT "match_filters".* FROM "match_filters" INNER JOIN "experts" ON "match_filters"."filtrable_element_id" = "experts"."id" WHERE "experts"."id" = ? AND "match_filters"."filtrable_element_type" = ?
SELECT "match_filters".* FROM "match_filters" INNER JOIN "antennes" ON "match_filters"."filtrable_element_id" = "antennes"."id" INNER JOIN "experts" ON "antennes"."id" = "experts"."antenne_id" WHERE "experts"."id" = ? AND "match_filters"."filtrable_element_type" = ?
SELECT "match_filters".* FROM "match_filters" INNER JOIN "institutions" ON "match_filters"."filtrable_element_id" = "institutions"."id" INNER JOIN "antennes" ON "institutions"."id" = "antennes"."institution_id" INNER JOIN "experts" ON "antennes"."id" = "experts"."antenne_id" WHERE "experts"."id" = ? AND "match_filters"."filtrable_element_type" = ?
|
|
sql
app/services/diagnosis_creation/create_matches.rb:16
|
<1%
|
app/services/diagnosis_creation/create_matches.rb:16
- Average Self
-
2ms
- Average calls
- 5.3x
- Total Self
- 10ms
- Total Children
- 0ms
- Total runtime
- 10ms
SELECT ? AS one FROM "matches" WHERE "matches"."expert_id" = ? AND "matches"."need_id" = ? LIMIT ?
INSERT INTO "matches" ("need_id", "created_at", "updated_at", "taken_care_of_at", "closed_at", "expert_id", "subject_id", "status", "archived_at", "sent_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?) RETURNING "id"
UPDATE "needs" SET "matches_count" = COALESCE("needs"."matches_count", ?) + ?, "updated_at" = ? WHERE "needs"."id" = ?
|
|
sql
app/services/diagnosis_creation/create_automatic_diagnosis.rb:15
|
<1%
|
app/services/diagnosis_creation/create_automatic_diagnosis.rb:15
- Average Self
-
4.6ms
- Average calls
- 1.8x
- Total Self
- 8.4ms
- Total Children
- 0ms
- Total runtime
- 8.4ms
UPDATE "solicitations" SET "updated_at" = ? WHERE "solicitations"."id" = ?
COMMIT
|
|
sql
app/jobs/create_automatic_diagnosis_job.rb:3
|
<1%
|
app/jobs/create_automatic_diagnosis_job.rb:3
- Average Self
-
7.8ms
- Average calls
- 1x
- Total Self
- 7.8ms
- Total Children
- 0ms
- Total runtime
- 7.8ms
SELECT "solicitations".* FROM "solicitations" WHERE "solicitations"."id" = ? LIMIT ?
|
|
sql
app/services/diagnosis_creation/steps.rb:25
|
<1%
|
app/services/diagnosis_creation/steps.rb:25
- Average Self
-
4.3ms
- Average calls
- 1.8x
- Total Self
- 7.6ms
- Total Children
- 0ms
- Total runtime
- 7.6ms
INSERT INTO "contacts" ("email", "phone_number", "company_id", "created_at", "updated_at", "full_name") VALUES (?, ?, ?, ?, ?, ?) RETURNING "id"
UPDATE "diagnoses" SET "updated_at" = ?, "visitee_id" = ? WHERE "diagnoses"."id" = ?
|
|
sql
app/services/diagnosis_creation/find_relevant_expert_subjects.rb:31
|
<1%
|
app/services/diagnosis_creation/find_relevant_expert_subjects.rb:31
- Average Self
-
1.6ms
- Average calls
- 3x
- Total Self
- 4.7ms
- Total Children
- 0ms
- Total runtime
- 4.7ms
SELECT ? AS one FROM "subject_answer_groupings" INNER JOIN "subject_answers" ON "subject_answers"."subject_answer_grouping_id" = "subject_answer_groupings"."id" AND "subject_answers"."type" = ? INNER JOIN "subject_questions" "subject_question" ON "subject_question"."id" = "subject_answers"."subject_question_id" INNER JOIN "subjects" ON "subjects"."id" = "subject_question"."subject_id" WHERE "subject_answer_groupings"."institution_id" = ? AND "subject_question"."subject_id" = ? LIMIT ?
SELECT DISTINCT "subject_answer_groupings".* FROM "subject_answer_groupings" INNER JOIN "subject_answers" ON "subject_answers"."subject_answer_grouping_id" = "subject_answer_groupings"."id" AND "subject_answers"."type" = ? INNER JOIN "subject_questions" "subject_question" ON "subject_question"."id" = "subject_answers"."subject_question_id" INNER JOIN "subjects" ON "subjects"."id" = "subject_question"."subject_id" WHERE "subject_answer_groupings"."institution_id" = ? AND "subject_question"."subject_id" = ?
|
|
sql
app/models/expert.rb:244
|
<1%
|
app/models/expert.rb:244
- Average Self
-
5.3ms
- Average calls
- 0.87x
- Total Self
- 4.7ms
- Total Children
- 0ms
- Total runtime
- 4.7ms
SELECT "experts"."id" FROM "experts" LEFT OUTER JOIN "territorial_zones" ON "territorial_zones"."zoneable_type" = ? AND "territorial_zones"."zoneable_id" = "experts"."id" WHERE ("territorial_zones"."zone_type" = ? AND "territorial_zones"."code" = ? OR "territorial_zones"."zone_type" = ? AND "territorial_zones"."code" IS NULL OR "territorial_zones"."zone_type" = ? AND "territorial_zones"."code" = ? OR "territorial_zones"."zone_type" = ? AND "territorial_zones"."code" = ?)
|
|
sql
app/services/diagnosis_creation/create_automatic_diagnosis.rb:21
|
<1%
|
app/services/diagnosis_creation/create_automatic_diagnosis.rb:21
- Average Self
-
2ms
- Average calls
- 2x
- Total Self
- 3.9ms
- Total Children
- 1.3ms
- Total runtime
- 5.2ms
BEGIN
SELECT "diagnoses".* FROM "diagnoses" WHERE "diagnoses"."solicitation_id" = ? LIMIT ?
|
|
sql
app/models/diagnosis.rb:134
|
<1%
|
app/models/diagnosis.rb:134
- Average Self
-
0.57ms
- Average calls
- 6.3x
- Total Self
- 3.6ms
- Total Children
- 0ms
- Total runtime
- 3.6ms
SELECT "diagnoses".* FROM "diagnoses" INNER JOIN "solicitations" ON "solicitations"."id" = "diagnoses"."solicitation_id" WHERE "solicitations"."id" = ?
|
|
sql
app/models/concerns/mandatory_answers.rb:30
|
<1%
|
app/models/concerns/mandatory_answers.rb:30
- Average Self
-
0.71ms
- Average calls
- 4.8x
- Total Self
- 3.4ms
- Total Children
- 0.13ms
- Total runtime
- 3.5ms
SELECT "subject_questions"."id" FROM "subject_questions" WHERE "subject_questions"."subject_id" = ?
BEGIN
SELECT "subjects".* FROM "subjects" INNER JOIN "landing_subjects" ON "subjects"."id" = "landing_subjects"."subject_id" WHERE "landing_subjects"."id" = ? LIMIT ?
SELECT "subject_answers".* FROM "subject_answers" WHERE "subject_answers"."type" = ? AND "subject_answers"."subject_questionable_id" = ? AND "subject_answers"."subject_questionable_type" = ? AND "subject_answers"."subject_question_id" NOT IN (?)
|
|
sql
app/services/diagnosis_creation/find_relevant_expert_subjects.rb:76
|
<1%
|
app/services/diagnosis_creation/find_relevant_expert_subjects.rb:76
- Average Self
-
1ms
- Average calls
- 3.3x
- Total Self
- 3.4ms
- Total Children
- 0ms
- Total runtime
- 3.4ms
SELECT ? AS one FROM "subjects" INNER JOIN "match_filters_subjects" ON "subjects"."id" = "match_filters_subjects"."subject_id" WHERE "match_filters_subjects"."match_filter_id" = ? LIMIT ?
SELECT ? AS one FROM "subjects" INNER JOIN "match_filters_subjects" ON "subjects"."id" = "match_filters_subjects"."subject_id" WHERE "match_filters_subjects"."match_filter_id" = ? AND "subjects"."id" = ? LIMIT ?
|
|
sql
app/models/solicitation.rb:608
|
<1%
|
app/models/solicitation.rb:608
- Average Self
-
2.8ms
- Average calls
- 1.2x
- Total Self
- 3.2ms
- Total Children
- 0ms
- Total runtime
- 3.2ms
SELECT "landing_subjects".* FROM "landing_subjects" WHERE "landing_subjects"."id" = ? LIMIT ?
SELECT "subjects".* FROM "subjects" WHERE "subjects"."id" = ? LIMIT ?
|
|
sql
app/services/diagnosis_creation/steps.rb:45
|
<1%
|
app/services/diagnosis_creation/steps.rb:45
- Average Self
-
1.1ms
- Average calls
- 2.7x
- Total Self
- 2.9ms
- Total Children
- 0ms
- Total runtime
- 2.9ms
SELECT "subject_questions".* FROM "subject_questions" WHERE "subject_questions"."id" = ? LIMIT ?
SELECT ? AS one FROM "subject_answers" WHERE "subject_answers"."type" = ? AND "subject_answers"."subject_questionable_id" IS NULL AND "subject_answers"."subject_questionable_type" = ? AND "subject_answers"."subject_question_id" = ? LIMIT ?
SELECT ? AS one FROM "needs" WHERE "needs"."subject_id" = ? AND "needs"."diagnosis_id" = ? LIMIT ?
UPDATE "diagnoses" SET "updated_at" = ?, "step" = ? WHERE "diagnoses"."id" = ?
INSERT INTO "needs" ("diagnosis_id", "subject_id", "created_at", "updated_at", "content", "matches_count", "satisfaction_email_sent", "status", "abandoned_email_sent", "retention_sent_at", "starred_at") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) RETURNING "id"
INSERT INTO "subject_answers" ("subject_question_id", "subject_questionable_type", "subject_questionable_id", "filter_value", "created_at", "updated_at", "type", "subject_answer_grouping_id") VALUES (?, ?, ?, ?, ?, ?, ?, ?) RETURNING "id"
|
|
sql
app/services/diagnosis_creation/find_relevant_expert_subjects.rb:30
|
<1%
|
app/services/diagnosis_creation/find_relevant_expert_subjects.rb:30
- Average Self
-
0.58ms
- Average calls
- 4.8x
- Total Self
- 2.8ms
- Total Children
- 0ms
- Total runtime
- 2.8ms
SELECT "experts".* FROM "experts" WHERE "experts"."id" = ? LIMIT ?
SELECT "institutions".* FROM "institutions" INNER JOIN "antennes" ON "institutions"."id" = "antennes"."institution_id" WHERE "antennes"."id" = ? LIMIT ?
|
|
sql
app/services/diagnosis_creation/create_or_update_diagnosis.rb:19
|
<1%
|
app/services/diagnosis_creation/create_or_update_diagnosis.rb:19
- Average Self
-
3ms
- Average calls
- 0.89x
- Total Self
- 2.6ms
- Total Children
- 0ms
- Total runtime
- 2.6ms
INSERT INTO "diagnoses" ("content", "created_at", "updated_at", "step", "advisor_id", "visitee_id", "facility_id", "happened_on", "solicitation_id", "completed_at", "retention_email_sent") VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) RETURNING "id"
|
|
redis
app/services/api.rb:14
|
<1%
|
app/services/api.rb:14
- Average Self
-
0.6ms
- Average calls
- 3.7x
- Total Self
- 2.2ms
- Total Children
- 0ms
- Total runtime
- 2.2ms
get
|
|
sql
app/services/diagnosis_creation/create_automatic_diagnosis.rb:31
|
<1%
|
app/services/diagnosis_creation/create_automatic_diagnosis.rb:31
- Average Self
-
2.1ms
- Average calls
- 0.87x
- Total Self
- 1.8ms
- Total Children
- 0ms
- Total runtime
- 1.8ms
SELECT "subject_answers".* FROM "subject_answers" WHERE "subject_answers"."type" = ? AND "subject_answers"."subject_questionable_id" = ? AND "subject_answers"."subject_questionable_type" = ?
SELECT "matches".* FROM "matches" WHERE "matches"."need_id" = ?
DELETE FROM "matches" WHERE "matches"."id" = ?
SELECT "feedbacks".* FROM "feedbacks" WHERE "feedbacks"."feedbackable_id" = ? AND "feedbacks"."feedbackable_type" = ? AND "feedbacks"."category" = ?
DELETE FROM "feedbacks" WHERE "feedbacks"."id" = ?
SELECT "reminders_actions".* FROM "reminders_actions" WHERE "reminders_actions"."need_id" = ?
SELECT "company_satisfactions".* FROM "company_satisfactions" WHERE "company_satisfactions"."need_id" = ? LIMIT ?
DELETE FROM "needs" WHERE "needs"."id" = ?
DELETE FROM "diagnoses" WHERE "diagnoses"."id" = ?
|
|
cache
app/services/api.rb:14
|
<1%
|
app/services/api.rb:14
- Average Self
-
0.41ms
- Average calls
- 3.7x
- Total Self
- 1.5ms
- Total Children
- 2.2ms
- Total runtime
- 3.7ms
read
|
|
sql
app/services/diagnosis_creation/steps.rb:40
|
<1%
|
app/services/diagnosis_creation/steps.rb:40
- Average Self
-
0.92ms
- Average calls
- 1.6x
- Total Self
- 1.5ms
- Total Children
- 0ms
- Total runtime
- 1.5ms
SELECT ? AS one FROM "needs" WHERE "needs"."subject_id" = ? AND "needs"."diagnosis_id" = ? LIMIT ?
|
|
sql
app/models/solicitation.rb:601
|
<1%
|
app/models/solicitation.rb:601
- Average Self
-
1.7ms
- Average calls
- 0.82x
- Total Self
- 1.4ms
- Total Children
- 0ms
- Total runtime
- 1.4ms
SELECT "landing_subjects".* FROM "landing_subjects" WHERE "landing_subjects"."id" = ? LIMIT ?
SELECT "subjects".* FROM "subjects" WHERE "subjects"."id" = ? LIMIT ?
|
|
sql
app/models/need.rb:466
|
<1%
|
app/models/need.rb:466
- Average Self
-
0.64ms
- Average calls
- 1.8x
- Total Self
- 1.1ms
- Total Children
- 0ms
- Total runtime
- 1.1ms
UPDATE "diagnoses" SET "updated_at" = ? WHERE "diagnoses"."id" = ?
|
|
code
vendor/bundle/ruby/4.0.0/gems/sidekiq-8.1.6/lib/active_job/queue_adapters/sidekiq_adapter.rb:13
|
<1%
|
vendor/bundle/ruby/4.0.0/gems/sidekiq-8.1.6/lib/active_job/queue_adapters/sidekiq_adapter.rb:13
- Average Self
-
1.1ms
- Average calls
- 1x
- Total Self
- 1.1ms
- Total Children
- 3,307ms
- Total runtime
- 3,308ms
CreateAutomaticDiagnosisJob#perform
|
|
sql
app/services/diagnosis_creation/steps.rb:42
|
<1%
|
app/services/diagnosis_creation/steps.rb:42
- Average Self
-
1.1ms
- Average calls
- 0.89x
- Total Self
- 0.94ms
- Total Children
- 0ms
- Total runtime
- 0.94ms
SELECT "subject_answers".* FROM "subject_answers" WHERE "subject_answers"."type" = ? AND "subject_answers"."subject_questionable_id" = ? AND "subject_answers"."subject_questionable_type" = ?
|
|
sql
app/services/diagnosis_creation/steps.rb:51
|
<1%
|
app/services/diagnosis_creation/steps.rb:51
- Average Self
-
0.94ms
- Average calls
- 0.91x
- Total Self
- 0.86ms
- Total Children
- 0ms
- Total runtime
- 0.86ms
SELECT "matches".* FROM "matches" INNER JOIN "needs" ON "matches"."need_id" = "needs"."id" WHERE "needs"."diagnosis_id" = ?
|
|
sql
app/services/diagnosis_creation/create_matches.rb:15
|
<1%
|
app/services/diagnosis_creation/create_matches.rb:15
- Average Self
-
0.47ms
- Average calls
- 1.8x
- Total Self
- 0.83ms
- Total Children
- 0ms
- Total runtime
- 0.83ms
SELECT "subjects".* FROM "subjects" INNER JOIN "institutions_subjects" ON "subjects"."id" = "institutions_subjects"."subject_id" WHERE "institutions_subjects"."id" = ? LIMIT ?
|
|
sql
app/models/need.rb:462
|
<1%
|
app/models/need.rb:462
- Average Self
-
0.46ms
- Average calls
- 1.8x
- Total Self
- 0.81ms
- Total Children
- 0ms
- Total runtime
- 0.81ms
SELECT "matches".* FROM "matches" WHERE "matches"."need_id" = ?
|
|
sql
app/services/diagnosis_creation/steps.rb:54
|
<1%
|
app/services/diagnosis_creation/steps.rb:54
- Average Self
-
0.84ms
- Average calls
- 0.87x
- Total Self
- 0.73ms
- Total Children
- 0ms
- Total runtime
- 0.73ms
UPDATE "diagnoses" SET "updated_at" = ?, "step" = ? WHERE "diagnoses"."id" = ?
|
|
sql
app/models/solicitation.rb:705
|
<1%
|
app/models/solicitation.rb:705
- Average Self
-
1.2ms
- Average calls
- 0.58x
- Total Self
- 0.7ms
- Total Children
- 0ms
- Total runtime
- 0.7ms
SELECT "spams".* FROM "spams" WHERE "spams"."email" = ? LIMIT ?
|
|
sql
app/models/solicitation.rb:702
|
<1%
|
app/models/solicitation.rb:702
- Average Self
-
1.3ms
- Average calls
- 0.4x
- Total Self
- 0.52ms
- Total Children
- 0ms
- Total runtime
- 0.52ms
SELECT "spams".* FROM "spams" WHERE "spams"."email" = ? LIMIT ?
|
|
sql
app/services/diagnosis_creation/find_relevant_expert_subjects.rb:62
|
<1%
|
app/services/diagnosis_creation/find_relevant_expert_subjects.rb:62
- Average Self
-
0.68ms
- Average calls
- 0.74x
- Total Self
- 0.5ms
- Total Children
- 0ms
- Total runtime
- 0.5ms
SELECT "subject_answers".* FROM "subject_answers" WHERE "subject_answers"."type" = ? AND "subject_answers"."subject_answer_grouping_id" = ?
|
|
sql
app/models/facility.rb:84
|
<1%
|
app/models/facility.rb:84
- Average Self
-
0.55ms
- Average calls
- 0.87x
- Total Self
- 0.48ms
- Total Children
- 0ms
- Total runtime
- 0.48ms
SELECT "companies".* FROM "companies" WHERE "companies"."id" = ? LIMIT ?
|
|
sql
app/services/diagnosis_creation/find_relevant_expert_subjects.rb:161
|
<1%
|
app/services/diagnosis_creation/find_relevant_expert_subjects.rb:161
- Average Self
-
0.71ms
- Average calls
- 0.68x
- Total Self
- 0.48ms
- Total Children
- 0ms
- Total runtime
- 0.48ms
SELECT "companies".* FROM "companies" INNER JOIN "facilities" ON "companies"."id" = "facilities"."company_id" INNER JOIN "diagnoses" ON "facilities"."id" = "diagnoses"."facility_id" WHERE "diagnoses"."id" = ? LIMIT ?
|
|
sql
app/models/subject.rb:132
|
<1%
|
app/models/subject.rb:132
- Average Self
-
0.43ms
- Average calls
- 0.89x
- Total Self
- 0.38ms
- Total Children
- 0ms
- Total runtime
- 0.38ms
SELECT "subjects".* FROM "subjects" WHERE "subjects"."slug" = ? LIMIT ?
|
|
sql
app/services/diagnosis_creation/find_relevant_expert_subjects.rb:157
|
<1%
|
app/services/diagnosis_creation/find_relevant_expert_subjects.rb:157
- Average Self
-
0.41ms
- Average calls
- 0.87x
- Total Self
- 0.36ms
- Total Children
- 0ms
- Total runtime
- 0.36ms
SELECT "facilities".* FROM "facilities" INNER JOIN "diagnoses" ON "facilities"."id" = "diagnoses"."facility_id" WHERE "diagnoses"."id" = ? LIMIT ?
|
|
sql
app/services/diagnosis_creation/steps.rb:13
|
<1%
|
app/services/diagnosis_creation/steps.rb:13
- Average Self
-
0.4ms
- Average calls
- 0.89x
- Total Self
- 0.35ms
- Total Children
- 0ms
- Total runtime
- 0.35ms
UPDATE "diagnoses" SET "updated_at" = ?, "happened_on" = ? WHERE "diagnoses"."id" = ?
|
|
sql
app/services/api_consumption/models/facility/api_entreprise.rb:123
|
<1%
|
app/services/api_consumption/models/facility/api_entreprise.rb:123
- Average Self
-
1.6ms
- Average calls
- 0.19x
- Total Self
- 0.31ms
- Total Children
- 0ms
- Total runtime
- 0.31ms
SELECT "institutions".* FROM "institutions" INNER JOIN "categories_institutions" ON "categories_institutions"."institution_id" = "institutions"."id" INNER JOIN "categories" ON "categories"."id" = "categories_institutions"."category_id" WHERE "institutions"."deleted_at" IS NULL AND "categories"."label" = ? AND "institutions"."siren" = ? LIMIT ?
|
|
sql
app/services/diagnosis_creation/steps.rb:31
|
<1%
|
app/services/diagnosis_creation/steps.rb:31
- Average Self
-
0.35ms
- Average calls
- 0.89x
- Total Self
- 0.31ms
- Total Children
- 0ms
- Total runtime
- 0.31ms
SELECT "needs".* FROM "needs" WHERE "needs"."diagnosis_id" = ?
|
|
sql
app/services/diagnosis_creation/find_relevant_expert_subjects.rb:64
|
<1%
|
app/services/diagnosis_creation/find_relevant_expert_subjects.rb:64
- Average Self
-
0.28ms
- Average calls
- 1x
- Total Self
- 0.29ms
- Total Children
- 0ms
- Total runtime
- 0.29ms
SELECT "subject_answers".* FROM "subject_answers" WHERE "subject_answers"."type" = ? AND "subject_answers"."subject_questionable_id" = ? AND "subject_answers"."subject_questionable_type" = ? AND "subject_answers"."subject_question_id" = ? LIMIT ?
|
|
sql
app/models/concerns/mandatory_answers.rb:19
|
<1%
|
app/models/concerns/mandatory_answers.rb:19
- Average Self
-
0.13ms
- Average calls
- 1.8x
- Total Self
- 0.23ms
- Total Children
- 0ms
- Total runtime
- 0.23ms
SELECT ? AS one FROM "subject_questions" WHERE "subject_questions"."subject_id" = ? LIMIT ?
|
|
sql
app/services/diagnosis_creation/create_matches.rb:22
|
<1%
|
app/services/diagnosis_creation/create_matches.rb:22
- Average Self
-
0.21ms
- Average calls
- 0.87x
- Total Self
- 0.19ms
- Total Children
- 0ms
- Total runtime
- 0.19ms
SELECT "matches".* FROM "matches" INNER JOIN "needs" ON "matches"."need_id" = "needs"."id" WHERE "needs"."diagnosis_id" = ?
|
|
sql
app/models/concerns/mandatory_answers.rb:17
|
<1%
|
app/models/concerns/mandatory_answers.rb:17
- Average Self
-
0.1ms
- Average calls
- 1.9x
- Total Self
- 0.18ms
- Total Children
- 0ms
- Total runtime
- 0.18ms
SELECT ? AS one FROM "subject_questions" WHERE "subject_questions"."subject_id" = ? LIMIT ?
|
|
sql
app/models/facility.rb:104
|
<1%
|
app/models/facility.rb:104
- Average Self
-
0.71ms
- Average calls
- 0.19x
- Total Self
- 0.13ms
- Total Children
- 0ms
- Total runtime
- 0.13ms
SELECT "institutions".* FROM "institutions" INNER JOIN "categories_institutions" ON "categories_institutions"."institution_id" = "institutions"."id" INNER JOIN "categories" ON "categories"."id" = "categories_institutions"."category_id" WHERE "institutions"."id" = ? AND "institutions"."deleted_at" IS NULL AND "categories"."label" = ? LIMIT ?
|
|
sql
app/models/expert_subject.rb:83
|
<1%
|
app/models/expert_subject.rb:83
- Average Self
-
0.3ms
- Average calls
- 0.31x
- Total Self
- 0.09ms
- Total Children
- 0ms
- Total runtime
- 0.09ms
SELECT "institutions".* FROM "institutions" WHERE "institutions"."slug" = ? LIMIT ?
|
|
code
vendor/bundle/ruby/4.0.0/gems/activesupport-8.1.3/lib/active_support/callbacks.rb:130
|
<1%
|
vendor/bundle/ruby/4.0.0/gems/activesupport-8.1.3/lib/active_support/callbacks.rb:130
- Average Self
-
0.09ms
- Average calls
- 1x
- Total Self
- 0.09ms
- Total Children
- 3,306ms
- Total runtime
- 3,307ms
CreateAutomaticDiagnosisJob
|
|
sql
app/models/expert_subject.rb:85
|
<1%
|
app/models/expert_subject.rb:85
- Average Self
-
0.19ms
- Average calls
- 0.44x
- Total Self
- 0.08ms
- Total Children
- 0ms
- Total runtime
- 0.08ms
SELECT "institutions".* FROM "institutions" WHERE "institutions"."slug" = ? LIMIT ?
|
|
sql
app/models/diagnosis.rb:225
|
<1%
|
app/models/diagnosis.rb:225
- Average Self
-
0.64ms
- Average calls
- 0.1x
- Total Self
- 0.07ms
- Total Children
- 0ms
- Total runtime
- 0.07ms
SELECT ? AS one FROM "needs" WHERE "needs"."diagnosis_id" = ? LIMIT ?
SELECT "needs".* FROM "needs" WHERE "needs"."diagnosis_id" = ?
|
|
code
vendor/bundle/ruby/4.0.0/gems/sidekiq-8.1.6/lib/sidekiq/middleware/chain.rb:182
|
<1%
|
vendor/bundle/ruby/4.0.0/gems/sidekiq-8.1.6/lib/sidekiq/middleware/chain.rb:182
- Average Self
-
0.06ms
- Average calls
- 0.95x
- Total Self
- 0.06ms
- Total Children
- 3,280ms
- Total runtime
- 3,280ms
|
|
sql
app/models/expert_subject.rb:84
|
<1%
|
app/models/expert_subject.rb:84
- Average Self
-
0.2ms
- Average calls
- 0.21x
- Total Self
- 0.04ms
- Total Children
- 0ms
- Total runtime
- 0.04ms
SELECT "institutions".* FROM "institutions" WHERE "institutions"."slug" = ? LIMIT ?
|
|
sql
app/models/diagnosis.rb:217
|
<1%
|
app/models/diagnosis.rb:217
- Average Self
-
0.71ms
- Average calls
- 0.03x
- Total Self
- 0.02ms
- Total Children
- 0ms
- Total runtime
- 0.02ms
SELECT "needs".* FROM "needs" WHERE "needs"."diagnosis_id" = ?
|
|
sql
app/services/diagnosis_creation/steps.rb:18
|
<1%
|
app/services/diagnosis_creation/steps.rb:18
- Average Self
-
0.43ms
- Average calls
- 0.03x
- Total Self
- 0.01ms
- Total Children
- 0ms
- Total runtime
- 0.01ms
SELECT "contacts".* FROM "contacts" WHERE "contacts"."id" = ? LIMIT ?
|
|
sql
app/models/concerns/mandatory_answers.rb:24
|
<1%
|
app/models/concerns/mandatory_answers.rb:24
- Average Self
-
0ms
- Average calls
- 0.33x
- Total Self
- 0ms
- Total Children
- 0ms
- Total runtime
- 0ms
SELECT "subject_questions"."id" FROM "subject_questions" WHERE "subject_questions"."subject_id" = ?
|