文档显示架构问题

发布于 2024-10-06 07:51:22 字数 550 浏览 0 评论 0原文

我正在考虑开发一个在线作业提交系统,学生可以上传他们的文本文档,这些文档可以由具有查看权限的人(老师/教授)查看。此人可以注释/标记/突出显示该文档,然后可以传递该文档以供进一步审查。审核完成后,该文件将被发送回给学生并提供适当的反馈。

这里有很多令人感动的部分,我很难弄清楚从哪里开始。我使用这个项目作为练习,使用完全开源的工具设计一个可扩展/安全/快速的 Web 应用程序,支持类似桌面的用户体验,但除了 UI 框架(Vaadin)和语言(Java)之外,我还有一点找出在这方面取得一些进展所需的路线图有点麻烦。

如果 SO 专家能够在这方面指导我或为我提供正确方向的推动,那就太好了。

编辑:感谢您的回复。这是响应中描述的标准三层架构。我需要巨大的可扩展性,并且由于应用程序将主要以文档为中心,并且我可能需要在以后改进搜索,因此我想避开 RDBMS。由于我们目前有大量用户在任何给定时间发布他们的文档(比如说 *.txt)文件,因此我需要某种消息队列来处理这些大量的信息涌入。必须有某种快速转换层来获取所有格式的文档,并以适合注释和标记的格式显示它......这样的例子不胜枚举。从域模型开始并向下移动将是理想的选择,但我有点怀疑。

I am thinking of working on an online homework submission system where students can upload their text documents that can viewed by somebody(Teacher/Professor) with viewing rights. This person can annotate/mark up/highlight this document and then can pass this document on for further review. After the review is done, this document is sent back to the student with proper feedback.

There are a lot of moving pieces here and I am having a tough time trying to figure out where to start. I am using this project as an exercise to design a scalable/secure/fast web-application using entirely open source tools that supports desktop like user experience but besides the UI-framework(Vaadin) and language(Java), I am having a little bit of trouble figuring out the roadmap needed to make some progress with this.

It will be great if the SO gurus can mentor me through this or provide me with a nudge in the right direction.

Edit: Thanks for the response. This is the standard three-tiered architecture that was described in the response. I need massive scalability and since the application will be primarily document centric and I may have to retrofit search at some later date, I would like to steer away from RDBMS. Since we have a massive amount of users posting their documents at any given time(lets say *.txt) files for the time being, I would need some kind of message queue to process this massive information influx. There has to be some kind of a fast transformation layer that takes the documents in all its formats and displays it in a format suited for annotations and markup....and the list goes on. Starting with the Domain model and moving down would be ideal but I am a little bit of a skeptic.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

小傻瓜 2024-10-13 07:51:22

我是一个 Java 人。我将如何解决这个问题,

  1. 找出数据模型。系统将使用哪些对象。
  2. 基于此设计您的数据库。您可以使用 Ibatis 或 Hibernate 等 ORM 框架(Ibatis 有一个代码生成器,可以生成几乎所有 DAO 来访问表。它为您提供 CRUD 方法,您可以在其上添加)。
  3. 完成后,您就可以开始设计服务层。将 DAO 直接暴露给控制器(MVC 模式)并不是一个好习惯。这是您的业务逻辑应该介入的地方。
  4. 选择可用的 Web 框架之一。最流行的 Java Web 框架是 Spring MVC。您也可以尝试 Google Guice。
  5. 最后一步是设计您的前端。我认为你的项目会包含很多javascript。因此,请查看 JQueryEXT JS

我希望这可以帮助您开始使用。

