You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@accumulo.apache.org by Anthony F <af...@gmail.com> on 2014/02/13 18:55:07 UTC

shell extensions

As part of development for GeoMesa, I've found it valuable to have
maintenance and other custom operations available at the accumulo shell.
To support this, I have modified the Shell class to load commands defined
as SPI META-INF/services in jars in $ACCUMULO_HOME/lib/ext.  This allows
developers to create a jar with a file:

META-INF/services/org.apache.accumulo.core.util.shell.Command

which contains one Command per line such as:

geomesa.core.util.shell.ListFeaturesCommand
geomesa.core.util.shell.InitializeFeatureCommand
geomesa.core.util.shell.IngestFeatureCommand
geomesa.core.util.shell.OptimizeIndexCommand
geomesa.core.util.shell.RefreshBoundsCommand

I have put up a branch of the modification here:

https://github.com/ccri/accumulo/tree/extensible_shell

The actual code change is quite minimal but I had to pull the abstract
Command class up into its own file so I could use the ServiceLoader to load
Command resources.

Does this sound like something that could be valuable to others?

Thanks,
Anthony

Re: shell extensions

Posted by John Vines <vi...@apache.org>.
No, we don't add new features in minor releases


On Thu, Feb 13, 2014 at 2:17 PM, Anthony F <af...@gmail.com> wrote:

> Welp, it's almost exactly the same, except for the scripting part.  Guess
> this won't make it into 1.5.1?
>
>
> On Thu, Feb 13, 2014 at 2:11 PM, Mike Drob <ma...@cloudera.com> wrote:
>
> > Anthony,
> >
> > I have not had a chance to look at your code yet, but it sounds similar
> to
> > the feature described in
> > https://issues.apache.org/jira/browse/ACCUMULO-1399
> >
> > What are your thoughts?
> >
> > Mike
> >
> >
> > On Thu, Feb 13, 2014 at 9:55 AM, Anthony F <af...@gmail.com> wrote:
> >
> > > As part of development for GeoMesa, I've found it valuable to have
> > > maintenance and other custom operations available at the accumulo
> shell.
> > > To support this, I have modified the Shell class to load commands
> defined
> > > as SPI META-INF/services in jars in $ACCUMULO_HOME/lib/ext.  This
> allows
> > > developers to create a jar with a file:
> > >
> > > META-INF/services/org.apache.accumulo.core.util.shell.Command
> > >
> > > which contains one Command per line such as:
> > >
> > > geomesa.core.util.shell.ListFeaturesCommand
> > > geomesa.core.util.shell.InitializeFeatureCommand
> > > geomesa.core.util.shell.IngestFeatureCommand
> > > geomesa.core.util.shell.OptimizeIndexCommand
> > > geomesa.core.util.shell.RefreshBoundsCommand
> > >
> > > I have put up a branch of the modification here:
> > >
> > > https://github.com/ccri/accumulo/tree/extensible_shell
> > >
> > > The actual code change is quite minimal but I had to pull the abstract
> > > Command class up into its own file so I could use the ServiceLoader to
> > load
> > > Command resources.
> > >
> > > Does this sound like something that could be valuable to others?
> > >
> > > Thanks,
> > > Anthony
> > >
> >
>

Re: shell extensions

Posted by Anthony F <af...@gmail.com>.
Welp, it's almost exactly the same, except for the scripting part.  Guess
this won't make it into 1.5.1?


On Thu, Feb 13, 2014 at 2:11 PM, Mike Drob <ma...@cloudera.com> wrote:

> Anthony,
>
> I have not had a chance to look at your code yet, but it sounds similar to
> the feature described in
> https://issues.apache.org/jira/browse/ACCUMULO-1399
>
> What are your thoughts?
>
> Mike
>
>
> On Thu, Feb 13, 2014 at 9:55 AM, Anthony F <af...@gmail.com> wrote:
>
> > As part of development for GeoMesa, I've found it valuable to have
> > maintenance and other custom operations available at the accumulo shell.
> > To support this, I have modified the Shell class to load commands defined
> > as SPI META-INF/services in jars in $ACCUMULO_HOME/lib/ext.  This allows
> > developers to create a jar with a file:
> >
> > META-INF/services/org.apache.accumulo.core.util.shell.Command
> >
> > which contains one Command per line such as:
> >
> > geomesa.core.util.shell.ListFeaturesCommand
> > geomesa.core.util.shell.InitializeFeatureCommand
> > geomesa.core.util.shell.IngestFeatureCommand
> > geomesa.core.util.shell.OptimizeIndexCommand
> > geomesa.core.util.shell.RefreshBoundsCommand
> >
> > I have put up a branch of the modification here:
> >
> > https://github.com/ccri/accumulo/tree/extensible_shell
> >
> > The actual code change is quite minimal but I had to pull the abstract
> > Command class up into its own file so I could use the ServiceLoader to
> load
> > Command resources.
> >
> > Does this sound like something that could be valuable to others?
> >
> > Thanks,
> > Anthony
> >
>

Re: shell extensions

Posted by Mike Drob <ma...@cloudera.com>.
Anthony,

I have not had a chance to look at your code yet, but it sounds similar to
the feature described in https://issues.apache.org/jira/browse/ACCUMULO-1399

What are your thoughts?

Mike


On Thu, Feb 13, 2014 at 9:55 AM, Anthony F <af...@gmail.com> wrote:

> As part of development for GeoMesa, I've found it valuable to have
> maintenance and other custom operations available at the accumulo shell.
> To support this, I have modified the Shell class to load commands defined
> as SPI META-INF/services in jars in $ACCUMULO_HOME/lib/ext.  This allows
> developers to create a jar with a file:
>
> META-INF/services/org.apache.accumulo.core.util.shell.Command
>
> which contains one Command per line such as:
>
> geomesa.core.util.shell.ListFeaturesCommand
> geomesa.core.util.shell.InitializeFeatureCommand
> geomesa.core.util.shell.IngestFeatureCommand
> geomesa.core.util.shell.OptimizeIndexCommand
> geomesa.core.util.shell.RefreshBoundsCommand
>
> I have put up a branch of the modification here:
>
> https://github.com/ccri/accumulo/tree/extensible_shell
>
> The actual code change is quite minimal but I had to pull the abstract
> Command class up into its own file so I could use the ServiceLoader to load
> Command resources.
>
> Does this sound like something that could be valuable to others?
>
> Thanks,
> Anthony
>