Skip to content

Next

  • Projects
  • Groups
  • Snippets
  • Help
    • Loading...
    • Help
    • Support
    • Submit feedback
    • Contribute to GitLab
    • Switch to GitLab Next
  • Sign in / Register
Minds Backend - Engine
Minds Backend - Engine
  • Project
    • Project
    • Details
    • Activity
    • Releases
    • Cycle Analytics
    • Insights
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
    • Charts
    • Locked Files
  • Issues 225
    • Issues 225
    • List
    • Boards
    • Labels
    • Service Desk
    • Milestones
  • Merge Requests 32
    • Merge Requests 32
  • CI / CD
    • CI / CD
    • Pipelines
    • Jobs
    • Schedules
    • Charts
  • Security & Compliance
    • Security & Compliance
    • Dependency List
  • Packages
    • Packages
    • List
    • Container Registry
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Members
    • Members
  • Collapse sidebar
  • Activity
  • Graph
  • Charts
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
  • Minds
  • Minds Backend - EngineMinds Backend - Engine
  • Merge Requests
  • !347

Open
Opened 1 week ago by Ben Hayward@benhayward.ben
  • Report abuse
Report abuse

[Sprint/OldfashionedOwl](fix): Subscription feed upgrade #435

Closes #435

Summary

This page was using some very old code, so I've upgraded it to use the paging tokens. This should avoid situations like this: https://www.minds.com/kratommotivation1/subscriptions

Testing

To test, pick a user with some subscriptions, and visit /{user}/subscriptions.

Click through subscriptions and subscribers, scroll up and down. https://fix-subscription-feed-435.minds.io/

For bonus points, deploy against live data and check: https://www.minds.com/kratommotivation1/subscriptions

Edited 1 week ago by Ben Hayward

Check out, review, and merge locally

Step 1. Fetch and check out the branch for this merge request

git fetch origin
git checkout -b "fix/subscription-feed-435" "origin/fix/subscription-feed-435"

Step 2. Review the changes locally

Step 3. Merge the branch and fix any conflicts that come up

git fetch origin
git checkout "origin/master"
git merge --no-ff "fix/subscription-feed-435"

Step 4. Push the result of the merge to GitLab

git push origin "master"

Note that pushing to GitLab requires write access to this repository.

Tip: You can also checkout merge requests locally by following these guidelines.

Request to merge fix/subscription-feed-435 into master
The source branch is 33 commits behind the target branch
Open in Web IDE
  • Email patches
  • Plain diff
Pipeline #84839674 passed for 0f12af4c on fix/subscription-feed-435
          Requires 3 more approvals from Devs, Deployers, and QA.
          Rami Albatal
          Rami Albatal
          Mark Harding
          Mark Harding
          Marcelo Rivera
          Marcelo Rivera
          Emiliano Balbuena
          Emiliano Balbuena
          Olivia Madrid
          Olivia Madrid
          Ready to be merged automatically. Ask someone with write access to this repository to merge this request

          Closes #435

          Deletes source branch

          • Discussion 3
          • Commits 2
          • Pipelines 2
          • Changes 5
          0/3 threads resolved
          • Loading...
          • Ben Hayward @benhayward.ben added Squad::Yellow scoped label 1 week ago

            added Squad::Yellow scoped label

          • Ben Hayward @benhayward.ben added 1 commit 1 week ago

            added 1 commit

            • 0f12af4c - Updated

            Compare with previous version

          • Ben Hayward @benhayward.ben unmarked as a Work In Progress 1 week ago

            unmarked as a Work In Progress

          • Ben Hayward @benhayward.ben changed the description 1 week ago

            changed the description

          • Ben Hayward @benhayward.ben added MR::Awaiting Review scoped label 1 week ago

            added MR::Awaiting Review scoped label

          • Mark Harding
            Mark Harding @markeharding started a thread on the diff 1 hour ago
            Core/Subscriptions/Repository.php
            41 if (!$opts['guid']) {
            42 throw new \Exception('GUID is required');
            43 }
            44
            45 $response = new Response;
            46 if ($opts['type'] === 'subscribers') {
            47 $statement = "SELECT * FROM friends";
            48 } else {
            49 $statement = "SELECT * FROM friendsof";
            50 }
            51
            52 $where = ["column1 = ?"];
            53 $values = [$opts['guid']];
            54
            55 $statement .= " WHERE " . implode(' AND ', $where);
            56 $statement .= " ALLOW FILTERING";
            • Mark Harding
              Mark Harding @markeharding · 1 hour ago
              Owner

              Why are we using allow filtering?

            • Please register or sign in to reply
          • Mark Harding
            Mark Harding @markeharding started a thread on the diff 1 hour ago
            Core/Data/Cassandra/Prepared/Custom.php
            37 37 {
            38 38 return $this->opts;
            39 39 }
            40
            41 public function getTemplate()
            • Mark Harding
              Mark Harding @markeharding · 1 hour ago
              Owner

              can we get some doc markup and return type : string?

            • Please register or sign in to reply
          • Mark Harding
            Mark Harding @markeharding started a thread on the diff 1 hour ago
            Core/Subscriptions/Repository.php
            20 20 }
            21 21
            22 22 /**
            23 * @param array $opts
            24 * @return Response
            23 * Gets a subscription or subscribers list from cassandra.
            24 *
            25 * @param array $opts -
            26 * guid - required!
            27 * type - either 'subscribers' or 'subscriptions'.
            28 * limit - limit.
            29 * offset - offset.
            30 * @return Response response object.
            25 31 */
            26 32 public function getList(array $opts = [])
            • Mark Harding
              Mark Harding @markeharding · 1 hour ago
              Owner

              : Response

            • Please register or sign in to reply
          • Mark Harding @markeharding added MR::Requires Changes scoped label and automatically removed MR::Awaiting Review label 1 hour ago

            added MR::Requires Changes scoped label and automatically removed MR::Awaiting Review label

          • You're only seeing other activity in the feed. To add a comment, switch to one of the following options.
          Please register or sign in to reply
          0 Assignees
          None
          Assign to
          None
          Milestone
          None
          Assign milestone
          None
          Time tracking
          No estimate or time spent
          2
          Labels
          MR::Requires Changes Squad::Yellow
          Assign labels
          • View project labels
          Lock merge request
          Unlocked
          10
          10 participants
          user avatar
          Rami Albatal
          user avatar
          Mark Harding
          user avatar
          Marcelo Rivera
          user avatar
          Emiliano Balbuena
          user avatar
          Olivia Madrid
          user avatar
          Martin Santangelo
          user avatar
          Brian Hatchet
          Reference: minds/engine!347