Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 330576

Summary: [Search] Implements XML/Search engine with XPath like File/Search, Java/Search
Product: [WebTools] WTP Source Editing Reporter: Angelo ZERR <azerr>
Component: wst.xpathAssignee: David Carver <d_a_carver>
Status: REOPENED --- QA Contact: Jesper Moller <jesper>
Severity: enhancement    
Priority: P3 CC: ariv, azerr, dave, dgolovin, dgolovin, d_a_carver, gregory.amerson, manderse, olejorgenb, rakes123, thatnitind
Version: unspecified   
Target Milestone: ---   
Hardware: PC   
OS: Windows XP   
Whiteboard:
Attachments:
Description Flags
Screen of XML Search dialog with "//pipeline" Xpath
none
Screen of XML result Search with "//pipeline" Xpath
none
XML Search engine to manage autocmpletion
none
Ctrl+Shift+G used to find referenced Node
none
Doc about XML Jetty Plugins which use XML Search engine
none
Doc about XML Search engine UI + how use it into Eclipse plugins
none
WTP/XML Search plugins
none
WTP/XML Search plugins [Java 2 X references + namespaces management]
none
WTP/XML Search plugins (license fixed) none

Description Angelo ZERR CLA 2010-11-18 10:20:01 EST
Hi WST Team,

I don't know if you are interested with my work but I'm implementing an XML Search Engine to give the capability to search Nodes with XPath (or pur DOM) by using DOM SSE.

With this XML Search Engine you can search nodes in your XML files of your Eclipse workspace. In my case I have several (custom) XML files which are linked with attribute and I manage completion.

For instance image you have thoses XML files in your workspace : 

roles.xml : 
------------------------
<roles>
   <role id="role1" />
   <role id="role2" />
</roles>
------------------------

person.xml
------------------------
<person>
    <role-ref id="role1" />
    <role-ref id="role2" />
</person>
------------------------

role-ref element from person xml file is linked to role element from roles.xml. I have managed completion for the "id" attribute of the person/role-ref. To do taht I need to query roles.xml to display the list of the roles. I'm using my XML Search engine to manage that.

I'm studying Eclipse Search API to manage Ctrl+Shift+G. For instance if you do Ctrl+Shift+G after selecting the "id" attribute  (from roles.xml), I want display XML files wich are linked to the role id.

Once I will finsish to implement Eclipse Search API  with my search Engine I would like add XML Search like File Search or Java Search to type Xpath in a field and start the search and retrieve XML files wich follow teh XPath expression.

Today I have created 2 projects : 

* org.eclipse.wst.xml.search.core
* org.eclipse.wst.xml.search.ui

If you are interested, tell me and I will send you a patch when I will finish my work.

Regards Angelo
Comment 1 Rakesh CLA 2010-11-18 23:53:50 EST
It looks like an enhancement.
Comment 2 David Carver CLA 2010-11-21 16:24:42 EST
Moving to the wst.xpath component.

