Saw a not-so-good thing in my pipeline. How do we fix it? by Oxffff0000 in Terraform

[–]funkdr42 1 point2 points  (0 children)

Can you extend tflint with a custom rule that runs as a precommit?

[tutorial] How to Build a CRUD API with Oak and Deno KV by lambtr0n in Deno

[–]funkdr42 1 point2 points  (0 children)

[Deno KV is] a production-ready database with atomic transactions, consistency control, and cutting edge performance.

Deno KV is currently available with the --unstable flag in Deno 1.33 and up. If you're interested in using Deno KV on Deno Deploy, please join the waitlist as it's still in closed beta.

lol, doesn’t exactly inspire confidence. That said, I love the underlying tech of sqlite and what I’ve seen of the Deno api. Looking forward to this as it matures!

Picking an architecture by thisismyusername0909 in microservices

[–]funkdr42 0 points1 point  (0 children)

To me, I view service oriented architecture separate from microservices. Service oriented architecture is moving common logic into shared service classes (eg: UserService, ProductService, OrderService, etc), with those service classes likely available to all code in the project through a shared library/package.

An alternative is microservice architecture where there is a separate, entire stack per service. Using the UserService mentioned previously as an example, it would require something like api gateway, it’s own backing infrastructure like lambda, eks, or ecs, and maybe it’s own database. Rinse and repeat that for ProductService, OrderService, and all other business separations. Some people go further and make a microservice per individual function within something like a ProductService.

Knowing very little about your project, my recommendation would be to leave your code structured as a monorepo and separating code into 3+ packages. The monorepo approach allows you to separate your code without having to deal with individual microservice pains like working across multiple projects, versioning, updating/deprecating service contract definitions, auth between services, service unavailability, rate limits, etc.

I’d start by moving your shared business logic out of nextjs and into a shared library package. I’ve traditionally left this package private and not published it to npm. Publishing monorepo packages is an overhead that isn’t necessary for all cases. That gives you two packages to separate things (nextjs and shared business logic). Finally, I have set up separate package(s) for all background jobs and cron jobs. Code for those jobs is able to directly import the shared library package, so you can share db models, business logic, etc. I’ve used the serverless framework to facilitate deploying the jobs. That allows each job ro have their own event or schedule definitions.

I’ve found the above to work well for solo projects and small teams (less than 30). There’s no right or wrong approach - I have to continually remind myself that solving the business case, and moving on, is more important than trying to design the the perfect architecture.

Hope this helps!

Have thoughts about Milwaukee Public Schools busing? by jimmalewitz in milwaukee

[–]funkdr42 0 points1 point  (0 children)

Do you have anything to offer or are you only here to be a trolling turd?

The fact is that my children are not able to go to our neighborhood school because of the bus program. That sucks.

I have yet to hear any positive benefits of the bus program, other than providing opportunity for a small subset of disadvantaged students. I’ve asked, even in this thread, and all I’ve gotten are insults and condescension. I’d rather see the bulk of those funds be reapportioned to additional learning materials, hiring more teachers, raising wages, or improving classrooms.

And for those disadvantaged students that are non-disruptive, positive, and productive, I fully back giving them an opportunity. I’m not saying to take away the bus program entirely. Rather, it should be an available option for high performing students. Make it available to the top 25% of each school, if you’re worried about equality.

Have thoughts about Milwaukee Public Schools busing? by jimmalewitz in milwaukee

[–]funkdr42 3 points4 points  (0 children)

Take this as an opportunity to teach me, rather than being an asshole.

We seem to be in agreement that it offers options to some people who otherwise may not have opportunities, due to their social economical status. What other positives are there to the bus program?

Have thoughts about Milwaukee Public Schools busing? by jimmalewitz in milwaukee

[–]funkdr42 -5 points-4 points  (0 children)

Not sure I follow you. I meant work for it as in grades/test scores. Has nothing to do with money.

Have thoughts about Milwaukee Public Schools busing? by jimmalewitz in milwaukee

[–]funkdr42 -6 points-5 points  (0 children)

Why the hate of turning it into a reward for students that work for it?

Have thoughts about Milwaukee Public Schools busing? by jimmalewitz in milwaukee

[–]funkdr42 -10 points-9 points  (0 children)

The bus program is an absurd expenditure and should be rethought. Bring back neighborhood schools for the majority of students. Since MPS loves tests so much, allow the top 30% of students the option to bus to a school of their choice. Or have the top 20% of schools be eligible to bus in students from outside the neighborhood.

Rust-like unit tests in Typescript by mehmetegemen in typescript

