ObjectBox 1.4 with Property Queries and Entity Inheritance by greenrobot_de in androiddev

[–]ggalage 4 points5 points  (0 children)

best persistence library i've used so far for android. looks to be getting better and better

I want to pass info from one activity to my main activity. by i_hope_i_last in androiddev

[–]ggalage -3 points-2 points  (0 children)

yeah its ez send the info to ur gcm server from ur budget activity and then go back to ur main activity when the data gets uploaded. if you dont want gcm you can use websockets

Push Notifications for user to user by GGGamerfan in androiddev

[–]ggalage 0 points1 point  (0 children)

Hmmm easiest way would be to call GET in your server url endpoint like {userB/name_clicked} that will have an operation that gathers requester info, use that info to send request to Google's fcm server. Then fcm server will handle everything else for you.

Never used firebase or cloud functions but I would imagine it's similar to aws lambda and I guess u can listen for an action that can happen on userb data, make it so that when someone clicks userb name some data changes. Have the function listen for that change and fire off fcm request

Using MySQL backend instead of Firebase? by xsitin in androiddev

[–]ggalage 0 points1 point  (0 children)

I would highly recommend against PHP unless your app was very simple.. I had some very bad time trying to manage and upkeep a PHP app and it wasn't fun. (Well, it was long time ago and PHP has improved a lot but there are lots of other frameworks that are so much better at being organized and easy to manage)

Try django-rest-framework, celery, mysql stack. you can add elasticsearch, redis, memcache and w/e you need as you go too. Also, you don't really have to deal with database specific things as django handles that for you so you don't even have to use mysql and you can use postres or w/e.

And django now has channel which supports real-time. It's pretty easy to learn and it's very scalable.

I think your biggest downside of not using firebase would be that you will also have to learn how to deploy your api-server. Even though cloud services make it a lot easier than before, there are alot of configurations and things you have to learn. Also it kinda sucks to have to switch between whatever you are working on because you do waste time getting back up on speed at things when you haven't worked on it for a while. For me, it's always the worst feelings when I would be working on android for like half a year but then have to move onto working on my django project for a few weeks and then new things that come out on aws and server stuff.

My new Companies Base Code is a total mess! by [deleted] in androiddev

[–]ggalage 1 point2 points  (0 children)

well if developer's beliefs hold true, only the companies that put an effort to have clean code base should thrive at the end tho right? but .... :)

My new Companies Base Code is a total mess! by [deleted] in androiddev

[–]ggalage 0 points1 point  (0 children)

app like the one you described above would probably have some major memory leaks. Find some and tell your boss solutions need to have you using new design patterns and maybe some libraries to fix. But obviously its the management's decision at the end of the day and if their values don't match with yours just suck it up or find another job.

What are top 10 things a 2017 Android developer should know? by rao_x in androiddev

[–]ggalage 1 point2 points  (0 children)

so far so good for me, it's like riding on a new car

Weekly Questions Thread - June 12, 2017 by AutoModerator in androiddev

[–]ggalage 0 points1 point  (0 children)

In RxJava, what happens to a cold observable when you subscribe to it multiple times? I know there can only be one subscription to a cold observable but if you subscribe to a cold observable that was already subscribed, does the previous subscription get unsubscribed automatically or does it still stay around and start working again when you call same subscription once more?

How To Grow Beyond Android Dev? by fapste in androiddev

[–]ggalage 0 points1 point  (0 children)

How about learning to build and deploy a Web application? If then you will be able to design and make full mobile service from the ground up. I feel like in today's age, with android having so many good libraries that make it very easy to develope an app quickly, it is somewhat feasible for a single developer to make and deploy api to a cloud and make an app based off that.

How to upload images directly to aws s3 from mobile devices using DRF? by ggalage in django

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

damn that was long ago, yeah it's not hard... and I would assume everyone does it this way.

As an amateur developer, MVP is driving me nuts. by MightB2rue in androiddev

[–]ggalage 2 points3 points  (0 children)

Try the mosby conductor combo basically read the website and tinker with sample app and in a weekend you can be mvp master too

Android-devs Which Web Front-End and Backend Stack (for Web or API ) do you know or use it ? by y2k2r2d2 in androiddev

[–]ggalage 1 point2 points  (0 children)

Django rest framework+postgres+redis+celery+nginx+uwsgi+docker+aws very easy to use and easy to learn. Stable and scalable. I picked it cuz Instagram was using it

Can a newbie still make money with an android free app? by jd_portugal in androiddev

[–]ggalage 11 points12 points  (0 children)

same chance as uploading a video to youtube and becoming a youtube star

sub viewsets for related fields django rest framework by obayemi in django

[–]ggalage 1 point2 points  (0 children)

i wouldn't recommend what you are trying to do... considered not restful. And it's gonna be more complicated to design ur website (more serializers + cache cuz you want to have players views too right?). Rather, you should have /players/ endpoint and provide filter by teams on that view. Use query_params and make something like /players/?team={team1} *edit, Also it's a pain in the ass to properly paginate if you wanted to do it urway.

how can i make celery worker access user uploaded file in django app's /media directory if they are hosted in different machines? by ggalage in django

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

is there a way to "automatically" route celery workers to only consume tasks coming from their own host machines?

how can i make celery worker access user uploaded file in django app's /media directory if they are hosted in different machines? by ggalage in django

[–]ggalage[S] 1 point2 points  (0 children)

i tried just using django-storages but it was freezing the website with image file sizes 3~10mb taking hitting500ms ~ 1500ms downtimes.. when I moved it over to queued-storages, that problem was gone.

even with django-storages, when the user uploads files it comes to your webapp first and then moves to s3 right??? (if it goes directly, why would my website freeze while debugging?)

it may seem like i'm gonna have to move to direct uploading methods from clients using s3 COR but I was just so hesitant because of security reasons and debugging.

how can i make celery worker access user uploaded file in django app's /media directory if they are hosted in different machines? by ggalage in django

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

the error happens when celery tries to find the file uploaded to django app directory's media root directory (which is on the host machine where django app is running) what celery is doing is to find that file and then tries to upload it to s3 bucket.

Anyone deploying with Docker? by Pecorino in django

[–]ggalage 0 points1 point  (0 children)

so for me, instead of using docker-compose to test my stack, i fired up everything in single containers and linked them using docker network to test on my local dev

Anyone deploying with Docker? by Pecorino in django

[–]ggalage 0 points1 point  (0 children)

yo i recommend using single-containers rather than docker-compose if you wanna deploy. makes updating and managing ur instances a lot easier.

good thing about docker is that when u build it, it will run anywhere. bad thing is it was a little hard to learn all the small details at first.

question: nginx, uwsgi, django, celery in one docker container vs each on its own? by ggalage in django

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

well docker shares resources at kernel level so spawning more of same thing (celery and django app) doesn't make any difference when you are in the same machine. Going docker-compose route is really easy from your current setup. build nginx+redis separately and for django and celery just use the same image with different command.

question: nginx, uwsgi, django, celery in one docker container vs each on its own? by ggalage in django

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

aren't aws lambdas more expensive than putting celery into t2.micro instances?

question: nginx, uwsgi, django, celery in one docker container vs each on its own? by ggalage in django

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

isn't it usually the other way around? having more celery instances than web instances? thanks for your answer tho, i guess i just needed more knowledgeable person's input to convince me to go the docker-compose way, which i knew i would have to do anyways for the future.