This has been something we have been wanting to do.  One of the thoughts has been to leverage the PsychoPath engine's ability to handle adopter Collection implementations to implement the search functionality.  This way any xpath 2.x expression can be used.
Comment 3 David Carver CLA 2010-11-21 16:26:52 EST
Angelo, please submit a patch, and we'll take a look at it.
Comment 4 Angelo ZERR CLA 2010-11-21 16:51:36 EST
(In reply to comment #3)
> Angelo, please submit a patch, and we'll take a look at it.

Hi Daniel,

Thank a lot for your answer. I have not finished to develop the XML search engine and I do a lot of refactor every time. But now I can manage XML Search by using Eclipse Search API (to launch the search with Ctrl+Shift+G to find referenced node for instance) or without the Search API (to use the XML search engine for completion).

My next step is to develop XML Search UI Dialog like Java Search/ File Search.

As soon as I will have something stable, I will do send a patch.

Regards Angelo
Comment 5 Angelo ZERR CLA 2010-11-22 06:09:06 EST
Created attachment 183559 [details]
Screen of XML Search dialog with "//pipeline" Xpath

XML Search dialog with "//pipeline" Xpath
Comment 6 Angelo ZERR CLA 2010-11-22 06:09:55 EST
Created attachment 183560 [details]
Screen of XML result Search with "//pipeline" Xpath
Comment 7 Angelo ZERR CLA 2010-11-22 06:13:40 EST
Comment on attachment 183559 [details]
Screen of XML Search dialog with "//pipeline" Xpath

Screan of XML Search dialog where you can type XPath expression. Here I'm searching pipeline Node in XML files from my workspace.
Comment 8 Angelo ZERR CLA 2010-11-22 06:14:50 EST
Comment on attachment 183560 [details]
Screen of XML result Search with "//pipeline" Xpath

Scren of XML search result with "//pipeline" Xpath. The search result display Nodes founded (pipeline).   You can double click on Node to open editor ans select the Node in the editor.
Comment 9 Angelo ZERR CLA 2010-11-22 06:17:16 EST
Created attachment 183561 [details]
XML Search engine to manage autocmpletion

Here I have opened autocmpletion fired on src attribute of a pipeline with fiche2 uri. It opens the whole pipeline declared (ex : fiche). You can select it and use Hyperlink (Ctrl+Clic) to open linked Pipeline (this case use XML searc engien too).
Comment 10 Angelo ZERR CLA 2010-11-22 06:20:24 EST
Created attachment 183562 [details]
Ctrl+Shift+G used to find referenced Node

Here I have selected uri attribute fiche and I have done "Ctrl+Shift+G" to find referenced pipelines. The search is launched and it display the Node pipeline[@uri="fiche2"] which is linked to pipeline[@uri="fiche"]. Here I'm using in my custom Plugin to find this referenced pripelines node.
Comment 11 Angelo ZERR CLA 2010-11-22 06:25:18 EST
Hi David,

I send you scren of my XML Search Engine to see it in action. Hope my features will please you. As soon as I have stable code, I will send you a patch in order to play with it.

I have an another idea to declare just link between XML files and autocmpletion, referenced search, hyperlink works just by using declared link. For instance I would like declare just a link in extension Point:

-------------------------------
<link from="/pipelines/pipeline/transformer[@type='pipeline']/@src" to="/pipelines/pipeline/@uri" /> 
-------------------------------

And autocmpletion, hyperlink will works (with no code) for src attribute. Referenced search (Ctrl+Shift+G) will works too automaticly when you do it on pipeline/@uri attribute.

Hope my idea will please you.

Regards Angelo
Comment 12 David Carver CLA 2010-11-25 09:45:29 EST
Angelo, I'll take a look at this in the next few days.  Thanks.
Comment 13 Angelo ZERR CLA 2010-12-01 14:52:58 EST
(In reply to comment #12)
> Angelo, I'll take a look at this in the next few days.  Thanks.

Hi David, 

Thank a lot. For your information I have commited my work at https://tk-ui.svn.sourceforge.net/svnroot/tk-ui/cnaf.sidoc.ide/

You will find : 

# org.eclipse.wst.xml.search.core/
# org.eclipse.wst.xml.search.core.tests/
# org.eclipse.wst.xml.search.editor/
# org.eclipse.wst.xml.search.ui/

which are teh XML Search Engien that I wish contribute. The another projects are projects which use via extension point the XML search engine to have autocmpletion, hyperlink, validation + Ctrl+Shift+G (to retrieved linked nodes). 

References between XML Nodes (<XML <-> XML), XML nodes and Java (<XML -> Java) or files (<XML -> files) are declared with extension point with XPath like. When you declare the refernces, the autocmpletion, hyperlink, validation and CXtl+Shift+G are managed automaticly.

I'm using my XML search engine with my custom XML descriptor but I think I will use it to manage XML Jetty config files. Jetty team could be interested with thoses features.

XML Search engine is not stable but tell me if you have some questions.

Regards Angelo
Comment 14 Angelo ZERR CLA 2010-12-03 05:35:15 EST
Created attachment 184454 [details]
Doc about XML Jetty Plugins which use XML Search engine

Hi David,

I have attached a doc about my work with XML Jetty Plugins where the goal is to manage XML Jetty files with XML Search engine to have completion, validation, hyperlink, Ctrl+Shift+G. You will see several screen which show you the XMl Search UI Dialog and the capaibility to use the XML Search engien with Extension Point to add  completion, validation, hyperlink, Ctrl+Shift+G.

Hope it will please you.

Regards Angelo
Comment 15 David Carver CLA 2010-12-03 08:57:07 EST
Thanks, Angelo.  Sorry I haven't gotten to this yet.  Day job is keeping me busy at the moment.
Comment 16 David Carver CLA 2010-12-03 08:59:14 EST
Angelo, can you zip and attach the source code to this bug.  This way I can start the review process and make any suggestions.  In order for it to be a contribution, I need the source attached to the bug.
Comment 17 Angelo ZERR CLA 2010-12-03 09:05:07 EST
(In reply to comment #16)
> Angelo, can you zip and attach the source code to this bug.  This way I can
> start the review process and make any suggestions.  In order for it to be a
> contribution, I need the source attached to the bug.

Hi david thank a lot for your answer. My code is very very not clean (API change very time, no comments, no EPL Header....) and I'm improving the XML search engine for Jetty Plugins. 

If you wish I can set sources but tomorrow sources will change. Do you prefer I have a stable API or do you wish I send you sources from XML search engine + Jetty plugins (to see in action how use XML search engine extension point to manage completion, hyperlink, valiation and Ctl=Shift+G)?

Regards Angelo
Comment 18 Jesper Moller CLA 2010-12-03 09:57:33 EST
Hi Angelo

This is looking very promising! To take this further, it is important to keep things separate, i.e. please don't mix your Jetty specific code with the general XML search, since they would come in as separate contributions.

It would be best of the sources had the copyrights in place, and the API pretty good before you attach them, since when you do that, two separate processes can start:

One is an IP review which is a legal thing, where the Eclipse Foundation will check your work and ask you some questions to ensure that you are legally OK with licensing this work and submitting it to the Eclipse codebase. Don't be afraid, it won't hurt, it just takes a little time.

The other process that will happen the the technical review, where the committers and others will evaluate how the code works and make suggestions and changes, and what not. Don't be afraid of this either...

This process is required for any contributions longer than 250 lines, but many adjustments can be made afterwards, once the code is in, just as they are kept as smaller steps.

All this needs to happen well before the M6 milestone (API freeze) towards Indigo, which happens March 29th 2011.

Thank you very much for coming forward with this contribution! I hope the above doesn't discourage you, but now you'll know what to expect...
Comment 19 Angelo ZERR CLA 2010-12-03 10:05:01 EST
(In reply to comment #18)

Hi David,

> Hi Angelo
> 
> This is looking very promising! 

Cool:)

>To take this further, it is important to keep
> things separate, i.e. please don't mix your Jetty specific code with the
> general XML search, since they would come in as separate contributions.

Yes I have done that. I have : 

* org.eclipse.wst.xml.search.core
* org.eclipse.wst.xml.search.ui
* org.eclipse.wst.xml.search.editor

for XML search engine. No dependency to Jetty Plugins. I'm using too XML Search engine for my XML custom descriptor.

> 
> It would be best of the sources had the copyrights in place, and the API >pretty
> good before you attach them, since when you do that, two separate processes can
> start:
>
Ok. It will take long time because with Jetty I discover a lot of case that I have not managed.
 
For the IP review, I know that because I have created the WTP Jetty Adaptor http://wiki.eclipse.org/Jetty_WTP_Plugin and I'm Eclipse E4 commiter because I have created CSS engine. I know it's long to validate code:) but thanks for this information.

I will recontact you as soon as I will have a stable API. If you wish play with XML Search engine, tell me and I will send you a patch.

Regards Angelo


> One is an IP review which is a legal thing, where the Eclipse Foundation will
> check your work and ask you some questions to ensure that you are legally OK
> with licensing this work and submitting it to the Eclipse codebase. Don't be
> afraid, it won't hurt, it just takes a little time.
> 
> The other process that will happen the the technical review, where the
> committers and others will evaluate how the code works and make suggestions and
> changes, and what not. Don't be afraid of this either...
> 
> This process is required for any contributions longer than 250 lines, but many
> adjustments can be made afterwards, once the code is in, just as they are kept
> as smaller steps.
> 
> All this needs to happen well before the M6 milestone (API freeze) towards
> Indigo, which happens March 29th 2011.
> 
> Thank you very much for coming forward with this contribution! I hope the above
> doesn't discourage you, but now you'll know what to expect...
Comment 20 Nitin Dahyabhai CLA 2010-12-03 16:32:15 EST
What would be in org.eclipse.wst.xml.search.editor?
Comment 21 Angelo ZERR CLA 2010-12-06 09:51:44 EST
Created attachment 184605 [details]
Doc about XML Search engine UI + how use it into Eclipse plugins 

This Doc show you : 

* XML Search engine UI dialog
* explains how create an XML Jetty plugins like in 30 minutes which use XML Search engine extension point to declare reference between XML Node to Java, XML Node to XML node or XML Node to File. On other words you can 
** manage Java class (completion, hyperlink, validation) in class attribute for Configure, New, ...elements.
** manage Ref element (completion, hyperlink, validation, CTRL+Shift+G) in id attribute linked to Configure, New...id attributes.

Any suggestions are welcome! Thank a lot.

@Nitin : hope you will understand the goal of org.eclipse.wst.xml.search.editor with this documentation.
Comment 22 Angelo ZERR CLA 2010-12-09 04:09:57 EST
(In reply to comment #21)
> Created an attachment (id=184605) [details]
> Doc about XML Search engine UI + how use it into Eclipse plugins 
> 
> This Doc show you : 
> 
> * XML Search engine UI dialog
> * explains how create an XML Jetty plugins like in 30 minutes which use XML
> Search engine extension point to declare reference between XML Node to Java,
> XML Node to XML node or XML Node to File. On other words you can 
> ** manage Java class (completion, hyperlink, validation) in class attribute for
> Configure, New, ...elements.
> ** manage Ref element (completion, hyperlink, validation, CTRL+Shift+G) in id
> attribute linked to Configure, New...id attributes.
> 
> Any suggestions are welcome! Thank a lot.
> 
> @Nitin : hope you will understand the goal of org.eclipse.wst.xml.search.editor
> with this documentation.

Hi,

I have modified a little the API of the XML Search engine. Please read last document at SVN https://tk-ui.svn.sourceforge.net/svnroot/tk-ui/cnaf.sidoc.ide/docs/org.eclipse.wst.xml.search.odt

Regards Angelo
Comment 23 David Carver CLA 2010-12-09 10:36:56 EST
(In reply to comment #22)
> (In reply to comment #21)
> > Created an attachment (id=184605) [details] [details]
> > Doc about XML Search engine UI + how use it into Eclipse plugins 
> > 
> > This Doc show you : 
> > 
> > * XML Search engine UI dialog
> > * explains how create an XML Jetty plugins like in 30 minutes which use XML
> > Search engine extension point to declare reference between XML Node to Java,
> > XML Node to XML node or XML Node to File. On other words you can 
> > ** manage Java class (completion, hyperlink, validation) in class attribute for
> > Configure, New, ...elements.
> > ** manage Ref element (completion, hyperlink, validation, CTRL+Shift+G) in id
> > attribute linked to Configure, New...id attributes.
> > 
> > Any suggestions are welcome! Thank a lot.
> > 
> > @Nitin : hope you will understand the goal of org.eclipse.wst.xml.search.editor
> > with this documentation.
> 
> Hi,
> 
> I have modified a little the API of the XML Search engine. Please read last
> document at SVN
> https://tk-ui.svn.sourceforge.net/svnroot/tk-ui/cnaf.sidoc.ide/docs/org.eclipse.wst.xml.search.odt
> 
> Regards Angelo


Angelo, I took a quick look the Xpath implementation you are using, and you seem to be using whatever is the default JAXP provider.   I would prefer if you would use the Xpath Engine provided by the PsychoPath XPath 2.0 processor.   By making it the default processor you will gain much greater functionality as compared to the traditional one that is XPath 1.0 based.   The existing XPath View has some code that shows how to call and use the XPath 2.0 processor, in org.eclipse.wst.xml.xpath2.processor bundle.
Comment 24 Angelo ZERR CLA 2010-12-09 10:56:03 EST
(In reply to comment #23)
> (In reply to comment #22)
> > (In reply to comment #21)
> > > Created an attachment (id=184605) [details] [details] [details]
> > > Doc about XML Search engine UI + how use it into Eclipse plugins 
> > > 
> > > This Doc show you : 
> > > 
> > > * XML Search engine UI dialog
> > > * explains how create an XML Jetty plugins like in 30 minutes which use XML
> > > Search engine extension point to declare reference between XML Node to Java,
> > > XML Node to XML node or XML Node to File. On other words you can 
> > > ** manage Java class (completion, hyperlink, validation) in class attribute for
> > > Configure, New, ...elements.
> > > ** manage Ref element (completion, hyperlink, validation, CTRL+Shift+G) in id
> > > attribute linked to Configure, New...id attributes.
> > > 
> > > Any suggestions are welcome! Thank a lot.
> > > 
> > > @Nitin : hope you will understand the goal of org.eclipse.wst.xml.search.editor
> > > with this documentation.
> > 
> > Hi,
> > 
> > I have modified a little the API of the XML Search engine. Please read last
> > document at SVN
> > https://tk-ui.svn.sourceforge.net/svnroot/tk-ui/cnaf.sidoc.ide/docs/org.eclipse.wst.xml.search.odt
> > 
> > Regards Angelo
> 
> 
> Angelo, I took a quick look the Xpath implementation you are using, and you
> seem to be using whatever is the default JAXP provider.   I would prefer if you
> would use the Xpath Engine provided by the PsychoPath XPath 2.0 processor.   By
> making it the default processor you will gain much greater functionality as
> compared to the traditional one that is XPath 1.0 based.   The existing XPath
> View has some code that shows how to call and use the XPath 2.0 processor, in
> org.eclipse.wst.xml.xpath2.processor bundle.

Hi David,

If you see last source from SVN, you will see that I have implemented an new extension point "xpathFactoryProviders" wich give you the capability to provide your XPathFactory implementation. This extension point require teh implementation of the IXPathFactoryProvider : 

------------------------------------------------
package org.eclipse.wst.xml.search.core.xpath;

import javax.xml.xpath.XPathFactory;

public interface IXPathFactoryProvider {

	XPathFactory getFactory();
	
}
------------------------------------------------

The default implementation is : 

------------------------------------------------
package org.eclipse.wst.xml.search.core.xpath;

import javax.xml.xpath.XPathFactory;

public class DefaultXPathFactoryProvider implements IXPathFactoryProvider {

	public static final String ID = "org.eclipse.wst.xml.search.core.xpath.DefaultXPathFactoryProvider";

	public XPathFactory getFactory() {
		return XPathFactory.newInstance();
	}
}
------------------------------------------------

So you can contribute with extension point to get new XPathFactory implementation. For instance I have created a new plugins for saxon : 

------------------------------------------------
package org.sample.xmlsearch.xpathfactoryprovider.saxon;

import javax.xml.xpath.XPathFactory;
import javax.xml.xpath.XPathFactoryConfigurationException;

import org.eclipse.wst.xml.search.core.xpath.IXPathFactoryProvider;

public class SaxonXPathFactoryProvider implements IXPathFactoryProvider {

	public XPathFactory getFactory() {
		try {
			return XPathFactory.newInstance(
					XPathFactory.DEFAULT_OBJECT_MODEL_URI,
					"net.sf.saxon.xpath.XPathFactoryImpl",
					SaxonXPathFactoryProvider.class.getClassLoader());
		} catch (XPathFactoryConfigurationException e) {			
			e.printStackTrace();
		}
		return null;
	}

}
------------------------------------------------

The XML Search UI dialog display a combo and you can select your XPath factory provider. I must develop XML/Search/Xpath preferences to select your XPath factory that you wish use for plugins which contribute for completion, hyperlink...

I will create new plugins which will contribute to XPath factory with org.eclipse.wst.xml.xpath2.processor

Regards Angelo
Comment 25 Angelo ZERR CLA 2010-12-09 11:03:47 EST
David it seems that org.eclipse.wst.xml.xpath2.processor doesn't implements javax.xml.xpath.XPathFactory. In my case I need an implementation about this interface. Do you know how I can do that with org.eclipse.wst.xml.xpath2.processor? 

Regards Angelo
Comment 26 David Carver CLA 2010-12-09 12:09:53 EST
(In reply to comment #25)
> David it seems that org.eclipse.wst.xml.xpath2.processor doesn't implements
> javax.xml.xpath.XPathFactory. In my case I need an implementation about this
> interface. Do you know how I can do that with
> org.eclipse.wst.xml.xpath2.processor? 
> 
> Regards Angelo

The XPathFactory basically allows returning of NodeLists.   There is a class in the org.eclipse.wst.xml.xpath.core plugin that implements NodeLists for the psychopath processor.

http://dev.eclipse.org/viewcvs/viewvc.cgi/sourceediting/plugins/org.eclipse.wst.xml.xpath.core/src/org/eclipse/wst/xml/xpath/core/util/NodeListImpl.java?view=markup&root=WebTools_Project

If you really need an XPathFactory implementation, then it shouldn't be too hard to create one, and return it.  However, XPath 2.0 is best used outside of the XPathFactory as that jaxp specification is truely only setup to handle XPath 1.0.

Which will greatly limit the functionality somebody can do with an XPath query, considering that XPath 2.x is a much more robust implemenation.  PsychoPath also is XML Schema aware as well in its evaluation of XPath.
Comment 27 Angelo ZERR CLA 2010-12-10 05:18:35 EST
Hi David,

Thank a lof for your answer. I have changed my code and now you are not linked to XPathFactory. I have introduced a new interface called IXPathEvaluator which is used by the XML search engine. I have implementented that with WST XPath 2.0, Saxon and classical XPathFactory.newInstance().

IXPathEvaluator can be contributed with extension point, so you can add any XPath processor (I hope). For WST XPath 2.0, I have created a new plugin org.eclipse.wst.xml.search.xpath.evaluator which contribute IXPathEvaluator  for WST XPath2.0.

Now in the XML Search dialog you have a combo XPath evaluator where you can choose your XPath processor engine. You can see a screen in the doc
https://tk-ui.svn.sourceforge.net/svnroot/tk-ui/cnaf.sidoc.ide/docs/org.eclipse.wst.xml.search.odt

I must now add preferences page the XPath evaluator by default to use. So plugins which contribute to XML search engine (for completion, hyperlink...) will use the XPath evaluator setted in the preferences.

Regards Angelo
Comment 28 Angelo ZERR CLA 2010-12-16 09:42:40 EST
(In reply to comment #27)
Hi David,

Just for your information I have started Struts2 IDE which use XML references capaibility to manage completion, hyperlink....for XML Struts2 files. With XML Jetty and Struts2 samples I think XML search engine will manage a lot of thing (I hope).

I'm happy because I have developped this plugins into 2 hours (I have just declared XML references with Extension point for Struts2) and I manage several things like Java compeltion, XML references.... 

You can see doc about Struts2 IDE at https://tk-ui.svn.sourceforge.net/svnroot/tk-ui/cnaf.sidoc.ide/docs/org.appache.struts2.ide.odt

Regards Angelo
Comment 29 Angelo ZERR CLA 2010-12-21 09:06:28 EST
(In reply to comment #28)
> (In reply to comment #27)
> Hi David,
> 
> Just for your information I have started Struts2 IDE which use XML references
> capaibility to manage completion, hyperlink....for XML Struts2 files. With XML
> Jetty and Struts2 samples I think XML search engine will manage a lot of thing
> (I hope).
> 
> I'm happy because I have developped this plugins into 2 hours (I have just
> declared XML references with Extension point for Struts2) and I manage several
> things like Java compeltion, XML references.... 
> 
> You can see doc about Struts2 IDE at
> https://tk-ui.svn.sourceforge.net/svnroot/tk-ui/cnaf.sidoc.ide/docs/org.appache.struts2.ide.odt
> 
> Regards Angelo

Hi David,

For your information I have started to blog about XML Search engine with several articles at http://angelozerr.wordpress.com/about/eclipse-wtp-xml-search/

You can find teh first article at http://angelozerr.wordpress.com/2010/12/21/wtpxmlsearch-step1/

For your information I have managed completion, hyperlink, validation for Java method that I use for Struts2 and Jetty.

Regards Angelo
Comment 30 Max Rydahl Andersen CLA 2011-01-19 18:30:54 EST
This looks like an interesting contribution - but it would be great if the Ctrl+Shift+G functionallity moved higher up and be part of WTP XML core so we can all react on such find references.

i.e. both Spring IDE and JBoss Tools have metadata they search when Ctrl+Shift+G is pressed but those bindings conflicts since there is no common binding and you get errors.
Comment 31 Angelo ZERR CLA 2011-01-20 02:18:11 EST
(In reply to comment #30)
> This looks like an interesting contribution - but it would be great if the
> Ctrl+Shift+G functionallity moved higher up and be part of WTP XML core so we
> can all react on such find references.
> 
> i.e. both Spring IDE and JBoss Tools have metadata they search when
> Ctrl+Shift+G is pressed but those bindings conflicts since there is no common
> binding and you get errors.

Hi Max,

Thank a lot for your comments. You are right , I think it should be cool if Ctrl+Shift+G could be host by WTP XML UI.


For your information I have started an article at http://angelozerr.wordpress.com/2011/01/17/wtpxmlsearch-step2/ where I show screenshot about web.xml managed with WTP/XML search (completion, validation, hyperlink, text hover for Java class, servlet mapping, welcome-files....). In next article ((step3), I will explain how manage that with WTP XML Search.

I'm starting too to add WTP/XML Search for JSP and it works for the completion. I have done that for struts2. The struts2 taglib <s:form action="MyAction" have action attribute and it references the XML action from struts.xml. To do that you must just declare the reference : 

-------------------------------
<reference>
  <from
       path="//s:form"
       targetNodes="@action"
  </from>
  <to path="/struts/package/action"
      targetNodes="@name"/>
</reference>
-------------------------------

Regards Angelo
Comment 32 David Carver CLA 2011-01-27 23:37:57 EST
Angelo...any updates on this.  At this late stage, we probably can't get this through Eclipse IP in time to make it for the Indigo release.

I'm still interested in the XML/XPath search functionality though.
Comment 33 Angelo ZERR CLA 2011-01-28 03:07:57 EST
(In reply to comment #32)
> Angelo...any updates on this.  At this late stage, we probably can't get this
> through Eclipse IP in time to make it for the Indigo release.
> 
> I'm still interested in the XML/XPath search functionality though.

Hi Dave,

It's my fault, because I have not attached a patch, because I'm still developping WTP/XML Search. For your information I have managed : 

* JSP taglib attribute which can reference the same thing than XML. For instance I'm using this features o manage Struts Taglib : 
** <s:form action="MyAction" -> reference XML node from Struts action <action name="MyAction"
** <s:text key="MyMessageKey" -> reference property of properies file (MyMessageKey=its my message).

* I'm implementing JDT IQueryParticipant which use XML referenced declared to retrieve Java class from XML files. Once you have declared XML references with Java class. Ex for Jetty @class attribute mapped with Java class, you declare just your extension point like this :  

--------------------------------------
<reference>			
  <from path="/Configure//"
        targetNodes="@class" />
  <toJava />
</reference>
--------------------------------------

And you benefit with completion, validation hyperlink, text hover (to display Javadoc) and search declared Java class from the Java Editor (Ctrl+Shift+G from the Java editor will search too in the XML files).

As soon as I have stable code, I will create a patch.
Comment 34 Angelo ZERR CLA 2011-06-13 10:29:33 EDT
Hi Dave,

I would like know if you are interested again with WTP/XML Search plugins. I'm using WTP/XML Search :

1) XML Jetty files.
2) struts2 struts.xml
3) in my professional Job with our custom XML descriptor which are very complex and it works well (since 1 year). 

WTP/XML Search plugins give you several features : 

1) it gives you the Search/XML... menu (like Search/File...) to search XML node/file with XPath. You can select your XPath processor implementation.
2) it gives you the capability to develop custom plugins to manage XML references between your XML files (ex : for XML Jetty file you have references with Java class, with another XML Set element...). The basic idea is to declare with extension point your references between XML files (from and to) with XPath expression and completion, validation, hyperlink and Ctrl+Shift+G works automaticly.

I ahve too implements JSP to have references with Taglib (instead of XML elements).

I have started to write articles about WTP/XML Search at http://angelozerr.wordpress.com/about/eclipse-wtp-xml-search/

If you are interested, tell me and I will create a patch.

Regards Angelo
Comment 35 David Carver CLA 2011-06-13 10:51:42 EDT
Yes, would be interested in the XML Search portion.  I'd leave out the other portions (XML Jetty, struts, etc), but would be interested in the xml editor integration as well.

Since Indigo is now out, would be a good time to get the patch submitted, and then we can start the review process of getting it in place.



(In reply to comment #34)
> Hi Dave,
> 
> I would like know if you are interested again with WTP/XML Search plugins. I'm
> using WTP/XML Search :
> 
> 1) XML Jetty files.
> 2) struts2 struts.xml
> 3) in my professional Job with our custom XML descriptor which are very complex
> and it works well (since 1 year). 
> 
> WTP/XML Search plugins give you several features : 
> 
> 1) it gives you the Search/XML... menu (like Search/File...) to search XML
> node/file with XPath. You can select your XPath processor implementation.
> 2) it gives you the capability to develop custom plugins to manage XML
> references between your XML files (ex : for XML Jetty file you have references
> with Java class, with another XML Set element...). The basic idea is to declare
> with extension point your references between XML files (from and to) with XPath
> expression and completion, validation, hyperlink and Ctrl+Shift+G works
> automaticly.
> 
> I ahve too implements JSP to have references with Taglib (instead of XML
> elements).
> 
> I have started to write articles about WTP/XML Search at
> http://angelozerr.wordpress.com/about/eclipse-wtp-xml-search/
> 
> If you are interested, tell me and I will create a patch.
> 
> Regards Angelo
Comment 36 Angelo ZERR CLA 2011-06-13 11:09:53 EDT
Hi Dave,

Thank a lot for your answer. I'm adding EPL license to my Java code (sorry for comments, sometimes it doesn't exists). Plugins are very well splitted and I would like to send you plugins : 

1) org.eclipse.wst.xml.search.core the WTP/XML Search Core.
2) org.eclipse.wst.xml.search.ui the WTP/XML Search UI which gives you teh Search.../XML menu to open the search dialog with XPath.
3) org.eclipse.wst.xml.search.xpath.processors which implements WTP/XML Search processor to use Eclipse org.eclipse.wst.xml.xpath2.processor (by default it's the XPathFactory.newInstance() which is used.
4) org.eclipse.wst.xml.search.editor which gives you the capability to develop your own plugins to manage reference between XML files. It should be very cool if you accept this plugin because IMHO it's very simply to manage reference between XML files with XPath expression declared as extension point. My dream is that Spring Tools Suite will use this plugin to manage Spring XML files. If you are not certain with that, please  tell me some time I write article to explain how manage web.xml reference like I have explained in this article http://angelozerr.wordpress.com/2011/01/17/wtpxmlsearch-step2/ 
5) org.eclipse.jst.jsp.search.editor the same thing than org.eclipse.wst.xml.search.editor but to manage JSP Taglib (ex : have completion in the struts2 XML <s:text action= and it search into the struts.xml the <action name=).

