Teemo Yordle
    • Create new note
    • Create a note from template
      • Sharing URL Link copied
      • /edit
      • View mode
        • Edit mode
        • View mode
        • Book mode
        • Slide mode
        Edit mode View mode Book mode Slide mode
      • Customize slides
      • Note Permission
      • Read
        • Only me
        • Signed-in users
        • Everyone
        Only me Signed-in users Everyone
      • Write
        • Only me
        • Signed-in users
        • Everyone
        Only me Signed-in users Everyone
      • Engagement control Commenting, Suggest edit, Emoji Reply
    • Invite by email
      Invitee

      This note has no invitees

    • Publish Note

      Share your work with the world Congratulations! 🎉 Your note is out in the world Publish Note

      Your note will be visible on your profile and discoverable by anyone.
      Your note is now live.
      This note is visible on your profile and discoverable online.
      Everyone on the web can find and read all notes of this public team.
      See published notes
      Unpublish note
      Please check the box to agree to the Community Guidelines.
      View profile
    • Commenting
      Permission
      Disabled Forbidden Owners Signed-in users Everyone
    • Enable
    • Permission
      • Forbidden
      • Owners
      • Signed-in users
      • Everyone
    • Suggest edit
      Permission
      Disabled Forbidden Owners Signed-in users Everyone
    • Enable
    • Permission
      • Forbidden
      • Owners
      • Signed-in users
    • Emoji Reply
    • Enable
    • Versions and GitHub Sync
    • Note settings
    • Note Insights
    • Engagement control
    • Transfer ownership
    • Delete this note
    • Save as template
    • Insert from template
    • Import from
      • Dropbox
      • Google Drive
      • Gist
      • Clipboard
    • Export to
      • Dropbox
      • Google Drive
      • Gist
    • Download
      • Markdown
      • HTML
      • Raw HTML
Menu Note settings Versions and GitHub Sync Note Insights Sharing URL Create Help
Create Create new note Create a note from template
Menu
Options
Engagement control Transfer ownership Delete this note
Import from
Dropbox Google Drive Gist Clipboard
Export to
Dropbox Google Drive Gist
Download
Markdown HTML Raw HTML
Back
Sharing URL Link copied
/edit
View mode
  • Edit mode
  • View mode
  • Book mode
  • Slide mode
Edit mode View mode Book mode Slide mode
Customize slides
Note Permission
Read
Only me
  • Only me
  • Signed-in users
  • Everyone
Only me Signed-in users Everyone
Write
Only me
  • Only me
  • Signed-in users
  • Everyone
Only me Signed-in users Everyone
Engagement control Commenting, Suggest edit, Emoji Reply
  • Invite by email
    Invitee

    This note has no invitees

  • Publish Note

    Share your work with the world Congratulations! 🎉 Your note is out in the world Publish Note

    Your note will be visible on your profile and discoverable by anyone.
    Your note is now live.
    This note is visible on your profile and discoverable online.
    Everyone on the web can find and read all notes of this public team.
    See published notes
    Unpublish note
    Please check the box to agree to the Community Guidelines.
    View profile
    Engagement control
    Commenting
    Permission
    Disabled Forbidden Owners Signed-in users Everyone
    Enable
    Permission
    • Forbidden
    • Owners
    • Signed-in users
    • Everyone
    Suggest edit
    Permission
    Disabled Forbidden Owners Signed-in users Everyone
    Enable
    Permission
    • Forbidden
    • Owners
    • Signed-in users
    Emoji Reply
    Enable
    Import from Dropbox Google Drive Gist Clipboard
       owned this note    owned this note      
    Published Linked with GitHub
    1
    Subscribed
    • Any changes
      Be notified of any changes
    • Mention me
      Be notified of mention me
    • Unsubscribe
    Subscribe
    # PTT 新版本開發專案-常見Q&A ## 維護人 提莫 ###### tags: `Ptt App`、`FAQ` ###### 位置: [主目錄](https://hackmd.io/@twbbs/Root)/常見Q&A 1. 是否可以直接看規格(如果沒有,至少需要重點說明)開發中台 C# ? * 請參考文件主目錄底下的 * 中介應用層(中台對外API)/專案討論區 * 中介應用層(中台對外API)/Asp版本中台應用層(與Pichu版本底層對接)/開發文件 2. BBS daemon 是自己架的嗎? * 目前 PTT 的 Daemon 是由PTT站方架設的。 * 目前(2021/07/27)由開發者架設兩個測試站台作為 App 前端測試使用,測試資料與真實站台不同。 * 測試站的部分有一個共用的測試站是由 Codingman 架的。 * 另外如果自己開發需求,需要自行架設也是可以的,或是請洽提莫。 3. 其實對於 BBS 的運作原理還沒有很了解,猜測是一個 server 去 hosting,然後協議是 telnet 這樣? * 這邊我先不使用 Server 這個詞。我先假設你理解一般的 LAMP 架構,也就是 Linux Apache MySQL PHP 架構。 那在連線進來時, Linux 底層會進行 80或443的TCP 交握,隨後把交握結果交給 Apache, 由Apache 確定要交由哪個行程 Process 處理, Apache 處理完基本的 TLS 以及 HTTP 之後發現是 PHP 程式的請求,即透過同主機內的連線請 PHP-FPM 進行處理,接著PHP-FPM是情況決定是否連線 SQL 後把資訊回傳。 * 而 BBS 的架構簡單一點, Linux 處理完交握的事情之後剩下來的事都是BBS的事情了,因此要走TELNET或是SSH或是任何Protocol 大多數都是在 BBS 的程式上實作的,使用者連線連入後行程會進行 Fork, 一個行程變成兩個,所以如果站上有五萬人,那主機就會有五萬個行程! 4. 中台的意義是? * 支援新的介面,提供 RESTful API * 用於專屬官方APP獨有支援的評價與留言功能 * 提供現代化搜尋(實作中文斷詞) * 增加支援 CDN、Redis * Log 5. 主要看到有多個中台,.net / go / python 各有一個,且在雙版本架構中,go 版本的中介底層似乎跟 bbs daemon 在同一層級,因此想知道下各個的意義是為何? * 目前(2021/07/27)實際上就是支持兩個版本的後台與一個版本的中台,分別是: * 後台中介底層(中台對內資料存取原生BBS層) * Hsiao版本中介底層(Go) 老蕭負責 * Pichu 版本中介底層(Go) Pichu負責 * 中台 * Hsiao版本中台(中台應用層)(Go) 老蕭負責 6. 對於 websocket 及 grpc 兩者間關係不是那麼清楚,想問下為何兩個會被放在同一塊? * 架構圖中指的是 term.ptt.cc 的形式,所以區塊中把 websocket 與 grpc 放在同一塊示意。 7. 現在市面上的 app ( mo j ....) 知道他們是用什麼架構嗎? telnet / ssh / socket ? * 首先, socket = telnet ,原則上所有的網路連線都可以用 socket 實作。 * 再來 SSH 和 TELNET 的主要差異在連線之前有沒有加密,SSH像是一個大的不透光的牛皮紙袋, telnet 像是明信片,因此即使是透過SSH加密,裡面通常還是直接把明信片裝在這個牛皮紙袋裡面,因此還是會需要用到製作裡面這張明信片的程式碼,只是加上了外面的牛皮紙袋後讓上面的資訊變得安全了許多。 * 而關於市面上的 app ,老實說每個APP的手法可能不同,有些可能會把資料先存在該伺服器,有些可能不會。 8. 有考慮改動水桶系統的計算天數方式嗎?比方說看對方上線時間而非現實的天數之類的?不過這要紀錄離站時間,會有負荷? * 官方APP專案的範疇,不會改動原BBS的程式碼,所以不會改變原機制。 9. 這專案缺人麼樣的人? * 這專案需要大家一起來協助,所以歡迎來g0v一起討論。 * 如果你不確定自己是否適合或是能做什麼,可以先從g0v新手導覽開始。 10. 是否會支援水球系統? * 官方APP專案的範疇,暫無此部分,先把目前目標完成,後續可討論進程。 11. 是否會支援小天使系統? * 官方APP專案的範疇,暫無此部分,先把目前目標完成,後續可討論進程。 12. 中台應用層與前端連線方式 * 中台應用層對外使用 RESTful API。 * (底層)<-RESTful API->(中台)<-RESTful API->(前端) 13. 為何是中台傳遞 user token 給後端的設計,而不是使用 api key? 一般都是認證串接來源,不會認證串接來源的來源? * 設計上為了保留中台未來有彈性可以同時支援適應:1.移動至公有雲或2.留在與底層相同內網的環境,讓這兩種環境*都可能*持續維運,認證串接來源的來源是一種候選的解決方案,因此我們選擇實作這機制。 14. 不使用 api key 的考量 * API keys are generally not considered secure; they are typically accessible to clients, making it easy for someone to steal an API key. Once the key is stolen, it has no expiration, so it may be used indefinitely, unless the project owner revokes or regenerates the key. While the restrictions you can set on an API key mitigate this, there are better approaches for authorization.

    Import from clipboard

    Paste your markdown or webpage here...

    Advanced permission required

    Your current role can only read. Ask the system administrator to acquire write and comment permission.

    This team is disabled

    Sorry, this team is disabled. You can't edit this note.

    This note is locked

    Sorry, only owner can edit this note.

    Reach the limit

    Sorry, you've reached the max length this note can be.
    Please reduce the content or divide it to more notes, thank you!

    Import from Gist

    Import from Snippet

    or

    Export to Snippet

    Are you sure?

    Do you really want to delete this note?
    All users will lose their connection.

    Create a note from template

    Create a note from template

    Oops...
    This template has been removed or transferred.
    Upgrade
    All
    • All
    • Team
    No template.

    Create a template

    Upgrade

    Delete template

    Do you really want to delete this template?
    Turn this template into a regular note and keep its content, versions, and comments.

    This page need refresh

    You have an incompatible client version.
    Refresh to update.
    New version available!
    See releases notes here
    Refresh to enjoy new features.
    Your user state has changed.
    Refresh to load new user state.

    Sign in

    Forgot password

    or

    By clicking below, you agree to our terms of service.

    Sign in via Facebook Sign in via Twitter Sign in via GitHub Sign in via Dropbox Sign in with Wallet
    Wallet ( )
    Connect another wallet

    New to HackMD? Sign up

    Help

    • English
    • 中文
    • Français
    • Deutsch
    • 日本語
    • Español
    • Català
    • Ελληνικά
    • Português
    • italiano
    • Türkçe
    • Русский
    • Nederlands
    • hrvatski jezik
    • język polski
    • Українська
    • हिन्दी
    • svenska
    • Esperanto
    • dansk

    Documents

    Help & Tutorial

    How to use Book mode

    Slide Example

    API Docs

    Edit in VSCode

    Install browser extension

    Contacts

    Feedback

    Discord

    Send us email

    Resources

    Releases

    Pricing

    Blog

    Policy

    Terms

    Privacy

    Cheatsheet

    Syntax Example Reference
    # Header Header 基本排版
    - Unordered List
    • Unordered List
    1. Ordered List
    1. Ordered List
    - [ ] Todo List
    • Todo List
    > Blockquote
    Blockquote
    **Bold font** Bold font
    *Italics font* Italics font
    ~~Strikethrough~~ Strikethrough
    19^th^ 19th
    H~2~O H2O
    ++Inserted text++ Inserted text
    ==Marked text== Marked text
    [link text](https:// "title") Link
    ![image alt](https:// "title") Image
    `Code` Code 在筆記中貼入程式碼
    ```javascript
    var i = 0;
    ```
    var i = 0;
    :smile: :smile: Emoji list
    {%youtube youtube_id %} Externals
    $L^aT_eX$ LaTeX
    :::info
    This is a alert area.
    :::

    This is a alert area.

    Versions and GitHub Sync
    Get Full History Access

    • Edit version name
    • Delete

    revision author avatar     named on  

    More Less

    Note content is identical to the latest version.
    Compare
      Choose a version
      No search result
      Version not found
    Sign in to link this note to GitHub
    Learn more
    This note is not linked with GitHub
     

    Feedback

    Submission failed, please try again

    Thanks for your support.

    On a scale of 0-10, how likely is it that you would recommend HackMD to your friends, family or business associates?

    Please give us some advice and help us improve HackMD.

     

    Thanks for your feedback

    Remove version name

    Do you want to remove this version name and description?

    Transfer ownership

    Transfer to
      Warning: is a public team. If you transfer note to this team, everyone on the web can find and read this note.

        Link with GitHub

        Please authorize HackMD on GitHub
        • Please sign in to GitHub and install the HackMD app on your GitHub repo.
        • HackMD links with GitHub through a GitHub App. You can choose which repo to install our App.
        Learn more  Sign in to GitHub

        Push the note to GitHub Push to GitHub Pull a file from GitHub

          Authorize again
         

        Choose which file to push to

        Select repo
        Refresh Authorize more repos
        Select branch
        Select file
        Select branch
        Choose version(s) to push
        • Save a new version and push
        • Choose from existing versions
        Include title and tags
        Available push count

        Pull from GitHub

         
        File from GitHub
        File from HackMD

        GitHub Link Settings

        File linked

        Linked by
        File path
        Last synced branch
        Available push count

        Danger Zone

        Unlink
        You will no longer receive notification when GitHub file changes after unlink.

        Syncing

        Push failed

        Push successfully