Monday, June 17, 2019

Confluent platform installed

Much happy to have Confluent platform installed into Ubuntu Linux on the windows.

Thanks for this instruction.

I have real console on the browser.
And, also can play between windows and linux.



Ubuntun file system in the windows 10

It's in

C:\Users\[user name]\AppData\Local\Packages\CanonicalGroupLimited.UbuntuonWindows_79rhkp1fndgsc\LocalState\rootfs


Install jdk 8 into Ubuntun in the windows

Today, I would like to see if I can get Confluent platform working in the windows.

Trying to install JDK 8 now.

Learn the installation from
sudo add-apt-repository ppa:webupd8team/java 
sudo apt-get update 
sudo apt-get install oracle-java8-installer
  

However, it's not available as oracle tighten the jdk license recently.

Find another package

sudo apt-get update 
sudo apt-get install openjdk-8-jdk
  
I can get through  this installation

Sunday, June 16, 2019

Simple way to start up kafka in windows

In the kafka home folder, create a start script like

D:\apps\kafka_2.12-2.2.0\start.bat

start "Zookeeper" bin\windows\zookeeper-server-start.bat "config\zookeeper.properties"
start "Kafka" bin\windows\kafka-server-start.bat "config\server.properties"

Saturday, June 15, 2019

Kafka command line cheat sheet in windows

The following are the command line to startup kafka after installed.
In here, I have kafka unzip into d:\app.

Start kafka

cd D:\apps\kafka_2.12-2.2.0

bin\windows\zookeeper-server-start.bat "config\zookeeper.properties"

 
bin\windows\kafka-server-start.bat "config\server.properties"


Topic :

Create topic
bin\windows\kafka-topics.bat --create --bootstrap-server localhost:9092 --replication-factor 1 --partitions 1 --topic test   

List topic
bin\windows\kafka-topics.bat --list --bootstrap-server localhost:9092

bin\windows\kafka-topics.bat --describe --bootstrap-server localhost:9092


bin\windows\kafka-topics.bat --describe --bootstrap-server localhost:9092 --topic test


Producer:

console
bin\windows\kafka-console-producer.bat --broker-list localhost:9092 --topic test

Power shell to pipe apache web server access log
gc access.log | D:\dvp\kafka\kafka_2.12-2.2.0\bin\windows\kafka-console-producer.bat --broker-list localhost:9092 --topic test
 

gc access.log -wait -tail 1 | ... (Like linux tail -f access.log. Not working)

Configure apache httpd.conf
TransferLog "| d:/dvp/kafka/kafka_2.12-2.2.0/bin/windows/kafka-console-producer.bat --topic test --broker-list localhost:9092"

For both pipe and TransferLog, I really doubt the reliabliability.




Consumer:
Console
bin\windows\kafka-console-consumer.bat --bootstrap-server localhost:9092 --topic test --from-beginning

Friday, June 14, 2019

Starting hadoop in windows

If you run start-dfs.cmd and see the error like the following
... FATAL datanode.DataNode: Exception in secureMain
java.lang.RuntimeException: Error while running command to get file permissions : ExitCodeException exitCode=-1073741515
Or like the message in the stackoverflow : https://stackoverflow.com/questions/53341528/java-lang-runtimeexception-error-while-running-command-to-get-file-permissions#new-answer

Try to run winutils.exe in the command line.

If you see the following message :
The code execution cannot proceed because MSVCR100.dll was not found. ....




See how to fix in
https://www.lifewire.com/how-to-fix-msvcr100-dll-not-found-or-missing-errors-2623799 

Or google your solution.



Friday, February 22, 2019

Thursday, September 30, 2010

‘Do you want to view only the webpage content that was delivered securely?

I installed HttpWatch to inspect all my media. They were all in the same domain.

Took me a while to narrow the cause.
Javascript like this
obj.style.backgroundImage:url(myimage.gif);
wass trouble. Image url need need to be full path.

Tuesday, January 05, 2010

HTML P and FIELDSET