I have developped too org.eclipse.jst.jee.web.xml plugins which is based on WTP/XMl Search org.eclipse.wst.xml.search.editor to manage as I have explained at http://angelozerr.wordpress.com/2011/01/17/wtpxmlsearch-step2/  teh web.xml file.

So I would create a patch with the 5 plugins. Are you OK?

Regards Angelo

(In reply to comment #35)
> Yes, would be interested in the XML Search portion.  I'd leave out the other
> portions (XML Jetty, struts, etc), but would be interested in the xml editor
> integration as well.
> 
> Since Indigo is now out, would be a good time to get the patch submitted, and
> then we can start the review process of getting it in place.
> 
> 
> 
> (In reply to comment #34)
> > Hi Dave,
> > 
> > I would like know if you are interested again with WTP/XML Search plugins. I'm
> > using WTP/XML Search :
> > 
> > 1) XML Jetty files.
> > 2) struts2 struts.xml
> > 3) in my professional Job with our custom XML descriptor which are very complex
> > and it works well (since 1 year). 
> > 
> > WTP/XML Search plugins give you several features : 
> > 
> > 1) it gives you the Search/XML... menu (like Search/File...) to search XML
> > node/file with XPath. You can select your XPath processor implementation.
> > 2) it gives you the capability to develop custom plugins to manage XML
> > references between your XML files (ex : for XML Jetty file you have references
> > with Java class, with another XML Set element...). The basic idea is to declare
> > with extension point your references between XML files (from and to) with XPath
> > expression and completion, validation, hyperlink and Ctrl+Shift+G works
> > automaticly.
> > 
> > I ahve too implements JSP to have references with Taglib (instead of XML
> > elements).
> > 
> > I have started to write articles about WTP/XML Search at
> > http://angelozerr.wordpress.com/about/eclipse-wtp-xml-search/
> > 
> > If you are interested, tell me and I will create a patch.
> > 
> > Regards Angelo
Comment 37 David Carver CLA 2011-06-13 13:13:20 EDT
Some of this might move to org.eclipse.xml.xpath.  but yes, go ahead and zip up the 5 plugins, and I'll start the cQ process.

