Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

243
Visualizações
Django: File upload to s3 using boto

I am trying to upload images (average size 12 MB) to my server (django using PIL)then I'm processing them to scale down images and creating thumbnails.

During this process I'm not saving images to server local disk instead, I'm using In Memory file and processing it. I'm uploading images to s3, using boto and I have original image, scaled image and the thumbnail which should be uploaded one by one (all these three are still present in my in Memory).

This process is very time consuming and sometimes the server which I am using (Digital Ocean 512 MB RAM) throws out of memory error.

Can I know is there any better way of uploading images

Any help is much appreciated. Thanks in advance.

over 4 years ago · Santiago Trujillo
1 Respostas
Responde à pergunta

0

I haven't worked a lot with django & boto but u can try few suggestions:

  • Upgrade your server. if you are going to process that much big files, image processing requires a lot of memory.
  • You can try implementing queues (i.e. whenever you will get any upload request and file is bigger then enqueue it and process after current process is complete). You can use celery for this work.
  • If you don't need that much big files, then you can reduce image size at client side first and then pass it to the server.
over 4 years ago · Santiago Trujillo Relatório
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda