Voici la réponse à la recherche de « patrick » dans la vue abonnement.
root@serveur:~# tail -f /apps/fabmanager/log/app-stdout.log
Started GET "/api/notifications/polling?last_poll=2019-01-19T14:32:54.488Z" for 90.17.218.53 at 2019-01-19 14:33:24 +0000
Processing by API::NotificationsController#polling as JSON
Parameters: {"last_poll"=>"2019-01-19T14:32:54.488Z"}
User Load (0.6ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 ORDER BY "users"."id" ASC LIMIT 1 [["id", 1]]
(1.4ms) SELECT COUNT(*) FROM "notifications" WHERE "notifications"."receiver_id" = $1 AND "notifications"."receiver_type" = $2 [["receive
r_id", 1], ["receiver_type", "User"]]
(1.0ms) SELECT COUNT(*) FROM "notifications" WHERE "notifications"."receiver_id" = $1 AND "notifications"."receiver_type" = $2 AND "notifi
cations"."is_read" = $3 [["receiver_id", 1], ["receiver_type", "User"], ["is_read", "f"]]
Notification Load (1.0ms) SELECT "notifications".* FROM "notifications" WHERE "notifications"."receiver_id" = $1 AND "notifications"."recei
ver_type" = $2 AND (is_read = false AND created_at >= '2019-01-19T14:32:54.488Z') ORDER BY created_at DESC [["receiver_id", 1], ["receiver_t
ype", "User"]]
Rendered api/notifications/index.json.jbuilder (2.1ms)
Completed 200 OK in 12ms (Views: 1.6ms | ActiveRecord: 4.0ms | Elasticsearch: 0.0ms)
Started GET "/api/members/search/patrick?subscription=false" for 90.17.218.53 at 2019-01-19 14:33:53 +0000
Processing by API::MembersController#search as JSON
Parameters: {"subscription"=>"false", "query"=>"patrick"}
User Load (0.7ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 ORDER BY "users"."id" ASC LIMIT 1 [["id", 1]]
Role Load (0.4ms) SELECT "roles".* FROM "roles" INNER JOIN "users_roles" ON "roles"."id" = "users_roles"."role_id" WHERE "users_roles"."use
r_id" = $1 AND (((roles.name = 'member') AND (roles.resource_type IS NULL) AND (roles.resource_id IS NULL))) [["user_id", 1]]
SQL (2.0ms) SELECT "users"."id" AS t0_r0, "users"."email" AS t0_r1, "users"."encrypted_password" AS t0_r2, "users"."reset_password_token" A
S t0_r3, "users"."reset_password_sent_at" AS t0_r4, "users"."remember_created_at" AS t0_r5, "users"."sign_in_count" AS t0_r6, "users"."current
_sign_in_at" AS t0_r7, "users"."last_sign_in_at" AS t0_r8, "users"."current_sign_in_ip" AS t0_r9, "users"."last_sign_in_ip" AS t0_r10, "users"
."confirmation_token" AS t0_r11, "users"."confirmed_at" AS t0_r12, "users"."confirmation_sent_at" AS t0_r13, "users"."unconfirmed_email" AS t0
_r14, "users"."failed_attempts" AS t0_r15, "users"."unlock_token" AS t0_r16, "users"."locked_at" AS t0_r17, "users"."created_at" AS t0_r18, "u
sers"."updated_at" AS t0_r19, "users"."is_allow_contact" AS t0_r20, "users"."group_id" AS t0_r21, "users"."stp_customer_id" AS t0_r22, "users"
."username" AS t0_r23, "users"."slug" AS t0_r24, "users"."is_active" AS t0_r25, "users"."invoicing_disabled" AS t0_r26, "users"."provider" AS
t0_r27, "users"."uid" AS t0_r28, "users"."auth_token" AS t0_r29, "users"."merged_at" AS t0_r30, "users"."is_allow_newsletter" AS t0_r31, "prof
iles"."id" AS t1_r0, "profiles"."user_id" AS t1_r1, "profiles"."first_name" AS t1_r2, "profiles"."last_name" AS t1_r3, "profiles"."gender" AS
t1_r4, "profiles"."birthday" AS t1_r5, "profiles"."phone" AS t1_r6, "profiles"."interest" AS t1_r7, "profiles"."software_mastered" AS t1_r8, "
profiles"."created_at" AS t1_r9, "profiles"."updated_at" AS t1_r10, "profiles"."facebook" AS t1_r11, "profiles"."twitter" AS t1_r12, "profiles
"."google_plus" AS t1_r13, "profiles"."viadeo" AS t1_r14, "profiles"."linkedin" AS t1_r15, "profiles"."instagram" AS t1_r16, "profiles"."youtu
be" AS t1_r17, "profiles"."vimeo" AS t1_r18, "profiles"."dailymotion" AS t1_r19, "profiles"."github" AS t1_r20, "profiles"."echosciences" AS t
1_r21, "profiles"."website" AS t1_r22, "profiles"."pinterest" AS t1_r23, "profiles"."lastfm" AS t1_r24, "profiles"."flickr" AS t1_r25, "profil
es"."job" AS t1_r26 FROM "users" INNER JOIN "profiles" ON "profiles"."user_id" = "users"."id" INNER JOIN "users_roles" ON "users_roles"."user_
id" = "users"."id" INNER JOIN "roles" ON "roles"."id" = "users_roles"."role_id" LEFT JOIN "subscriptions" ON "subscriptions"."user_id" = "user
s"."id" WHERE (users.is_active = 'true' AND roles.name = 'member') AND (lower(f_unaccent(profiles.first_name)) ~ regexp_replace('patrick', E'\
\s+', '|') OR lower(f_unaccent(profiles.last_name)) ~ regexp_replace('patrick', E'\\s+', '|')) AND (subscriptions.id IS NULL OR subscriptions.
expired_at < '2019-01-19')
Completed 500 Internal Server Error in 15ms (ActiveRecord: 3.0ms | Elasticsearch: 0.0ms)
ActiveRecord::StatementInvalid (PG::UndefinedColumn: ERROR: column subscriptions.expired_at does not exist
LINE 1: ..., E'\\s+', '|')) AND (subscriptions.id IS NULL OR subscripti...
^
: SELECT "users"."id" AS t0_r0, "users"."email" AS t0_r1, "users"."encrypted_password" AS t0_r2, "users"."reset_password_token" AS t0_r3, "use
rs"."reset_password_sent_at" AS t0_r4, "users"."remember_created_at" AS t0_r5, "users"."sign_in_count" AS t0_r6, "users"."current_sign_in_at"
AS t0_r7, "users"."last_sign_in_at" AS t0_r8, "users"."current_sign_in_ip" AS t0_r9, "users"."last_sign_in_ip" AS t0_r10, "users"."confirmatio
n_token" AS t0_r11, "users"."confirmed_at" AS t0_r12, "users"."confirmation_sent_at" AS t0_r13, "users"."unconfirmed_email" AS t0_r14, "users"
."failed_attempts" AS t0_r15, "users"."unlock_token" AS t0_r16, "users"."locked_at" AS t0_r17, "users"."created_at" AS t0_r18, "users"."update
d_at" AS t0_r19, "users"."is_allow_contact" AS t0_r20, "users"."group_id" AS t0_r21, "users"."stp_customer_id" AS t0_r22, "users"."username" A
S t0_r23, "users"."slug" AS t0_r24, "users"."is_active" AS t0_r25, "users"."invoicing_disabled" AS t0_r26, "users"."provider" AS t0_r27, "user
s"."uid" AS t0_r28, "users"."auth_token" AS t0_r29, "users"."merged_at" AS t0_r30, "users"."is_allow_newsletter" AS t0_r31, "profiles"."id" AS
t1_r0, "profiles"."user_id" AS t1_r1, "profiles"."first_name" AS t1_r2, "profiles"."last_name" AS t1_r3, "profiles"."gender" AS t1_r4, "profi
les"."birthday" AS t1_r5, "profiles"."phone" AS t1_r6, "profiles"."interest" AS t1_r7, "profiles"."software_mastered" AS t1_r8, "profiles"."cr
eated_at" AS t1_r9, "profiles"."updated_at" AS t1_r10, "profiles"."facebook" AS t1_r11, "profiles"."twitter" AS t1_r12, "profiles"."google_plu
s" AS t1_r13, "profiles"."viadeo" AS t1_r14, "profiles"."linkedin" AS t1_r15, "profiles"."instagram" AS t1_r16, "profiles"."youtube" AS t1_r17
, "profiles"."vimeo" AS t1_r18, "profiles"."dailymotion" AS t1_r19, "profiles"."github" AS t1_r20, "profiles"."echosciences" AS t1_r21, "profi
les"."website" AS t1_r22, "profiles"."pinterest" AS t1_r23, "profiles"."lastfm" AS t1_r24, "profiles"."flickr" AS t1_r25, "profiles"."job" AS
t1_r26 FROM "users" INNER JOIN "profiles" ON "profiles"."user_id" = "users"."id" INNER JOIN "users_roles" ON "users_roles"."user_id" = "users"
."id" INNER JOIN "roles" ON "roles"."id" = "users_roles"."role_id" LEFT JOIN "subscriptions" ON "subscriptions"."user_id" = "users"."id" WHERE
(users.is_active = 'true' AND roles.name = 'member') AND (lower(f_unaccent(profiles.first_name)) ~ regexp_replace('patrick', E'\\s+', '|') OR
lower(f_unaccent(profiles.last_name)) ~ regexp_replace('patrick', E'\\s+', '|')) AND (subscriptions.id IS NULL OR subscriptions.expired_at <
'2019-01-19')):
app/controllers/api/members_controller.rb:241:in `search'
Started GET "/api/notifications/polling?last_poll=2019-01-19T14:33:23.638Z" for 90.17.218.53 at 2019-01-19 14:33:54 +0000
Processing by API::NotificationsController#polling as JSON
Parameters: {"last_poll"=>"2019-01-19T14:33:23.638Z"}
User Load (0.8ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 ORDER BY "users"."id" ASC LIMIT 1 [["id", 1]]
(3.0ms) SELECT COUNT(*) FROM "notifications" WHERE "notifications"."receiver_id" = $1 AND "notifications"."receiver_type" = $2 [["receive
r_id", 1], ["receiver_type", "User"]]
(2.2ms) SELECT COUNT(*) FROM "notifications" WHERE "notifications"."receiver_id" = $1 AND "notifications"."receiver_type" = $2 AND "notifi
cations"."is_read" = $3 [["receiver_id", 1], ["receiver_type", "User"], ["is_read", "f"]]
Notification Load (2.1ms) SELECT "notifications".* FROM "notifications" WHERE "notifications"."receiver_id" = $1 AND "notifications"."recei
ver_type" = $2 AND (is_read = false AND created_at >= '2019-01-19T14:33:23.638Z') ORDER BY created_at DESC [["receiver_id", 1], ["receiver_t
ype", "User"]]
Rendered api/notifications/index.json.jbuilder (3.8ms)
Completed 200 OK in 26ms (Views: 2.7ms | ActiveRecord: 8.0ms | Elasticsearch: 0.0ms)
^[[DStarted GET "/api/notifications/polling?last_poll=2019-01-19T14:33:53.839Z" for 90.17.218.53 at 2019-01-19 14:34:24 +0000
Processing by API::NotificationsController#polling as JSON
Parameters: {"last_poll"=>"2019-01-19T14:33:53.839Z"}
User Load (0.7ms) SELECT "users".* FROM "users" WHERE "users"."id" = $1 ORDER BY "users"."id" ASC LIMIT 1 [["id", 1]]
(2.5ms) SELECT COUNT(*) FROM "notifications" WHERE "notifications"."receiver_id" = $1 AND "notifications"."receiver_type" = $2 [["receive
r_id", 1], ["receiver_type", "User"]]
(1.0ms) SELECT COUNT(*) FROM "notifications" WHERE "notifications"."receiver_id" = $1 AND "notifications"."receiver_type" = $2 AND "notifi
cations"."is_read" = $3 [["receiver_id", 1], ["receiver_type", "User"], ["is_read", "f"]]
Notification Load (1.0ms) SELECT "notifications".* FROM "notifications" WHERE "notifications"."receiver_id" = $1 AND "notifications"."recei
ver_type" = $2 AND (is_read = false AND created_at >= '2019-01-19T14:33:53.839Z') ORDER BY created_at DESC [["receiver_id", 1], ["receiver_t
ype", "User"]]
Rendered api/notifications/index.json.jbuilder (2.9ms)
Completed 200 OK in 18ms (Views: 3.1ms | ActiveRecord: 5.2ms | Elasticsearch: 0.0ms)