I have FIELDSET inside of P. If I set P style to hidden, FIELDSET is still shown.

Layout sample


This is a paragraph.


Group
ONE
TWO





Code

<P style="display:none; visibility:hidden;">
This is a paragraph.
<FIELDSET>
<LEGEND>Group</LEGEND>
ONE<BR>TWO
</FIELDSET>
</P>


The only solution I have is to use DIV instead of P.

Wednesday, May 20, 2009

ARIA resource

This is a good resource to learn ARIA. It lists all test case. From some sample test case pages, you can always see how to code it.

Monday, May 11, 2009

ARIA tab sample

Google around some tab samples :
University of Illinois and YUI, as I said before they were very complicated.

I believe my tab page design is very generic for web designers.
So this is my address book sample of Work and Home tab. I don't provide those complicated key navigation. All user need is just "tab" key.

My question is do I present "tab" role properly in my above design?

Friday, April 24, 2009

ARIA tablist and tab.

I though to make page AREA aware is just role attribute. When, I try to put together tablist and tab, then things are getting complicated. In IE8 with JAWS10, it read out all tabs are visited, so I guess there should be another attribute to tell which tab is on.

When I look at example. It's so complicated. A long long of javascript to create widget. This is really not simple and create burden to developer.

Tuesday, March 17, 2009

Alex Blog: Use text-algin:right for table

Alex Blog: Use text-algin:right for table

So what is the solution?
Below is sample of center table alignment.


<STYLE>
#container {text-align:center;}
#area {
width:600px; border:solid 1px black; text-align:left;
margin-left:auto; margin-right:auto;
}
</STYLE>
<DIV id="container">
<TABLE cellpadding="0" cellspacing="0" border="1" id="area">
<TR>
<TD>
This is a table.
</TD>
</TR>
</TABLE>
</DIV>


People also were talking about the solution in
here.

Thursday, February 26, 2009

CSS Comparison Chart

A nice comparison of CSS features in the latest/future browsers.
Summary

Calculation of support of currently displayed feature lists


Internet ExplorerFirefoxSafariChromeOpera
Past6.0: 4%2.0: 35%3.1: 47%0.2: 55%9.0: 38%
Present7.0: 12%3.0: 53%3.2: 69%1.0: 55%9.6: 62%
Near Future (2009)8.0: 31%3.1: 82%4.0: 85%1.*: 55%10.0: 68%
Future (2010 or later)9.0: 31%3.2: 92%4.*: 87%2.0: 79%10.*: 73%


At this point, IE is very behind and lock down all proprietary, like buggy "filter".

Tuesday, February 24, 2009

acid3 test

Today, Apple just release Safari 4 beta. The interface is much similar its sister Chrome. The top site view is impressed.

The only interface issue is "New tab (+)" is too close the minimized icon.

Try Acid test 3, score 100. Firefox 3.1 beta 2 is 93. IE 8 rc1 is 20. Looks like Apple put a lot of resource on it.

In the javascript canvas line chart test, Safari 4 beta is much smooth.

Got to try grammar test later.

Thursday, February 12, 2009

Vertical Text

Firefox 3.1 comes with css transform. I learn IE also has matrix equally.

Previously, I use writing-mode: tb-rl; filter: flipv fliph; for IE vertical text. Unfortunately, the text is very jagged after rotated. I decide to give matrix a try.


For IE, method 1



<style>
.vt {
writing-mode: tb-rl; filter: flipv fliph;
white-space:nowrap; font-size:12px; font-family:arial; letter-spacing:2px
}
</style>
<div class="vt">Vertical Text</div>




For IE, method 2



<style>
.displayretainer {
width:160px;text-align:right; z-index:25;
font-family:arial; font-size:12px; letter-spacing:2px
}
</style>

<div id="vt" class="displayretainer"
style="filter:progid:DXImageTransform.Microsoft.Matrix(M11='1.0', sizingmethod='auto expand');">
Vertical Text
</div>

