GithubHelp home page GithubHelp logo

spring-attic / greenhouse Goto Github PK

View Code? Open in Web Editor NEW
1.3K 101.0 944.0 4.75 MB

Reference web application for Spring technologies and social destination for Spring developers.

Home Page: http://greenhouse.springsource.org

License: Apache License 2.0

Java 98.51% HTML 0.17% CSS 1.33%

greenhouse's Introduction

Greenhouse Reference Application

Overview

Greenhouse is a Java web application built for the Spring community that has two primary goals:

  1. Serve as an open-source, public-facing reference and driver for Spring technology, including Spring MVC, Security, Integration, Social and Mobile projects.
  2. Help foster and support our passionate application developer community through the development of useful community services.

Features

  • Extensive use of Spring Framework, Spring MVC, Spring Social, Spring Mobile, Spring Security, and Spring Integration projects.
  • An OAuth-based App Catalog that allows Developers to develop new client apps for which users may establish Account->App connections.
  • The ability to connect your local Greenhouse Account to Twitter, Facebook, LinkedIn, and TripIt ServiceProviders.
  • Member Sign Up, Sign In, and Reset Password Modules.
  • A Member Invite Module allowing you to invite your Facebook friends and email contacts.
  • A Member Badge (Award) System that rewards members for community participation.
  • A mobile web version of the app that can be used across multiple smartphone platforms.
  • A Group Event Management Module for powering Spring events, such as conferences and user group meetings.
  • Numerous Spring Framework contributions in the areas of:
  • Data (S3 File Storage and RDMS Migrations)
  • Web (Email Templating, Flash Map, Comet)
  • An agile Continuous Deployment CI Process

Check Out and Build from Source

  1. Clone the repository from GitHub:

     $ git clone git://github.com/SpringSource/greenhouse.git
    
  2. Navigate into the cloned repository directory:

     $ cd greenhouse
    
  3. The project uses Maven to build:

     $ mvn clean install
    

Running from the Command Line

Deploy the .war to any Servlet 2.5 >, such as Tomcat. By default, the app will run in 'embedded' mode which does not require any external setup. The Tomcat 7 Maven plugin is configured for you in the POM file.

  1. Launch Tomcat from the command line:

     $ mvn t7:run
    
  2. Access the deployed webapp at

     http://localhost:8080/greenhouse
    

IDE Support

If you would like to build and run from a Maven/Java Dynamic Web-project-capable IDE, such as Eclipse/SpringSource Tool Suite, you may simply import "as a Maven Project" into your IDE and deploy the project to your IDE's embedded servlet container.

greenhouse's People

Contributors

habuma avatar mtdowns avatar royclarkson avatar rstoyanchev avatar spring-operator avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

greenhouse's Issues

mvn install fails and so does STS build

STS error:
Errors occurred during the build.
Errors running builder 'AspectJ Builder' on project 'greenhouse'.
java.util.NoSuchElementException

mvn install error:

[ERROR] Failed to execute goal org.codehaus.mojo:aspectj-maven-plugin:1.3.1:compile (default) on project greenhouse: Compiler errors:
[ERROR] error classpath error: unable to find org.aspectj.lang.JoinPoint (check that aspectjrt.jar is in your classpath)
[ERROR] -> [Help 1]
org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal org.codehaus.mojo:aspectj-maven-plugin:1.3.1:compile (default) on project greenhouse: Compiler errors:
error classpath error: unable to find org.aspectj.lang.JoinPoint (check that aspectjrt.jar is in your classpath)

at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:217)
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:84)
at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:59)
at org.apache.maven.lifecycle.internal.LifecycleStarter.singleThreadedBuild(LifecycleStarter.java:183)
at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:161)
at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:319)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:156)
at org.apache.maven.cli.MavenCli.execute(MavenCli.java:537)
at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:196)
at org.apache.maven.cli.MavenCli.main(MavenCli.java:141)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:290)
at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:230)
at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:409)
at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:352)

Caused by: org.codehaus.mojo.aspectj.CompilationFailedException: Compiler errors:
error classpath error: unable to find org.aspectj.lang.JoinPoint (check that aspectjrt.jar is in your classpath)

at org.codehaus.mojo.aspectj.AbstractAjcCompiler.execute(AbstractAjcCompiler.java:374)
at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:101)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:209)
... 19 more

[ERROR]
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException

Integrity constraint raised on local signup

hi,
I get this issue when the app is deployed locally and running the startup screen properly. Then I have clicked on "join", filled up the fields and submitted.

here is the stacktrace on submit:


HTTP Status 500 - Request processing failed; nested exception is org.springframework.dao.DataIntegrityViolationException: PreparedStatementCallback; SQL [insert into MemberAction (actionType, performTime, latitude, longitude, member) values (?, ?, ?, ?, ?)]; Referential integrity constraint violation: "CONSTRAINT_8A0: PUBLIC.MEMBERACTION FOREIGN KEY(MEMBER) REFERENCES PUBLIC.MEMBER(ID)"; SQL statement:


It seems a foreign key is misplaced on MemberAction table

