kutaybuyukkorukcu / devnews-fv Goto Github PK
View Code? Open in Web Editor NEWLicense: GNU General Public License v3.0
License: GNU General Public License v3.0
Behaivoral design pattern -> prob strategy.
counterValue() fonksiyonu url'ler crawl edilirken unique Id atamak icin kullaniliyor.
Her kayit icin Id'yi belirlemek icin counterValue() kullanmaktansa collection'da bulunan bir onceki kayitin id'si alinip ona +1 ekleyip, yeni kayida Id atanabilir.
// Bad wording. But i know i'll get it so nw.
request to v1/recommend -> database de kisinin begendigi makalelerin linkleri URL collectioni altinda tutuluyor. v1/recommend calistigi zaman bu article linkler crawllanip Like collectionu icerisine yazilir.
v1/recommend is a one per week request so it might not be a problem to think about.
The kick is we have to update isNew field from true to false every single week in order to avoid conflict.
3.5 out of 6 services are already done.
Will continue later.
Implementing new crawler endpoint for subreddits
Handling user operations
Login, register, JWT etc.
Making API to return a template class composed of status code, message, data and status (error, success)
When transitioning to Spring Framework i should use Response Entity.
using @transactional on service layer
Need an alternative for @transactional currently not using Spring
Check for best practice. (React)
Also don't forget to check Spring Security's solution to resolving JWT on every single request.
Catch from service layer and throw into - handle on controller or
Catch from service layer using Optional OrElse and handle on controller
Still searching for what do use as DI
Guice, Dagger, javax.inject etc.
App.java contains all the controller and the database stuff.
Make database stuff service layer thing and remove them from controller (inject them into service layer)
Data ve Article kavramlarinin isimleri birbirinden ayristirilacak.
Biri raw digeri raw data degil. DB'de data adli collection yerine Article adli collection olmasi daha mantikli.
Data -> Article yapip, Article derken de recommendationdan donen makaleler oldugunu yani recommended content oldugunu belirtmemiz gerekir.
Isimlerdirmelerde degisime gidilecek.
Caching most viewed/visited subreddits. Refresh the cached data every single day and automate the process.
Implementing slf4j and adding logging functions for try / catch blocks
Service katmanindan donen response'u duzenlemek lazim.
Service katmaninda insert() oncesi yapilan kontrollerden gecemiyor ise exception mi atmaliyim? Ve bu exceptioni atarak controller tarafinda try/catch ile yakalayip controller da buna gore mi donus yapmaliyim?
Ornegin API'ma request yapilinca kayit islemi yapiyor. Service katmaninda ekleme de hata cikarsa bu exception controller tarafina nasil gonderilmeli? Approach 1 -> Service katmani tarafinda insert() islemi yapmadan once yapilan kontrollerden gecemiyorsa exception yollanmali ve controller tarafinda bu exception try/catch ile catchlenmeli ve ona gore controller da response atilmali ?
Should i take it as a consideration? Is it worth changing mongodb api?
Create a static getMongoDatabase() function for decreasing the usage of MongoDatabase parameter in db functions.
getNextArticleIdSequence()'yu ile ayri bir collection yaratip bu collection uzerinden id hesaplamak yerine Data collectionundaki articleID elemani $inc edilerek auto increment ID fonksiyonu elde edilecektir.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.