The next question would be, if you are interested in helping to maintain these going forward?  We could possibly bring you on as a committer for the the XPath compoment, but I'll have to discuss that with Nitin.   For now, just attach the exported plugins in a zip, and we'll take it from there.
Comment 38 Angelo ZERR CLA 2011-06-13 13:26:19 EDT
(In reply to comment #37)
> Some of this might move to org.eclipse.xml.xpath.  but yes, go ahead and zip up
> the 5 plugins, and I'll start the cQ process.

Thank a lot Dave! 

> 
> The next question would be, if you are interested in helping to maintain these
> going forward?  We could possibly bring you on as a committer for the the XPath
> compoment, but I'll have to discuss that with Nitin.   For now, just attach the
> exported plugins in a zip, and we'll take it from there.
Yes I'm interested to help you to maintain WTP/XML Search because I'm using for my professional job and I will need some features (like manage multi values for attribute (ex : <user roles="role1 role2 role3" ...) and this case doesn't works for the moment). The XML Search is done for workspace scope only (even if you select Resource in the scope, workspace scope is done).

I will be happy to have rights to commit for WTP/XML Search to improve it. Otherwise I will send you patches but it can be boring for you and me.

But before doing that, play with WTP/XMl Search if you like it. I could send you too Jetty Plugins to see in action WTP/XML Search editor. I will try to send you a patch tomorrow because I'm cleaning my code to add comments + license.

Regards Angelo
Comment 39 Angelo ZERR CLA 2011-06-27 09:57:25 EDT
Created attachment 198650 [details]
WTP/XML Search plugins

Hi Dave,

Sorry for the delay but I had to implement attribute expression to for instance manage completion, validation, hyperlink, text hover, Ctrl+Shift+G for multi attribute values (ex : <user roles="ROLE1 ROLE2" ...> or any expression (you must just implements a WTP/XML Search expression parser to manage yoru expression like EL for instance). We could use this features for XSL plugins for instance (if you wish that XSL plugins use WTP/XML Search too manage <xsl:include/@href for instance).

This patch contains 8 plugins : 

1) org.eclipse.wst.xml.search.core the WTP/XML Search Core.
2) org.eclipse.wst.xml.search.ui the WTP/XML Search UI which gives you teh
Search.../XML menu to open the search dialog with XPath.
3) org.eclipse.wst.xml.search.xpath.processors which implements WTP/XML Search
processor to use Eclipse org.eclipse.wst.xml.xpath2.processor (by default it's
the XPathFactory.newInstance() which is used.
4) org.eclipse.wst.xml.search.editor which gives you the capability to develop
your own plugins to manage reference between XML files. It should be very cool
if you accept this plugin because IMHO it's very simply to manage reference
between XML files with XPath expression declared as extension point. My dream
is that Spring Tools Suite will use this plugin to manage Spring XML files. If
you are not certain with that, please  tell me some time I write article to
explain how manage web.xml reference like I have explained in this article
http://angelozerr.wordpress.com/2011/01/17/wtpxmlsearch-step2/ 
5) org.eclipse.jst.jsp.search.editor the same thing than
org.eclipse.wst.xml.search.editor but to manage JSP Taglib (ex : have
completion in the struts2 XML <s:text action= and it search into the struts.xml
the <action name=).
6) I have developped too org.eclipse.jst.jee.web.xml plugins which is based on
WTP/XMl Search org.eclipse.wst.xml.search.editor to manage as I have explained
at http://angelozerr.wordpress.com/2011/01/17/wtpxmlsearch-step2/  teh web.xml
file.