thanks for any help

edited: 2/7/2013

i've removed all foreign keys, bad practise, but just to make it run, signup etc properly

Exception loading webapp at http://localhost:8080/greenhouse/

~/spring-mobile> git clone https://github.com/SpringSource/greenhouse.git

~/spring-mobile> cd greenhouse/

~/s/greenhouse> mvn -version
Apache Maven 3.0.3 (r1075438; 2011-02-28 18:31:09+0100)
Maven home: /opt/apache-maven-3.0.3
Java version: 1.6.0_26, vendor: Sun Microsystems Inc.
Java home: /usr/lib/jvm/java-6-sun-1.6.0.26/jre
Default locale: en_US, platform encoding: UTF-8
OS name: "linux", version: "2.6.38-11-generic", arch: "i386", family: "unix"

~/s/greenhouse> mvn clean install t7:run
(...)
Oct 14, 2011 11:51:08 PM org.apache.catalina.core.StandardWrapperValve invoke
SEVERE: Servlet.service() for servlet [appServlet] in context with path [/greenhouse] threw exception [Handler processing failed; nested exception is java.lang.LinkageError: loader constraint violation: loader (instance of org/apache/catalina/loader/WebappClassLoader) previously initiated loading for a different type with name "javax/el/ExpressionFactory"] with root cause
java.lang.LinkageError: loader constraint violation: loader (instance of org/apache/catalina/loader/WebappClassLoader) previously initiated loading for a different type with name "javax/el/ExpressionFactory"
    at java.lang.ClassLoader.defineClass1(Native Method)
    at java.lang.ClassLoader.defineClassCond(ClassLoader.java:631)
    at java.lang.ClassLoader.defineClass(ClassLoader.java:615)
    at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:141)
    at org.apache.catalina.loader.WebappClassLoader.findClassInternal(WebappClassLoader.java:2820)
    at org.apache.catalina.loader.WebappClassLoader.findClass(WebappClassLoader.java:1150)
    at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1645)
    at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1523)
    at org.apache.tiles.el.ELAttributeEvaluator.evaluate(ELAttributeEvaluator.java:151)

mvn 2.2.1 compilation failure mvn install

ERROR] COMPILATION ERROR :
[INFO] -------------------------------------------------------------
[ERROR] /Users/manav/Downloads/SpringSource-greenhouse-5af03aa/src/main/java/com/springsource/greenhouse/events/Event.java:[22,20] package org.joda.time does not exist
[ERROR] /Users/manav/Downloads/SpringSource-greenhouse-5af03aa/src/main/java/com/springsource/greenhouse/events/Event.java:[23,20] package org.joda.time does not exist
[ERROR] /Users/manav/Downloads/SpringSource-greenhouse-5af03aa/src/main/java/com/springsource/greenhouse/events/Event.java:[40,15] cannot find symbol
symbol : class DateTimeZone
location: class com.springsource.greenhouse.events.Event
[ERROR] /Users/manav/Downloads/SpringSource-greenhouse-5af03aa/src/main/java/com/springsource/greenhouse/events/Event.java:[42,15] cannot find symbol
symbol : class DateTime

Unable To sign Up

Sql exception as referential integrity constraint, Member(Id) and MemberAction(id) do not match

ServiceProviderConnectionRepository bean created before user is signed in

When attempting to signin with Facebook, Twitter, etc, the ServiceProviderConnectionRepository bean(s) cannot be created because the postCreateAccount callback method is called before AccountUtils.signin() is called. Thus, throwing a BeanCreationException. Exception message:

org.springframework.web.util.NestedServletException: Request processing failed; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'scopedTarget.connectionRepository' defined in class path resource [com/springsource/greenhouse/config/connect/ConnectFrameworkConfig.class]: Instantiation of bean failed; nested exception is org.springframework.beans.factory.BeanDefinitionStoreException: Factory method [public org.springframework.social.connect.ServiceProviderConnectionRepository com.springsource.greenhouse.config.connect.ConnectFrameworkConfig.connectionRepository(java.security.Principal)] threw exception; nested exception is java.lang.IllegalStateException: Unable to get a ServiceProviderConnectionRepository: no user logged in

I changed SignupHelper.java to look like this

....
/**
 * Signup the person who completed the signup form.
 * Returns true if signup was successful, false if there was an error.
 * Records any errors in the form's BindingResult context for display to the person.
 * An optional SignupCallback may be specified for performing custom processing after successful member signup.
 */
public boolean signup(SignupForm form, BindingResult formBinding, SignupCallback callback) {
    try {
        Account account = createAccount(form.createPerson());
        gateway.signedUp(account);
        AccountUtils.signin(account);
        if (callback != null) {
            callback.postCreateAccount(account);
        }
        return true;
    } catch (EmailAlreadyOnFileException e) {
        formBinding.rejectValue("email", "account.duplicateEmail", "already on file");
        return false;
    }        
}

// internal helpers

@Transactional
private Account createAccount(Person person) throws EmailAlreadyOnFileException {
    Account account = accountRepository.createAccount(person);
    return account;
}
....

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.