Categories
China iPhone app

WeChat is not banned, at least not yet

Reading Time: 2 minutes

(Update 09-20-2020) It looks like the 9th court temporarily blocked the WeChat ban. The TikTok ban became irrelevant because there is the new with Oracle / Walmart.

(Original 09-18-2020)

CNN: US will ban WeChat and TikTok downloads on Sunday. Quote: “The only real change as of Sunday night will be [TikTok users] won’t have access to improved apps, updated apps, upgraded apps or maintenance,” Commerce Secretary Wilbur Ross said Friday morning on Fox Business. || Also, quote: “The restrictions targeting WeChat are more extensive. Beginning Sunday, it will be illegal to host or transfer internet traffic associated with WeChat, the Department said in a release. The same will be true for TikTok as of Nov. 12, it said.” I don’t know if this part is doable (again not sure if it’s legal) in the US. Also this part seems contradicts with Wilbur Ross’s comments. Btw, Wilbur Ross made most of his money from coal industry (and coal miners’ pension or healthcare): this part is similar to how his boss got rich…

(Earlier) TechCrunch: Justice Department says WeChat users won’t be penalized under Trump’s executive order : the normal chat / group chat function will continue to work after Sunday September 20. It does seem impact the WeChat pay (financial transaction) as well as the App / Google Play store (workaround later). Also refer to this Ars Technica article.

The workaround for the App store is to change your country / region, for example, change from the US to Canada. You may create a new user if needed. One thing I found out is if I have app store credit on account, I cannot switch. This applies to TikTok users as well.

Workaround

  1. There are ways to download apps even if the apps are no longer available in the US App Store or Google Play Store. The trick is to pick another country / region in the store setting. There is a limit though: if you have balance (credit, money) in the App Store, you cannot switch (have to spend it first). In this case you may have to create another app store id solely for the purpose to download apps (for example, in addition to wechat, there are some other apps only available in China app store).
  2. If the administration decide to block the web traffic (app traffic is a part of web traffic, it’s usually at the http level). One may use VPN service to get around that. This is nothing new.
  3. There is also desktop app (Mac, Windows) and web app on WeChat web site. You may install the desktop app, or use the web app (essentially it’s like a website). Note WeChat still needs the phone app for sign in for those.

Here is a link to the US WeChat User Alliance. They are suing the US government for the unreasonable action (likely illegal as well).

Last but not least, this is mostly a last ditch effort from the current administration to save the re-election (this part if proven, it’s illegal too). Because, in the US the political campaign and governing are separate.

Categories
Fun Technology

Virtual Learning

Reading Time: < 1 minute

I normally use google calendar for kiddos’ Zoom meetings. My older daughter who is going to be FGC dragon knows get to Zoom via Google classroom. I can train her on the google calendar too. But now I am thinking I will take Monday off for the full time support of virtual learning (I feel I need a break from work too). || A bigger question though, this kind of management tool seems like new normal to all of us. In the past I used Google Calendar for all my personal appointments and all my kids activities, this includes my girl’s basketball (time, location), and my volunteer meeting at kids school etc. || Also, a side note, I have not looked into kiddos iPad yet, but I assume everything is setup including google classroom. But I prefer kids not to watching iPad whole day. So I setup bigger monitor with laptops (MacBooks) and webcams. I will need to provide some support for my 1st grader on this…

Categories
Software development Technology Web

API Gateway

Reading Time: < 1 minute

Kong

Kong is a cloud-native, fast, scalable, and distributed Microservice Abstraction Layer (also known as an API Gateway or API Middleware). Made available as an open-source project in 2015, its core values are high performance and extensibility.

Actively maintained, Kong is widely used in production at companies ranging from startups to Global 5000 as well as government organizations.

CA Layer 7 / API Gateway: was owned by CA Technology, formerly Computer Associates. Sold it to Broadcom the chip company in recent years. It used slightly older technology as Kong, apigee and Okta.

documentation:

architecture:

Categories
Java Software development Technology

Spring batch, Spring Scheduler, PCF

Reading Time: < 1 minute

Was experimenting running scheduled job on PCF. One natural choice is PCF scheduler, which comes with the Pivotal Web Services (PAAS). Googled around and found this example on DZone. The spring batch code is here. There was a small typo in the manifest.yaml,

path: build/libs/payment-processing-spring-batch-0.0.1-SNAPSHOT.jar
Note the snapshot.jar file name does not match what’s specified in the build.gradle file.

The correct file name is

spring-batch-job-0.0.1-SNAPSHOT.jar

The rest of the manifest.yml looks good, in fact I used the following options for my spring scheduler app manifest.

no-hostname: true
no-route: true
health-check-type: none

But PCF scheduler is not available in our environment. The Spring Scheduler is used instead. I followed this Get Started Guide from Spring. In my case I need to use Cron Expression, here is the code sample and here is the guide to cron expression.

Last but not least, in my case I need to send out email notification for the cron job conditionally. I used the java email code sample here.

======

Some PCF references

pivotal web serivce

cf login -a https://api.run.pivotal.io/

https://console.run.pivotal.io/tools

https://docs.pivotal.io/pcf-dev/index.html

cf login -a api.local.pcfdev.io --skip-ssl-validation

https://tanzu.vmware.com/tutorials/getting-started/local/deploy-the-sample-app

Categories
401k and Personal Finance

GCP Cloud Storage and PCF

Reading Time: < 1 minute

Tried two two tutorials on my personal GCP.

hello world


cloud storage (upload a file, then return a public url for download; another download link)

I may delete those bucket and files later on, as hosting costs money (app engine, cloud storage). Update: I disabled the app (here is one article talking about disable / delete app engine app). In simple term: I go to project, app engine, go to settings, click disable. Btw, I noticed all 73 cents charges for about 20 hours is from app engine.

From GCP Console Dashboard, I saw Resource

App Engine
2 versions
Storage
4 buckets

GCP Service Broker

For PCF, the approach above did not work (got an error on line 61 on the example above). I followed the steps for GCP service broker and pushed it to our pcf.

Virus Scan

Automating malware scanning for documents uploaded to Cloud Storage

PCF Sample App

It looks like with the VMWare Pivotal acquisition / integration, their hello world sample app website also moved. Here is the new link.

Categories
Software development Technology

How to generate a Lets encrypt SSL cert

Reading Time: < 1 minute

I followed the instruction here https://certbot.eff.org to get a free SSL cert for my website: (pretty cool, huh 🙂 (found it here)

To actually do it, I just go to the website: Scroll down a little, select the software and the system my website is running on, and it will generate all the command-lines for me, here is my link 🙂

There is one small glitch after the installation of ssl cert: that is in the wordpress, I need to set the home page from http to https

Also, an older post Move WordPress from Share Hosting to DigitalOcean

Earlier: I summarized it on twitter.

Categories
Software development Technology

Couple agile tools

Reading Time: < 1 minute

Point Poker: free (accepts donation). A nice pointing tool, click start session, for collaborators: put in name, and join the session.

Fun Retro: there are free and non-free choices. The free ones are public. It’s a bit like Trello. For that matter, if someone likes to keep it private, I think Trello is a good alternative: just put in swimming lanes such as liked, learned, lacked, longed for and action items

scrumpoker-online

Categories
Career Software development Technology

Job search advice amid COVID-19 pandemic

Reading Time: 5 minutes

We are at unprecedented times, in terms of the pandemic, and the economy aftermath. The IT software dev job market is not impacted as much as some of the hard hit ones such as. travel and leisure, but nobody is also insulated when there is a typhoon. For example, locally here in St. Louis, Enterprise rent a car, the largest car rental company in the US and in the world, has laid off more than 2,000 people, IT division included. I recall about 10 years ago I wrote a post about job search, and I like to update it, amid the time change and this specific pandemic change.

Some obvious things

No onsite interviews, remote or video interview only these days. Zoom is the most popular choice, and for developers there are some white-boarding online software. Realtime white boarding is actually quite challenging, from my personal experience, on both ends. It also depends on the friendliness of the interviewer, some interviewers like to be “above the interviewee”, they give the problem, did not like to talk or give hints, and expect a quick answer right away. On the other hand, there are some other interviewers who are more open and friendly, and sometimes they will throw a dog bone to rescue. As interviewer I always try to be the former, as I personally have been in the receiving end of “bad interviewers”, and don’t like the experience. Once at an onsite interview (long time ago), a guy who maybe quite sharp, made this comment: it sounds like you did much better than the other guys came in earlier, they really don’t know what they were talking about. And at least you put up this and that, blah blah blah… is this a compliment? I guess my English is already good enough to appreciate the underlying tone there. On the other hand, I can always appreciate good / friendly interviewers, once (not in coding or white boarding) during an onsite interview, the interviewer saw my schedule and saw that I was stuck in the little room all day, he offered let’s talk a walk, and talk in the company cafeteria. It was year early / winter 2005 as I recall, in middle of New Jersey.

Websites

Below two the most popular websites now.

Indeed: note Indeed.com is No. 1 in terms of the number of jobs. I found my last job and current job via Indeed.com. This is mind boggling when you think about it. I am not sure whether it exists in 2010. It’a an aggregator website. A bit like Google for information search.

LinkedIn: linkedIn became more meaningful too, I got a job offer in my last round job search and the lead is from LinkedIn. Many companies now post jobs at LinkedIn. Besides the number of jobs, we all know LinkedIn is the top 1 place that recruiters congregate. And as I built profile at LinkedIn, I also received more unsolicited messages or requests from mostly recruiters or website SEO people. Most recently I decided to be more discreet on accepting recruiters request. Most recruiters are young enthusiastic people and I bet they send out things blindly. This brings to another point.

Also, stackoverflow has a job portal, and some of the jobs are looking good too.

Recruiters

I think recruiters are still useful, if we are more discreet and we ask what we want. I have some recruiters friends from both ends as well: job search, or candidate technical screen. And I keep in touch with them from time to time, as a part of relationship building. Sometimes this could be a simple “hi” when the recruiter is in the hallway or in the office. I do understand, on linkedIn, or via database, sometime some younger recruiters will cold call (the reason I pick up the reason was probably the call from number is an agency I know). And we need to keep things in perspective that’s a part of their job and paycheck too. Also keep in mind we live in a small world especially in the St. Louis IT job market, and sometimes the table can turn quickly. I recall seeing a former coworker at two separate places (and I remember he was not being nice to me 🙂 I don’t have grudges against him, but I just know I probably won’t use him as reference, and vice versa.

Code Test

Not white-boarding or pairing either remote or on spot, but something like hacker rank, or filtered.ai. Those are okay as they are usually not overly difficult, they are fair test in other words. There is some random ones, which is usually some problem a tech lead, an architect came up with. And some of those can be nasty. Once I spent 24 hours on a problem, and could not solve it. I solved it a day later. Also noted the behavior type questions on filtered.ai or company recruiting website. Those are easy ones to score points, so don’t waste the opportunities. Usually they let you re-do if the first recording does not look good. The coding test, if done properly, you can run the unit test on the editor and you know it’s failed or passed.

(Update 05-19-2020) There are a lot of online code playground or white boarding tools for code testing on the spot. Those are mostly collaboration tools, with some syntax highlighting. But it’s usually not as powerful as the hacker rank or filterer.ai as the latter ones usually have the build-tests, so basically you will know your code is good enough or not by passing those tests (tests are usually hidden though). Tools such as code labstack are still pretty useful. One thing I am not sure is how they manage the sessions. From interviewer (hiring side) point of view, it maybe helpful to give a heads up if a quick code test is expected so that the candidate is aware. I have seen candidate just bail out without even trying. I have been on the receiving end of this kind of test as well. Again the interviewers friendliness (more precisely helpfulness, do they just want to see the candidate fail, or they want to be as human as possible) varies. (sample java code question here). Also JavaScript code playground such as codepen.io and jsbin.com .

My javascript code samples.

Last but not least, problem solving questions. One example: Suppose we have 8 balls: one is heavier than the other 7, the other 7 are identical. Now we have one balance (or scale), and we can put balls on two sides to weigh and compare. Use as few attempts as possible, to find the heavy ball? A follow up question is, if we have 2 or 3 attempts, how many balls can we handle (again one heavy ball with many identical lighter balls). 

About me. Also you may read about my other post on related topic.

Also, please note this guide on job search. I haven’t read the whole thing but it appears good. Much longer than this blog. Last but not least, this post is a good read too (Helen Anderson @helenanders26).

The Science Behind Making Software Engineering Interviews Truly Predictive of Job Performance by Geoff Roberts.

Categories
Software development

GCP Cloud SQL hibernate issue

Reading Time: < 1 minute

It complains the table does not exist when in the data.sql we were trying to insert some data. Turns out the table did exist but the default table name was lower case, while we were using Upper case both in the data.sql and the java hibernate entity. The fix is to add one line in the application.properties file. Note this is a spring boot app. Also note the data.sql was used to load initial data in spring boot.

spring.jpa.hibernate.naming.physical-strategy=org.hibernate.boot.model.naming.PhysicalNamingStrategyStandardImpl

I found out about it as I first work around the issue by doing something like shown in this article. But I was thinking this was not right. I was able to find out once I connect to the cloud sql db via proxy. Also refer to this stackoverflow discussion. 

DROP TABLE IF EXISTS employee;

CREATE TABLE employee (
  empId VARCHAR(10) NOT NULL,
  empName VARCHAR(100) NOT NULL
);

Also Spring Data

Spring data REST reference: this is by default will be shown in the root of the website.

the key seems to be adding this in pom:

<dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-data-rest</artifactId> </dependency>

Last but not least, to disable the end points or to show the available ends points for spring boot app, we can use actuator.

management.endpoints.web.exposure.include=mappings

We can show the end points at:

/actuator/mappings

Categories
401k and Personal Finance

Weekend thoughts: Zoom and Math

Reading Time: 2 minutes

For most Americans, Zoom meeting probably becomes the hottest potato in last few weeks, as we saw the pandemic situation got worse: New York, New Orleans, Detroit, Dallas, and so on. I started to using Zoom about a year ago when I started my new job, and the product experience was good. Note I have used many meeting software in the past, from Webex, Skype, GoToMeeting to google hangout, Slack, Microsoft Teams. Before Zoom GoToMeeting was my favorite. Skype probably is the worst. This is not a scientific comparison, mostly my gut feeling. Zoom is pretty standard in technology companies as well, even for interviewing (no more airplane ride, and uber ride, and hotel stay). Couple more points on Zoom. Zoom is not perfect in terms of security and privacy. And yours truly owns a few shares of Zoom. Last but not least, I do like Zoom’s founder, Eric S. Yuan (wiki English; wiki Chinese). It looks like he came to the US the same year I came. He is very much grounded person, even though is a billionaire now. I think he came from a humble background in China, which is common in China in those days (he was born in 1970, one year earlier than me).

But my point here is while Zoom is important, we should not equivalent zoom = learning or communicating or working. For that I am very much appreciative of this tweet by @DHH.

A more important task, in nowadays’ always-on culture, is the basics: reading, writing, thinking and so on. Otherwise we will end like this. Everyone makes mistakes, my point is not that Brian Williams makes stupid math mistakes. It’s more the issue two people talking about the talking points without realizing that their math is totally wrong. This is more issue in the America right now: the guy or the girl who have the microphone (in some sort of public facing position) usually don’t know what they are talking about. If in doubt, just look at the white house.

Last but not least, here is a stimulus check calculator developed by OmniCalculator.

Stimulus Check Calculator