I'm a Java guy. How I would approach this problem will be,

  1. Figure out the data model. What are the Objects that the system will be using.
  2. Based on that design your database. You can use ORM frameworks like Ibatis or Hibernate ( Ibatis has a code generator which generates pretty much all the DAO's to access the tables. It gives you the CRUD methods and you can add on top of it).
  3. Once you are done with that, then you can start designing your service layer. Its not a good practice to expose the DAO's directly to the controllers( MVC pattern). This is where your business logic should go in.
  4. The choose one of the web frameworks available. The most popular java web frameworks are Spring MVC. You can also try Google Guice.
  5. Final step will be to design your front end. I think your project will include a lot of javascript. So look into JQuery or EXT JS

I hope this helps you to get started with.

蓦然回首 2024-10-13 07:51:22

这并不是一个真正的“完整答案”,但希望能提供一些值得深思的东西。

<块引用>

我使用这个项目作为练习,使用完全开源的工具设计可扩展/安全/快速的 Web 应用程序...

这是一件很棒的事情 - 所以我的问题是为什么要担心架构?我承认,对于一个自认为是建筑倡导者的人来说,这有点奇怪,但“学习建筑”和学习新技术都可能要求很高。也许您只想先了解其中一个,然后再解决另一个?

构建、设计和构建一个“可扩展/安全/快速”的系统并非易事。在“现实世界”的业务驱动案例中,您需要适应系统上下文,并满足非功能性需求:这些可能会建议不同的技术堆栈。不同的关键驱动因素将对您处理事情的方式以及做出的决策产生巨大的影响——当然,架构将围绕它构建。

编辑:

我会从对你来说更重要的事情开始;然后,当我开始讨论“其他”主题时,我会不断检查我学到的内容/我的假设。

根据两个主题的不同,可能会存在一些“协同效应”,从而建议采取不同的方法。我一方面想建议在其中一个方面做足够的工作,以获得良好的基本掌握,然后将另一个提升到类似的水平 - 然后继续前进。这样你就会更加一致。

我的另一部分说——只做最有趣的事!

<块引用>

我应该在继续前进之前深入研究给定的技术堆栈,还是从与工具无关的角度获取正确的蓝图?

首先,你肯定想要获得一个广阔但肤浅的视野;如果某些特定领域对您特别重要,也许会更详细地讨论它们。

<块引用>

或者我的蓝图会因为技术限制而改变吗?

我假设你的意思是:如果你发现“给定的技术以这种方式工作”以及它的工作方式与你的预期不同 - 那么这会影响蓝图吗?

它可以做到 - 这就是为什么对相关技术的广泛但肤浅的看法应该帮助您避免最糟糕/最明显的错误。我还假设您有足够的总体经验来知道当您开始这样做时您在看什么 - 您可以在进行设计之前认识到需要更详细研究的领域。

从较高的层面来看,您所要做的就是确保您不会限制进一步的选择。

Not really a "full answer" but hopefully some food for thought.

I am using this project as an exercise to design a scalable/secure/fast web-application using entirely open source tools...

That's a great thing to be doing - so my question would be why worry about the architecture? I admit this is a bit strange coming from someone who see's themselves as an advocate for architecture, but "learning architecture" and learning new technologies can both be demanding. Maybe you just want to get up-to speed with one first, then tackle the other?

Architecting, designing and building a system that is "scalable/secure/fast" isn't trivial. In a "real-world" business driven case you'd have a system context to fit in with, and non-functional requirements to hit: these might suggest a different technology stack. Different key drivers will have a huge affect on how you approach things and what decisions get made - and of course the architecure would be built around that.

Edit:

I'd start with what was more important to you; then as I start on the "other" topic I'd be constantly checking what I'd learnt / my assumptions.

Depending on the two subjects there might be some "synergies" which suggest a different approach. Part of me wants to recommend doing enough on one to get a good basic grasp and then bring the other one up to a similar level - then move on. That way you're kind of more consistent.

Another part of me says - just do what's most interesting!

Should I plumb the depths of a given technology stack before moving forward or get the blueprint right from a tool agnostic standpoint?

As a start, you'd definately want to get a broad but shallow view; maybe go into some specific areas in a little more detail if they were of particular importance to you.

Or is my blueprint going to change because of the technology constraints?

By this I'm assuming you mean that: if you discover a "given technology works in such a way" and how it works it different form what you were expecting - then will this affect the blueprint?

It could do - that's why a broad but shallow view of the relevant technology should help you avoid the worst / most obviously bad mistakes. I'm also assuming that you have enough overal experience to know what you're looking at when you start doing this - that you can recognise an area that needs more detailed study before committing to a design.

At a high level, all you're looking to do is ensure you're not restricting options further down the path.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文