New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Integrated Alfresco Technical Validation tool in the SDK 'verify' phase #188

Closed
mindthegab opened this Issue Jul 20, 2014 · 10 comments

Comments

Projects
None yet
3 participants
@mindthegab
Contributor

mindthegab commented Jul 20, 2014

From gabriele...@alfresco.com on June 10, 2014 08:33:04

In order to ensure the development of best practice driven extensions and to avoid unsupportable developments we want to integrate the ATV in the SDK.

This is blocked on AlfrescoLabs/technical-validation#33 (i.e. having a Java API for the ATV).

Original issue: http://code.google.com/p/maven-alfresco-archetypes/issues/detail?id=188

@mindthegab

This comment has been minimized.

Show comment
Hide comment
@mindthegab

mindthegab Jul 20, 2014

Contributor

From colum...@gmail.com on June 10, 2014 05:35:44

Labels: Milestone-Release-sdk-2.0.0

Contributor

mindthegab commented Jul 20, 2014

From colum...@gmail.com on June 10, 2014 05:35:44

Labels: Milestone-Release-sdk-2.0.0

@mindthegab mindthegab modified the milestone: Release-sdk-2.0.0 Jul 20, 2014

@mindthegab

This comment has been minimized.

Show comment
Hide comment
@mindthegab

mindthegab Jul 20, 2014

Contributor

@pmonks Peter, assigning to you for now. Just push it back to me when we feel AlfrescoLabs/technical-validation#33 is ready for integration.

Contributor

mindthegab commented Jul 20, 2014

@pmonks Peter, assigning to you for now. Just push it back to me when we feel AlfrescoLabs/technical-validation#33 is ready for integration.

@pmonks

This comment has been minimized.

Show comment
Hide comment
@pmonks

pmonks Aug 1, 2014

The underlying enhancement request for the ATV has now been implemented and I'll be pushing a new release (v0.4.0) of the validation tool to clojars sometime over the weekend (from whence you'll be able to retrieve it via a vanilla Maven dependency).

I also have a worked Java example showing how to use the tool via its Java API. That example is not yet on github but will go up there at around the same time.

Stay tuned!

pmonks commented Aug 1, 2014

The underlying enhancement request for the ATV has now been implemented and I'll be pushing a new release (v0.4.0) of the validation tool to clojars sometime over the weekend (from whence you'll be able to retrieve it via a vanilla Maven dependency).

I also have a worked Java example showing how to use the tool via its Java API. That example is not yet on github but will go up there at around the same time.

Stay tuned!

@mindthegab

This comment has been minimized.

Show comment
Hide comment
@mindthegab

mindthegab Aug 2, 2014

Contributor

Peter,

you rock :)

Gab

Sent from my iPad

On 1 aug. 2014, at 19:56, Peter Monks notifications@github.com wrote:

The underlying issue is now fixed and I'll be pushing a new release (v0.4.0) of the validation tool to clojars sometime over the weekend.

I also have a worked Java example showing how to use the tool via its Java API. That example is not yet on github but will go up there at around the same time.

Stay tuned!


Reply to this email directly or view it on GitHub.

Contributor

mindthegab commented Aug 2, 2014

Peter,

you rock :)

Gab

Sent from my iPad

On 1 aug. 2014, at 19:56, Peter Monks notifications@github.com wrote:

The underlying issue is now fixed and I'll be pushing a new release (v0.4.0) of the validation tool to clojars sometime over the weekend.

I also have a worked Java example showing how to use the tool via its Java API. That example is not yet on github but will go up there at around the same time.

Stay tuned!


Reply to this email directly or view it on GitHub.

@pmonks

This comment has been minimized.

Show comment
Hide comment
@pmonks

pmonks Aug 2, 2014

The ATV v0.4.0 is now published to Clojars, and a worked Java example that uses it is available here.

The example should clearly demonstrate how the ATV can be leveraged from Java code, but if it doesn't (or if you run into issues or whatever), please don't hesitate to let me know!

pmonks commented Aug 2, 2014

The ATV v0.4.0 is now published to Clojars, and a worked Java example that uses it is available here.