7) org.eclipse.wst.xml.search.core.tests Seacrh Core JUnit Test
8) org.eclipse.wst.xml.search.editor.tests Search Editor JUnit Test

I think code is stable (we are using it since 6 months) but the problem is comments. I hope it will not be a problem to contribute to WTP.

For your information, when I have started WTP/XML Search I have studied Spring IDE (Spring Tools Suite) so some name fo classes/interfaces are the same like Spring IDE (ex : IContentAssistContext) but content of thoses classes/interfaces are not the same.

Regards Angelo
Comment 40 David Carver CLA 2011-06-28 10:33:17 EDT
Thanks Angelo, one of the things I'm considering doing with this contribution is incubating it a bit in the WTP Incubator, and nominating you as a committer there.   This gives us a couple of advantages:

1. We can work on the code separately from the main wtp source editing code.
2. It gives Nitin the WTP Source Editing project lead time to review and test it, as well as gives the community time to look at it.
3. Allows us to nominate you as a committer in WTP Incubator, and get you adjusted to the way WTP and eclipse development process works, including becoming more familiar with the IP process.

I'm pretty busy this week, but I hope to get the CQ submitted for this next week, and also nominate you in the WTP Incubator.
Comment 41 Angelo ZERR CLA 2011-06-28 10:39:06 EDT
(In reply to comment #40)
> Thanks Angelo, one of the things I'm considering doing with this contribution
> is incubating it a bit in the WTP Incubator, and nominating you as a committer
> there.   This gives us a couple of advantages:
> 
> 1. We can work on the code separately from the main wtp source editing code.
> 2. It gives Nitin the WTP Source Editing project lead time to review and test
> it, as well as gives the community time to look at it.
> 3. Allows us to nominate you as a committer in WTP Incubator, and get you
> adjusted to the way WTP and eclipse development process works, including
> becoming more familiar with the IP process.
> 
> I'm pretty busy this week, but I hope to get the CQ submitted for this next
> week, and also nominate you in the WTP Incubator.

Many thanks Dave for your investment! For your information I have contacted Martin Lippert, lead of Spring Tools Suite to see if STS could be interesting with WTP/XML Search.

I think too that XSL Editor could use WTP/XML Search to manage completion, validation, hyperlink.... What do you think about that?

Regards Angelo
Comment 42 David Carver CLA 2011-06-28 17:18:52 EDT
> Many thanks Dave for your investment! For your information I have contacted
> Martin Lippert, lead of Spring Tools Suite to see if STS could be interesting
> with WTP/XML Search.
> 
> I think too that XSL Editor could use WTP/XML Search to manage completion,
> validation, hyperlink.... What do you think about that?

Yeah, I can see some uses for it not only at eclipse but in some other projects I'm working on as well.
Comment 43 Angelo ZERR CLA 2011-06-30 10:09:33 EDT
(In reply to comment #42)
> > Many thanks Dave for your investment! For your information I have contacted
> > Martin Lippert, lead of Spring Tools Suite to see if STS could be interesting
> > with WTP/XML Search.
> > 
> > I think too that XSL Editor could use WTP/XML Search to manage completion,
> > validation, hyperlink.... What do you think about that?
> 
> Yeah, I can see some uses for it not only at eclipse but in some other projects
> I'm working on as well.

Hi Dave,

I'm starting a plugin with WTP/XML Search for Wicket where I wish manage the same things than http://code.google.com/p/qwickie/

Today WTP/XML Search supports only references XML to another thing (XML, Properties, Java class, Java method, static values....), but not Java to another thing. To do that I must do a big refactoring because my all code works only with IDOMNode. To support Java to another thing, I must support IJaveElement. I'm restarting from scratch WTP/XML Search. I think you can start the IP but I think I will send you a new patch when I will finish.

Regards Angelo
Comment 44 David Carver CLA 2011-06-30 10:23:07 EDT
> 
> Hi Dave,
> 
> I'm starting a plugin with WTP/XML Search for Wicket where I wish manage the
> same things than http://code.google.com/p/qwickie/
> 
> Today WTP/XML Search supports only references XML to another thing (XML,
> Properties, Java class, Java method, static values....), but not Java to
> another thing. To do that I must do a big refactoring because my all code works
> only with IDOMNode. To support Java to another thing, I must support
> IJaveElement. I'm restarting from scratch WTP/XML Search. I think you can start
> the IP but I think I will send you a new patch when I will finish.

Okay let me submit what we currently have to IP team so we can get the process started.

A couple of standard questions:

1. How much of the code did you write yourself?

2. You have the rights to contribute the code?


I'm sure IP will ask a few other questions as well, but that should cover the basis.
Comment 45 David Carver CLA 2011-06-30 10:29:09 EDT
I've submitted the CQ.
Comment 46 Angelo ZERR CLA 2011-06-30 10:40:29 EDT
(In reply to comment #44)
> > 
> > Hi Dave,
> > 
> > I'm starting a plugin with WTP/XML Search for Wicket where I wish manage the
> > same things than http://code.google.com/p/qwickie/
> > 
> > Today WTP/XML Search supports only references XML to another thing (XML,
> > Properties, Java class, Java method, static values....), but not Java to
> > another thing. To do that I must do a big refactoring because my all code works
> > only with IDOMNode. To support Java to another thing, I must support
> > IJaveElement. I'm restarting from scratch WTP/XML Search. I think you can start
> > the IP but I think I will send you a new patch when I will finish.
> 
> Okay let me submit what we currently have to IP team so we can get the process
> started.
> 
> A couple of standard questions:
> 
> 1. How much of the code did you write yourself?
The all code, except some code for completion with JDT that I have used from Spring IDE but I have changed a lot of thing.
> 
> 2. You have the rights to contribute the code?
I'm E4 Eclipse commiter because I'm the creator of the CSS Engine. I have too created WTP/Jetty Adaptor http://wiki.eclipse.org/Jetty_WTP_Plugin and my company signed me a paper for that. I suppose I will have to sign a paper to have right commits.

> 
> 
> I'm sure IP will ask a few other questions as well, but that should cover the
> basis.

Sure.
Comment 47 Angelo ZERR CLA 2011-06-30 10:40:44 EDT
(In reply to comment #45)
> I've submitted the CQ.

Many thanks!
Comment 48 David Carver CLA 2011-06-30 10:43:43 EDT
(In reply to comment #47)
> (In reply to comment #45)
> > I've submitted the CQ.
> 
> Many thanks!

And I've submitted your nomination as a WTP Incubator committer, so we can incubate this for a bit and then determine when to graduate it into the WTP Source Editing XPath component.
Comment 49 Angelo ZERR CLA 2011-07-01 10:38:53 EDT
(In reply to comment #48)
> (In reply to comment #47)
> > (In reply to comment #45)
> > > I've submitted the CQ.
> > 
> > Many thanks!
> 
> And I've submitted your nomination as a WTP Incubator committer, so we can
> incubate this for a bit and then determine when to graduate it into the WTP
> Source Editing XPath component.

Hi Dave,

I have done my big refactoring to support JDT IJaveElement as from path. So now I can manage completion in my Java code to display XML nodes (ex : for wicket display XML attribute wicket:id in the Java code), Resources files...

Do you want I do a patch for that? Or do you prefere waiting the result of the CQ?

Regards Angelo
Comment 50 David Carver CLA 2011-07-01 11:55:08 EDT
(In reply to comment #49)
> Hi Dave,
> 
> I have done my big refactoring to support JDT IJaveElement as from path. So now
> I can manage completion in my Java code to display XML nodes (ex : for wicket
> display XML attribute wicket:id in the Java code), Resources files...
> 
> Do you want I do a patch for that? Or do you prefere waiting the result of the
> CQ?

Let's wait until we get Parallel IP approval for the incubator.  Once that happens I can create a git repository for you, and we can check in the code at that point.

You can then add your refactoring to the code as well.
Comment 51 Angelo ZERR CLA 2011-07-20 03:48:42 EDT
(In reply to comment #50)
> (In reply to comment #49)
> > Hi Dave,
> > 
> > I have done my big refactoring to support JDT IJaveElement as from path. So now
> > I can manage completion in my Java code to display XML nodes (ex : for wicket
> > display XML attribute wicket:id in the Java code), Resources files...
> > 
> > Do you want I do a patch for that? Or do you prefere waiting the result of the
> > CQ?
> 
> Let's wait until we get Parallel IP approval for the incubator.  Once that
> happens I can create a git repository for you, and we can check in the code at
> that point.
> 
> You can then add your refactoring to the code as well.

Hi Dave,

It seems that vote for WTP incubator is concluded with success (that's cool:). Do you know if you have result of CQ? I would like send you a new patch which improve a lot WTP/XMl Search for : 

* manage namespaces in the XPath.
* manage references between Java -> X (XML, Properties files).

I have done that to manage wicket features for the wicket eclipse plugin http://code.google.com/p/qwickie/ (the creator seems OK to use it). Tell me when you wish that I send you a new patch.

Thank a lot.

Regards Angelo
Comment 52 David Carver CLA 2011-07-27 12:34:38 EDT
(In reply to comment #51)
> Hi Dave,
> 
> It seems that vote for WTP incubator is concluded with success (that's cool:).
> Do you know if you have result of CQ? I would like send you a new patch which
> improve a lot WTP/XMl Search for : 
> 
> * manage namespaces in the XPath.
> * manage references between Java -> X (XML, Properties files).
> 
> I have done that to manage wicket features for the wicket eclipse plugin
> http://code.google.com/p/qwickie/ (the creator seems OK to use it). Tell me
> when you wish that I send you a new patch.
> 

I'll ping them on the CQ to see if we can get at least Parallel IP on this.   Do you have your committer Id and Password yet?  Have you completed all your paperwork for the Foundation?
Comment 53 David Carver CLA 2011-07-27 12:40:08 EDT
Looks like we are awaiting a PMC member to approve the CQ, once that is done I can bug the eclipse ip team about getting Parallel review for this.
Comment 54 Angelo ZERR CLA 2011-07-28 03:37:11 EDT
(In reply to comment #53)
> Looks like we are awaiting a PMC member to approve the CQ, once that is done I
> can bug the eclipse ip team about getting Parallel review for this.

Hi Dave,

Thank a lot for your answer. I'm waiting for that. Tell me when you wish I create a new patch.

Regards Angelo
Comment 55 Angelo ZERR CLA 2011-08-02 03:05:42 EDT
Created attachment 200688 [details]
WTP/XML Search plugins [Java 2 X references + namespaces management]

Hi Dave,

I send you a new path of WTP XML Search which is very important because I have done a lot of refactoring to :

1) manage Java 2 X (XML, Properties....) refernces.
2) manage namespaces to manage completion, ... for XML which uses namespaces.
3) manage completion, .... with references for HTML files (like XML and JSP files)

I needed thoses features to manage Wicket Plugin.

This patch contains 9 plugins: 

1) org.eclipse.wst.xml.search.core the WTP/XML Search Core.
2) org.eclipse.wst.xml.search.ui the WTP/XML Search UI which gives you teh
Search.../XML menu to open the search dialog with XPath.
3) org.eclipse.wst.xml.search.xpath.processors which implements WTP/XML Search
processor to use Eclipse org.eclipse.wst.xml.xpath2.processor (by default it's
the XPathFactory.newInstance() which is used.
4) org.eclipse.wst.xml.search.editor which gives you the capability to develop
your own plugins to manage reference between XML files. It should be very cool
if you accept this plugin because IMHO it's very simply to manage reference
between XML files with XPath expression declared as extension point. My dream
is that Spring Tools Suite will use this plugin to manage Spring XML files. If
you are not certain with that, please  tell me some time I write article to
explain how manage web.xml reference like I have explained in this article
http://angelozerr.wordpress.com/2011/01/17/wtpxmlsearch-step2/ 
5) org.eclipse.jst.jsp.search.editor the same thing than
org.eclipse.wst.xml.search.editor but to manage JSP Taglib (ex : have
completion in the struts2 XML <s:text action= and it search into the struts.xml
the <action name=).
6) I have developped too org.eclipse.jst.jee.web.xml plugins which is based on
WTP/XMl Search org.eclipse.wst.xml.search.editor to manage as I have explained
at http://angelozerr.wordpress.com/2011/01/17/wtpxmlsearch-step2/  teh web.xml
file.

7) org.eclipse.wst.xml.search.core.tests Seacrh Core JUnit Test
8) org.eclipse.wst.xml.search.editor.tests Search Editor JUnit Test
9) org.eclipse.wst.html.search.editor the same thing than
org.eclipse.wst.xml.search.editor but for HTML.

Regards Angelo
Comment 56 David Carver CLA 2011-08-04 15:58:41 EDT
Thanks, we should be getting Parallel IP approval soon.  Once that is complete I'll get the git repository created, and you can get your code checked into there.  Then we can iterate on this for a while.
Comment 57 David Carver CLA 2011-08-09 09:24:46 EDT
Angelo, they have a few slight changes they would like made in order to approve the contribution to be checked in.

>>>>
1.  Several files appear to match heavily to other Webtools content.  In cases
where files are derivative works, the original copyright header should be
retained with any changes being notated in the Contributor Section.  Can you
please have a closer look at the following files and adjust where required:

XMLSearchPreferencePage.java
AbstractTableBlock.java
OpenXMLSearchPageAction.java
LocalizedMessage.java
Trace.java
XMLSearchTreeContentProvider.java
XMLReferenceSyntaxColoringPage.java
EditorOpener.java
ImageResource.java
XMLSearchPreferencePage.java
XMLSearchTableContentProvider.java


2. I've confirmed there is content matching to original Spring IDE content as
indicated.  The first two files also appear to contain content from another
Webtools file.  Therefore, the copyright information will need to be adjusted
as follows:  

DOMAttrCompletionProposal + DOMTextCompletionProposal:

Copyright (c) 2001, 2007 IBM Corporation and others
Copyright (c) 2005, 2007 Spring IDE Developers


JavaCompletionUtils:
Copyright (c) 2005, 2007 Spring IDE Developers and others

I was able to confirm provenance of the Spring content and as the license is
EPL, we just need the copyright changes made.

Based on these changes being made, you can proceed to checkin.  A new
attachment should be uploaded when available.
<<<<

The IP team says that we can just attach a new contribution with the changes for review, or just the affected files.   Probably best to do a new contribution with all the changes, since you've done some new changes.

If you committer paperwork has been completed and approved, then please go ahead and add yourself to CQ 5303 on the eclipse IPzilla system.
Comment 58 Angelo ZERR CLA 2011-08-11 10:52:14 EDT
Created attachment 201319 [details]
WTP/XML Search plugins (license fixed)

Hi Dave,

Here a patch which fix license problem. 

"If you committer paperwork has been completed and approved, then please go
ahead and add yourself to CQ 5303 on the eclipse IPzilla system."

I have done nothing for that because if I have well understood, I'm commiter Eclipse (E4 + I have done Jetty WTP Adaptor) so I need do nothing (Hope I have well understood)

Regards Angelo
Comment 59 David Carver CLA 2011-08-11 11:55:55 EDT
(In reply to comment #58)
> Created attachment 201319 [details]
> WTP/XML Search plugins (license fixed)
> 
> Hi Dave,
> 
> Here a patch which fix license problem. 
> 
> "If you committer paperwork has been completed and approved, then please go
> ahead and add yourself to CQ 5303 on the eclipse IPzilla system."
> 
> I have done nothing for that because if I have well understood, I'm commiter
> Eclipse (E4 + I have done Jetty WTP Adaptor) so I need do nothing (Hope I have
> well understood)
> 
> Regards Angelo

Please go ahead and add your self to the CQ 5303 then, as you should have access rights to it.  Attach the latest code there, or I can do it later today.

Thanks.
Comment 60 David Carver CLA 2011-08-18 11:27:45 EDT
Git repository is now created.  I'll close out this bug.  Welcome aboard Angelo.

http://git.eclipse.org/c/webtools/incubator/org.eclipse.webtools.incubator.xmlsearch.git/

The plan is to incubate this for a while, before we look at moving it into the Xpath component.
Comment 61 David Carver CLA 2012-06-25 11:06:53 EDT
Angelo, I haven't heard anything from you in regards to this project.  I've temporarily closed the CQ in regards to this, and we need to discuss how to proceed with the incubator project if at all.  

Re-opening this so we can come to some resolution.
Comment 62 Angelo ZERR CLA 2012-06-25 11:17:16 EDT
(In reply to comment #61)
> Angelo, I haven't heard anything from you in regards to this project.  I've
> temporarily closed the CQ in regards to this, and we need to discuss how to
> proceed with the incubator project if at all.  
> 
> Re-opening this so we can come to some resolution.

Hi David,

I'm really sorry, I had no time to work on it, but I'm using it for my professionnal job.
I think this plug-in is stable (must do some improvment with Java JDT) and we could create an update site (perhaps I must just test if sources hosted on Git are well)?

I'm so sorry not to have give you information about this plug-in since long time.

Regards Angelo
Comment 63 David Carver CLA 2012-06-27 11:34:17 EDT
Unfortunately due to lack of activity on this, I had to withdraw the CQ on it.  So I'm going to have to get this deleted from the incubator.   We need to make sure that we have people that can maintain things for the code contributed especially of this size.  I think the plugin is a great idea, so you may still want to host it on GitHub or continue on sourceforge.

If you are fine with this, please let me know and I'll get the existing git repository that I setup for this removed.

Dave


(In reply to comment #62)
> (In reply to comment #61)
> > Angelo, I haven't heard anything from you in regards to this project.  I've
> > temporarily closed the CQ in regards to this, and we need to discuss how to
> > proceed with the incubator project if at all.  
> > 
> > Re-opening this so we can come to some resolution.
> 
> Hi David,
> 
> I'm really sorry, I had no time to work on it, but I'm using it for my
> professionnal job.
> I think this plug-in is stable (must do some improvment with Java JDT) and we
> could create an update site (perhaps I must just test if sources hosted on Git
> are well)?
> 
> I'm so sorry not to have give you information about this plug-in since long
> time.
> 
> Regards Angelo
Comment 64 Angelo ZERR CLA 2012-06-27 11:45:31 EDT
(In reply to comment #63)
> Unfortunately due to lack of activity on this, I had to withdraw the CQ on it. 
> So I'm going to have to get this deleted from the incubator.   We need to make
> sure that we have people that can maintain things for the code contributed
> especially of this size.  I think the plugin is a great idea, so you may still
> want to host it on GitHub or continue on sourceforge.

That's very shame, but it's my fault-(
As I said you I'm using this plugin in my professional job and since I have do this contribution, I had not need to improve it, it's the reason that I have do nothing.

I hope one day that WTP/XML Search will be integrated to the Eclipse JEE distribution, and some other plugins (Spring IDE, Jetty IDE, Struts2 IDE, Wicket IDE etc) will be based on it but if you remove it to the WTP Incubator, I think it will be difficult for me to accept to use this plugin by other contributors.

What can I do to change your decision? If you want I can continue my articles at http://angelozerr.wordpress.com/about/eclipse-wtp-xml-search/ to explain step by step how to create a plugin based on WTP/XML Search?

But I think your decision is token (it's my fault-().

Angelo

> 
> If you are fine with this, please let me know and I'll get the existing git
> repository that I setup for this removed.
> 
> Dave
> 
> 
> (In reply to comment #62)
> > (In reply to comment #61)
> > > Angelo, I haven't heard anything from you in regards to this project.  I've
> > > temporarily closed the CQ in regards to this, and we need to discuss how to
> > > proceed with the incubator project if at all.  
> > > 
> > > Re-opening this so we can come to some resolution.
> > 
> > Hi David,
> > 
> > I'm really sorry, I had no time to work on it, but I'm using it for my
> > professionnal job.
> > I think this plug-in is stable (must do some improvment with Java JDT) and we
> > could create an update site (perhaps I must just test if sources hosted on Git
> > are well)?
> > 
> > I'm so sorry not to have give you information about this plug-in since long
> > time.
> > 
> > Regards Angelo
Comment 65 David Carver CLA 2012-06-27 12:01:31 EDT
For right now I'm going to hold off on doing the delete request.  I'll give some time for the others copied on this bug to chime in and respond.

The main thing we need to see if some activity on the project.  There was a CQ that was waiting code changes for several months.  My own time is very limited at the moment so I understand the time constraints.

I'll give this a bit of time for people to comment and then we can make a final decision.  We can always start the project at a later date when you have more time.
Comment 66 Angelo ZERR CLA 2012-06-28 05:16:34 EDT
(In reply to comment #65)
> For right now I'm going to hold off on doing the delete request.  I'll give
> some time for the others copied on this bug to chime in and respond.
> 
> The main thing we need to see if some activity on the project.  There was a CQ
> that was waiting code changes for several months.  My own time is very limited
> at the moment so I understand the time constraints.
> 
> I'll give this a bit of time for people to comment and then we can make a final
> decision.  We can always start the project at a later date when you have more
> time.

Hi David,

I understand your fears about the activity of the project. As I said you, I use it for my professionnal job and I will improve it as soon as I will need new features.

So this project can be used on production mode (my team is using every day this plugin). But if I have some feedbacks to improve the project, I will do it.

> There was a CQ that was waiting code changes for several months. 
I'm reaaly sorry, but which CQ? I believed that I had done that?

Regards Angelo
Comment 67 David Carver CLA 2012-06-28 13:52:55 EDT
https://dev.eclipse.org/ipzilla/show_bug.cgi?id=5303

Anyways, we can always reopen the CQ if we want.
Comment 68 Angelo ZERR CLA 2012-07-02 03:33:03 EDT
(In reply to comment #67)
> https://dev.eclipse.org/ipzilla/show_bug.cgi?id=5303
> 
Hi David,
> Anyways, we can always reopen the CQ if we want.
If it's possible, it should be cool. As I said you, plugin can be used in production mode, and it shouldbe very cool if WTP provides this plugin (after web.xml, Jetty XML files are managed with WTP/XMl Search).

Regards Angelo
Comment 69 Ole Jørgen CLA 2012-09-19 07:08:56 EDT
Just saying I'd be interested in this. Especially if it can handle jsp files. 

Maybe it can be distributed as a third-party plugin instead?
Comment 70 Angelo ZERR CLA 2012-09-19 08:19:05 EDT
(In reply to comment #69)

Hi Jørgen,
> Just saying I'd be interested in this. Especially if it can handle jsp
> files. 
> 
Many thank's for your internment about WTP/XML Search.

> Maybe it can be distributed as a third-party plugin instead?

David I'm waiting for your decision. Do you think it's possible to host WTP/XML Search in the Eclipse WTP Git? 

If you are not OK with that, I think I will create a GitHub project which will host WTP/XML Search and update site to install it.

Many thank's for your answer.

Regards Angelo
Comment 71 David Carver CLA 2012-09-21 14:45:13 EDT
Let me bring Nitin into this conversation, as ultimately it is going to reside in the WTP Source editing project when it is ready.  So it basically comes down to whether Source Editing wants to take it on and maintain it going forward.
Comment 72 Nitin Dahyabhai CLA 2012-09-21 22:15:56 EDT
If it doesn't come with someone who's going to own the contribution, refine it, and respond to bugs reported in it, I'd reluctantly admit that I'm not keen on adding it (even if it does look pretty cool).  That said, there's nothing wrong with a well-defined scope and feature set.  Perhaps you can host it on GitHub and make it discoverable from the Eclipse Marketplace as an alternative?

As an aside, the newer org.eclipse.wst.sse.ui.completionProposal extension point will let you contribute a class to take part in content assist, rather than make you responsible for all of it (and avoids colliding with any source viewer configuration that's already contributed to the XML or JSP content type).
Comment 73 Angelo ZERR CLA 2013-03-22 04:41:51 EDT
Hi everybody,

For your information, I'm hosting EClipse WTP/XML Search in my GitHub at 
https://github.com/angelozerr/eclipse-wtp-xml-search

Regards Angelo
Comment 74 Artem Ivanov CLA 2015-05-22 03:37:52 EDT
Hello Angelo
There is bug in this plugin. Filter by enclosing project of selected resources is not work
Comment 75 Angelo ZERR CLA 2015-05-22 03:44:04 EDT
Artem,

I don't understand your bug? Plezse create an issue at https://github.com/angelozerr/eclipse-wtp-xml-search/issues

Thanks!
Comment 76 Artem Ivanov CLA 2015-05-22 04:04:39 EDT
Issue was created:
"XML search cannot be launched for selected resources or enclosing project"