Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[SCB-679] Support Cross-Origin Resource Sharing (CORS) #771

Merged
merged 3 commits into from Jun 22, 2018

Conversation

yhs0092
Copy link
Member

@yhs0092 yhs0092 commented Jun 20, 2018

Follow this checklist to help us incorporate your contribution quickly and easily:

  • Make sure there is a JIRA issue filed for the change (usually before you start working on it). Trivial changes like typos do not require a JIRA issue. Your pull request should address just this issue, without pulling in other changes.
  • Each commit in the pull request should have a meaningful subject line and body.
  • Format the pull request title like [SCB-XXX] Fixes bug in ApproximateQuantiles, where you replace SCB-XXX with the appropriate JIRA issue.
  • Write a pull request description that is detailed enough to understand what the pull request does, how, and why.
  • Run mvn clean install to make sure basic checks pass. A more thorough check will be performed on your pull request automatically.
  • If this contribution is large, please file an Apache Individual Contributor License Agreement.

See details in SCB-679

@coveralls
Copy link

coveralls commented Jun 20, 2018

Coverage Status

Coverage increased (+0.08%) to 87.266% when pulling 1975396 on yhs0092:support_cors into 9147c70 on apache:master.

@yhs0092
Copy link
Member Author

yhs0092 commented Jun 21, 2018

Wait for a sec, I need to add some fix in this pr.

@yhs0092
Copy link
Member Author

yhs0092 commented Jun 21, 2018

Done. Please review.

  • add alias to default executor thread pool, let users can use "servicecomb.executor.groupThreadPool" to specify executor thread poll.
  • add warning log to remind users of schema compatibility problem.

@@ -31,3 +31,10 @@ servicecomb:
address: http://127.0.0.1:30100
rest:
address: 127.0.0.1:8080
cors:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

cros?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Support Cross-Origin Resource Sharing (CORS)

+ "It's recommended to increment microservice version before deploying.", scSchemaMap.keySet());
+ "It's recommended to increment microservice version before deploying.",
scSchemaMap.keySet());
LOGGER.warn("ATTENTION: The schemas in new version are less than the old version, "
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this warning message is the same as above one. Anyway, it's fine to keep it.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is for the review opinion in another PR-757. I need to warn users to take care of compatibility issues.
I don't know how to describe it clearer with my poor English :P

@@ -36,5 +36,6 @@

<bean id="cse.executor.groupThreadPool" class="org.apache.servicecomb.core.executor.FixedThreadExecutor"></bean>
<alias name="cse.executor.groupThreadPool" alias="cse.executor.default"/>
<alias name="cse.executor.groupThreadPool" alias="servicecomb.executor.groupThreadPool"/>
<bean id="cse.executor.reactive" class="org.apache.servicecomb.core.executor.ReactiveExecutor"></bean>
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

cse.executor.reactive also need a alias?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

an alias has been added for cse.executor.reactive

@@ -32,12 +40,14 @@
private static HelloWorld helloWorld;

public static void main(String[] args) throws Exception {
System.setProperty("sun.net.http.allowRestrictedHeaders", "true");
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

a little strange
crossapp demo is to verify cross ServiceComb application

but no problem, we will merge most demo and integration test to one or two project in the future.

@liubao68 liubao68 merged commit 02df05d into apache:master Jun 22, 2018
@yhs0092 yhs0092 deleted the support_cors branch July 23, 2018 12:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants