use of org.springframework.social.google.connect.GoogleConnectionFactory in project ORCID-Source by ORCID.
the class SocialConfig method connectionFactoryLocator.
@Bean
public ConnectionFactoryLocator connectionFactoryLocator() {
logger.info("getting connectionFactoryLocator");
ConnectionFactoryRegistry registry = new ConnectionFactoryRegistry();
registry.addConnectionFactory(new FacebookConnectionFactory(fb_key, fb_secret));
registry.addConnectionFactory(new GoogleConnectionFactory(gg_key, gg_secret));
return registry;
}
use of org.springframework.social.google.connect.GoogleConnectionFactory in project nixmash-blog by mintster.
the class SocialConfig method addConnectionFactories.
@Override
public void addConnectionFactories(ConnectionFactoryConfigurer cfConfig, Environment env) {
cfConfig.addConnectionFactory(new TwitterConnectionFactory(appSettings.getTwitterAppId(), appSettings.getTwitterAppSecret()));
cfConfig.addConnectionFactory(new FacebookConnectionFactory(appSettings.getFacebookAppId(), appSettings.getFacebookAppSecret()));
cfConfig.addConnectionFactory(new GoogleConnectionFactory(appSettings.getGoogleAppId(), appSettings.getGoogleAppSecret()));
}
use of org.springframework.social.google.connect.GoogleConnectionFactory in project FuryViewer by TheDoctor-95.
the class SocialConfiguration method addConnectionFactories.
@Override
public void addConnectionFactories(ConnectionFactoryConfigurer connectionFactoryConfigurer, Environment environment) {
// Google configuration
String googleClientId = environment.getProperty("spring.social.google.client-id");
String googleClientSecret = environment.getProperty("spring.social.google.client-secret");
if (googleClientId != null && googleClientSecret != null) {
log.debug("Configuring GoogleConnectionFactory");
connectionFactoryConfigurer.addConnectionFactory(new GoogleConnectionFactory(googleClientId, googleClientSecret));
} else {
log.error("Cannot configure GoogleConnectionFactory id or secret null");
}
// Facebook configuration
String facebookClientId = environment.getProperty("spring.social.facebook.client-id");
String facebookClientSecret = environment.getProperty("spring.social.facebook.client-secret");
if (facebookClientId != null && facebookClientSecret != null) {
log.debug("Configuring FacebookConnectionFactory");
connectionFactoryConfigurer.addConnectionFactory(new FacebookConnectionFactory(facebookClientId, facebookClientSecret));
} else {
log.error("Cannot configure FacebookConnectionFactory id or secret null");
}
// Twitter configuration
String twitterClientId = environment.getProperty("spring.social.twitter.client-id");
String twitterClientSecret = environment.getProperty("spring.social.twitter.client-secret");
if (twitterClientId != null && twitterClientSecret != null) {
log.debug("Configuring TwitterConnectionFactory");
connectionFactoryConfigurer.addConnectionFactory(new TwitterConnectionFactory(twitterClientId, twitterClientSecret));
} else {
log.error("Cannot configure TwitterConnectionFactory id or secret null");
}
// jhipster-needle-add-social-connection-factory
}
use of org.springframework.social.google.connect.GoogleConnectionFactory in project dubion by valsamiq.
the class SocialConfiguration method addConnectionFactories.
@Override
public void addConnectionFactories(ConnectionFactoryConfigurer connectionFactoryConfigurer, Environment environment) {
// Google configuration
String googleClientId = environment.getProperty("spring.social.google.client-id");
String googleClientSecret = environment.getProperty("spring.social.google.client-secret");
if (googleClientId != null && googleClientSecret != null) {
log.debug("Configuring GoogleConnectionFactory");
connectionFactoryConfigurer.addConnectionFactory(new GoogleConnectionFactory(googleClientId, googleClientSecret));
} else {
log.error("Cannot configure GoogleConnectionFactory id or secret null");
}
// Facebook configuration
String facebookClientId = environment.getProperty("spring.social.facebook.client-id");
String facebookClientSecret = environment.getProperty("spring.social.facebook.client-secret");
if (facebookClientId != null && facebookClientSecret != null) {
log.debug("Configuring FacebookConnectionFactory");
connectionFactoryConfigurer.addConnectionFactory(new FacebookConnectionFactory(facebookClientId, facebookClientSecret));
} else {
log.error("Cannot configure FacebookConnectionFactory id or secret null");
}
// Twitter configuration
String twitterClientId = environment.getProperty("spring.social.twitter.client-id");
String twitterClientSecret = environment.getProperty("spring.social.twitter.client-secret");
if (twitterClientId != null && twitterClientSecret != null) {
log.debug("Configuring TwitterConnectionFactory");
connectionFactoryConfigurer.addConnectionFactory(new TwitterConnectionFactory(twitterClientId, twitterClientSecret));
} else {
log.error("Cannot configure TwitterConnectionFactory id or secret null");
}
// jhipster-needle-add-social-connection-factory
}
Aggregations