<SCRIPT>
var deg2rad = Math.PI * 2 / 360;
function setRotation(obj, deg) {
var rad = deg * deg2rad;
var costheta = Math.cos(rad);
var sintheta = Math.sin(rad);

obj.filters.item(0).M11 = costheta;
obj.filters.item(0).M12 = -sintheta;
obj.filters.item(0).M21 = sintheta;
obj.filters.item(0).M22 = costheta;
}

setRotation(document.getElementById("vt"), 270)
</SCRIPT>


Still, the text is very jagged. The matrix filter is quite mathematical. Not sure any other attribute can smooth the font.

Monday, February 09, 2009

style vertical text

Previously, I have a vertical text sample.

Today, I replace the line chart y-axis label with it.
Unfortunately, IE does not come out good render.

I think the issue is in the filter (filter:flipv fliph;).

Monday, December 15, 2008

Insurance Scam

Another number I got was (304) 369 0968.

Many people complaint to it :
http://whocallsme.com/Phone-Number.aspx/3043690968

When I do phone number reversed look up. 3 records found :


Found 3 Results for (304) 369-0968 in WV
Residential Listing
Residential Listing
Jeffrey
Jeffrey, WV 25114
(304) 369-0968



Residential Listing
Residential Listing
Address Unlisted
Madison, WV 25130
(304) 369-0968





Residential Listing
Residential Listing
Address Unlisted
Jeffrey, WV 25114
(304) 369-0968




My guess this is cell phone number and those 3 people were prior owned this number.

Thursday, October 16, 2008

WinMerge - copy particular line

WinMerge is a great tool to compare.

There is still one feature I am still looking for.
In a block (multiple lines) of difference, I only want to merge a particular line.

Right now, I need to do three clicks
a. Select Line Difference
b. "Copy" it.
b. Go the other side, then "Paste".

I wish it can be done in one click.
I have latest WinMerge (2.10.0.0). I don't find this kind of feature. Not sure any kind of plugins can do that.

Wednesday, October 08, 2008

Photo Scam

When I picked up my phone, I heard "This is the second warning .....".

I really hate the phone scam. A lot of people get that, too.

Does people really need to do business like that? Got to stop that.

Monday, October 06, 2008

Use style sheet to control SELECT box height

I try to make a SELECT and DIV side by side with outline (style by border) in the same height; unfortunately, IE6 has always few pixels short.

I play it more. This situation only happens on heavy styling -- font is problem.
So, I try to set my SELECT with fixed size font (font-family:monospace,Courier,Courier New;), then both SELECT and DIV are in the same height.


<html>
<head>
<title>Control SELECT height</title>
<STYLE>
BODY, TABLE, TD, TH, P, OL, LI, INPUT, SELECT, BUTTON {font-family: Verdana, sans-serif; color:#343434}
</STYLE>
</head>

<body>

<TABLE width="100%" border="0" cellpading="0" cellspacing="0">
<TR valign="top">
<TD width="50%">
Avialable List <BR>
<SELECT SIZE="7" NAME="available" id="available" STYLE="width:100%; height:96px;">
</SELECT>
</TD>
<TD style="padding-left:1em">
Description<BR>
<DIV NAME="detailPanel" id="detailPanel" STYLE="width:100%; height:96px; border:1px solid blue">
 
</DIV>
</TD>
</TR>
</TABLE>
<BR><BR>

<TABLE width="100%" border="0" cellpading="0" cellspacing="0">
<TR valign="top">
<TD width="50%">
Avialable List <BR>
<SELECT SIZE="7" NAME="available" id="available" STYLE="width:100%; height:96px; font-size:12px; font-family: monospace,Courier,Courier New;">
</SELECT>
</TD>
<TD style="padding-left:1em">
Description<BR>
<DIV NAME="detailPanel" id="detailPanel" STYLE="width:100%; height:96px; border:1px solid blue">
 
</DIV>
</TD>
</TR>
</TABLE>
<BR><BR>

</body>
</html>


You can only see the result correctly in web, not open from file system.