Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In
Continue with Google
Continue with Facebook
or use


Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here
Continue with Google
Continue with Facebook
or use


Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.


Have an account? Sign In Now

Sorry, you do not have a permission to ask a question, You must login to ask question.

Continue with Google
Continue with Facebook
or use


Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

Stack Ask

Stack Ask Logo Stack Ask Logo

Stack Ask Navigation

  • Home
  • About Us
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • About Us
  • Contact Us

Share & grow the world's knowledge!

We want to connect the people who have knowledge to the people who need it, to bring together people with different perspectives so they can understand each other better, and to empower everyone to share their knowledge.

Create A New Account
  • Recent Questions
  • Most Answered
  • Bump Question
  • Answers
  • Most Visited
  • Most Voted
  • No Answers
  1. Asked: February 3, 2023In: Spring

    Cách truy vấn và xử lý dữ liệu lớn trong Oracle(table khoảng 50M record)

    tvd12 Enlightened
    Added an answer on February 4, 2023 at 7:50 am

    1. Anh không hiểu tại sao em lại cần phải lấy tất cả user lên để xử lý mà không lấy từ từ khoảng 100 user 1 lần để xử lý nhỉ? 2. Anh thấy việc em lưu dữ liệu vào redis (lưu user_id) thế sau đó lại lấy danh sách user id đó để truy vấn cơ sở dữ liệu thì nó có khác gì việc em gọi 1 câu truy vấn để lấyRead more

    1. Anh không hiểu tại sao em lại cần phải lấy tất cả user lên để xử lý mà không lấy từ từ khoảng 100 user 1 lần để xử lý nhỉ?
    2. Anh thấy việc em lưu dữ liệu vào redis (lưu user_id) thế sau đó lại lấy danh sách user id đó để truy vấn cơ sở dữ liệu thì nó có khác gì việc em gọi 1 câu truy vấn để lấy ra danh sách user thoả mãn điều kiện đâu nhỉ?

    Vậy nên anh nghĩ là việc sinh ra redis là không cần thiết, và cách làm anh nghĩ là cứ lấy khoảng vài trăm user ra để xử lý 1 lần em ạ, vừa an toàn, đơn giản mà lại dễ maintain và tiết kiệm hạ tầng hơn

    See less
    • 0
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report
  2. Asked: February 3, 2023In: Java

    Không submit được File trên postman

    tvd12 Enlightened
    Added an answer on February 4, 2023 at 7:46 am
    This answer was edited.

    Cái này anh thấy là em đang gửi dữ liệu dạng form-data lên server, nhưng có vẻ server lại đang chấp nhận loại dự liệu khác có thể là ảnh thôi, em xem trong code em đang accept kiểu dữ liệu nào ở controller xử lý API nhé

    Cái này anh thấy là em đang gửi dữ liệu dạng form-data lên server, nhưng có vẻ server lại đang chấp nhận loại dự liệu khác có thể là ảnh thôi, em xem trong code em đang accept kiểu dữ liệu nào ở controller xử lý API nhé

    See less
    • 0
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report
  3. Asked: February 2, 2023In: Spring

    Gen database bằng code java sử dụng các anotation

    monkey Enlightened
    Added an answer on February 2, 2023 at 6:07 am

    Cách này chỉ dùng cho test thôi em ạ, chứ trong dự án thật thì không nên dùng, vì sao nhỉ? 1. Việc tạo bảng còn liên quan đến việc chọn charset, đánh index, như vậy thì nếu tạo bằng code thì chưa chắc đã đủ. 2. Trong quá trình vận hành thì bảng thay đổi nhiều, ví dụ như thêm cột, thêm index, nhưng cRead more

    Cách này chỉ dùng cho test thôi em ạ, chứ trong dự án thật thì không nên dùng, vì sao nhỉ?

    1. Việc tạo bảng còn liên quan đến việc chọn charset, đánh index, như vậy thì nếu tạo bằng code thì chưa chắc đã đủ.
    2. Trong quá trình vận hành thì bảng thay đổi nhiều, ví dụ như thêm cột, thêm index, nhưng có thể không cần phải update code, vậy bây giờ mỗi lần thay đổi lại phải update code thì không hợp lý.
    3. Những annotation kia trong dự án thật (những dự án dữ liệu lớn) thì không dùng được, ví dụ dự án chat em có bảng user liên kết với message (1 user nhiều message) thì em không thể nào select hết toàn bộ message của user được vì số lượng message là rất lớn.
    4. Việc thiết kế db thường làm trước việc thiết kế code, nên từ db rồi gen ra entity sẽ thuận lợi hơn nhiều.
    5. Theo nguyên tắc single repository thì mỗi 1 thành phần nên thực hiện một chức năng, nếu bây giờ em nhồi cả việc tạo bảng cho entity thì nó đã là 2 việc mất rồi.

    See less
    • 0
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report
  4. Asked: January 20, 2023In: Spring

    Xóa kiểm tra ràng buộc primary key-foreign key khi sử dụng spring data jpa

    tvd12 Enlightened
    Added an answer on January 20, 2023 at 4:28 pm
    This answer was edited.

    Anh thấy chỉ cần lúc tạo bảng em cứ khai báo fk là được em nhỉ? (mặc dù anh chưa bao giờ khai báo fk) Với cả em cũng không nên dùng @ManyToOne, @OneToMany, @OneToOne, bởi vì khi cơ sở dữ liệu của em nhỏ không sao, đến lúc lên đến hàng chục nghìn bản ghi thì hậu quả sẽ rất nặng nề. Liệu anh có đang hRead more

    Anh thấy chỉ cần lúc tạo bảng em cứ khai báo fk là được em nhỉ? (mặc dù anh chưa bao giờ khai báo fk) Với cả em cũng không nên dùng @ManyToOne, @OneToMany, @OneToOne, bởi vì khi cơ sở dữ liệu của em nhỏ không sao, đến lúc lên đến hàng chục nghìn bản ghi thì hậu quả sẽ rất nặng nề.

    Liệu anh có đang hiểu nhầm câu hỏi không em nhỉ?

    See less
    • 1
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report
  5. Asked: January 16, 2023In: Java

    Synchronous Redis trong Spring boot

    monkey Enlightened
    Added an answer on January 16, 2023 at 9:55 am

    1. Anh chưa hiểu là cơ sở dữ liệu của em thiết kế như thế nào mà tại sao lại chậm, em đang chỉ sử dụng đến truy vấn findById thôi nhỉ? Hay câu lệnh truy vấn của em là khác? 2. Việc lưu toàn bộ dữ liệu lên redis cũng là 1 phương án, redis nó cũng lưu dữ liệu ra disk và có replica nên có sập thì cũngRead more

    1. Anh chưa hiểu là cơ sở dữ liệu của em thiết kế như thế nào mà tại sao lại chậm, em đang chỉ sử dụng đến truy vấn findById thôi nhỉ? Hay câu lệnh truy vấn của em là khác?
    2. Việc lưu toàn bộ dữ liệu lên redis cũng là 1 phương án, redis nó cũng lưu dữ liệu ra disk và có replica nên có sập thì cũng vẫn còn dữ liệu. Nếu em lưu cả dữ liệu trên redis và mysql thì cũng sẽ có nguy cơ bị bất đồng bộ dữ liệu nên anh nghĩ là nên xem xét, cá nhân anh thấy lưu vào mysql chỉ để backup và truy vấn làm report thì ok.
    3. Cá nhân anh vẫn đang dùng mysql, anh vẫn thấy truy vấn rất nhanh nếu dữ liệu được đánh index một cách hợp lý nên anh cũng không cần dùng đến redis và lại phải maintain phức tạp.

    See less
    • 0
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report
  6. Asked: January 16, 2023In: Java

    kafka serializer và deserializer

    monkey Enlightened
    Added an answer on January 16, 2023 at 4:38 am

    Hiện tại thì anh đang thấy có 2 hướng sử dụng: 1. Dùng json: cái này anh thấy hay dùng nhất vì nó tiện và có thư viện jackson hỗ trợ sẵn rồi. Tuy nhiên nhược điểm là json là string nên gói tin sẽ lớn. 2. Dùng msgpack: cái này thấy ít dùng vì nó ít thư viện hỗ trợ hơn jackson, nên anh đang hỗ trợ mặcRead more

    Hiện tại thì anh đang thấy có 2 hướng sử dụng:

    1. Dùng json: cái này anh thấy hay dùng nhất vì nó tiện và có thư viện jackson hỗ trợ sẵn rồi. Tuy nhiên nhược điểm là json là string nên gói tin sẽ lớn.

    2. Dùng msgpack: cái này thấy ít dùng vì nó ít thư viện hỗ trợ hơn jackson, nên anh đang hỗ trợ mặc định cho ezymq để anh em đỡ phải nghĩ ngợi.

    3. Dùng protobuf hoặc Avro: cũng ít dùng phải sinh ra file proto hay file avro khá loằng ngoằng.

    Với cá nhân anh thì anh dùng msgpack vừa làm nhỏ được dung lượng gói tin mà lại vừa dễ sử dụng hơn.

    See less
    • 0
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report
  7. Asked: January 14, 2023In: Anything

    có thể dùng server side và client side đồng thời k ạ

    tvd12 Enlightened
    Added an answer on January 14, 2023 at 9:49 am

    Có đó em ạ, hiện nay có các thư viện như Next.js Nuxt.js sinh ra để hiện thực hoá ý tưởng này, em có thể tham khảo nhé.

    Có đó em ạ, hiện nay có các thư viện như Next.js Nuxt.js sinh ra để hiện thực hoá ý tưởng này, em có thể tham khảo nhé.

    See less
    • 0
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Ask A Question

Stats

  • Questions 826
  • Answers 1k
  • Best Answers 80
  • Users 336
  • Popular
  • Answers
  • monkey

    [Deep Learning] Làm thế nào để xác định được cái ...

    • 16 Answers
  • Thành Vương

    Bug sai đường dẫn khi config ckeditor lên live

    • 14 Answers
  • Tú Trần Anh

    [Ezyfox Server] Unity game client không gửi được command khi ...

    • 12 Answers
  • tvd12
    tvd12 added an answer 1. Anh không hiểu tại sao em lại cần phải… February 4, 2023 at 7:50 am
  • tvd12
    tvd12 added an answer Cái này anh thấy là em đang gửi dữ liệu… February 4, 2023 at 7:46 am
  • monkey
    monkey added an answer Đây em: class Event{} class Room{} class EventRoom{eventId, roomId} February 2, 2023 at 9:07 am

Top Members

tvd12

tvd12

  • 76 Questions
  • 1k Points
Enlightened
monkey

monkey

  • 122 Questions
  • 1k Points
Enlightened
Nguyễn Thái Sơn

Nguyễn Thái Sơn

  • 205 Questions
  • 307 Points
Enlightened

Trending Tags

#formatdate .net .net core .net oop abstract class access app access token ai analytics android ansible anti-flooding apache poi api app architecture artificial intelligence assembly async asyncawait atomicboolean authentication backend backend nestjs background bash script batch bean big project binding bitcoin blockchain blog boot-nodes branch british btree bucket4j buffered build bundle c# c# .net cache caching callback career career path cast centos chat cloud cloud reliability commit communication company computer science concurrent config-css connection pool content-disposition contract convert date to number cookie cors cosmos cosmos-sdk crawl data cron css database database migration datasource datastructure deadlock decentralized exchange deep learning deploy contract design-pattern design patterns devops dex di distraction programing dns docker download draw.io du học duration dữ liệu lớn eclip editor elasticsearch email employee english erc20 erc721 estimation eth ethereum ethereum login excel exception exception handle exception handler executor export compliance extensions exyfox ezyfox ezyfox-boot ezyfox-server ezyfoxserver ezyhttp ezymq-kafka ezyredis facebook fe filter floating point flutter format json freetank french front-end frontend fullstack fulltextsearch future gallery game game-box game-room game-server gateway get get file zip git glide go golang google gorilla graduation thesis graphql grapql grpc guide h2 database handy terminal hazelcast hibernate hibernateconfig html http https hyperloglog image index indexing integration-test intellij interface interview io ioc ipfs isolate issue it java java core javacore javascript java spring javaw java web jenkins jetbrains job join jotform jpa js json json file jsonproperty json to object jsp jsp & servlet junit-test jvm jwt kafka keep promise kerberos keycloak kotlin language languague library list load-balancing load balancer lock log log4j log4j-core login lưu trữ machine learning macos mail mail template main maria db math maven merge message queue messaging metamask microservice microservices migration mobile model mongo monitoring mq msgpack multi-threading multiple tenant multithread multithreading mysql n naming naming convention nan netcore netty networking nft nft game nginx nio node.js nodejs non-blocking io null oop opensource optimize oracle orm otp message paginaiton pagination pancakeswap panic partition pdf pgpool phỏng vấn plugin pointer postgresql postman pre private_key procedure profile programming project management promise properties push-noti push message android push notification python python unicode qrcode question queue rabbitmq reactive reactjs reactjs download readmoretextview recyclerview redis refactor refresh token regex replica repository request resilence4j resource rest resttemplate roadmap ropssten ropsten round robin rust rxjava s3 schedule scheduled scheduled spring boot search security send email send mail server servlet session shift jis singleton sjis slack smart contract soap socket socket server soft delete solution sosanh spring spring-boot-test spring-jpa spring aop springboot spring boot spring data jpa spring redis springsecurity spring security springwebflux mysql spring websocket spring websocket cors sql sql server sse ssl email stackask storage stream stream api stress test structure trong spring boot study synchronize synchronized system environment variables test thread threadjava threadpool thread pool thymeleaf tomcat totp tracking location transaction transfer transfer git udp uniswap unit test unity upload upload file utf-8 file validate validate date vector view volatile vue vue cli watermark web web3 web3 client webassembly webflux webpack websocket windows 11 winforms work zip file zookeeper

Footer

Stack Ask

Stack Ask is where Developers Ask & Answers. It will help you resolve any questions and connect you with other people.

About Us

  • Meet The Team
  • About Us
  • Contact Us

Legal Stuff

  • Terms of Service
  • Privacy Policy
  • Cookie Policy

Help

Follow

© 2021 Stack Ask. All Rights Reserved
Powered by youngmonkeys.org