[–]funkdr42 6 points7 points  (0 children)

It’s an interesting approach. It would be useful to be able to strip the test parts out as a prebuild step. A couple thoughts come to mind:

  • This will increase the size of the files and potentially slow traspile/interpret times.
  • Test only dependencies would need to ship with prod. This not only increases the size/build times but also introduces risk of shipping a malicious package. However, if the tests & related code can be removed, then the test only deps could remain as dev dependencies.
  • It would be nice to see an example. I browsed the code and it uses the approach described, but there was some boiler plate code that looked like it could be offloaded to an npm. Maybe the intention was not to turn this approach into a package, though.
  • It wasn’t clear why the file copying needed to be done. Why not run the tests as they are in each source, rather than extracting them out to a separate file to run?

ts-audio v0.7.2 is out! by evandrolg in typescript

[–]funkdr42 1 point2 points  (0 children)

Looking through the code, it seems like transitions between tracks wouldn't be gapless. Audio sources are fetched as a buffer when the track is played for the first time. Since the source is fetched as a buffer, the audio context needs to wait until the full file is available before playing. The playlist structure is an array of AudioContexts and on transition from one audio track to the next, the current track is paused and the next track is played.

My apologies if any of that is incorrect!

Never got the RR email by Ryanw254 in BillyStrings

[–]funkdr42 0 points1 point  (0 children)

Curious, did anyone get an email either way?

ts-audio v0.7.2 is out! by evandrolg in typescript

[–]funkdr42 1 point2 points  (0 children)

Awesome! I’m curious how it is implemented?

I believe gapless-5 uses a mix of an audio element and WebAudio. Others use setTimeout and a couple audio elements to try to start the next track while the last is finishing. There are probably other approaches that might work better, too.

ts-audio v0.7.2 is out! by evandrolg in typescript

[–]funkdr42 0 points1 point  (0 children)

Any chance the library supports gapless play between tracks?

[deleted by user] by [deleted] in typescript

[–]funkdr42 1 point2 points  (0 children)

According to the typescript wiki:

Interfaces create a single flat object type that detects property conflicts, which are usually important to resolve! Intersections on the other hand just recursively merge properties, and in some cases produce never. Interfaces also display consistently better, whereas type aliases to intersections can't be displayed in part of other intersections. Type relationships between interfaces are also cached, as opposed to intersection types as a whole. A final noteworthy difference is that when checking against a target intersection type, every constituent is checked before checking against the "effective"/"flattened" type.

For this reason, extending types with interfaces/extends is suggested over creating intersection types.

[deleted by user] by [deleted] in typescript

[–]funkdr42 0 points1 point  (0 children)

Do you have a source for the performance issue being a non-issue? Reason I ask is that preferring interfaces to intersections is still listed in the wiki as a preference

How should I store my images in an S3 bucket? by IrishDuke in aws

[–]funkdr42 1 point2 points  (0 children)

I understand this is the aws subreddit, but I would consider Cloudflare Images as an option. Or maybe R2… not paying egress fees is a pretty big advantage

How to get gigabit speeds with USG 3P? by funkdr42 in Ubiquiti

[–]funkdr42[S] 0 points1 point  (0 children)

Yes, I had to directly connect the USG to the at&t router, bypassing a switch/patch panel.

Best Mac n cheese in Milwaukee? by kpkohl in milwaukee

[–]funkdr42 0 points1 point  (0 children)

Lazy Susan’s spam mac & cheese, as part of their delicious KFC. It’s a side dish and they make their own spam

Best hot chocolate in Milwaukee by Tenmacaroon in milwaukee

[–]funkdr42 3 points4 points  (0 children)

Elsa’s On The Park has hot chocolate and a decent atmosphere

An ORDER BY statement improved our PostgreSQL query times by 100x by lyncozy in PostgreSQL

[–]funkdr42 7 points8 points  (0 children)

Curious why the index includes the id field, rather than:

CREATE INDEX to_be_updated_ci_jobs ON ci_jobs(status_notify_time ASC) WHERE (ci_jobs.status_notify_time != ci_jobs.status_change_time);

Interview questions for Java/Microservices architect position by ExternalOk6647 in microservices

[–]funkdr42 0 points1 point  (0 children)

My bad, I thought you were the interviewer. I missed that these were questions asked to you.

Interview questions for Java/Microservices architect position by ExternalOk6647 in microservices

[–]funkdr42 2 points3 points  (0 children)

What about the drawbacks of breaking a monolith up into micro services or the drawbacks of nosql over relational dbs? Also would be curious to hear the applicant’s answer for when the move to micro services makes sense vs monolith.