Cixak95211's Posts
Nairaland Forum › Cixak95211's Profile › Cixak95211's Posts
1 2 3 4 5 6 7 8 9 10 11 12 13 (of 13 pages)
stanliwise:You were kinda right before, then you took a swift turn . . . APIs go far more than a frontend calling a backend service. That would be classified under 3rd party APIs There are Language APIs which are constructs built on the core layer to help the language interact with stuffs, for example, in Javascript: there is a browser API . . that allows Javascript communicate with the browser. Under browser API for example, there is a Device API , this api contains a Vibrate API which makes your device vibrate . . There is a Storage API, localstorage, cookie and indexed db comes to mind . . Audio and Video API . . the list is very long . What Dan was trying to tell you that these interfaces are not for you to learn, cos that's how the language communicates with the environment. They are sub-levels, Your own job is the high-level part of it, the 3rd party API part . . . Truly, APIs goes way beyond /GET /PUT /PATCH /POST and /DELETE request to a server sitting somewhere. This right here is one of the problems with being "self-taught". While its a good thing, it comes with a whole lot of limitations. Cos 99.99% of the tutorials on what have you, like Youtube, all refer to building 3rd party APIs. And if yo follow these videos rigorously, you think life ends there, when in fact, it just begun. |
^^ Why the rabid screaming of POSIX, POSIX, POSIX since morning. I guess you just came across that term and wont let us hear word. Its normal. The same stack overflow you run to to copy codes has told you its Windows hands-down, you say it's none of your business. By the way, POSIX has been in existence for over 30 years now, stop screaming it in 2020 like its some new technology. Haba !!! |
^ I'll very much like to know too. . |
DanTheGeek:Its fine now, as of when i posted, the hero section was missing . . then it came back later thats why i figured, you were prolly doing an update, based on the complaint somebody said earlier , about the hero section |
crunchyDope:You're welcome, glad to have been of help. |
crunchyDope:It not about being fast the users wont notice. It utilizes what we call 'graceful shutdown". When you do a hot reload, imagine you have 10 users on yur platform, and 6 have sent a request to login at exactly when you did that reload. A cold reload will kill nginx, and they will recieve an error page. For A hot reload [because nginx uses master => slave workers]., the master will see that there are 6 pending request, and it will fulfil those requests first. The requests are handled by slaves, Then it will command the slaves to shutdown. Any new request (remember the other 4) will be routed to the new updated application. So in summary, it waits to fulfil any pending request before killing the processes. Read more on "worker thread and processes". its is very fundamental to building a performant application. For your local dev, u dont need any hot reload, waste of time. If you cant type npm run this, npm run that all the time just add shortcuts to ur terminal or console's profile e.g. A few of mine, i have like hundreds of those literally, git push origin HEAD --force-with-lease = gpf npm run start:dev = dev yarn install = yi you get the idea, right? Then use autocomplete for your terminals, so yo dont have to remember even the shortcuts, cos u wil forget after some time. |
crunchyDope:Nah, far from that . . thats for when you're writing codes on ur laptop. As part of your learning, you will venture into something called CI/CD. Pls google the full meaning. simply put, its a workflow that allows for continuous integration. I'll give u a case study of our own flow. We have 6 servers in AWS and they are always online. Once we make an update to github, it automatically pushes itself to AWS but code is not deployed yet, that's only a staging environment. It gives us a unque environment to test and test. When satisfied, we push to production. I like to do it manually, when am bored and here is what i do. 1. log into server via ssh 2. turn on bastion host, and update it to mirror staging environment, which as the latest update.. 3. We use nginx as a reverse proxy server . . . google what a reverse proxy is for claririfcation, it might not make sense tho for now 4. Open nginx config and reroute all traffic to bastion host. 5. Do a hot reload. A hot reload will make sure connections are not dropped, cos users are online, but it will switch all users automatically to the new version. You wont even notice. 6. Update main application. 7. Open nginx config again and reroute all traffic to main app 8. Do a hot reload once more. 9. Shut down bastion host and exit out of ssh server. For our API, its running under PM2 process manager, and we have a flag called "watching" . . which means when there is a change, it will auto build and deploy itself and do a hot reload. It will do exactly the same thing I listed above but this time automatically. Its a very long story and might not make sense now. But trust me, your time will come. |
crunchyDope:The url in this case, a url to where the application resides, usually localhost, if you are developing but in production, localhost will bind to the server ip address, which can in turn be bound to a custom domain so e.g . localhost:4000/api => 34.32.12.XX/api => nairaland.com/api so using nairaland as an example, if its a microservice, its gonna have at least 2 urls . . it could even be 50 . . but lets stick to the minimum 2 nairaland.com, which is what you will see and type, and that inturn will make a request to e..g. api.nairaland.com or nairaland.co/api [the owner chooses the style they like] . . the 2nd url is the server which responds with required data, and the data is shown to you on your screen or allows you to do something, eg. login. |
Sapeleboy911:manners maketh man.... In case you missed it, please refer to step 4. Thank you. |
crunchyDope:1. Nodejs is meant for server-side applications . . although you can write a bit of frontend too, using stuffs like hbs and pug. But its primary focus is server-side code. Server side applications dont have that www.example.com/something where it displays a page. Nope! Yes, they might have a URL, but its more like api.example.com/v1 So you will need a frontend to marry the backend (node js) for a complete application . . Thats what is popularly referred to as a microservice architecture. as against Laravel for instance where both frontend and backend are sitting inside one application, Monolithic architecture. You can still use Laravel to write APis only, story for another day! 2. This question is now damn funny. Show truly you just started out, No shame in it, brov! As a professional software engineer, you will learn stuffs like "fault tolerance" which means what happens if I'm asleep and my server crashes? who will restart it? A fault tolerant app will restart itself. You will learn stuffs like process management. One good example is PM2. Google it, You will learn a little bit of server adminstration and what it means to deamonize an app [make it a service]. A service will always restart itself as long as it was enabled. Servers in production dont reboot. They can be online for 1000000 years without rebooting. Even your PC can be online for so long too, but eventually nepa will "take light" Servers are online 24/7. Google pictures of servers and see for yourself what they look like. And yes, you need to be very good with the terminal too. One step at a time. Learn javascript first, then node then a little bit of cloud engineering, which will teach you most stuffs in server administration Then take a deep dive into building applications that scale, and mission-critical apps . .[app that shoudl nevr go down, even during updates for 1 second]. Good luck. |
Sapeleboy911:1. Lack of home training 2. One problem with self-taught people, they are limited to what they have learnt online and its where the cap ends. 3. Step out into the world, and you;ll discover your skills are just about 0.001% of what it takes; cos you've been stuck in your own world. 4. Lack of home training, again. 5. Repeat step 4 until it sinks into your empty skull. |
No wonder quacks full here! Is it everything that is learnt online? did you breeze thru primary and secondary school online? ![]() someday, someone would seek recommendation for a good university to study medicine & surgery, and the response will be "go to youtube, you can learn online, use ur phone blah blah blah" Caramba ![]() |
melodyogonna:It does ! |
^^ Sadly VC funding doesn't work like that . . . Googling escrows in Nigera returns a swarm of result, with a popular one being vesicash.com Can OP tell why his service is better then the aforementioned, why I should use him and what his USP is? p.s.: oh i just checked, ur mvp isnt really ready, the page is undergoing a redesign and cannot access customer portal of any kind what if i had initiated a transaction before ? |
Bestdev:http://example.com:2082 or https://example.com:2083 |
^ Is Linux office365 compliant, and should i be damn mad that it isnt and hit my head on the wall? What do i do when i am in dire need of office365 for my business to survive and i only have a linux machine? your guess is as good as mine . . . i stop crying and buy a windows machine or a mac you are in dire need of posix compliance, stop crying, get or install a unix flavor as OS cannot be everything, even macos has limits Steven spielberg may love windows to a fault, but he actually needs to edit movies, and so has to be stuck with a mac just cos he needs Final cut pro . . he doesnt go on crying about how he cannot use final cut pro on windows, cos its not final-cut pro compliant please grow up! be a man |
cixak95211:True, but i still dont know what version of windows you guys run. windows studies you and knows when you're active and will never try to full-cycle update. Never! Even if it takes 10 years, its gonna wait. The only disadvantage is that you do have to powerdown when its time. But even on Linux, critical updates do require a reboot, except, once again you're into livepatching, and that's pretty much for servers, hardly used by personal users. These cracked versions do have some features cut out, perhaps. Fact, is running windows, is not cheap. If you dont have unlimited data, better to steer clear of windows, than try to disable updates. Last fact: Dont try using Windows for a job for Unix , each of the OSes have their specific use cases. Its akin to firing up Ubuntu and expecting to see Office365, and then crying that "Wine" sucks. I cannot live without office365 and gaming so i use windows pretty much I cannot also live without superb trackpad gestures, lol [ me joking ], macos comes to the rescue and when i wanna look cool at public events, or just blend into the crowd at technical events . . . i go with the Linux machine case closed ! p.s. i am not a windows fan"man" . . i have all three OSes and them for their specific uses cases without bias. |
Javierleon:Simply put is bad practice. And take for example . . I have a public API that sends payment to user bank accounts The API is on Zapier and a user is trying to connect their existing with mine and they have something like this which is pretty standard . . #1 return status === 'success' && code === 201 ? TransactionPostWorker() : TransactionFailedWorker() Now yu see the problem, your POST requests returns a 200 and not a 201, and even tho status says success. The only way out is for the user to go modify their API, and what if its legacy code? They modify it, it works for me, but now it breaks for others , both internal and external. That's why there is a standard which must be adhered to. #2 All webhooks send a POST request to servers and expect a 200 response. If you decide to go against http standards and send a 201 response for whatever reasons best to you, webhook fails. Then you modify the webhook endpoint to work with http standards and yet, other parts of the api violates the same http standards . . =>>> spaghetti code |
vheckthor1:They need to overhaul their engineers. It violates HTTP principles on all levels, and will cause some special APIs consumers to act funny or even break; A POST request is expected to add a new entity and should return a 201 on success while a GET request is expected to fetch an existing entity return a 200 on success Sending a POST request and modifying your API to return a 200 is just plain ridiculous . . . and like I said earlier will create confusion when publishing to specialized APIs, because the request and response headers will fail an integrity check. |
SegFault:Your assumptions are very wrong on a whole lot of levels. I've witnessed linux boot errors to due to failed headers update, the only saving grace was Rsync Whomsoever borrowed his pc must have messed with it somewhere I program on MacOs, Linux and Windows everyday, this message was posted from Windows and I have never had any issue with Windows in my programming career, not even a BSOD. And windows 10 was the next best thing after windows 7. windows 8 was a failed experiment Why people have issues with windows is cos they often installed cracked versions and therefore disable system updates, [plus disabling system updates to save data] I would advise anybody using windows for professional development to install a genuine version and have peace of mind and if you have enough bandwidth, please allow automatic system updates. Its very critical for system stability, even Linux too. if it wasnt, then Linux wouldnt have introduced "canonical livepatch", but i guess, you dont' know what that means. cheers |
spartan117:Fixed! Be careful of type coercion !!! |
melodyogonna:Good question |
DanTheGeek:OK i rechecked, your site 1st pic What you should strive to acquire; 2nd pic cheers. https://prnt.sc/ud1k9n |
IDEs are on a different ballgame compared to editors . . Its apples to oranges. Cos all IDEs contain text-editor as part of their functionalities i.e. All IDEs are also text-editors; but text-editors are not IDEs In a very professional environment, the company pays for IDE licences which are distributed to team members and there are reasons behind that fact. |
Landing pages takes forever to load . . . Did you run a Lighthouse report ? |
LOL to above post. Well OP first off, the track manipulation panel is way too small and has been drowned by the rather over-bloated content on the main page. Second, by the right hand side, why do you have to keep repeating 2020 If you wanna show us the year, you could have made it in smaller and dimmer font. Its rather disturbing and breaks the eyesight flow. Thirdly, like you last picture posted, your dark mode is what we call "lazy man dark mode" . . simply an inversion of text and background color i.e. black text become white and white background becomes black dark mode goes way than that and not cool to use #000 cos the contrast would be too striking. |
Millerules:True, I'll rate it a 2 for the effort. The design still violates a lot of UI principles. Cant rate the UX cos there was no live prototype to play with. And that takes us back to the topic.... if you so much detest the way a man handles his business, isn't that an opportunity for you to create your own? Why force him to bend to your rules? Are you an invester or a member of the board of trustees? Use your head, OP |
lordally:Honestly, I cannot promise you that it's going to be very consistent, due to time and all, which you might already know .. But i assure, if you do get stuck, or trying hard to figure out something, or wanna level up, you can leave a message and i'll be there as soon as its possible for me to do so. cheers |
lordally:No qualms; |
KristaPretty:Not trying to take sides, but your post above just affirmed what the guy said. You're indeed a developer, but still at the grassroots level. When you're experienced, your field of play aka area of concentration gets massively narrowed down to one subject matter, thus becoming an SME, [subject matter expert] Besides, no experienced developer would introduce themselves with an array of languages, only newbies do that. Dont take offence tho. Just my two cents i might "stand corrected" |
tensazangetsu20:It is left to each one his/her personal preferences on what to accept. I just stated what the Nigerian market offers, generally. Of course, there will be exceptions such as working with a multinational where entry level can get even 300k and working with one-man backyard venture, where even a senior level will earn you just 80k, you dig? |
why do you keep asking the same question in multiple threads; even when you have been answered in one or more? |

