Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
E
ecommerce-maven
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Ascend
ecommerce-maven
Commits
3cdd2228
Commit
3cdd2228
authored
May 12, 2021
by
Christopher Cottier
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
config adjustments
parent
d89cbfd8
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
7 deletions
+12
-7
AppConfig.java
...src/main/java/com/nisum/ecomservice/config/AppConfig.java
+12
-7
No files found.
ecom-service/src/main/java/com/nisum/ecomservice/config/AppConfig.java
View file @
3cdd2228
package
com
.
nisum
.
ecomservice
.
config
;
import
lombok.NoArgsConstructor
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Value
;
import
org.springframework.context.annotation.Bean
;
import
org.springframework.context.annotation.Configuration
;
import
org.springframework.core.env.Environment
;
@
Bean
@
NoArgsConstructor
public
class
AppConfig
{
@Value
(
"${orders.apiUrl}"
)
private
static
String
orderManagementUrl
;
@
Value
(
"${products.apiUrl}"
)
private
static
String
productsManagementUrl
;
@
Autowired
private
static
Environment
env
;
@Value
(
"${promos.apiUrl}"
)
private
static
String
promoManagementUrl
;
private
static
String
orderManagementUrl
=
env
.
getProperty
(
"orders.apiUrl"
);
private
static
String
productsManagementUrl
=
env
.
getProperty
(
"products.apiUrl"
);
private
static
String
promoManagementUrl
=
env
.
getProperty
(
"promos.apiUrl"
);
public
static
String
getOrderManagementUrl
()
{
return
orderManagementUrl
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment