chemistry-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Florian Müller <f...@apache.org>
Subject Re: CMIS 1.1 and broken support for WebSphere
Date Wed, 03 Jul 2013 11:01:00 GMT
 Hi Ivan,

 I wouldn't be so sure that relative URLs work with all Web Services 
 stacks. There are many programming languages with dodgy stacks out 
 there. JAX-WS stacks are not a good benchmark because they are popular 
 and therefore have been adapted to many scenarios. That's not the case 
 for many less popular stacks.

 But you are right. The OpenCMIS server framework has not been written 
 for Axis. It has written for the Metro stack. And all the template files 
 are necessary to bypass issues with this stack and wouldn't be necessary 
 for other stacks. (The Metro stack is not able to generate two different 
 WSDLs for the same service [same = same namespace and name] in the same 
 web application. Now the CMIS web services servlet generates the WSDLs 
 instead.)

 And I agree it would be great to have support for all other JAX-WS 
 stacks. Unfortunately, all stacks need some sort of proprietary 
 tweaking. Some need more and some need less.
 I don't have the time or the requirement to support or test other 
 stacks. But this is an open source project and contributions are 
 welcome.


 - Florian


> Well, I compared the content of wsdl's and the difference is only in 
> set of
> urls inside.
> I bet if one place all content properly inside of WEB-INF relative 
> URL's
> would work just fine, w/o the need to patch them at runtime. Client 
> uses
> dynamic endpoint URL's (
> 
> http://tugdualgrall.blogspot.com/2009/02/jax-ws-how-to-configure-service-end_17.html)
> at
> runtime, code generation should work fine with relative urls.
> The issue I see with Websphere is that servlet which you wrote can't 
> be
> used on axis because of dependency on metro, plus Websphere do 
> generate
> proper urls for service endpoitns by webservices.xml files, except 
> ones for
> wsdl's itself.
>
> Do think its better to keep two copies of XSD's/WSDL's in 
> commons/server
> and have same servlet for each jax-ws stack?
> Please advise.
>
> Thanks,
> Ivan
>
>
> 2013/7/2 Florian Müller <fmui@apache.org>
>
>> Hi Ivan,
>>
>> XSD/WSDL's in in the commons package and the .template files are not 
>> the
>> same.
>> XSD/WSDL's are (more or less) the original specification files and
>> required for the code generation and for the client. The .template 
>> files
>> contain placeholders that the server needs to build an appropriate 
>> WSDL at
>> runtime.
>>
>>
>> - Florian
>>
>>
>>  Hello,
>>>
>>> After looking on how to fix WebSphere support for latest version of 
>>> apache
>>> chemistry, I'm a bit confused with this code:
>>>
>>> https://github.com/apache/**chemistry-opencmis/blob/trunk/**
>>> chemistry-opencmis-server/**chemistry-opencmis-server-**
>>> bindings/src/main/java/org/**apache/chemistry/opencmis/**
>>> 
>>> server/impl/webservices/**CmisWebServicesServlet.java<https://github.com/apache/chemistry-opencmis/blob/trunk/chemistry-opencmis-server/chemistry-opencmis-server-bindings/src/main/java/org/apache/chemistry/opencmis/server/impl/webservices/CmisWebServicesServlet.java>
>>>
>>> Can XSD/WSDL's from commons be re-used instead of copy and pasting 
>>> them
>>> into server module?
>>> https://github.com/apache/**chemistry-opencmis/tree/trunk/**
>>> chemistry-opencmis-commons/**chemistry-opencmis-commons-**
>>> 
>>> impl/src/main/resources/wsdl<https://github.com/apache/chemistry-opencmis/tree/trunk/chemistry-opencmis-commons/chemistry-opencmis-commons-impl/src/main/resources/wsdl>
>>>
>>> I have an idea to attach both WSDL's from commons into maven repo 
>>> and then
>>> unpack into bindings war, so there will be no ".template" files 
>>> copy and
>>> paste issue.
>>> Please let me know WDYT.
>>>
>>> P.S.: Below are snippets from maven on how to get WSDL into maven 
>>> repo and
>>> then use it as dependency in other maven project:
>>>
>>> 1. Project1. Publish wsdl/xsd into maven repo
>>>
>>>              <!-- Antrun to zip wsdl files and schemas, can be done
>>> with assembly as well-->
>>>              <plugin>
>>>                  <groupId>org.apache.maven.**plugins</groupId>
>>>                  <artifactId>maven-antrun-**plugin</artifactId>
>>>                  <executions>
>>>                      <execution>
>>>                          <id>wsdl=pack</id>
>>>
>>>                          <phase>package</phase>
>>>                          <goals>
>>>                              <goal>run</goal>
>>>
>>>                          </goals>
>>>                          <configuration>
>>>                              <tasks>
>>>                                  <mkdir dir="target/wsdl-tmp/" />
>>>                                  <copy todir="target/wsdl-tmp/"
>>> flatten="true">
>>>                                      <fileset dir="${wsdl.path}">
>>>                                          <include name="**/*.*" />
>>>                                      </fileset>
>>>                                  </copy>
>>>
>>>                                  <zip destfile="target/wsdl.zip">
>>>                                      <fileset 
>>> dir="target/wsdl-tmp">
>>>                                          <include name="**/*.*" />
>>>                                      </fileset>
>>>                                  </zip>
>>>                              </tasks>
>>>                          </configuration>
>>>                      </execution>
>>>                  </executions>
>>>              </plugin>
>>>
>>>
>>>              <plugin>
>>>                  <groupId>org.codehaus.mojo</**groupId>
>>>                  
>>> <artifactId>build-helper-**maven-plugin</artifactId>
>>>                  
>>> <version>${plugin.version.**build-helper}</version>
>>>                  <executions>
>>>                      <execution>
>>>                          <id>2</id>
>>>
>>>                          <goals>
>>>                              <goal>attach-artifact</goal>
>>>                          </goals>
>>>                          <configuration>
>>>                              <artifacts>
>>>                                  <artifact>
>>>
>>> <file>${project.build.**directory}/wsdl.zip</file>
>>>                                      
>>> *<classifier>wsdl</classifier>***
>>>
>>>                                  </artifact>
>>>                              </artifacts>
>>>                          </configuration>
>>>                      </execution>
>>>                  </executions>
>>>              </plugin>
>>>
>>> 2.  Project 2. Use wsdl to generate client or include into target
>>> artifact:
>>>
>>>              <plugin>
>>>                  <groupId>org.apache.maven.**plugins</groupId>
>>>                  <artifactId>maven-dependency-**plugin</artifactId>
>>>                  <version>${plugin.version.**dependency}</version>
>>>                  <executions>
>>>                      <execution>
>>>                          <id>unpack</id>
>>>
>>>                          <phase>validate</phase>
>>>
>>>                          <goals>
>>>                              <goal>unpack</goal>
>>>                          </goals>
>>>                          <configuration>
>>>                              <artifactItems>
>>>                                  <artifactItem>
>>>                                      <groupId>...</groupId>
>>>                                      <artifactId>...</artifactId>
>>>                                      
>>> <version>${project.version}</**
>>> version>
>>>                                      
>>> *<classifier>wsdl</classifier>***
>>>
>>>                                      <type>jar</type>
>>>                                      <overWrite>false</overWrite>
>>>
>>> <outputDirectory>${wsdl.**unpacked.path}</**outputDirectory>
>>>                                      
>>> <includes>**/*.wsdl,**/*.xsd</**
>>> includes>
>>>                                  </artifactItem>
>>>                              </artifactItems>
>>>                          </configuration>
>>>                      </execution>
>>>                  </executions>
>>>              </plugin>
>>>
>>> Regards,
>>> Ivan
>>>
>>>

Mime
View raw message