2015 JavaOne

Day 1

power of open source

  • discipline – experienced/bright developers and they dont sleep
  • freedom
  • Vosao CMS + GAE = free hosting




glassfish community

http://glassfish.java.net/  Arun Gupta/Reza ahman

  • # of downloads – 4.5 M from update center; 6.5 M installer/zip (doesn’t include maven artifacts)
  • more social – 3000 more twitter followers
  • date driven vs event driven release cycle (glassfish is more date driven)
  • glassfish 4.0 taking feature requests
  • JPA(persistence API)/JRS/Jigsaw
  • project avatar
  • how weblogic and glassfish compensate each other – shared library, same group of engineers
  • weblogic – HA is essential. same applies to glassfish


netbean platform

  • why netbeans – well accounting people prefer console apps
  • BL economy (accounting software) – jasper (doc generator) plugin for netbeans http://plugins.netbeans.org/PluginPortal/faces/PluginDetailPage.jsp?pluginid=2553
  • ORKA – sale gas and unconventional reservoir – adobe database with jpa
  • Agrosystem (agrosense) – agriculture/farm management – pluggable software, map(gxmap), offline operation
  • lynden FMS (cargo, freight management system) – universe bof database

everything you want to know about java

  • how can we run java on iOS – there is java API (code name one) on iOS – google has java converter to iOS code
  • how can we do write once and run anywhere on mobile
  • are JVM anguages competition to java or complementary
  • web socket and spdy
  • is jrocket dead
  • diagnose java performance issues – jClarity – measure dump analysis
  • why is there no common interface from numerical types
  • what is the best way to diagnose perm gen – via JDK 8 (there is no perm gen!!); best way is heap dump; two gc to then heap dump and look for things that shouldn’t be there (
  • success stories for the G1 collector
  • can java do multiple inheritance
  • real modularity in java
  • best java caching mechanism
  • java equivalent to link in .net
  • jrocket is dead –>hot rocket team in oracle
  • hotspot is not dead
  • java vs others – you need more than just 1 language but complimentary to each other
  • portlets is dead
  • why gosling left oracle?
  • where to submit bug for JRE – there will be a public bug tracker
  • Make java user friendly
    Naming of API
    Second pair of eyes to review
  • Link4j
  • Best way to do soap is to use restapi
  • (Jsr)
  • Best caching -JSR; don’t use caching because of gc. Or to serialize to memcache
  • Integrate spring with cdi
  • Queue solution? Java unsafe tool for concurrent coding


Java Strategy Keynotes

  • key to success 


    • Developer productivity
    • Open and transparent evolution
    • Community involvement
  • 3 key factors 
    • Leadership
    • Innovation
    • Community
  • roadmap – openjdk, jcp, jugs (java user group) 


    • Javafx will be open source
    • Javafx to replace swing and financial stats app
    • Nosql in oracle already
    • Nosql is not standardized yet
  • AMD SVP -HSA heterogeneous system architecture to coincide with Java User Group 


    • Magical vs natural progression
    • Java card
  • Nike – Nike fuel band



######################### side notes ####################################


http://java.net/projects/websocket-spec/ (API for web socket)

start using web socket


http://en.wikipedia.org/wiki/Multitenancy (cloud)

Learn how to use the Java instrumentation API to instrument your application and its external libraries to monitor transactions and visualize trends in your application. This tutorial starts by introducing transaction monitoring and ends with a complete, running transaction monitoring system. You learn every step along the way: instrument Java code in a running Java server, log SQL queries as the database sees them, visualize high-volume servlet performance as your users experience it, and expose statistics with JMX. The tutorial shows you how these techniques enable you to not just detect but also but predict outages on large-scale systems.

Day 2

teaching java programming to next generation

engaging enterprise (CTO of webphere Jerry Cuomo)

  • a story teller
  • motivation, design
  • Jerry’s technology trends (blog and facebook page – user community) – living document
  • GPS, social, business promos, analytics, mobile, bigdata
  • amazon is a perfect example to leverage the power of the web
  • data – public data records, rate comparison, company#123 data, analytics sensors on all devices to provide real time data
  • engaging enterprse dsign – extend (externalizing and sync), transact with security and scale, optimize with insights
  • extend – core services, APIs (paypal, bestbuy, more users use API then websites), APPs that use your API (mobile app, small app like paceMaker, java Card)
  • transact – (seuciryt, contorl, scale, resilience, accounting) – insights and actions
  • web API service – create/document/assemble/moble API on demand (using ACME airline as an example ) with IBM worklight implementation
  • transact – security, pattern
  • IBM bigdata
  • analytics – platform of client apps, geographic source of client app usage

Tooling Support for Enterprise Development (Reza Rahman’s session)

Delivering Performance and Reliability at the World’s Leading Futures Exchange – Rene Perrin – Technical Specialist Software Engineer, CME Group

  • CME group – found designated contract markets (DCMs) – CME/CBOT, NYMEX, COMEX – http://cmegroup.com
  • electronic trading on globex – CME Globex first and remains fastest trading app on earth
  • overview
    • order entry bus – falcon gageway component —>match server –>market data componet –>market data bus
    • admin server, JMS
  • app behavior – match incoming order against any resting orders –
  • CLZ2 http://www.barchart.com/quotes/futures/CLZ2
  • CL: C1 HO-CLZ2
  • buy/sell HOZ
  • cme do implied trading and implied matching
  • scalability and capacity problems – customers cannot be segregated in different columns – ordering is important. allocation algo such as FIFO
  • conclusion – tranditional scaling solutions to address problem cannot be applied
  • high level comparison – monthly order volumes vs RTT (round trip time)
  • performance – measurement: order volumes vs round trip time
  • performance – constantly measures performance, every week, the 6 busiest minutes for each market is identified to used as baseline (window doesn’t want to be too long; uptime is 24×7, shutdown on the weekend; just enough interval for repetivie tests)
  • performance – orders MAY have cascading effects – such cascading side effects must be processed before handling the next incoming order – measuring order queuing and latency
  • benchmarking
    • 0-1 ms: good
    • 1-5 ms: ok
    • 5-30 ms: slow
    • more than 30: very slow – 41ms = time of a standard (24fps) video frame
  • HRI – how and when to measure performance – HRI (history replay injector)
    • used to replay all orders received during 6 minutes, established weekly
    • multiple HRIs are run in each production environment on Saturdays to validate that the weekly maintenance (config changes, hw/sw updates) have no negative impacts on performance
      • HRI – homegrown
      • all tradings engines are brought down on Friday nights after US markets close
      • weekly maintenace is applilied after the markets are closed
      • saturdays are dedicated to testing the production environment steup for the upcoming week
      • testing in production – has to be very good at cleaning up afterwards
  • Performance analysis
    • data collector
    • measuring key/critical processing steps
    • metrics collector run within memory
    • collecting metrics and tracers
    • metric data – counter
    • tracer data – hexcode
  • performance analysis – falcon dashboard
    • tracer info is captured from logs and stored in a mango database for query purposes
    • source – production logs –
    • build server logs – change log
    • filter – order types
    • with cumulative distribution
    • performance varies on different OS
    • technology – mongoDB, Scala
    • automated performance tests in build server
  • reliability measures
  • functional correctness, software resiliency and fault tolerance
  • what’s done – testing
  • real world – testing with real data
  • HRI is the answer
    • cons – can be difficult to reproduce; in case of message format changes, some adapters may be needed to normalize data
    • Pros – high volume. real orders
  • testing in production – Prod Parallel testing
  • roll in rollout – saturday test run in production – after all due diligence tests have been run, running several history replays, running in prod-parallel.
  • time for a dress rehearsal
  • fault torelance – fault torelance synchronization (primary engine – backup engine)
  • tips
    • simple coding
    • hashmap
    • no full GC during the week – no custom core – tuning, tuning and tuning
    • barely any multi-threading

Clojure/ClojureScript: One Language to Rule the Web Stuart Sierra – Developer, Relevance, Inc.

  • efficient way to distribute apps
  • immutable data structures – list/vector/map/set
  • data manipulation – expressive language
  • make up the gap of javascript – multi-arity functions (function that takes different form of argument or none at all)
  • namespaces – ns (javascript doesn’t have namespace concept)
  • designed for concurrency – time and state
  • google closure compiler
  • share code – code without host interop just works/lein-cljsbuild has “crossovers”, feature expressions coming to clojure

JSR 347 Data Grids, and NoSQL Manik Surtani – Open Source Hacker, Red Hat Ltd.

  • http://jcp.org/en/jsr/detail?id=107 – temporary caching API
  • http://jcp.org/en/jsr/detail?id=347 – data grids for java platform
  • data grids – distributed caches – clustered by nature
  • http://www.infoq.com/interviews/JSR347-Manik-Surtani (JSR 107, JSR 347, Infinispan, NoSQL, Hot Rod, Memcached, CDI and Beyond)
  • infinispan – in-memory data grid; open used as a performance boost for database, used as a nosql key/value store
  • standards – JSR-107/347
  • nosql overlaps with data grids
  • why relational database – disk space expensive, slow network speed, Codd’s normal forms ruled the earth. http://en.wikipedia.org/wiki/Boyce%E2%80%93Codd_normal_form
  • not anymore – cheap storage/memory;high available/scalability are important/cloud; relational model never sat well with OOP anyway
  • nosql comes in – flexible(soft) schema – often de-mormalized
  • overlaps
  • Data Grids – primarily accessed in – VM, optimized for fast, mainly store data in memory, optonally writing through to disk (casandra?!)
  • NoSql – primarily accessed remotely over a socket, optmized for very large volume, maily store data on disk, and optionally caching in memory
  • BoF – NoSql engine – evenutal consistency, async API, returns futures, control co-location
  • JSON is used to standardize API cross difference provided by different vendors which still have proprietary API
  • JPQL is the answer


  • NoSQL and Polyglot Persistence
  • Java Persistence with NoSQL and SQL
  • JavaFX a platform to present data http://docs.oracle.com/javafx/2/overview/jfxpub-overview.htm
  • TUT5173 – Transaction Monitoring with the Instrumentation API – http://docs.oracle.com/javase/6/docs/api/java/lang/instrument/Instrumentation.html
  • JCP – java community press
  • http://nosql-database.org/

Day 3

MongoDB and Java: Big Data Made Easy – antoine girbal – Solutions Architect, 10gen

  • mongo db is a nosql database.
  • big data – masses pushing data
  • volume – big/difficult/exterme volume is relative – 100GBs or 100 PB
  • volume – causes an organization to consider DB tech
  • variety of data – not easy to comform to a single schema, schema is out of control, whose schema might potentially be unknown at design time
  • data store and analytics – RDBMS, RDBMS helper (memcache, app layer), new gen OLAP and then non-relational operational stores (NoSQLL)
  • NoSql – non-relational, operational datastores and dbs, focus on scalability, ease of modeling and changing data and no sql syntax
  • NoSql – no joins and no complext transactions – horizotally scalable arch
  • NoSql  key-value stores/big table dscendants(distributed multi-dimenson map, data sored in a column oriented fashion; predominantly hash based indexing), document oriented stores (stored as JSON or XML)
  • JSON style documents, light/firendly XML and represented as BSON (http://bsonspec.org/ – binary json) – no buffer, no parsing is necessary
  • terminology database–>database, table->collection, row–>document
  • flexible schemas – potentially all documents (row) in the same collection (table)
  • craiglist use mongo db for catalog system
  • embedded documents – little need for joins and YOU CAN STORE A LIST.
  • Mongo DB key features – data stored as docs, schema scree, CRUB (create read update delete), atomic document operations, ad hoc queries like SQL (equality, regular expression, ranges, geospatial), secondary indexes, sharding (sometimes caled partitioning) for scalability, replication – HA and read scalability
  • java driver is open source, available on github, mongon.jar is the one, bson.jar is a subset with BSON lib only; java driver is currently the most used, receives active dev by 10gen and the community
  • driver features, CRUD, support for replica sets, connection pooling, BSON/JSON, GridFS (ability to store files in mongoDB)
  • operation – first obtain a mong, db, and collection instnace; many settings stored within each object. settings are inherited from parent object
  • comparison (photo)
  • BSON object – document is represented by basicDBObject class. basically a linke hashmap; a BasicDBObject can be built manually or using a BasicDBObjectBuilder
  • safe writes – turned on by specifying a writeConcern at Mongo, DB, Collection or query level – by default writes are fire-and-forget and may not detect certain errors
  • querying – use find() to query for docs and it creates a cursor, use limit() to limit the number of docs returned
  • other operations – count, update, remove and arbitrary command
  • indexing
  • replica sets – 1 primary + n secondary; only primary write to DRIVER
  • sharding – MongoS process (shard key); sharding is defined per collection
  • Morphia – maps plain java objects, annotations
  • the ORMs – spring data, hibernate OGM project
  • conclusion – mogonDB is document-orented, java support is strong, additional tools like ORMs exist to simplify the use of MongoDB and maintain the langugage strengths
  • Q/A: synchronize (no reconciding data is done; write will be lost temporarily if primary is down)


Deep Dive into Java Performance analysis with advanced toolsets (intel)

  1. motivation – growing complications, multi-core, CPU ecache, new arch and instruction sets, expansion of new SW models, cloud arch, virtualization and app complexity growth
  2. typical tasks: java stack, java heap, synchromization, hotspots (jstack, jmap, profilers)
  3. advanced tasks: java/nactive heap and stack, SW based profiling, hw based profiling, advanced analysis techniquies (intel vtune amlifier XE, oracle solaris performance analyzer)
  4. Intel Vtune amplifier XE
  • part of VTune studio
  • two data collection types – hardware event-based sampling and user-mode sampling and tracking (time based, takes snapshots with some time interval to identify hopspots with stats call graphs)
  1. time-based vs event-based analysis – compared hotspots vs lw hotspots
  • very much like dynaTrace


JVM JIT for Dummies – Charles Nutter – JRuby Guy, Red Hat


 Forge New Ground in Rapid Enterprise Software Development: Paul Bakker,  Lincoln Baxter III – Senior Software Engineer, Red Hat
  • jboss forge
  • jboss tool
  • new project, maven (pom.xml) and then scaffold
  • use persistence plugin –> JPA
  • use forge command console



############################additional notes ###############################

Day 4

Java Paas – the engine to drive mobile to enterprise applications – CloudBees/Harpreet Singh and Mark Prichard

  • background jenkins, bea, jboss and continuous integration and agile
  • goal – to get the market faster
  • what deployment should be – build –(continuous deployment)–>Run
  • PaaS is perfect tor that
  • traditional software stack – install monitor patch upgrade and validate stack
  • three layers of cloud – IaaS (amazon,terremark, ecualyptus systems)
  • PaaS – cloudbees, heroku, vmForce, database.com
  • SaaS
  • four steps – platform –> stack –> app –> upgrade
  • Paas: reference architecture – runing services(auto scaling, HA, monitoring)/middleware services(app server, DBMS/nosql, logging, messaging, mail), core platform services (provisioning, SLA, monitoring, metering, billing) and IaaS and virtualization/OS below
  • Jenkins – community-driven OSS project (open source software) – market share (33% jenkins, 30% maven)
  • ALM (application lifecycle management) in the cloud
  • cloudbees http://www.cloudbees.com/pricing-standard-services.cb
  • Jenkins, Cloud and Mobile – why jenkins in cloud for mobile CI
  • iOS mobile app (build/test using jenkins, MacOS slaves for builds, testFlight push to beta testers)
  • built using eclipse, maven, junit, jax-rs, jax-B, gson
  • jenkins – iOs packaging/distribution, cloudbees (repository), iOs development (xcode), eclipse (services development), jUnit, SOASTA (integration/functional testing)
  • Considerations for choosing a Java PaaS
  • so essential jenkins running in the cloud https://partnerdemo.ci.cloudbees.com/
  • PaaS Criteria
  • use case? existing/greenfield development app, limited users or web-scale, simplicity or fexibility, ALM (dev, test or production), private cloud or public cloud
  • what friction points does it eliminate, architecting solutions in a new way?
  • evaluation: application stack –  java/php/python/ruby, if java, which jvm languages (scala, groovy)
  • answer to “custom” stack –> cloudbees clickstacks

Oracle and .NET: Best practices for performance and deployment

  • optmization process: .NET data access tuning (ODP.NET best practices)–>SQL tuning (use SQL tuning advisor in visual studio), database tuning under real world conditions (oracle performance analyzer in visual studio detects issues)
  • ODP.NET – close/dispose connections (and all objects)
  • ODP.NET performance counters (version or higher) – monitor with windows performance monitor
  • connection management – clusters and standbys – RAC automatic connection load balancing (Load Balancing=true), RAC and data gurad automatic “bad” connection removal (HA Events=true)
  • optimizing ODP.NET performance – connections, data retreivel and updates, ODPnet data types and caching
  • commands – statement caching (retains previously parsed statement in shared pool, cursor stays open on the client side for faster re-use, no additional lookup needed on server; metadata remains on the client/caches most recently used statements – works with SQl and PL/SQL statements
  • commands – data retrieval: control how much data is retrieved per DB roundtrip, (too much data: excessive client-side app, too little data – additional round trip) – set rowSize properly
  • commands – statement batching – use OracleDataAdapter.UpdateBatchSize to batch updates from DataSet. Execute multiple commands in on DB roundtrip (use anonymous PL/SQL block)
  • commands – mass data movement with arrays (PL?SQL associative arrays, uuse parameter arrybinding)
  • promotable transactions
  • ODP.NET data types – avoid unnecessary data type conversions: .net vs ODP.net types; option to store oracle data types in dataset (available in ADO.NET 2.0)
  • REF cursors – retrieve data as needed, defers result set retrieval until needed, pass REF cursors back as input stored proc, OracleRefCursor class
  • Oracle .NET caching solutions, client result cache, CQN (continuous query notification), Times Ten in-memory database;
  • optimizing performance from visual studio, sql tuning advisor and oracle performance analyzer
  • managing multiple oracle homes in .net – solution for 10.2 and later, DLL search order
  • SQL tuing advisor (32bit only?) http://www.oracle.com/webfolder/technetwork/tutorials/obe/db/dotnet/TuningNETAdvisor/TuningNETAdvisor.htm


BPM and Analytics: Process Dashboards, BAM, and Intelligent Optimization

  • BPM analytics value proposition – en-to-end process visibility, current KPI status, spot common problems/bottleneckts, ynamacially adapt business process base on current conditions/trends, real time alerts trigger corrective action
  • BPM analytics stakehodlers, process owner, analysits, process developer an executives
  • usage patterns – order to cash, more efficient workand document routing
  • BPM analytics, metrics and reporting–>monitor and analyze–>optimization (tech dashboard evolution)
  • key features – KPI monitoring, health montiroing, simulation, real time alerts/action, next-best action recommdnation, pattern detection and geo fecning, process intelligence(PI), data discovery and social analytics
  • operational monitoring –> actional insights –> process optimization –> process intelligence
  • actionable business insights – monitor business activity, manage by exceptions, perform dimensional analysis, monitor business KPIs –>moniotr/analyze/act
  • Oracle BAM (Oracle Business Activity Monitoring)
  • process optmization – build simulation scnerios, identify causes for bottlenecks
  • BAM 12c feature highlights
  • leverage OEP engine as the process engine
  • Tight integration with OBIEE (Oracle Business Intelligence Enterprise Edition)
  • enhanced real-time alerting and action framework
  • ready process monitoring profile for BPM/SOA (automated KPI creation?!)
  • OPSS – Oracle Platform Security Services security (http://www.oracle.com/technetwork/middleware/id-mgmt/index-100381.html)
  • KPI risk assessment
    • outcome metrics (lagging)
    • driver metrics (leaing) – in a customer service scenario, call waiting time is an outcome metric, Call volume affects its riskiness
    • KPI watch list
    • metrics harvest


Advanced Enterprise Architectures Using Open Source Heath Kesler – SOA Architect, Savoir Technologies

  • Evangelist, SOA architect, application fire fighter
  • no problem cannot be solved by open source. you can debug and modify it. hidden gems
  • apache, apache camel, apache activemq,..,etc
  • OSGi- http://www.osgi.org/Main/HomePage  karaf http://karaf.apache.org/
  • ESB (enterprise service bus)
  • activemq messaging options – non-shared/pure (master/slave – 2 different persistence store) – problem in-flight messages, data persistence, data integrity.
  • activemq messaging options – shared file system/JDBC – master/slave/shared persistence – watch out for the “journal file”
  • activemq scaling – network of brokers – meshed network 2 pairs of master/slave – duplex
  • activemq persistence adapter (kahaDB)
  • CXF – proxy – an apache camel compoent http://cxf.apache.org/
  • exception handling is important – the solution might not funtion as you expect
  • loC – spring and bluespring (can be deployed in same environment with OSGi)
  • ESB – layer under which you can implement routing and integration (in opensource Karaf and Servicemix)
  • clustering – proxy cluster (servicemix node1/2) logic cluster (smx node3/4/5)


Leverage Enterprise Integration Patterns with Apache Camel and Twitter (Bruno Borges)

  • enterprise integration patterns
  • apache camel: components, endpoints, routes, exchanges and messages, consumers, producers and processors
  • camel components – jms, http, mina, jdbc, ftp, webservices, ejb, jpa, hibernate, IRC, JRC, AS/400, LDAP, Mail, Nagios, POP, Printers, Quartz, restlet, RMI, RSS, scalate, XMPP
  • Camel integrates with CDI – camelcontext can be started with EJB3’s @startup and @singleton
  • twitter – Social media metrics (reading and processing all that data) –
  • social data, it’s not info overload. its a filter failure.
  • camel twitter and then camel social (uri format social://)
  • camel twitter implementation http://ec2-23-22-228-12.compute-1.amazonaws.com:8080/
  • twitter feed into camel stream video through web socket (real time pulling, too many porn on twitter orz)
  • demo
  • connects to search streaming channel
  • convert POJO to JSON (marshal)
  • coherence
  • camel vs spring (camel wins out because it’s been here for years)




Day 5


Building WebSocket Applications with GlassFish and Grizzly Stephen Millidge – Director, C2B2 CONSULTING LIMITED
  • agenda – intro to web sockets and push, websockets in glassflish (basic echo server, pushing stock prices to the browser), intro to data grids, code walkthrough (hooking up to a data grid)
  • typical http problem ( request-response protocol, it’s half-duplex, stateless – lots of redundant data, new connection required for each transaction)
  • push to browser
  • simaluted push – polling: regular requests at a set internal, near real-time, server events may occuur between requests
  • simulated push – long polling : connection is kept open, response is blocked until event happens
  • HTTP streaming – long lived http connection, or XMLHttpRequest connection, browser needs to close and reconnect the streaming channel to release memory (expensive as well)
  • Reverse AJAX/Comet (poor scalability), utlizes long polling or http streaming techniques, complex development
  • Web Sockets is the answer – html5, enables full duplex, allows web servers to push updates to browsers
  • web sockets is not mature yet, rfc 6455, wc3 SSE http://dev.w3.org/html5/eventsource http://dev.w3.org/html5/websockets
    • benefits of web sockets – reduced latency, netowkr traffic, server side cpu/memory; simplified development, scalable
    • supports IE9, chrome, firefox
    • web socket protocol – based on http, connection header, chat/superchat (security)
    • web sockets RFC – on top of TCP
    • adds web origin based security model
    • adds an addressing and protocol naming o support multiple services on one port and multiple host names on one ip
    • layers a framing mechanism on top of tcp to get back to the ip packet machanism that tcp is built on but no length limit
    • JavaScript API – websocket(location,protocol), function onmessage, function onopen, function onclose, function onerror, close(), send(data)
  • WebSockets in GlassFish (3.1.2) – grizzly 1.9, JDK 1.6, NetBeans IDE 7.0.1
  • enable web socket support in glassfish
  • grizzly key classes – websocket engine (singleton), websocket app, websocketx3 – just three classes
  • App – very siimple echo server
  • echo classes, echo servlet
  • create a echo project -> create the echo servlet, create an echo application (java class)
  • echo application extends WebSocketApplication
  • WebSocketEngine – http://grizzly.java.net/nonav/docs/2.0/apidocs/org/glassfish/grizzly/websockets/WebSocketEngine.html
  • websockets with HTTPS: WSS http://en.wikipedia.org/wiki/WebSocket
  • small jsp app to connect, disconnect send – websocket app
  • ##################################################################
  • extend the push – echo.jsp – pushSocket/echoServlet
  • new class PushSocket extends DefaultWebSocket
  • Data Grids – real time push at scale
  • JCache standard api for caches (JSR 107 coming in JEE7) – in memory caching
  • HA cache partitioning
  • Grid events sbusystem (cache listener)
  • coherence event listeners – classes MapEvent, ,MapListener, each time change takes place, raised to MapEvent
  • JSR 107 API
  • stock ticker architecture  – glassfish (cache), StockTicker App push change in the Cache
  • best practices -> load balancer–> J2E cluster–> data grid cache (oracle coherence in demo, infinispan, solutions)
  • Stock icker Classes – stock socket, application, servlet, ticker, stock –> websocket
  • stock – pojo
  • stock ticker – class
  • stock servlet
  • stock application – createwebsock, call stock, push to websocket
  • stock socket – cache, connect to mapListender, sendUpdate to MapEvent, change to JSON object to send it to websocket
  • real time dashboard = html5+websocket+grizzly+data grid run on glassfish
  • summary – reduced latency, network traffic and cpu/memory on server, highly scalable, when linked to a data grid, provie enterprise scale, event driven, real time push
How to Connect Java Embedded to Cloud Computing Hinkmond Wong – Consulting Member of Technical Staff, Oracle
  • Cloud computing – use of computing resources (hw, sw, peripherals) that are deliverd as a service over a network
  • Software as a service – gmail
  • PaaS –
  • Storage as a service
  • cloud compueting for embedded devices – use of mbedded device resources that are delivered as a service over netowrk, embedded device services (becomes a mini-server) – device as a service, concentrator (collection of devices) as a Service
  • ARM as concentrator http://en.wikipedia.org/wiki/ARM_architecture
  • typical cloud computing, one control and entry point, no need to install software on each client, workload shifted to network of computers
  • pro – easier to install, easier to manage and access
  • con – dependent on network, data on network systems, crash leads to serious impact
  • embedded cloud computing – one contorl (concentrator device, no need to install software on each client, workload shifted to network of devices
  • pro – same as typical “big” cloud computing
  • con – same as typical “big” cloud computing
  • spectrum of java (picture below)
  • Java SE Embedded – small footprint, larget commercial/industrial, full java 1.6 API, fixed location assets
  • Java ME embedded – smaller footprint, mobile devices, install base in the billions, dominates the feature phone market
  • Java Card – smallest footprint, M2M networks, install base nearing 10 billion, cyber-physical systems
  • intro to Java Embedded
  • java SE – fully implements Java SE spects, significant memory optimizations, smaller persistent (ROM/disk) and volatile (RAM), runtime optimizations
  • what features are needed enabling cloud computing on devices
  • ports avaiable for typical embedded cpus (arm, mips, powerpc)
  • support for “small” profiles – 10mb static footprint headless, 16mb dynamic footprint headless
  • will not inlcude many VM feautres – only include serial GC, only include C1 client JIT
  • will also support a large full featured config
  • techniques to connect with cloud –
  • device as the client
  • device as the cloud service – devices are the producers of cloud services, need more advanced web service framework (servlets, XML formating, database, web service framework), ofeers data to the cloud
  • developing for cloud computing – embedded devices, sammler memory and lower powered CPUs, wirelessly networked, headless or small screens, limited input (touchscreen or keypad)
  • developing for cloud computing – provision a serviice (as glassfish WAR bundles), provide subscription model (jersey web service), add/authenticate users and enable content (Java DB), operate monitor, configure, upgrade and diagnose (glassfish), flexible deployment (WAR bundles)
  • big data – JavaDB can be used as local storage and analytics instead of transmitting it out over wireless immediately
  • typical deployment – concentrator (JES 7.0), Java DB as database storage, device running java
  • jersey web service as the web interface – convience way to present as a RESTful web services
  • Grizzly implement
  • http://beagleboard.org/ – good for prototype
  • use netbeans as IDE
Powerful Analytics Apps Fueled by Java for High Performance and Scalability – Amit Rustagi – Principal Architect, eBay
  • # of users
  • # of servers and db instances
  • tech – oracle, hadoop
  • analytics 101 – data storage(structured/unstructed, data processing(mapredue framework), data access, management (workflow, suport, co-ordination) and BI (data mining, reporting, analytics)
  • analytics 101 – acquire, organize (data processing), anayze (access and manaement), decide (BI)
  • missing layer?!
  • tracking – track the path of user entering into ebay through different channel (affiliates, direct traffic, marketing emails, site emails, portals, social media, paid search, nature search) – marketing emails are sent by ebay, site emails
  • experimentation –
  • users go to the site,
  • experimentation platform(EP) identifies the user,
  • EP determines what treatment should be served based on user profile and experiments that are live in the EP system (persistent cookie)
  • applications serve the correct experience to the user based on the treatment selected by EP.
  • user experience is logged for analysis
  • personalization – share and leverage combined personalization data – ebay does see an opportunity to provide more custom info to customers through rea-time personalization by using dynamic site and apps to delivery targted content. Personalization filters out the noise consumers, helping them avoid info overload. highly targeted info!!
  • challenges – capturing the most important data as it happens (real-time), scalability, performance, cost effectiveness
  • data capture challenges – real-time data capture, collecting and quality data, accelerating the availability of data to consumers
  • performance challenges – consistent SLAs, redundant processing, when to process
  • solution
  • holistic view of the system
  • best practices – sometimes it’s appropriate to have exactly one instance of a class (singleton pattern) – typically those types of objects are accessed by disparate objects throughout a software system and therefore require a global point of access
  • best practices – decouple sender and receiver of a request by interposing a chain of objects between them
  • best practices – command design pattern. substitute a proxy for an object. letting app framework make requests of app-specific objects, without the framework knowing the objects
  • best practices – reduce the number of objects your apps create, which decreases your app’s memory footprint and increases performance –) simplify complex APIs by providing a simplified interface to a complex subsystem (FACADE)
  • things to consider:
    • breaking down the system into components
    • isolate those that could occur async
    • web services decomposition
    • evaluate the services for local and remote binding
    • always pool valuable system resources like threads, db connections and socket connections
    • optimize your I/O ops (caching) by using buffering when writing to and reading from files and/or streams
    • minimize network overheads by retrieving several related items simultaneously in one remote invocation if possible
    • evaluate single threaded and multi threaded before decide (misconception – multi thread runs faster?!)
    • serialization/deserialization
    • CPU profiling
    • memory profiling http://www.quest.com/jprobe/
  • local java binding sampel – request handler (info context exchange)–>request/response adapter <–>service with local java binding
  • ebay uses CI – continuous builds (jenkins)
################### additional notes ############################
  1. http://en.wikipedia.org/wiki/JavaServer_Faces
  2. oracle coherence http://en.wikipedia.org/wiki/Oracle_Coherence
  3. http://en.wikipedia.org/wiki/ARM_architecture
  4. http://en.wikipedia.org/wiki/List_of_JVM_languages
  5. http://openjdk.java.net/projects/lambda/
  6. http://www.raspberrypi.org/
  7. http://beagleboard.org/
















site planning www.njfcs.org with AWS

potential functionalities

  • ads – revenue generator
  • monitor and alert solutions
  • address work – hard copy address book could be replaced by online inventory
  • site building blog (separate journal site)
  • dedicated email box
  • lunch order
  • homework submission
  • teacher’s page
  • department’s page
  • club’s page
  • yearly book
  • address book
  • content translator (google or bing API)
  • favicon
  • SEO
  • comment/feedback (facebook)
  • site stats
  • discussion board
  • video/photo
  • friendly/vanity URL for static pages
  • file management (ftp, webdav, http)
  • google analytics visit
  • scheduled post publishing
  • file sharing and version control (including yearly performance media files)
  • scheduled post expiration
  • email alias migration
  • mysql database backup
  • dedicated mailboxes for staff
  • secured password archive solution

business tool for school

  • accounting?
  • educational?
  • 總務



  • annual domain registration $12.95  ($6.99 godaddy.com as of 9/21/2012)
  • annual hosting service  $356.40 ($48 justhost.com as of 9/12/2012) – justhost coupon code 50OFF
  • Gwo-Ming out of pocket $?? (ec2 http://aws.amazon.com/pricing/ec2/)

cost forecast and comparison



current proposed
vendor cost vendor cost vendor
njfcs.org domain registration $12.95 eapps $6.99 godaddy.com
http://www.njfcs.org hosting $356.40 eapps $0 dreamhost non-profit org discount
registration site $200 Gwo-Ming $168 amazon ec2
mail service $120  1&1 $10 amazon ses
 phone number $8.95 $0 google voice


  • Separate domain name registration from hosting service give us the flexibility to move to another vendor at any time
  • I’ve subscribed amazon ec2 with njfcs1944@gmail.com with my own contact and credit card info – will have to be updated with school’s info; I’ve kept setup and config notes at http://derekchang.me/ec2-for-fcs/
  • Once you and staff confirm, I will go ahead to subscribe to justhost with a 2-year term ($2.48/month) so that we can proceed with implementing new services – will have to be updated with school’s info
  • Once 3 is done, webmaster team can start building new site but first step is to secure mysql backup and the file sharing services
  • eapps is dedicated host while justhost is shared virtual host and ec2 is virtual machine built upon xen framework – there are pros and cons for each them but new solutions will be more economic


EC2 pricing chart


1 year 3 year
medium windows micro =0.013*24*365+54 167.88 =0.013*24*365*3+82 423.64
light windows micro =0.018*24*365+23 180.68 =0.018*24*365*3+35 508.04
medium linux micro =0.007*24*365+54 115.32 =0.007*24*365*3+82 265.96
light linux micro =0.012*24*365+23 128.12 =0.012*24*365*3+35 350.36



currently on http://www.njfcs.org


Home 首頁 New URL
Hour/Location 上課時間/地點 http://njfcs.yuhsunn.com/contact2/
Calendar 行事曆 http://njfcs.yuhsunn.com/events/
About Us 關於維德
Announcements 公佈事項
Curriculum 教學事宜
PA Activities 家長會活動
Forms 各式表格
Policy 校務守則
Board Meetings 學校會議
Alumni 校友會
Registration 學生註冊 http://register.njfcs.org 
Account Update 資料更新
Help 需要幫助
In the Press 相關報導
Useful Links 相關網站
Contact Us 聯絡維德

wordpress on AWS EC2 in 5 minutes

Setup AWS EC2 Instance

  1. sign up for amazon ec2 – http://aws.amazon.com/ec2/
  2. go to AWS management console https://console.aws.amazon.com/console/home
  1. Choose EC2 from AWS management console
  2. Click on Launch Instance
  3. Choose Classic Wizard and hit Continue
  4. Select Amazon Linux AMI (there are several other options)
  5. Choose Micro (t1 micro, 163 MiB) which is the free tier EC2
  6. Make sure you enter a short description for “User Data”
  7. Review the details on the next page and hit Continue
  8. Make sure you enter something for the Tag
  9. Create a new key pair for authentication
  10. create a new security group and make sure general ports such as 22(SSH), 80(HTTP), 443(HTTPS) and 8080(TOMCAT) are open
  11. hit “Launch” and you’re done with setting up an EC2 instance
  12. Create an Elastic IP (EIP) – select EIP used in “EC2”
  13. Associate the EIP to the EC2 instance that you just launched
  14. connect to the instance as “ec2-user” There are couple ways to do so from management console, simply right click on the instance and choose “connect”
    • or you can simply use SSH client like putty. Make sure you convert PEM file to PPK which is supported by putty

Apache, MySQL and PHP

  1. install packages you need with yum
    • yum install mlocate
    • yum install httpd24
    • yum install php54
    • yum install php54-mysql
    • yum install php54-gd (php GD graphic library)
    • yum install mysql-server
  2. Start services and ensure apache and mysql run when ec2 is booted
    • service httpd start
    • service mysqld start
    • chkconfig httpd on
    • chkconfig mysqld on
  3. Now you have a LAMP stack

Linux Configuration

  1. create new user and disable ec2-user access
  2. as root
    • adduser newuser
  3. su – newuser
  4. as newuser
    • mkdir .ssh
    • chmod 700 .ssh
    • touch .ssh/authorized_keys
    • chmod 600 .ssh/authorized_keys
    • vim .ssh/authorized_keys (add public key here)
  5. as root
    • visudo
    • newuser ALL=(ALL) NOPASSWD:ALL
    • disable ec2-user as sudoers /etc/sudoer.d/cloud-init
    • disable ec2-user login /etc/passwd
    • ec2-user:x:500:500:EC2 Default User:/home/ec2-user:/bin/bash
    • ec2-user:x:500:500:EC2 Default User:/home/ec2-user:/sbin/nologin
  6. setup ssh-agent forwarding if you plan to connect from your ec2 instance to another

WordPress setup

  1. Download and extract wordpress
  2. Create mysql database
    • # mysqladmin -uroot create blog
    • # mysql_secure_installation
      • Set root password? [Y/n] y
      • Remove anonymous users? [Y/n] y
      • Disallow root login remotely? [Y/n] n
      • Remove test database and access to it? [Y/n] y
      • Reload privilege tables now? [Y/n] y
  3. Configure wordpress
    • # cd /var/www/html
    • # mv wp-config-sample.php wp-config.php
    • # vi wp-config.php
      • define(‘DB_NAME’, ‘blog’);
        define(‘DB_USER’, ‘root’);
        define(‘DB_PASSWORD’, ‘YOUPASSWORD‘);
        define(‘DB_HOST’, ‘localhost’);
  4. Install wordpress from browser http://YOUR_ELASTIC_IP (which will be redirected to http://YOUR_ELASTIC_IP/wp-admin/install.php
  5. To enable permlinks, be sure to modify /etc/httpd/conf/httpd.conf and enable override option:
    •     AllowOverride All
    • sample .htaccess for wordpress:
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ – [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
  1. Optional step: Point your domain name to the EC2. For example I am a godaddy subscriber. what I need to do is simply pointing “A” record to the elastic IP
  1. ALL SET!!

WordPress 中文化

  • 通過 FTP、SSH 等方式打开并编辑站点根目录下的 wp-config.php
  • 查找 define('WPLANG', ''); 一行,在第二个参数处填入 zh_TW,变成 define('WPLANG', 'zh_TW'); 并保存文件
  • 进入站点控制板(dashboard),看到更新提示后进行升级即可。WordPress 会自动从官方网站下载中文语言包并安装
  • 多語言版下載 http://codex.wordpress.org/WordPress_in_Your_Language

MySQL worklog

  1. get default root password at /root/.mysql_secret
  2. mysql -u root -p
  3. mysql> CREATE USER 'wordpress-user'@'localhost' IDENTIFIED BY 'your_strong_password';
  4. enable root remote access
  5. install mysql
  6. install phpMyAdmin
  7. execute examples/create_tables.sql – it will create a database called phpmyadmin
  8. create a pm user and give access to phpmyadmin db.
  9. enable advanced features in config.inc.php
  10. make sure PHP MySQL library coincides with mysql server version.
  11. make sure following extensions are enabled:
  • mbstring (yum install php53-mbstring –nogpgcheck)
  • mcrypt (yum install php53-mcrypt –nogpgcheck)
  • restart apache

WordPress on Https

  • use following in wp-config.php

define(‘FORCE_SSL_ADMIN’, true);

  • setup site monitor https://uptimerobot.com/
  • run SSL test at https://www.ssllabs.com/ssltest/analyze.html?d=www.steamedbun.xyz

Enable SSL on Apache

  1. create CSR. use https://csrgenerator.com/ or http://www.thegeekstuff.com/2009/07/linux-apache-mod-ssl-generate-key-csr-crt-file/
  2. setup apache – http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/SSL-on-an-instance.html#ssl_enable
  3. https://guillaumemaka.com/2015/05/06/install-your-comodo-certificates-to-amazon-aws.html


SSLCertificateFile /etc/pki/tls/certs/www_steamedbun_xyz.crt

SSLCertificateKeyFile /etc/pki/tls/private/www_steamedbun_xyz.key

cp /home/ec2-user/www_steamedbun_xyz.key /etc/pki/tls/private/

cp /home/ec2-user/www_steamedbun_xyz.crt /etc/pki/tls/certs/

chown root:root /etc/pki/tls/private/www_steamedbun_xyz.key /etc/pki/tls/certs/www_steamedbun_xyz.crt

chmod 600 /etc/pki/tls/private/www_steamedbun_xyz.key /etc/pki/tls/certs/www_steamedbun_xyz.crt

If prompted for ftp login when trying to update wordpress:

  • put following in wp-config.php

define(‘FS_METHOD’, ‘direct’);

Upload file size limit


upload_max_filesize = 10M
post_max_size = 10M


Enable dashboard theme-editor

in wp-config.php

define(‘DISALLOW_FILE_EDIT’, true);

Linux Related

set timezone


PHP 7 Installation on CentOS6.9


rpm -Uvh https://dl.fedoraproject.org/pub/epel/epel-release-latest-6.noarch.rpm
rpm -Uvh https://mirror.webtatic.com/yum/el6/latest.rpm
yum install php70w php70w-opcache

MySQL 57

  1. find the temp root password in mysqld.log
  2. execute ‘mysql_secure_installation‘ to f


  1. https://premium.wpmudev.org/blog/set-up-wordpress-like-a-pro 
  2. http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/managing-users.html
  3. https://serverfault.com/questions/599357/how-does-amazon-ec2-user-get-its-sudo-rights
  4. http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-key-pairs.html#retrieving-the-public-key
  5. https://hashnode.com/post/users-and-ssh-setup-on-aws-ec2-best-practices-cj4bd8wpi0063zmk9mkivpoyu
  6. SSH forwarding http://www.unixwiz.net/techtips/ssh-agent-forwarding.html#fwd
    1. https://www.digitalocean.com/community/tutorials/how-to-use-pageant-to-streamline-ssh-key-authentication-with-putty


opencart notes

Site implemented


Steps to setup

  1. create subdomain
  2. opencart http://www.opencart.com/
  3. google vqmod for opencart http://code.google.com/p/vqmod/
  4. 中文包 安裝 http://www.opencart.com/index.php?route=extension/extension/info&extension_id=2483
  5. vqmod add more (tweet, google+ facebook; no plurk)
  6. vqmod manufacturer top navigation http://www.opencart.com/index.php?route=extension/extension/info&extension_id=3633 (中文化needs to be addressed)
  7. vqmod view product in admin http://www.opencart.com/index.php?route=extension/extension/info&extension_id=5838
  8. vqmod negative price to contact us button http://www.opencart.com/index.php?route=extension/extension/info&extension_id=5295
  9. vqmod category filter http://www.opencart.com/index.php?route=extension/extension/info&extension_id=2663
  10. vqmod facebook comment http://www.opencart.com/index.php?route=extension/extension/info&extension_id=6026
  11. vqmod admin email format http://www.opencart.com/index.php?route=extension/extension/info&extension_id=4137
  12. city (區) selection module – http://www.opencart.com/index.php?route=extension/extension/info&extension_id=4372
  13. google map and corresponding module configuration
  14. US date format http://www.opencart.com/index.php?route=extension/extension/info&extension_id=4504
  15. import/export tool http://www.opencart.com/index.php?route=extension/extension/info&extension_id=17
  16. 測試
  17. 語系設定
  18. address format configuration http://opencart-hk.blogspot.com/2012/02/translatecountry.html
  19. 貨幣設定
  20. mail setting to notify admin upon registration and order placed
  21. test shopper registration and email notifcation
  22. 收費方式設定
  23. 運送方式設定
  24. 現金回饋/gift certificate and coupon.
  25. backup
  26. update current store listing
  27. enable google analytics
  28. opencart SEO URL
  29. site/product meta tag key words and description
  30. google sitemap generator http://www.opencart.com/index.php?route=extension/extension/info&extension_id=5985
  31. enable google sitemap
  32. submit sitemap to google
  33. facebook OC plugin http://www.opencart.com/index.php?route=extension/extension/info&extension_id=6015

Ajax quick edit (plugin) – Chinese encoding fix


in tableditajax.php
header('Content-Type: text/html;charset=utf8');
 $bd = mysql_connect(DB_HOSTNAME, DB_USERNAME, DB_PASSWORD) or die("Could not connect database");
mysql_select_db(DB_DATABASE, $bd) or die("Could not select database");
$sql = "update ". DB_PREFIX ."product_description set name='$name' where product_id='$id'";
mysql_query('SET NAMES "utf8"');
$sql = "update ". DB_PREFIX ."product set model='$model' , price='$price' , quantity='$quantity' , sort_order='$sort_order' where product_id='$id'";

Theme modification

powered by content – /catalog/language/zh-HK/common/footer.php

powered by alignment – /catalog/view/theme/default/stylesheet/stylesheet.css


#powered {
margin-top: 5px;
text-align: left;
clear: both;

Shipping Module & Customization

  1. admin\controller\shipping\flat.php
  2. admin\language\zh-HK\shipping\flat.php – change text
  3. admin\view\template\shipping\flat.tpl – change image path
  4. catalog\language\zh-HK\shipping\flat.php – change text
  5. catalog\model\shipping\flat.php
  6. admin\view\image\711.gif
  7. text on register page
  8. order of fields on register page
  9. 國家設置 – disable all other countries except Taiwan via SQL
use pnc_blmojhnenc;
select * from oc_country;
UPDATE oc_country SET status = 0 WHERE country_id <> 206;



Opencart setup in 20 minutes

  1. install opencart (
  2. install following packages
    • google map
    • facebook comment
    • social
    • chat
    • keepalive admin
    • import/export
  3. setting up zh_TW language
  4. replace US$ to NT$ (TWD)
  5. edit store setting
    • store description
    • store name
    • owner
    • address
    • telephone number
    • fax number
    • email
    • location
    • default language
    • default currency
  6. disable all countries- UPDATE oc_country SET status = 0 WHERE country_id <> 206
  7. set zone setting – convert all english zone names to zh_TW
  8. remove  稅率類別from 商品稅類
  9. covert 區域群組


## remove 台中縣 台南縣 高雄縣


DELETE FROM oc_zone WHERE country_id =206 AND code IN (‘KH’,’TA’,’TG’);
## 中文名字
update oc_zone set name=’彰化縣’ where code=’CH’ and country_id=206;
update oc_zone set name=’嘉義縣’ where code=’CI’ and country_id=206;
update oc_zone set name=’新竹縣’ where code=’HS’ and country_id=206;
update oc_zone set name=’花蓮縣’ where code=’HL’ and country_id=206;
update oc_zone set name=’宜蘭縣’ where code=’IL’ and country_id=206;
update oc_zone set name=’金門縣’ where code=’KM’ and country_id=206;
update oc_zone set name=’連江縣’ where code=’LC’ and country_id=206;
update oc_zone set name=’苗栗縣’ where code=’ML’ and country_id=206;
update oc_zone set name=’南投縣’ where code=’NT’ and country_id=206;
update oc_zone set name=’澎湖縣’ where code=’PH’ and country_id=206;
update oc_zone set name=’屏東縣’ where code=’PT’ and country_id=206;
update oc_zone set name=’新北市’ where code=’TC’ and country_id=206;
update oc_zone set name=’台東縣’ where code=’TT’ and country_id=206;
update oc_zone set name=’桃園縣’ where code=’TY’ and country_id=206;
update oc_zone set name=’雲林縣’ where code=’CC’ and country_id=206;
update oc_zone set name=’嘉義市’ where code=’YL’ and country_id=206;
update oc_zone set name=’基隆市’ where code=’CL’ and country_id=206;
update oc_zone set name=’新竹市’ where code=’HC’ and country_id=206;
update oc_zone set name=’台中市’ where code=’TH’ and country_id=206;
update oc_zone set name=’台南市’ where code=’TN’ and country_id=206;
update oc_zone set name=’高雄市’ where code=’KC’ and country_id=206;
update oc_zone set name=’台北市’ where code=’TP’ and country_id=206;

sendy customization


  • change database to utf8_general_ci
  • change following fields to utf8_general_ci – name, plain_text, html_text
  • change following campaigns table and “title” field (aka subject)  to utf8_general_ci (chinese character encoding in the subject)




◆Lover 情人(不是:愛人)
◆Sporting house 妓院(不是:體育室)
◆Dead president 美鈔(不是:死了的總統)
◆Service station 加油站(不是:服務站)
◆Rest room 廁所(不是:休息室)
◆Busboy 餐館勤雜工(不是:公汽售票員)
◆Dry goods <美>紡織品 <英>穀物(不是:乾貨)
◆Heart man 換心人(不是:有心人)
◆Tea shop 茶館;小吃店(不是:茶葉店)
◆Senior citizen 老年人(不是:高級公民)
◆Wash one’s hands 上廁所(不是:洗手)
◆A busy body 愛管閒事的人(不是:忙人)
◆A black sheep 害群之馬(不是:一隻黑羊)
◆Be taken in 受騙,上當(不是:被接納)
◆Pull sb’s leg 開玩笑(不是:拖後腿)
◆African American 美國黑人(不是:非洲美國人)
◆Eat one’s words 收回前言,改正錯話(不是:食言)
◆Mad doctor 精神病科醫生(不是:發瘋的醫生)
◆Eleventh hour 最後時刻(不是:十一點)
◆Personal remark 人身攻擊(並非個人評論)
◆Sweet water 淡水(不是:糖水或者甜水)
◆Confidence man 騙子(不是:信得過的人)
◆Criminal lawyer 刑事律師(不是:犯罪的律師)
◆Dressing room 化粧室(不是:試衣間或者更衣室)
◆Horse sense 常識(不是:馬的感覺)
◆Capital idea 好主意(不是:資本主義思想)
◆Familiar talk 庸俗的交談(不是:熟悉的談話)
◆Black tea紅茶 (不是:黑茶)
◆Green hand 新手 (不是:綠手)
◆Have a fit 勃然大怒(不是:試穿)
◆Black art 妖術(不是:黑色藝術)
◆White coal (作動力來源用的)水
◆Chinese dragon 麒麟(不是:中國龍)
◆Red tape 官僚習氣(不是:紅色帶子)
◆China policy 對華政策(不是:中華政策)
◆White man 忠實可靠的人(不是:皮膚白色的人)
◆Black stranger 完全陌生的人(不是:陌生的黑人)
◆Eat ones words 收回前言(不是:食言)
◆An apple of love 番茄(不是:愛情之果)
◆Handwriting on the wall 不祥之兆(不是:大字報)
◆Bring down the house 博得滿堂喝彩(不是:推倒房子)
◆Blind date(由第三者安排的)男女初次見面(並非盲目的約會或者是瞎
◆Roadside business 汽車飯店;汽車旅館;汽車影院(不是:路邊店 )
◆American Dream 美國的生活方式,美國人的自由民主觀念(不是:美國夢)
◆Yellow book 黃皮書(法國政府報告書,以黃紙為封,不是:黃色書籍)
◆Blue stocking 女學者,女才子(不是:藍色長筒襪)
◆American beauty 一種玫瑰,名叫美麗動人(不是:美國美女)
◆English disease 軟骨病(不是:英國病)
◆Indian summer 愉快寧靜的晚年(不是:印度的夏日)
◆Greek gift 害人的禮品(不是:希臘的禮物)
◆Spanish athlete 吹牛的人(不是:西班牙的運動員)
◆French chalk 滑石粉(不是:法國粉筆)
◆In ones birthday suit 赤身裸體(不是:穿著生日禮服)
◆Make ones hair stand on end 令人毛骨悚然,恐懼(不是:令人髮指,氣憤)
◆Think a great deal of oneself 高看或者看重自己(不是:為自己想的很多)
◆Pull up ones socks 鼓起勇氣(不是:提上襪子)
◆Have the heart to do 用於否定句,忍心做(不是:有心做或者有意做)
◆What a shame 多可惜,真遺憾(不是:多可恥)
◆You don’t say 是嗎?(不是:你別說)
◆You can say that again 說的好(不是:你別說)
◆I haven’t slept better 我睡得很好(不是:我從未睡好過)


199x – 2012

  1. background
    • born in taiwan
    • served in army as constrution engineer/also supports network and backup infrastructure – 1996-98 – retired as sergeant first class
    • studied in USC 1999-2003
    • first job in AT&T lab in 2002 while in school
    • second second with WebMD since September 2004
    • fluent in english and mandarin
    • annual presentation in conferences HP, serena and velocity (web performance) since 2010
  2. current development projects (enterprise software prototyping, continuous integration and technology challenges)
    • continuous integration
      •  8-people task force – manager and director level across QA/PMO/OPS/Dev
      • different roles, PM, architect and technology lead
      • streamline and automate  build delivery/deployment process
      • expect to speed up product delivery pipeline by 60% and reduce communication overhead by 40%
      • currently in purchasing phase – SOW/SLA
    • business dashboard – BI team and business
      • tibco spotfire as analysis/graph engine
      • critical data sources – appfigure, itunes, google, internal personalization database (registration/news letter) and adobe omniture
      • adapters written in java
      • on display in major offices – NYC1/3, ATL and PORTLAND
    • technology intelligence dashboard
    • high impact performance degradation
      • architecture review
      • system/product reliability/performance optimization
  3. management principles
  4. technologies – php/java/unix/database (mysql, oracle/ms sql)


feedback questions

  • do you think i will be a good candidate for bridgewater associates? if not, how do i improve
  • i read about some negative feedback from bridgewater. can you share with me what your experience is with brigewater?


mistake i make (technology-related or management-related?)


process simplification

  • study current process
  • research other unsuccessful cases to avoid making the same/old mistakes
  • design new solution
  • test, test, and test
  • take challenge by smart people



  1. SDLC efficiency
  2. code analysis – static (model checking and data-flow analysis) and dynamic (how code behaves)
  3. nightly load testing in prod – history replay
  4. no full GC during the week. barely multi-threading, simple coding

metrics analysis and dashboard development

  • employee dashboard – interesting metrics such as page views visits, registrations, user logins
  • tech dashboard –
  • marketing dashboard
  • metrics correlation

incident analysis about critical outages and performance degradation

  • indepth troubleshooting and resolution
  • espeically architecture and platform

Agile and continuous integration task force

  • cross functional team consist of 12 members, directos, architects across dev/ops/sysadmin/qa/pmo
  • new solution implementation
  • simplify, standardize and automate SDLC process

new technology/solution – research and evaluation


  1. senior director
  2. 3 architects
    • reliability/performance engineering
    • CI (dev/ops/qa group of 15) and SDLC efficiency
    • tools and standards
    • metrics: KPI, depth of ‘purepath’; benchmark and metrics standard. SLA. definition of ‘good’
    • ad-hoc troubleshooting.
    • dashboard development
  3. attend conferences about tools/operations/performance – one presentation/year since 2010
  4. voluntary works – vice principal and IT director
    • java to php
    • from self and expesnive hosting to AWS
  5. vintage audio hobbyist

Troubleshooting Procedures

Collect background information

  • Scope of impact
  • Information about the product(s) impacted
  • Interview personnel involved

Initial interpretation

  • Type of incident – outage, service degradation
  • Expectation from senior management
  • Depth and scope of investigation
  • Resource planning

In-depth analysis

  • Timeline analysis
  • Change analysis
  • Log analysis
  • Monitoring data correlation


  • Vendor documentation and white paper
  • Architecture review
  • Code review and application profiling
  • Infrastructure review

Resolution and recommendation

  • process
  • design and architecture
  • infrastructure

use case – cnn slowness

  1. ping test/traceroute of cnn.com
  2. browsers add-ons and plugins
  3. state of PC – i/o, cpu and memory consumption
  4. router issue
  5. cable modem issue

Velocity 2013 Proposal (not accepted)

Proposal: “From hours to minutes – application deployment automation in WebMD

Submitter: Derek Chang (dchang@webmd.net)


Rajeev Borborah (rborborah@webmd.net)
Derek Chang (dchang@webmd.net)


Application deployment has been considered a bottleneck in our SDLC pipeline. In this talk we will share our story about achieving deployment automation in WebMD: from case studies, identifying requirements, process simplification and standardization, tool evaluation/selection to implementation. We’ll finish with a live demo – how we use the automation system to promote the code across SDLC.

Session type: 40-minute session
Topics: Operations


WebMD started a CI (Continuous Integration) initiative back in October 2011 to deal with the excessive demand for application deployment as a result of:

  • Increasing number of applications supported
  • Diversity of the infrastructure
  • Majority of release pipelines adopt agile approach

This presentation is meant to help organizations like us to prepare and deal with challenges by sharing our complete story with them.

  1. History lesson – how deployment process evolves in WebMD; from ‘cvs -d’ to python scripts, big name deployment tool to what we have today
  2. What we are facing – diversity of infrastructure, number of applications/agile approach which yields high demand for application deployment, configuration management, complexity of deployment procedures
  3. Case studies – deployment procedures as of 2012 and corresponding time analysis and maintenance cost
  4. CI (Continuous Integration) team in WebMD – how we organize a cross-functional task force
  5. Leadership and guidelines How we deal with politics and meet everyone’s need including QA, Dev, Ops, and PMO
  6. Requirement collection – identify features that we need the most: Cost efficiency, configuration management, fail fast, repeatability, Orchestration, Usability, Integration
  7. Vendor selection and evaluation – how do we choose from 20+ potential candidates
  8. Process Standardization and simplification
  9. Culture change and Collaboration – how Dev/Ops/QA team up to implement the system we have today
  10. Before and after comparison – quantify how much we improve
  11. challenges and resolutions – same challenges that YOU might have and how we deal with it
  12. Demo – how we use the automation system to promote the code across SDLC
  13. Q/A


ideas for HSNU Alumni site

key functionality

  • registration and user database
  • forum
  • blog
  • Hu’s blog
  • yearly graduation preparation and communication
  • photo album
  • historical records for annual graduation
  • FB integration
  • FB app_id and unique identifier
  • SSL and security consideration
  • migrate and consolidate BBS content

sizing and scalability

  • Amazon Cloud/EC2/small instance as the hosting platform
  • 200 concurrent users
  • 60GB space


  • possible joint force with https://www.facebook.com/groups/HSNUalumni/
  • accounting/finance staff – hosting fee, domain name, extra storage and database
  • legal in chief
  • technology in chief
  • webmaster
  • forum master
  • content contributor
  • content moderator
  • data migration



Data Definition Language (DDL) statements are used to define the database structure or schema. Some examples:


  • CREATE – to create objects in the database
  • ALTER – alters the structure of the database
  • DROP – delete objects from the database
  • TRUNCATE – remove all records from a table, including all spaces allocated for the records are removed
  • COMMENT – add comments to the data dictionary
  • RENAME – rename an object



Data Manipulation Language (DML) statements are used for managing data within schema objects. Some examples:


  • SELECT – retrieve data from the a database
  • INSERT – insert data into a table
  • UPDATE – updates existing data within a table
  • DELETE – deletes all records from a table, the space for the records remain
  • MERGE – UPSERT operation (insert or update)
  • CALL – call a PL/SQL or Java subprogram
  • EXPLAIN PLAN – explain access path to data
  • LOCK TABLE – control concurrency



Data Control Language (DCL) statements. Some examples:


  • GRANT – gives user’s access privileges to database
  • REVOKE – withdraw access privileges given with the GRANT command



Transaction Control (TCL) statements are used to manage the changes made by DML statements. It allows statements to be grouped together into logical transactions.


  • COMMIT – save work done
  • SAVEPOINT – identify a point in a transaction to which you can later roll back
  • ROLLBACK – restore database to original since the last COMMIT
  • SET TRANSACTION – Change transaction options like isolation level and what rollback segment to use

Create a free website or blog at WordPress.com.

Up ↑