SlideShare uma empresa Scribd logo
1 de 23
Baixar para ler offline
Overview

@jclouds
Agenda

• What is jclouds?
• What does it do?
• Relationship to other projects
• Code examples
• Extras
What is jclouds?
• Apache licensed Java multi-cloud SDK
• b 3/2009; ~525k loc; 110 contributors
• connects tools portably regardless of,
  yet also availing backend

• Over 40 cloud providers supported
• next release is 1.6 (March)
What does it do?
• Helps projects become cloud projects,
  and developers become cloud
  developers.

 • through consistency in
  • Tools vs Services
  • Services vs Model
  • API approach
Tools vs Services
• jclouds helps existing tools connect to
  cloud services

 • a consistent integration pattern and
    configuration

 • adjustable library dependencies
 • sample patterns, integrations, and
    abstractions
Services vs Model
• jclouds simplifies modeling of cloud
  services

 • Standards focus with pragmatic
    extensions. (JSR-330, 311)

 • Clean means of addressing service
    quirks

 • pluggable strategies for error/retry
API Approach
• Backend before abstraction
    •   proprietary features, multiple abstractions

• Async/Sync api mirroring
    •   scalably deal with 400ms-3m response time

•   Guava

• Universal Testing Approach
    •   unit, “expect”, and live tests
Who’s integrating?

      you?
Alternatives
• Roll-your-own
 • Jersey, RESTEasy
• EC2-based cloud apis
 • typica, jets3t
• Dasein Cloud API
• Proprietary Service Provider SDKs
Portable APIs

      BlobStore     LoadBalancer

                   DNS, Block Storage,
      Compute       Network, Identity


Provider-Specific Hooks
Embeddable

40 built-in providers & 20 apis and dialects!
java overview                        github jclouds/jclouds


// init
context = ContextBuilder.newBuilder(“cloudfiles-us”)
                        .credentials(apikey, secret)
                        .buildView(BlobStoreContext.class);

blobStore = context.getBlobStore();

// create container
blobStore.createContainerInLocation(null, “adriansmovies”);

