On 9/25/07, Hernan Cunico <[EMAIL PROTECTED]> wrote:
> The idea is to ease development from IDE's that will pick up the schemas 
> right away. Not sure the redirect would work for these scenarios.

Well, let me give a specific example.  Let's say you have a web app's web.xml:

<?xml version="1.0" encoding="ISO-8859-1"?>
<web-app xmlns="http://java.sun.com/xml/ns/j2ee";
         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
         xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee
http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd";
         version="2.4">
...
</web-app>

The namespace is "http://java.sun.com/xml/ns/j2ee"; and the schema URL
is "http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd"; -- they are
different.  However, if you declare them like that in the web.xml
header, any IDE ought to be able to find the schema based on the
xsi:schemaLocation attribute.  So it's not strictly necessary to make
the path on the web site match the namespace to get your IDE to work.

Thanks,
      Aaron

> I tried the aliases, just a couple of symbolic links, but then realized about 
> the different directories for the schemas so I was hoping there would be 
> another way (maybe a maven plugin) that would to the job.  Apparently there 
> isn't.
>
> I guess I'll get back to the alias work for now until we figure out a better 
> way to do this.
>
> Cheers!
> Hernan
>
> Aaron Mulder wrote:
> > I'm not that big a fan of trying to make the schema namespace be an
> > actual working URL.  Should the schema's namespace end in ".xsd"?
> > That seems weird.  Plus we have no control over the location for many
> > of the schemas we use (other projects we use, the Sun schemas, etc.)
> > And it might result in us scattering our schemas across several
> > directories on the site, which over several releases could get quite
> > messy.
> >
> > In contrast, we can point to the correct URL in e.g. a comment at the
> > top of the schema, and any file using that schema can include an
> > attribute pointing to the specific URL for the schema.  But I guess I
> > don't feel super-strongly, other than that I think the main navigation
> > for the site ought to always let you get to a listing of the pertinent
> > schemas.
> >
> > Another possibility would be to just set up aliases or redirects so we
> > can file the schemas where we want and then make the namespace URLs
> > forward or redirect to the actual schema files for additional
> > convenience.
> >
> > Thanks,
> >        Aaron
> >
> > On 9/25/07, Hernan Cunico <[EMAIL PROTECTED]> wrote:
> >> Hi All,
> >> trying to deal with the schemas update on the web site and I'm looking to 
> >> some things I would like to get your input.
> >>
> >> First of all the actual schemas file name don't match the target name 
> >> space defined in the schema itself.
> >>
> >> Here is the associated JIRA ( 
> >> https://issues.apache.org/jira/browse/GERONIMO-3425 ). This is mainly for 
> >> updating the web site but I think it would be more clear for everybody to 
> >> have matching names anyway.
> >>
> >> Is it feasible/practical to have the schemas file names match the name 
> >> space?
> >>
> >> Second, in order to have the schemas available on a target's name space 
> >> matching URL (http://geronimo.apache.org/xml/ns ...) we need to have and 
> >> maintain up-to-date copy a the schemas on the web site trunk.
> >>
> >> We currently have the schemas scattered all over the server trunk. Last 
> >> time Jarek manually copied the files over but clearly this can not be a 
> >> manual task.
> >>
> >> Anybody has any ideas for having this automatically updated?
> >>
> >> Cheers!
> >> Hernan
> >>
> >>
> >
>
>

Reply via email to