Custom local cache?

Discussion forum for Extension Writers regarding Extension Development.
Post Reply
User avatar
Toxyy
Registered User
Posts: 594
Joined: Mon Oct 24, 2016 3:22 pm
Location: Namek
Contact:

Custom local cache?

Post by Toxyy » Mon May 07, 2018 2:16 am

So I'm thinking about making something that would incorporate some machine learning just cuz.

Now I don't want to bog down the database with a bunch of searches, as it would require parsing through at least the current forum's topic list -

here's what I'm asking -

can I download a current forum's topic list or whatever topic list I want locally, and query that list instead of the server's? Preferably compatible with ajax.

I can't think of another way to have a whole topiclist queried without slowing down the server every time someone wants to make a topic.
I am a web developer/administrator, specializing in forums. If you have work you need done or are too lazy to do, pm me!

My extensions:
[3.2][BETA] Anonymous Posts || [3.2][RC] Show User Activity

User avatar
martti
Registered User
Posts: 684
Joined: Thu Jul 31, 2014 8:23 am
Location: Belgium

Re: Custom local cache?

Post by martti » Mon May 07, 2018 9:58 am


User avatar
Toxyy
Registered User
Posts: 594
Joined: Mon Oct 24, 2016 3:22 pm
Location: Namek
Contact:

Re: Custom local cache?

Post by Toxyy » Mon May 07, 2018 4:46 pm

martti wrote:
Mon May 07, 2018 9:58 am
viewtopic.php?f=461&t=2367726
While these functions work with phpbb they don't really pertain to the database issue I'm describing.

Essentially, every time someone posts, I would take a few keywords from their topic title and get a list of 5 or so related topics using the current forum's topic list. So I would either have to query the database every single time someone clicks new topic, which I can get around by making a json (or a lot of jsons per forum) for the forum. Then I'd only need that json updated a few times a day by the server itself.

But going that route I'm not too sure how to avoid needing a massive json, or multiple jsons. I was hoping there was a better way.
I am a web developer/administrator, specializing in forums. If you have work you need done or are too lazy to do, pm me!

My extensions:
[3.2][BETA] Anonymous Posts || [3.2][RC] Show User Activity

User avatar
canonknipser
Registered User
Posts: 1704
Joined: Thu Sep 08, 2011 4:16 am
Location: Germany
Name: Frank Jakobs
Contact:

Re: Custom local cache?

Post by canonknipser » Mon May 07, 2018 5:02 pm

So you want to build something like this? https://www.phpbb.com/customise/db/exte ... lar_topics
Greetings, Frank
phpbb.de support team member
English is not my native language - no support via PM or mail
New arrival - Extensions and scripts for phpBB

User avatar
Toxyy
Registered User
Posts: 594
Joined: Mon Oct 24, 2016 3:22 pm
Location: Namek
Contact:

Re: Custom local cache?

Post by Toxyy » Mon May 07, 2018 5:08 pm

canonknipser wrote:
Mon May 07, 2018 5:02 pm
So you want to build something like this? https://www.phpbb.com/customise/db/exte ... lar_topics
Yes, but using ajax, and having it appear while you're making a topic. I'm going to be writing my own recommender system as well since I want to build my github up. Since I'd be using ajax, caching the query is pretty important, because if they change their topic title the list of similar topics would change.

I was looking in the wiki and this seems promising:
https://wiki.phpbb.com/Cache

So I could cache a specific sql query and work with the cache that way, instead of having to make a json possibly. Though I'd need a json for the ajax preferably. Still working out the beginning stages here.
I am a web developer/administrator, specializing in forums. If you have work you need done or are too lazy to do, pm me!

My extensions:
[3.2][BETA] Anonymous Posts || [3.2][RC] Show User Activity

Post Reply

Return to “Extension Writers Discussion”

Who is online

Users browsing this forum: No registered users and 6 guests