The example should clearly demonstrate how the ATV can be leveraged from Java code, but if it doesn't (or if you run into issues or whatever), please don't hesitate to let me know!

@mindthegab mindthegab modified the milestones: 2.0.0-beta-1, 2.0.0 Aug 22, 2014

@mindthegab mindthegab changed the title from Integrated Alfresco Technical Validation tool in the SDK 'validate' phase to Integrated Alfresco Technical Validation tool in the SDK 'verify' phase Aug 27, 2014

@mindthegab

This comment has been minimized.

Show comment
Hide comment
@mindthegab

mindthegab Aug 27, 2014

Contributor

Hey @pmonks, took a first stab at integrating this.

For neo4j I am using https://github.com/rherschke/neo4j-maven-plugin which I deployed here https://artifacts.alfresco.com/nexus/content/repositories/thirdparty/de/herschke/neo4j-maven-plugin/2.0.2-20140827/.

The ATV starts correctly but then I get a 'Divide by Zero' exception, and I am not really familiar on how to read a Clj stack :)

Source and target amp locations should be fine, as take from the Maven project object.

If you want to test it, you could:

  • Clone branch https://github.com/Alfresco/alfresco-sdk/tree/atv-integration
  • run a 'mvn clean install -Dmaven.test.skip=true' of the SDK locally
  • create a project from the amp archetype with 'mvn archetype:generate
  • in the created project, run 'mvn clean verify -DskipTests' and you should see the build ending as follows:

[INFO] Started o.e.j.s.ServletContextHandler@51cb478c{/,null,AVAILABLE}
[INFO] Started ServerConnector@15bb0d8d{HTTP/1.1}{localhost:7474}
Aug 27, 2014 1:14:28 AM org.neo4j.server.logging.Logger log
INFO: Remote interface ready and available at [http://localhost:7474/]
[INFO] Neo4j CommunityServer started at target/test-data/impermanent-db
[INFO]
[INFO] --- alfresco-maven-plugin:2.0.0-SNAPSHOT:validate (run-atv) @ testamp2 ---
[INFO] Connecting to Neo4J server http://localhost:7474/db/data...
[INFO] Writing 18 nodes to Neo4J...
[INFO] Writing 25 edges to Neo4J...
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 13.740 s
[INFO] Finished at: 2014-08-27T01:14:34-04:00
[INFO] Final Memory: 74M/722M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.alfresco.maven.plugin:alfresco-maven-plugin:2.0.0-SNAPSHOT:validate (run-atv) on project testamp2: Execution run-atv of goal org.alfresco.maven.plugin:alfresco-maven-plugin:2.0.0-SNAPSHOT:validate failed: Divide by zero -> [Help 1]
org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal org.alfresco.maven.plugin:alfresco-maven-plugin:2.0.0-SNAPSHOT:validate (run-atv) on project testamp2: Execution run-atv of goal org.alfresco.maven.plugin:alfresco-maven-plugin:2.0.0-SNAPSHOT:validate failed: Divide by zero
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:224)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:153)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:145)
at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:116)
at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:80)
at org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build(SingleThreadedBuilder.java:51)
at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:120)
at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:347)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:154)
at org.apache.maven.cli.MavenCli.execute(MavenCli.java:584)
at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:213)
at org.apache.maven.cli.MavenCli.main(MavenCli.java:157)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)
at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:289)
at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:229)
at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:415)
at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:356)
Caused by: org.apache.maven.plugin.PluginExecutionException: Execution run-atv of goal org.alfresco.maven.plugin:alfresco-maven-plugin:2.0.0-SNAPSHOT:validate failed: Divide by zero
at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:143)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:208)
... 19 more
Caused by: java.lang.ArithmeticException: Divide by zero
at clojure.lang.Numbers.divide(Numbers.java:156)
at clojure.lang.Numbers.divide(Numbers.java:3731)
at alfresco_technical_validation.impl.validations.dev$dev02.invoke(dev.clj:54)
at alfresco_technical_validation.core$validate$fn__1493.invoke(core.clj:228)
at clojure.core$map$fn__4245.invoke(core.clj:2557)
at clojure.lang.LazySeq.sval(LazySeq.java:40)
at clojure.lang.LazySeq.seq(LazySeq.java:49)
at clojure.lang.RT.seq(RT.java:484)
at clojure.core$seq.invoke(core.clj:133)
at clojure.core$map$fn__4245.invoke(core.clj:2551)
at clojure.lang.LazySeq.sval(LazySeq.java:40)
at clojure.lang.LazySeq.seq(LazySeq.java:49)
at clojure.lang.ChunkedCons.chunkedNext(ChunkedCons.java:59)
at clojure.lang.ChunkedCons.next(ChunkedCons.java:43)
at clojure.lang.RT.next(RT.java:598)
at clojure.core$next.invoke(core.clj:64)
at clojure.core$dorun.invoke(core.clj:2856)
at clojure.core$doall.invoke(core.clj:2871)
at alfresco_technical_validation.core$validate_java.invoke(core.clj:261)
at alfresco_technical_validation.core$validate_java.invoke(core.clj:259)
at alfresco_technical_validation.core$validate_java.invoke(core.clj:258)
at clojure.lang.Var.invoke(Var.java:388)
at org.alfrescolabs.technical.validation.impl.AlfrescoTechnicalValidationImpl.validate(AlfrescoTechnicalValidationImpl.java:56)
at org.alfresco.maven.plugin.ValidateMojo.execute(ValidateMojo.java:52)
at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:132)
... 20 more

Any hint would be gladly appreciated my Master Clojurer :)

Contributor

mindthegab commented Aug 27, 2014

Hey @pmonks, took a first stab at integrating this.

For neo4j I am using https://github.com/rherschke/neo4j-maven-plugin which I deployed here https://artifacts.alfresco.com/nexus/content/repositories/thirdparty/de/herschke/neo4j-maven-plugin/2.0.2-20140827/.

The ATV starts correctly but then I get a 'Divide by Zero' exception, and I am not really familiar on how to read a Clj stack :)

Source and target amp locations should be fine, as take from the Maven project object.

If you want to test it, you could:

  • Clone branch https://github.com/Alfresco/alfresco-sdk/tree/atv-integration
  • run a 'mvn clean install -Dmaven.test.skip=true' of the SDK locally
  • create a project from the amp archetype with 'mvn archetype:generate
  • in the created project, run 'mvn clean verify -DskipTests' and you should see the build ending as follows:

[INFO] Started o.e.j.s.ServletContextHandler@51cb478c{/,null,AVAILABLE}
[INFO] Started ServerConnector@15bb0d8d{HTTP/1.1}{localhost:7474}
Aug 27, 2014 1:14:28 AM org.neo4j.server.logging.Logger log
INFO: Remote interface ready and available at [http://localhost:7474/]
[INFO] Neo4j CommunityServer started at target/test-data/impermanent-db
[INFO]
[INFO] --- alfresco-maven-plugin:2.0.0-SNAPSHOT:validate (run-atv) @ testamp2 ---
[INFO] Connecting to Neo4J server http://localhost:7474/db/data...
[INFO] Writing 18 nodes to Neo4J...
[INFO] Writing 25 edges to Neo4J...
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 13.740 s
[INFO] Finished at: 2014-08-27T01:14:34-04:00
[INFO] Final Memory: 74M/722M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.alfresco.maven.plugin:alfresco-maven-plugin:2.0.0-SNAPSHOT:validate (run-atv) on project testamp2: Execution run-atv of goal org.alfresco.maven.plugin:alfresco-maven-plugin:2.0.0-SNAPSHOT:validate failed: Divide by zero -> [Help 1]
org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal org.alfresco.maven.plugin:alfresco-maven-plugin:2.0.0-SNAPSHOT:validate (run-atv) on project testamp2: Execution run-atv of goal org.alfresco.maven.plugin:alfresco-maven-plugin:2.0.0-SNAPSHOT:validate failed: Divide by zero
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:224)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:153)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:145)
at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:116)
at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:80)
at org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build(SingleThreadedBuilder.java:51)
at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:120)
at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:347)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:154)
at org.apache.maven.cli.MavenCli.execute(MavenCli.java:584)
at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:213)
at org.apache.maven.cli.MavenCli.main(MavenCli.java:157)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)
at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:289)
at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:229)
at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:415)
at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:356)
Caused by: org.apache.maven.plugin.PluginExecutionException: Execution run-atv of goal org.alfresco.maven.plugin:alfresco-maven-plugin:2.0.0-SNAPSHOT:validate failed: Divide by zero
at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:143)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:208)
... 19 more
Caused by: java.lang.ArithmeticException: Divide by zero
at clojure.lang.Numbers.divide(Numbers.java:156)
at clojure.lang.Numbers.divide(Numbers.java:3731)
at alfresco_technical_validation.impl.validations.dev$dev02.invoke(dev.clj:54)
at alfresco_technical_validation.core$validate$fn__1493.invoke(core.clj:228)
at clojure.core$map$fn__4245.invoke(core.clj:2557)
at clojure.lang.LazySeq.sval(LazySeq.java:40)
at clojure.lang.LazySeq.seq(LazySeq.java:49)
at clojure.lang.RT.seq(RT.java:484)
at clojure.core$seq.invoke(core.clj:133)
at clojure.core$map$fn__4245.invoke(core.clj:2551)
at clojure.lang.LazySeq.sval(LazySeq.java:40)
at clojure.lang.LazySeq.seq(LazySeq.java:49)
at clojure.lang.ChunkedCons.chunkedNext(ChunkedCons.java:59)
at clojure.lang.ChunkedCons.next(ChunkedCons.java:43)
at clojure.lang.RT.next(RT.java:598)
at clojure.core$next.invoke(core.clj:64)
at clojure.core$dorun.invoke(core.clj:2856)
at clojure.core$doall.invoke(core.clj:2871)
at alfresco_technical_validation.core$validate_java.invoke(core.clj:261)
at alfresco_technical_validation.core$validate_java.invoke(core.clj:259)
at alfresco_technical_validation.core$validate_java.invoke(core.clj:258)
at clojure.lang.Var.invoke(Var.java:388)
at org.alfrescolabs.technical.validation.impl.AlfrescoTechnicalValidationImpl.validate(AlfrescoTechnicalValidationImpl.java:56)
at org.alfresco.maven.plugin.ValidateMojo.execute(ValidateMojo.java:52)
at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:132)
... 20 more