// add blob
blob = blobStore.blobBuilder("sushi.avi").payload(file).build();
blobStore.putBlob(“adriansmovies”, blob);
java overview                        github jclouds/jclouds
// init
context = ContextBuilder.newBuilder(“openstack-nova”)
                        .endpoint(“https://keystone:5000/v2.0”)
                        .credentials(tenantUser, password)
                        .modules(singleton(new SshjSshClientModule()))
                        .buildView(ComputeServiceContext.class);

compute = context.getComputeService();

// create a couple nodes and open a couple ports
nodes = compute.createNodesInGroup(“hbase-master”, 1,
                                 runScript(install).
                                 inboundPorts(60000, 60010));

// gather my ip addresses
for (NodeMetadata node : nodes) {
   node.getPublicAddresses();
   node.getPrivateAddresses();
}


 @jclouds                                                                12
jclouds locations
Location helps
normalize placement
across resource types
All top-level resources   listAssignableLocations

have a location                                           US



Location metadata is                            IE
                                                     SG


extensible
jclouds modularity
APIs are software
focused                               jclouds-blobstore



Providers are offering                    s3


focused                  aws-s3
                                          scality-ring        walrus


API + location +          googlestorage

                                          scaleup-storage

defaults = Provider
                                               eucaluptus-partnercloud-s3
New	
  Toys



• Fluent	
  Pagina,on	
  (1.5)
• Small	
  distribu,on	
  (1.6)




@jclouds
Fluent Pagination

• Many apis == pagination differences
• Desire ease, but also ability to “opt-out”
    of lazy continuations
•   Can we make it easier to filter/transform
    resources?
FluentIterable
lazy advance through all your metrics:
FluentIterable<Metric> allMetrics = cloudwatch.getMetricApi().list().concat();

advance only until we find the load balancer we want:
Optional<LoadBalancer> firstInterestingLoadBalancer = elb
   .getLoadBalancerApi().list()
   .concat()
   .firstMatch(isInterestingLB());

get only the first page of google instances
IterableWithMarker<Instance> firstPage =
    gce.getInstanceApiForProject("myproject").listFirstPage();
Small Distribution

• Before 1.6 we had more deps
• We now have much less deps
• You can now make a <5MB cloud app!
Where	
  now?



• jclouds.org
• github/jclouds/jclouds-­‐examples
• jclouds@googlegroups.com
• @jclouds


@jclouds
java overview                        github jclouds/jclouds

// create a couple nodes and open a couple ports
nodes = compute.createNodesInGroup(“web-prod”, 2,
                                 runScript(installApache).
                                 inboundPorts(22, 8080));

// load balance the nodes mapping port 80 -> 8080
lb = lbapi.createLoadBalancerInLocation(null, “web-prod”,
                                        “HTTP”, 80, 8080,
                                        nodes);

// gather my lb addresses
for (String lbAddress : lb.getAddresses()) {

}




    @jclouds                                                 20
chef integration           github jclouds/jclouds-chef



if (any(cookbookVersions, containsRecipe("apache2")))
  runList = new RunListBuilder().addRecipe("apache2").build();

chef.updateRunListForGroup(runList, “web-prod”);

boot = chef.createClientAndBootstrapScriptForGroup(“web-prod”);

nodes = compute.createNodesInGroup(“web-prod”, 1, runScript(boot));
CLI   github jclouds/jclouds-cli
BYON   github jclouds/jclouds

Mais conteúdo relacionado

Mais procurados

Libcloud and j clouds
Libcloud and j cloudsLibcloud and j clouds
Libcloud and j clouds
DaeMyung Kang
 

Mais procurados (20)

Openshift Container Platform on Azure
Openshift Container Platform on Azure Openshift Container Platform on Azure
Openshift Container Platform on Azure
 
Virtualized Containers - How Good is it - Ananth - Siemens - CC18
Virtualized Containers - How Good is it - Ananth - Siemens - CC18Virtualized Containers - How Good is it - Ananth - Siemens - CC18
Virtualized Containers - How Good is it - Ananth - Siemens - CC18
 
Deploy Elasticsearch Cluster on Kubernetes
Deploy Elasticsearch Cluster on KubernetesDeploy Elasticsearch Cluster on Kubernetes
Deploy Elasticsearch Cluster on Kubernetes
 
Deploying and running Grails in the cloud
Deploying and running Grails in the cloudDeploying and running Grails in the cloud
Deploying and running Grails in the cloud
 
Working in the multi-cloud with libcloud
Working in the multi-cloud with libcloudWorking in the multi-cloud with libcloud
Working in the multi-cloud with libcloud
 
Microsoft Azure Container Service - DockerCH
Microsoft Azure Container Service - DockerCHMicrosoft Azure Container Service - DockerCH
Microsoft Azure Container Service - DockerCH
 
Libcloud and j clouds
Libcloud and j cloudsLibcloud and j clouds
Libcloud and j clouds
 
Docker and CloudStack
Docker and CloudStackDocker and CloudStack
Docker and CloudStack
 
Deploying a 3 tier application using docker
Deploying a 3 tier application using dockerDeploying a 3 tier application using docker
Deploying a 3 tier application using docker
 
AWS-compared-to-OpenStack
AWS-compared-to-OpenStackAWS-compared-to-OpenStack
AWS-compared-to-OpenStack
 
AWS Elastic Container Service - DockerHN
AWS Elastic Container Service - DockerHNAWS Elastic Container Service - DockerHN
AWS Elastic Container Service - DockerHN
 
Building Web Scale Apps with Docker and Mesos by Alex Rukletsov (Mesosphere)
Building Web Scale Apps with Docker and Mesos by Alex Rukletsov (Mesosphere)Building Web Scale Apps with Docker and Mesos by Alex Rukletsov (Mesosphere)
Building Web Scale Apps with Docker and Mesos by Alex Rukletsov (Mesosphere)
 
Kubernetes Networking - Sreenivas Makam - Google - CC18
Kubernetes Networking - Sreenivas Makam - Google - CC18Kubernetes Networking - Sreenivas Makam - Google - CC18
Kubernetes Networking - Sreenivas Makam - Google - CC18
 
Setting up Kubernetes with tectonic
Setting up Kubernetes with tectonicSetting up Kubernetes with tectonic
Setting up Kubernetes with tectonic
 
Shakr - Container CI/CD with Google Cloud Platform
Shakr - Container CI/CD with Google Cloud PlatformShakr - Container CI/CD with Google Cloud Platform
Shakr - Container CI/CD with Google Cloud Platform
 
Elasticsearch on Kubernetes
Elasticsearch on KubernetesElasticsearch on Kubernetes
Elasticsearch on Kubernetes
 
Modern Web development and operations practices
Modern Web development and operations practicesModern Web development and operations practices
Modern Web development and operations practices
 
Running OpenStack on Amazon AWS, Alex Fishman
Running OpenStack on Amazon AWS, Alex FishmanRunning OpenStack on Amazon AWS, Alex Fishman
Running OpenStack on Amazon AWS, Alex Fishman
 
Kubernetes on Top of Mesos on Top of DCOS
Kubernetes on Top of Mesos on Top of DCOSKubernetes on Top of Mesos on Top of DCOS
Kubernetes on Top of Mesos on Top of DCOS
 
Securing Containers - Sathyajit Bhat - Adobe - Container Conference 18
Securing Containers - Sathyajit Bhat - Adobe - Container Conference 18Securing Containers - Sathyajit Bhat - Adobe - Container Conference 18
Securing Containers - Sathyajit Bhat - Adobe - Container Conference 18
 

Semelhante a jclouds High Level Overview by Adrian Cole

Introduction to Apache jclouds at NYJavaSIG
Introduction to Apache jclouds at NYJavaSIGIntroduction to Apache jclouds at NYJavaSIG
Introduction to Apache jclouds at NYJavaSIG
Everett Toews
 
Spark on Dataproc - Israel Spark Meetup at taboola
Spark on Dataproc - Israel Spark Meetup at taboolaSpark on Dataproc - Israel Spark Meetup at taboola
Spark on Dataproc - Israel Spark Meetup at taboola
tsliwowicz
 
Three Degrees of Mediation: Challenges and Lessons in building Cloud-agnostic...
Three Degrees of Mediation: Challenges and Lessons in building Cloud-agnostic...Three Degrees of Mediation: Challenges and Lessons in building Cloud-agnostic...
Three Degrees of Mediation: Challenges and Lessons in building Cloud-agnostic...
Alex Maclinovsky
 

Semelhante a jclouds High Level Overview by Adrian Cole (20)

jclouds overview
jclouds overviewjclouds overview
jclouds overview
 
Introduction to Apache jclouds at NYJavaSIG
Introduction to Apache jclouds at NYJavaSIGIntroduction to Apache jclouds at NYJavaSIG
Introduction to Apache jclouds at NYJavaSIG
 
Introduction to Apache CloudStack by David Nalley
Introduction to Apache CloudStack by David NalleyIntroduction to Apache CloudStack by David Nalley
Introduction to Apache CloudStack by David Nalley
 
Cloud State of the Union for Java Developers
Cloud State of the Union for Java DevelopersCloud State of the Union for Java Developers
Cloud State of the Union for Java Developers
 
20141021 AWS Cloud Taekwon - Startup Best Practices on AWS
20141021 AWS Cloud Taekwon - Startup Best Practices on AWS20141021 AWS Cloud Taekwon - Startup Best Practices on AWS
20141021 AWS Cloud Taekwon - Startup Best Practices on AWS
 
Spark on Dataproc - Israel Spark Meetup at taboola
Spark on Dataproc - Israel Spark Meetup at taboolaSpark on Dataproc - Israel Spark Meetup at taboola
Spark on Dataproc - Israel Spark Meetup at taboola
 
AWS Webcast - Build Agile Applications in AWS Cloud for Government
AWS Webcast - Build Agile Applications in AWS Cloud for GovernmentAWS Webcast - Build Agile Applications in AWS Cloud for Government
AWS Webcast - Build Agile Applications in AWS Cloud for Government
 
AWS re:Invent 2016 Day 2 Keynote re:Cap
AWS re:Invent 2016 Day 2 Keynote re:CapAWS re:Invent 2016 Day 2 Keynote re:Cap
AWS re:Invent 2016 Day 2 Keynote re:Cap
 
AWS re:Invent 2016 Day 2 Keynote re:Cap
AWS re:Invent 2016 Day 2 Keynote re:CapAWS re:Invent 2016 Day 2 Keynote re:Cap
AWS re:Invent 2016 Day 2 Keynote re:Cap
 
AWS Webcast - Build Agile Applications in AWS Cloud for Government
AWS Webcast - Build Agile Applications in AWS Cloud for GovernmentAWS Webcast - Build Agile Applications in AWS Cloud for Government
AWS Webcast - Build Agile Applications in AWS Cloud for Government
 
Three Degrees of Mediation: Challenges and Lessons in building Cloud-agnostic...
Three Degrees of Mediation: Challenges and Lessons in building Cloud-agnostic...Three Degrees of Mediation: Challenges and Lessons in building Cloud-agnostic...
Three Degrees of Mediation: Challenges and Lessons in building Cloud-agnostic...
 
비동기 회고 발표자료
비동기 회고 발표자료비동기 회고 발표자료
비동기 회고 발표자료
 
CQ5 and Sling overview
CQ5 and Sling overviewCQ5 and Sling overview
CQ5 and Sling overview
 
Node.js on Azure
Node.js on AzureNode.js on Azure
Node.js on Azure
 
Fighting Against Chaotically Separated Values with Embulk
Fighting Against Chaotically Separated Values with EmbulkFighting Against Chaotically Separated Values with Embulk
Fighting Against Chaotically Separated Values with Embulk
 
Quick and Easy Development with Node.js and Couchbase Server
Quick and Easy Development with Node.js and Couchbase ServerQuick and Easy Development with Node.js and Couchbase Server
Quick and Easy Development with Node.js and Couchbase Server
 
Cloud-native legacy applications
Cloud-native legacy applicationsCloud-native legacy applications
Cloud-native legacy applications
 
WebGUI Developers Workshop
WebGUI Developers WorkshopWebGUI Developers Workshop
WebGUI Developers Workshop
 
DevOps, Continuous Integration and Deployment on AWS: Putting Money Back into...
DevOps, Continuous Integration and Deployment on AWS: Putting Money Back into...DevOps, Continuous Integration and Deployment on AWS: Putting Money Back into...
DevOps, Continuous Integration and Deployment on AWS: Putting Money Back into...
 
Devops continuousintegration and deployment onaws puttingmoneybackintoyourmis...
Devops continuousintegration and deployment onaws puttingmoneybackintoyourmis...Devops continuousintegration and deployment onaws puttingmoneybackintoyourmis...
Devops continuousintegration and deployment onaws puttingmoneybackintoyourmis...
 

Mais de Everett Toews

Mais de Everett Toews (20)

All You Need to Know About Kustomize
All You Need to Know About KustomizeAll You Need to Know About Kustomize
All You Need to Know About Kustomize
 
Intro to InnerSource
Intro to InnerSourceIntro to InnerSource
Intro to InnerSource
 
An OpenShift Migration: From 3.9 to 4.5
An OpenShift Migration: From 3.9 to 4.5An OpenShift Migration: From 3.9 to 4.5
An OpenShift Migration: From 3.9 to 4.5
 
Cloud Native Summit 2019 Summary
Cloud Native Summit 2019 SummaryCloud Native Summit 2019 Summary
Cloud Native Summit 2019 Summary
 
DevOps: Chop wood. Carry water.
DevOps: Chop wood. Carry water.DevOps: Chop wood. Carry water.
DevOps: Chop wood. Carry water.
 
Intro to Docker Swarm
Intro to Docker SwarmIntro to Docker Swarm
Intro to Docker Swarm
 
Ciao: Continuous Integration for Apps on OpenStack
Ciao: Continuous Integration for Apps on OpenStackCiao: Continuous Integration for Apps on OpenStack
Ciao: Continuous Integration for Apps on OpenStack
 
DevStack: Learn OpenStack by Running OpenStack
DevStack: Learn OpenStack by Running OpenStackDevStack: Learn OpenStack by Running OpenStack
DevStack: Learn OpenStack by Running OpenStack
 
Enabling Walk Up Contributions to Your Documentation at GlueCon
Enabling Walk Up Contributions to Your Documentation at GlueConEnabling Walk Up Contributions to Your Documentation at GlueCon
Enabling Walk Up Contributions to Your Documentation at GlueCon
 
You Sir, Sir Vey
You Sir, Sir VeyYou Sir, Sir Vey
You Sir, Sir Vey
 
Walk n Doc
Walk n DocWalk n Doc
Walk n Doc
 
Nashorn
NashornNashorn
Nashorn
 
Enabling Walk Up Contributions to Your Project Documentation
Enabling Walk Up Contributions to Your Project DocumentationEnabling Walk Up Contributions to Your Project Documentation
Enabling Walk Up Contributions to Your Project Documentation
 
Introduction to Apache jclouds at ApacheCon 2014
Introduction to Apache jclouds at ApacheCon 2014Introduction to Apache jclouds at ApacheCon 2014
Introduction to Apache jclouds at ApacheCon 2014
 
Women Who Code
Women Who CodeWomen Who Code
Women Who Code
 
HackTX
HackTXHackTX
HackTX
 
Cybera Summit
Cybera SummitCybera Summit
Cybera Summit
 
The OpenStack Community Welcomes Developers in All Languages
The OpenStack Community Welcomes Developers in All LanguagesThe OpenStack Community Welcomes Developers in All Languages
The OpenStack Community Welcomes Developers in All Languages
 
NetflixOSS on OpenStack
NetflixOSS on OpenStackNetflixOSS on OpenStack
NetflixOSS on OpenStack
 
jclouds at HKJUG
jclouds at HKJUGjclouds at HKJUG
jclouds at HKJUG
 

Último

Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire business
panagenda
 

Último (20)

MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024
 
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
 
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
 
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
 
FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
 
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ..."I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
 
ICT role in 21st century education and its challenges
ICT role in 21st century education and its challengesICT role in 21st century education and its challenges
ICT role in 21st century education and its challenges
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
 
AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of Terraform
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire business
 
A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?
 
DBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor PresentationDBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor Presentation
 
A Beginners Guide to Building a RAG App Using Open Source Milvus
A Beginners Guide to Building a RAG App Using Open Source MilvusA Beginners Guide to Building a RAG App Using Open Source Milvus
A Beginners Guide to Building a RAG App Using Open Source Milvus
 

jclouds High Level Overview by Adrian Cole

  • 2. Agenda • What is jclouds? • What does it do? • Relationship to other projects • Code examples • Extras
  • 3. What is jclouds? • Apache licensed Java multi-cloud SDK • b 3/2009; ~525k loc; 110 contributors • connects tools portably regardless of, yet also availing backend • Over 40 cloud providers supported • next release is 1.6 (March)
  • 4. What does it do? • Helps projects become cloud projects, and developers become cloud developers. • through consistency in • Tools vs Services • Services vs Model • API approach
  • 5. Tools vs Services • jclouds helps existing tools connect to cloud services • a consistent integration pattern and configuration • adjustable library dependencies • sample patterns, integrations, and abstractions
  • 6. Services vs Model • jclouds simplifies modeling of cloud services • Standards focus with pragmatic extensions. (JSR-330, 311) • Clean means of addressing service quirks • pluggable strategies for error/retry
  • 7. API Approach • Backend before abstraction • proprietary features, multiple abstractions • Async/Sync api mirroring • scalably deal with 400ms-3m response time • Guava • Universal Testing Approach • unit, “expect”, and live tests
  • 9. Alternatives • Roll-your-own • Jersey, RESTEasy • EC2-based cloud apis • typica, jets3t • Dasein Cloud API • Proprietary Service Provider SDKs
  • 10. Portable APIs BlobStore LoadBalancer DNS, Block Storage, Compute Network, Identity Provider-Specific Hooks Embeddable 40 built-in providers & 20 apis and dialects!
  • 11. java overview github jclouds/jclouds // init context = ContextBuilder.newBuilder(“cloudfiles-us”) .credentials(apikey, secret) .buildView(BlobStoreContext.class); blobStore = context.getBlobStore(); // create container blobStore.createContainerInLocation(null, “adriansmovies”); // add blob blob = blobStore.blobBuilder("sushi.avi").payload(file).build(); blobStore.putBlob(“adriansmovies”, blob);
  • 12. java overview github jclouds/jclouds // init context = ContextBuilder.newBuilder(“openstack-nova”) .endpoint(“https://keystone:5000/v2.0”) .credentials(tenantUser, password) .modules(singleton(new SshjSshClientModule())) .buildView(ComputeServiceContext.class); compute = context.getComputeService(); // create a couple nodes and open a couple ports nodes = compute.createNodesInGroup(“hbase-master”, 1, runScript(install). inboundPorts(60000, 60010)); // gather my ip addresses for (NodeMetadata node : nodes) { node.getPublicAddresses(); node.getPrivateAddresses(); } @jclouds 12
  • 13. jclouds locations Location helps normalize placement across resource types All top-level resources listAssignableLocations have a location US Location metadata is IE SG extensible
  • 14. jclouds modularity APIs are software focused jclouds-blobstore Providers are offering s3 focused aws-s3 scality-ring walrus API + location + googlestorage scaleup-storage defaults = Provider eucaluptus-partnercloud-s3
  • 15. New  Toys • Fluent  Pagina,on  (1.5) • Small  distribu,on  (1.6) @jclouds
  • 16. Fluent Pagination • Many apis == pagination differences • Desire ease, but also ability to “opt-out” of lazy continuations • Can we make it easier to filter/transform resources?
  • 17. FluentIterable lazy advance through all your metrics: FluentIterable<Metric> allMetrics = cloudwatch.getMetricApi().list().concat(); advance only until we find the load balancer we want: Optional<LoadBalancer> firstInterestingLoadBalancer = elb .getLoadBalancerApi().list() .concat() .firstMatch(isInterestingLB()); get only the first page of google instances IterableWithMarker<Instance> firstPage = gce.getInstanceApiForProject("myproject").listFirstPage();
  • 18. Small Distribution • Before 1.6 we had more deps • We now have much less deps • You can now make a <5MB cloud app!
  • 19. Where  now? • jclouds.org • github/jclouds/jclouds-­‐examples • jclouds@googlegroups.com • @jclouds @jclouds
  • 20. java overview github jclouds/jclouds // create a couple nodes and open a couple ports nodes = compute.createNodesInGroup(“web-prod”, 2, runScript(installApache). inboundPorts(22, 8080)); // load balance the nodes mapping port 80 -> 8080 lb = lbapi.createLoadBalancerInLocation(null, “web-prod”, “HTTP”, 80, 8080, nodes); // gather my lb addresses for (String lbAddress : lb.getAddresses()) { } @jclouds 20
  • 21. chef integration github jclouds/jclouds-chef if (any(cookbookVersions, containsRecipe("apache2"))) runList = new RunListBuilder().addRecipe("apache2").build(); chef.updateRunListForGroup(runList, “web-prod”); boot = chef.createClientAndBootstrapScriptForGroup(“web-prod”); nodes = compute.createNodesInGroup(“web-prod”, 1, runScript(boot));
  • 22. CLI github jclouds/jclouds-cli
  • 23. BYON github jclouds/jclouds