技术文章 - CS272585

无法获取 Swagger JSON 错误:FlexPLM 11.0 FCS 中的 404

已修改: 26-Dec-2022   


注意:本文已使用机器翻译软件翻译,以方便非英语客户阅读。但翻译内容可能包含语法错误或不准确之处。请注意, PTC对本文所含信息的翻译准确性及使用后果不承担任何责任。请在 此处 查看本文的英文原始版本以便参考。有关机器翻译的更多详情,请单击 此处
感谢您告诉我们。我们将尽快审阅此译文。

适用于

  • FlexPLM 11.0 F000

说明

  • 无法在 FlexPLM 中获取 Swagger JSON
  • HTTPServer 或方法服务器上没有错误。
  • flexplmwebservice.log 中的错误
START: 2017-10-19.10:54:19
URL: https://[server]/Windchill/servlet/rest/p76/security/csrf
HTTP CODE: 404
CURL CODE: 0
END:   2017-10-19.10:54:20
:
  • 检查是否使用插件正确配置了 RESTful 服务
    • xconfmanager -d plugin76.rest.resources
E:\ptc\Windchill_11.0\Windchill>xconfmanager -d plugin76.rest.resources
Default product root=E:\ptc\Windchill_11.0\Windchill\bin\..
java -cp "E:\ptc\Windchill_11.0\Windchill\bin\..\codebase;E:\ptc\Windchill_11.0\Windchill\bin\..\codebase\WEB-INF\lib\*;E:\ptc\Windchill_11.0\Windchill\bin\..\lib\*" com.ptc.windchill.structconf.StructConfManager -r "E:\ptc\Windchill_11.0\Windchill\bin\.." -d plugin76.rest.resources
Property information for 'plugin76.rest.resources':
   Multivalued property delimiter: ,
   Values:
   - com.plugin76.rest.security.CSRFService
   -  com.plugin76.rest.security.AuthenticationFilter
   -  com.plugin76.rest.favorites.FavoritesService
   -  com.plugin76.rest.instances.InstancesService
   -  com.plugin76.rest.types.TypesService
   -  com.plugin76.rest.documents.DocumentRestService
   -  com.plugin76.rest.views.ViewRestService
   -  com.plugin76.rest.filters.FilterRestService
   -  com.plugin76.rest.product.ProductRestService
   -  com.plugin76.rest.imagespage.ImagesPageService
   -  com.plugin76.rest.specification.SpecificationRestService
   -  com.plugin76.rest.palette.PaletteRestService
   -  com.plugin76.rest.search.InstanceSearchService
   -  com.plugin76.rest.upload.UploadRestService
   -  com.plugin76.rest.bom.BOMRestService
   -  com.plugin76.rest.materials.MaterialsRestService
   -  com.plugin76.rest.seasons.SeasonsRestService
   Locations:
   - file:/E:/ptc/Windchill_11.0/Windchill/codebase/com/plugin76/rest/plugin76.rest.xconf, line 4
   Target File(s):
   - E:\ptc\Windchill_11.0\Windchill\codebase\com\ptc\windchill\rest\rest.properties

E:\ptc\Windchill_11.0\Windchill>
  • 获取 swagger JSON 以测试 Plugin76 的连接
    • 错误: “无法读取 Swagger JSON”
  • 验证 web.xml 文件并检查其余服务:
    • <服务小程序>
      <description>RESTEasy Servlet</description>
      <servlet-name>resteasy-servlet</servlet-name>
      <servlet-class>org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher</servlet-class>
      <初始化参数>
      <param-name>javax.ws.rs.Application</param-name>
      <参数值>com.ptc.windchill.rest.ApplicationConfig</参数值>
      </初始化参数>
      </servlet>
这是文章 272585 的 PDF 版本,可能已过期。最新版本 CS272585