Any hint would be gladly appreciated my Master Clojurer :)

@pmonks

This comment has been minimized.

Show comment
Hide comment

pmonks commented Aug 27, 2014

Raised as AlfrescoLabs/technical-validation#47 - will fix ASAP!

mindthegab added a commit that referenced this issue Aug 29, 2014

@mindthegab mindthegab modified the milestones: 2.0.0, 2.0.0-beta-3 Aug 29, 2014

@mindthegab

This comment has been minimized.

Show comment
Hide comment
@mindthegab

mindthegab Aug 29, 2014

Contributor

Initial integration via -Patv profile.

Creating your AMP and running -Patv would verify the customization. Currently no clear output is provided to the build.

Needs more work.

Contributor

mindthegab commented Aug 29, 2014

Initial integration via -Patv profile.

Creating your AMP and running -Patv would verify the customization. Currently no clear output is provided to the build.

Needs more work.

@mindthegab mindthegab modified the milestones: 2.0.0-beta-3, 2.0.0 Aug 29, 2014

@mindthegab mindthegab modified the milestones: 2.1.0, 2.0.0 Dec 23, 2014

@mindthegab

This comment has been minimized.

Show comment
Hide comment
@mindthegab

mindthegab Dec 23, 2014

Contributor

Moved to 2.1.0 although a basic -Patv profile is available for experimental purposes only.

Contributor

mindthegab commented Dec 23, 2014

Moved to 2.1.0 although a basic -Patv profile is available for experimental purposes only.

@ohej

This comment has been minimized.

Show comment
Hide comment
@ohej

ohej Mar 24, 2017

Collaborator

Not much progress has been made on the ATV tool. I will close this issue and open a new one if we go back and revisit the tool

Collaborator

ohej commented Mar 24, 2017

Not much progress has been made on the ATV tool. I will close this issue and open a new one if we go back and revisit the tool

@ohej ohej closed this Mar 24, 2017

@ohej ohej unassigned pmonks Mar 24, 2017

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment