You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

为何搭建CordApp后访问http://localhost:10007/web/example/返回空响应?

Troubleshooting CordApp Web Endpoint No Response Issue

Let’s break down the most likely causes and fixes for your unresponsive http://localhost:10007/web/example/ endpoint, even after successfully building your corapp-example:

  • Verify your Corda node is actually running
    Building the CorDapp doesn’t automatically start the node. Check if the node process is active:

    • On Linux/macOS: Run ps aux | grep corda to list related processes.
    • On Windows: Open Task Manager and look for java.exe or corda.exe instances.
      Also, check the node’s log file at node/logs/node.log for confirmation. You should see lines like Node for "O=Example Corp, L=London, C=GB" started up successfully and Started Jetty server on port 10007 if everything’s working.
  • Double-check node configuration for correct web port
    Open your node’s node.conf file and verify these settings:

    rpcSettings {
        address="localhost:10007"
    }
    webServer {
        address="localhost:10007"
    }
    

    Sometimes the default port might differ (e.g., 10006), or it could have been modified accidentally. Ensure the port in your config matches the one you’re trying to access.

  • Check for port conflicts or firewall blocks
    Port 10007 might be occupied by another application:

    • On Windows: Run netstat -ano | findstr :10007 to find the process ID using the port, then kill it via Task Manager if needed.
    • On Linux/macOS: Use lsof -i :10007 to identify the process, then kill it with kill <PID>.
      Also, confirm your local firewall isn’t blocking incoming connections on port 10007. Temporarily disabling the firewall (for testing) or adding an allow rule can help rule this out.
  • Ensure the Web CorDapp is properly deployed
    Building the CorDapp generates a .jar file in build/libs/. Make sure this file is copied to your node’s cordapps directory. After copying, restart the node and check the logs for a line like Loaded CorDapp: com.example.examplecordapp-<version>.jar—this confirms the CorDapp was loaded successfully.

  • Validate the web endpoint path
    The /web/example/ path depends on how your CorDapp registers its web routes. Check the WebServerPluginRegistry implementation in your code; look for a line like registerWebApp("example", ...). If the first parameter here is different (e.g., demo), your endpoint would be /web/demo/ instead. You can also scan the node startup logs for route registration messages to confirm the correct path.

  • Test basic web server connectivity
    Try accessing http://localhost:10007/rpc directly with a browser or curl. If you get a 403 Forbidden response, that means the node’s web server is running—your issue is likely with the CorDapp’s path or deployment. If you get no response at all, the problem is with the node not starting or the port being incorrect.

内容的提问来源于stack exchange,提问作者Deepthi Kr

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.05.27 04:05:31