简体   繁体   English

通过Web服务将.NET应用程序与Java / J2EE应用程序集成

[英]Integrating .NET application with Java/J2EE app via web services

Assume we have a .NET application that exposes its web services. 假设我们有一个.NET应用程序公开其Web服务。 This app needs to be integrated with our J2EE application running on Weblogic. 该应用程序需要与我们在Weblogic上运行的J2EE应用程序集成。 Both are internal applications so we don't worry too much about security. 两者都是内部应用程序,因此我们不必太担心安全性。

There are no really complex data structures/types so we should be able to map them between .NET and Java tier (or at least write adapters on the Java tier to ensure the match). 没有真正复杂的数据结构/类型,因此我们应该能够在.NET和Java层之间进行映射(或至少在Java层上编写适配器以确保匹配)。

What is the best approach of consuming these .NET web services in the J2EE application? 在J2EE应用程序中使用这些.NET Web服务的最佳方法是什么?

The simple approach would be to just generate WSDLs for the .NET web services, and generate Java client classes using wsdl2java or other similar tool and see if that can work without adapters/changes, create unit tests, etc. But in case of data related challenges we may need to deal with XSD/Schemas, generating classes, etc. 一种简单的方法是只为.NET Web服务生成WSDL,并使用wsdl2java或其他类似工具生成Java客户端类,然后查看它是否可以在不使用适配器/更改的情况下工作,创建单元测试等。我们可能需要处理XSD / Schema,生成类等挑战。

I know there is WSIT to deal with interoperability issues, but want to keep this as simple as possible. 我知道有WSIT可以处理互操作性问题,但是想让它尽可能简单。 Any thoughts, ideas? 有什么想法吗?

You could connect the two applications with a RESTful API. 您可以使用RESTful API连接这两个应用程序。 This lets them talk in a shared, high level API over HTTP. 这使他们可以通过HTTP在共享的高级API中进行交谈。 Both languages have plenty of support for both creating and using HTTP/RESTful services, so this should be fairly simple to implement in either language. 两种语言都对创建和使用HTTP / RESTful服务都提供了充分的支持,因此使用两种语言实现起来应该都非常简单。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM